C++ Based OPC UA Client/Server/PubSub SDK
1.7.9.586
|
Manages the description for an enumeration DataType. More...
#include <uaenumdefinition.h>
Inherits UaAbstractDefinition.
Public Member Functions | |
UaEnumDefinition () | |
Creates an instance. More... | |
UaEnumDefinition (const UaEnumDefinition &other) | |
Copies the UaEnumDefinition including all enum values. More... | |
UaEnumDefinition & | operator= (const UaEnumDefinition &other) |
Assignment operator. | |
bool | operator== (const UaEnumDefinition &other) const |
Checks whether two UaEnumDefinitions are equal. More... | |
bool | operator!= (const UaEnumDefinition &other) const |
Checks whether two UaEnumDefinitions are not equal. More... | |
virtual int | childrenCount () const |
Returns the number of enum values that are defined for the instance. More... | |
virtual void | clear () |
Clears the UaEnumDefinition including all enum values. More... | |
virtual bool | isNull () const |
Checks if the EnumDefinition is null. More... | |
UaEnumValue | child (int i) const |
Returns the EnumValue at position i. More... | |
void | addChild (const UaEnumValue &newChild) |
Adds a new child. More... | |
UaEnumValue | enumValue (int iValue) const |
Returns the EnumValue with value iValue. More... | |
UaEnumDefinitionDataType | getEnumDefinitionDataType () const |
Returns the definition of the enumeration DataType as EnumDefinitionDataType. More... | |
Public Member Functions inherited from UaAbstractDefinition | |
void | setDataTypeId (const UaNodeId &nodeId) |
Sets the DataTypeId of the UaAbstractDefinition. | |
UaNodeId | dataTypeId () const |
Returns the DataTypeId of the UaAbstractDefinition. More... | |
void | setName (const UaString &sName) |
Sets the Name of the UaAbstractDefinition. | |
UaString | name () const |
Returns the name of the UaAbstractDefinition. More... | |
void | setDocumentation (const UaLocalizedText &documentation) |
Sets the Documentation of the UaAbstractDefinition. | |
UaLocalizedText | documentation () const |
Returns the documentation of the UaAbstractDefinition. More... | |
void | setNamespace (const UaString &sNamespace) |
Sets the Namespace of the UaAbstractDefinition. | |
UaString | getNamespace () const |
Returns the NamespaceUri of the UaAbstractDefinition. More... | |
Additional Inherited Members | |
Protected Member Functions inherited from UaAbstractDefinition | |
UaAbstractDefinition (UaAbstractDefinitionPrivate *pBody) | |
Creates an instance. More... | |
Manages the description for an enumeration DataType.
Enumerations provide string representations of numeric values but the transport of the value is always done with the built-in data type Int32.
Each UaEnumValue is described by its name amd its integer value.
Enumerated DataTypes can be described using this class. This class can be used to add an enumerated DataType on server side as well as a description of available DataTypes in a server on client side.
UaEnumDefinition::UaEnumDefinition | ( | void | ) |
Creates an instance.
UaEnumDefinition::UaEnumDefinition | ( | const UaEnumDefinition & | other | ) |
Copies the UaEnumDefinition including all enum values.
void UaEnumDefinition::addChild | ( | const UaEnumValue & | newChild | ) |
Adds a new child.
The children are sorted by value.
UaEnumValue UaEnumDefinition::child | ( | int | i | ) | const |
Returns the EnumValue at position i.
|
virtual |
Returns the number of enum values that are defined for the instance.
Implements UaAbstractDefinition.
|
virtual |
Clears the UaEnumDefinition including all enum values.
Implements UaAbstractDefinition.
UaEnumValue UaEnumDefinition::enumValue | ( | int | iValue | ) | const |
Returns the EnumValue with value iValue.
If the EnumDefinition does not contain an EnumValue with value iValue, an empty UaEnumValue is returned.
UaEnumDefinitionDataType UaEnumDefinition::getEnumDefinitionDataType | ( | ) | const |
Returns the definition of the enumeration DataType as EnumDefinitionDataType.
|
virtual |
Checks if the EnumDefinition is null.
Reimplemented from UaAbstractDefinition.
bool UaEnumDefinition::operator!= | ( | const UaEnumDefinition & | other | ) | const |
Checks whether two UaEnumDefinitions are not equal.
If the definitions are created separately but have the same content, this method returns true.
bool UaEnumDefinition::operator== | ( | const UaEnumDefinition & | other | ) | const |
Checks whether two UaEnumDefinitions are equal.
If the definitions are created separately but have the same content, this method returns false.