-
Notifications
You must be signed in to change notification settings - Fork 5
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rds/kjw/function get swh uses associated with each building segment #1401
Merged
weilixu
merged 5 commits into
develop
from
RDS/KJW/function_get_SWH_uses_associated_with_each_building_segment
Sep 6, 2024
Merged
Changes from all commits
Commits
Show all changes
5 commits
Select commit
Hold shift + click to select a range
cf0b8ec
Create get_SWH_uses_associated_with_each_building_segment.md
KarenWGard d6cb177
Update get_SWH_uses_associated_with_each_building_segment.md
KarenWGard c2b73d1
Update get_SWH_uses_associated_with_each_building_segment.md
KarenWGard 891524c
Merge branch 'develop' of https://github.com/pnnl/ruleset-checking-to…
weilixu e82e3b4
update toc
weilixu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 28 additions & 0 deletions
28
docs/ruleset_functions/get_SWH_uses_associated_with_each_building_segment.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
## get_SWH_uses_associated_with_each_building_segment | ||
|
||
Description: This function gets all the SWH uses connected to a building segment. This function is primarily to encapsulate getting service water heating uses in one function so that if a change is made in the schema as to how service water heating use is specified, the RCT only needs to change in one place. | ||
|
||
Inputs: | ||
- **RMD** | ||
- **building_segment_id** - the id of the building segment | ||
|
||
Returns: | ||
- **swh_uses**: A list containing the ids of all service water heating uses associated with a building segment | ||
|
||
Function Call: | ||
- get_obj_by_id | ||
|
||
Data Lookup: None | ||
|
||
Logic: | ||
- get the building segment: `building_segment = get_obj_by_id(RMD, building_segment_id)` | ||
- create a blank list: `swh_uses = []` | ||
- look at each swh use: `for swh_use in building_segment.service_water_heating_uses:` | ||
- append the use to the list: `swh_uses.append(swh_use)` | ||
|
||
|
||
**Returns** swh_uses | ||
|
||
**[Back](../_toc.md)** | ||
|
||
**Notes:** |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see, so you are saying you would just have to update this function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes