First time here? Check out the Help page!
1 | initial version |
idfObject = OpenStudio::IdfObject::load(string_object)
returns an optional IdfObject, which is to say, it returns an object that may or may not actually have an IdfObject inside it. If there's an IdfObject inside it, then you use .get
to retrieve the actual IdfObject. There are additional methods available (e.g., .empty?
) to check if the object is there before trying to retrieve it.
All of this is described well in the Measure Writing Guide. Specifically look at the section: "OpenStudio Measures and the boost::optional Type".
2 | No.2 Revision |
idfObject = OpenStudio::IdfObject::load(string_object)
returns an optional IdfObject, which is to say, it returns an object that may or may not actually have an IdfObject inside it. If there's an IdfObject inside it, then you use .get
to retrieve the actual IdfObject. There are additional methods available (e.g., .empty?
) to check if the object is there before trying to retrieve it.
All of this is described well in the Measure Writing Guide. Specifically look at the section: "OpenStudio Measures and the boost::optional Type".
The Workspace
class is described here. Look at the "Detailed Description". As an approximation, the model object can be thought of as an OSM while the workspace object can be thought of as an IDF.
3 | No.3 Revision |
idfObject = OpenStudio::IdfObject::load(string_object)
returns an optional IdfObject, which is to say, it returns an object that may or may not actually have an IdfObject inside it. If there's an IdfObject inside it, then you use .get
to retrieve the actual IdfObject. There are additional methods available (e.g., .empty?
) to check if the object is there before trying to retrieve it.
All of this is described well in the Measure Writing Guide. Specifically look at the section: "OpenStudio Measures and the boost::optional Type".
The Workspace
class is described here. Look at the "Detailed Description". As an approximation, the model model
object can be thought of as an OSM while the workspace workspace
object can be thought of as an IDF.