openDAQ
Open data acquisition platform
IPropertyObjectClassBuilder Struct Referenceabstract

The builder interface of Property object classes. Allows for their modification and building of Property object classes. More...

+ Inheritance diagram for IPropertyObjectClassBuilder:
+ Collaboration diagram for IPropertyObjectClassBuilder:

Detailed Description

The builder interface of Property object classes. Allows for their modification and building of Property object classes.

The configuration interface allows for modifying the list of properties, the class's name, parent, and the sorting order of properties. To build the Class, the build method is used.

Public Member Functions

virtual ErrCode INTERFACE_FUNC build (IPropertyObjectClass **propertyObjectClass)=0
 Builds and returns a Property object class using the currently set values of the Builder. More...
 
virtual ErrCode INTERFACE_FUNC setName (IString *className)=0
 Sets the name of the property class. More...
 
virtual ErrCode INTERFACE_FUNC getName (IString **className)=0
 Gets the name of the property class. More...
 
virtual ErrCode INTERFACE_FUNC setParentName (IString *parentName)=0
 Gets the name of the parent of the property class. More...
 
virtual ErrCode INTERFACE_FUNC getParentName (IString **parentName)=0
 Gets the name of the parent of the property class. More...
 
virtual ErrCode INTERFACE_FUNC addProperty (IProperty *property)=0
 Adds a property to the class. More...
 
virtual ErrCode INTERFACE_FUNC getProperties (IDict **properties)=0
 Gets the dictionary of properties. More...
 
virtual ErrCode INTERFACE_FUNC removeProperty (IString *propertyName)=0
 Removes a property with the given name from the class. More...
 
virtual ErrCode INTERFACE_FUNC setPropertyOrder (IList *orderedPropertyNames)=0
 Sets a custom order of properties as defined in the list of property names. More...
 
virtual ErrCode INTERFACE_FUNC getPropertyOrder (IList **orderedPropertyNames)=0
 Gets a custom order of properties as defined in the list of property names. More...
 
virtual ErrCode INTERFACE_FUNC getManager (ITypeManager **manager)=0
 Gets a type manager. More...
 
- Public Member Functions inherited from IBaseObject
virtual ErrCode INTERFACE_FUNC borrowInterface (const IntfID &intfID, void **obj) const =0
 Returns another interface which is supported by the object without incrementing the reference count. More...
 
virtual ErrCode INTERFACE_FUNC dispose ()=0
 Disposes all references held by the object. More...
 
virtual ErrCode INTERFACE_FUNC getHashCode (SizeT *hashCode)=0
 Returns hash code of the object. More...
 
virtual ErrCode INTERFACE_FUNC equals (IBaseObject *other, Bool *equal) const =0
 Compares object to another object for equality. More...
 
virtual ErrCode INTERFACE_FUNC toString (CharPtr *str)=0
 Returns a string representation of the object. More...
 
- Public Member Functions inherited from IUnknown
virtual ErrCode INTERFACE_FUNC queryInterface (const IntfID &intfID, void **obj)=0
 Returns another interface which is supported by the object and increments the reference count. More...
 
virtual int INTERFACE_FUNC addRef ()=0
 Increments the reference count for an interface on an object. More...
 
virtual int INTERFACE_FUNC releaseRef ()=0
 Decrements the reference count for an interface on an object. More...
 

Member Function Documentation

◆ addProperty()

virtual ErrCode INTERFACE_FUNC addProperty ( IProperty property)
pure virtual

Adds a property to the class.

Parameters
propertyThe property to be added.
Return values
OPENDAQ_ERR_ALREADYEXISTSif a property with the same name already added to the class.
OPENDAQ_ERR_INVALIDTYPEif the property is an object type and is not atomic.

The default value of object-type properties that are added to a class are frozen once added.

◆ build()

virtual ErrCode INTERFACE_FUNC build ( IPropertyObjectClass **  propertyObjectClass)
pure virtual

Builds and returns a Property object class using the currently set values of the Builder.

Parameters
[out]propertyObjectClassThe built Property object class.

◆ getManager()

virtual ErrCode INTERFACE_FUNC getManager ( ITypeManager **  manager)
pure virtual

Gets a type manager.

Parameters
[out]managera type manager

◆ getName()

virtual ErrCode INTERFACE_FUNC getName ( IString **  className)
pure virtual

Gets the name of the property class.

Parameters
[out]classNameThe name of the class.

◆ getParentName()

virtual ErrCode INTERFACE_FUNC getParentName ( IString **  parentName)
pure virtual

Gets the name of the parent of the property class.

Parameters
[out]parentNameThe parent class's name.

◆ getProperties()

virtual ErrCode INTERFACE_FUNC getProperties ( IDict **  properties)
pure virtual

Gets the dictionary of properties.

Parameters
[out]propertiesdictionary of properties

◆ getPropertyOrder()

virtual ErrCode INTERFACE_FUNC getPropertyOrder ( IList **  orderedPropertyNames)
pure virtual

Gets a custom order of properties as defined in the list of property names.

Parameters
[out]orderedPropertyNamesA list of names of properties. The order of the list is applied to the class's properties.

◆ removeProperty()

virtual ErrCode INTERFACE_FUNC removeProperty ( IString propertyName)
pure virtual

Removes a property with the given name from the class.

Parameters
propertyNameThe name of the property to be removed.
Return values
OPENDAQ_ERR_NOTFOUNDif the property with propertyName is not a member of the class.

◆ setName()

virtual ErrCode INTERFACE_FUNC setName ( IString className)
pure virtual

Sets the name of the property class.

Parameters
classNameThe name of the class.

◆ setParentName()

virtual ErrCode INTERFACE_FUNC setParentName ( IString parentName)
pure virtual

Gets the name of the parent of the property class.

Parameters
parentNameThe parent class's name.

◆ setPropertyOrder()

virtual ErrCode INTERFACE_FUNC setPropertyOrder ( IList orderedPropertyNames)
pure virtual

Sets a custom order of properties as defined in the list of property names.

Parameters
orderedPropertyNamesA list of names of properties. The order of the list is applied to the class's properties.

The list should contain names of properties available in the class. When retrieving the class's properties, they will be sorted in the order in which the names appear in the provided list. Any class properties not in the custom order are kept in insertion order at the end of the class's list of properties.