#include "ComponentData.hpp"
Public Member Functions | |
virtual | ~ComponentData ()=default |
ComponentData (const ComponentData &other)=default | |
ComponentData (ComponentData &&other)=default | |
ComponentData & | operator= (const ComponentData &)=default |
ComponentData & | operator= (ComponentData &&)=default |
UUID | uuid () const |
UUID | versionUUID () const |
boost::optional< int > | creationTimestamp () const |
boost::optional< int > | versionTimestamp () const |
ModelObject | primaryComponentObject () const |
std::vector< ModelObject > | componentObjects () const |
ModelObject | getComponentObject (unsigned objectIndex) const |
UUID | createVersionUUID () |
unsigned | numComponentObjects () const |
Static Public Member Functions | |
static IddObjectType | iddObjectType () |
Related Functions | |
using | ComponentDataVector = std::vector< ComponentData > |
using | OptionalComponentData = boost::optional< ComponentData > |
ComponentData is a ModelObject that wraps the OpenStudio IDD object 'OS:ComponentData'.
It is used in Components to provide a contents list and data (unique identifiers and timestamps) that link the Component back to the Building Component Library (BCL). It is used in Models to indicate which objects are associated with which Components.
|
virtualdefault |
|
default |
|
default |
std::vector<ModelObject> openstudio::model::ComponentData::componentObjects | ( | ) | const |
Returns all of the ModelObjects that are part of this Component.
The primaryComponentObject() will be listed first.
UUID openstudio::model::ComponentData::createVersionUUID | ( | ) |
Creates and returns a new value for versionUUID().
boost::optional<int> openstudio::model::ComponentData::creationTimestamp | ( | ) | const |
Timestamp at time of creation (when the uuid was initially generated).
Unix timestamp from January 1, 1970 00:00 GMT, in seconds.
ModelObject openstudio::model::ComponentData::getComponentObject | ( | unsigned | objectIndex | ) | const |
Returns the ModelObject at objectIndex in the contents.
Throws an openstudio::Exception if objectIndex >= numComponentObjects.
|
static |
unsigned openstudio::model::ComponentData::numComponentObjects | ( | ) | const |
Returns the number of objects in the Component described by this object.
Must be >= 1.
|
default |
|
default |
ModelObject openstudio::model::ComponentData::primaryComponentObject | ( | ) | const |
Returns the primary object of this component, which defines the Component's overall type.
This method is equivalent to getComponentObject(0).
UUID openstudio::model::ComponentData::uuid | ( | ) | const |
The unique identifier of the component.
This identifier is generated on initial construction with ModelObject::createComponent, and then maintained as-is for the life of the Component. It is used to track the Component across multiple models, on disk (.osc and .osm), in the project::ProjectDatabase, and in local and online BCLs.
boost::optional<int> openstudio::model::ComponentData::versionTimestamp | ( | ) | const |
Timestamp of last versioning event (creation of versionUUID).
Unix timestamp from January 1, 1970 00:00 GMT, in seconds.
UUID openstudio::model::ComponentData::versionUUID | ( | ) | const |
|
related |
|
related |