![]() |
C++ Based OPC UA Client/Server/PubSub SDK
1.7.6.537
|
Management class for a PubSub configuration. More...
#include <pubsubconfiguration.h>
Inherits PubSubBase::PubSubObject.
Public Member Functions | |
PubSubConfiguration () | |
Creates an instance of the PubSub Configuration object. More... | |
UaStatus | loadConfiguration (const UaString &sConfigurationFile) |
Loads the PubSub configuration from a OPC UA Binary encoded file. More... | |
UaStatus | loadConfiguration (const UaString &sConfigurationFile, bool initializeStack) |
Loads the PubSub configuration from a OPC UA Binary encoded file. More... | |
UaStatus | loadConfiguration (const UaString &sConfigurationFile, bool initializeStack, const UaStringArray &targetNamepsaces) |
Loads the PubSub configuration from a OPC UA Binary encoded file. More... | |
UaStatus | loadConfiguration (const UaByteString &bsConfiguration, bool initializeStack) |
Loads the PubSub configuration from a ByteString containing the UABinaryFileDataType as extension object. More... | |
UaStatus | loadConfiguration (const UaByteString &bsConfiguration, bool initializeStack, const UaStringArray &targetNamepsaces) |
Loads the PubSub configuration from a ByteString containing the UABinaryFileDataType as extension object. More... | |
UaStatus | loadConfiguration (const UaStringArray &namespaceTable, const UaPubSubConfigurationDataType &pubSubConfiguration) |
Loads the PubSub configuration with a PubSubConfigurationDataType. More... | |
UaStatus | loadConfiguration (const UaStringArray &namespaceTable, const UaPubSubConfigurationDataType &pubSubConfiguration, bool initializeStack) |
Loads the PubSub configuration with a PubSubConfigurationDataType. More... | |
UaStatus | saveConfiguration (const UaString &sConfigurationFile) |
Saves the PubSub configuration to a OPC UA Binary encoded file. More... | |
UaStatus | saveConfiguration (UaByteString &bsConfiguration) |
Saves the PubSub configuration to a binary blob. More... | |
UaStatus | saveConfiguration (UaStringArray &namespaceTable, UaPubSubConfigurationDataType &pubSubConfiguration) |
Saves the PubSub configuration to a PubSubConfigurationDataType. More... | |
UaStatus | applyChanges () |
Apply all configuration changes to the current configuration. | |
void | clear () |
Clears the configuration. | |
UaStringArray | namespaceTable () const |
Returns the namespace table currently used by the configuration. More... | |
void | setNamespaceTable (const UaStringArray &namespaces) |
Sets the namespace table used by the configuration. More... | |
UaStatus | mapNamespaceTable (const UaStringArray &newNamespaceTable) |
Map the namespace indices of the configuration from the existing namespace table to the passed namespace table. More... | |
UaStructureDescriptions | structureDataTypes () const |
Returns the description of structure DataTypes used by the configuration. More... | |
void | setStructureDataTypes (const UaStructureDescriptions &structureDataTypes) |
Sets the description of structure DataTypes used by the configuration. More... | |
UaEnumDescriptions | enumDataTypes () const |
Returns the description of enumeration DataTypes used by the configuration. More... | |
void | setEnumDataTypes (const UaEnumDescriptions &enumDataTypes) |
Sets the description of enumeration DataTypes used by the configuration. More... | |
UaSimpleTypeDescriptions | simpleDataTypes () |
Returns the description of simple DataTypes used by the configuration. More... | |
void | setSimpleDataTypes (const UaSimpleTypeDescriptions &simpleDataTypes) |
Sets the description of simple DataTypes used by the configuration. More... | |
UaString | schemaLocation () const |
Returns the schema location used by the configuration. More... | |
void | setSchemaLocation (const UaString &schemaLocation) |
Sets the schema location used by the configuration. More... | |
UaKeyValuePairs | fileHeader () const |
Returns the additional header fields for the configuration. More... | |
void | setFileHeader (const UaKeyValuePairs &fileHeader) |
Sets the additional header fields for the configuration. More... | |
void | addFileHeader (const UaQualifiedName &key, const UaVariant &value) |
Add an entry to the additional header fields for the configuration. More... | |
bool | enabled () const |
Returns the enabled state of the PubSub configuration. | |
void | setEnabled (bool bEnabled) |
Sets the enabled state of the PubSub configuration. | |
PubSubConnection * | addConnection (TransportFacet transportFacet) |
Adds a PubSub connection to the configuration. | |
PubSubConnection * | addConnection_Datagram (const UaString &name, bool enabled, const UaVariant &publisherId, const UaString &address, const UaString &networkInterface, const UaString &discoveryAddress, TransportFacet transportFacet=PubSubObject::TransportFacet_PubSub_UDP_UADP) |
Adds a PubSub connection for a Datagram related transport to the configuration. More... | |
PubSubConnection * | addConnection_Broker (const UaString &name, bool enabled, const UaVariant &publisherId, const UaString &address, TransportFacet transportFacet) |
Adds a PubSub connection for a Broker related transport to the configuration. More... | |
PubSubConnection * | addConnection (const UaPubSubConnectionDataType &pubSubConnection) |
Adds a PubSub connection for the configuration. More... | |
PubSubConnection * | addConnection (const OpcUa_PubSubConnectionDataType &pubSubConnection) |
Adds a PubSub connection for the configuration. More... | |
OpcUa_UInt32 | connectionCount () const |
Returns the number of connection. | |
PubSubConnection * | getConnection (OpcUa_UInt32 index) |
Returns the connection at index or NULL if index is outside the valid range. | |
UaStatus | removeConnection (PubSubConnection *pConnection) |
Removes the passed connection. | |
PublishedDataSet * | addDataSet (const UaString &name, const UaStringArray &fieldNames, const UaNodeIdArray &publishedVariableNodeIds, const UaByteArray &publishedVariableBuiltInTypes, const UaInt32Array &publishedVariableValueRanks) |
Adds a PublishedDataSet to the configuration. More... | |
PublishedDataSet * | addDataSet (const UaString &name, const UaStringArray &fieldNames, const UaNodeIdArray &publishedVariableNodeIds, const UaByteArray &publishedVariableBuiltInTypes, const UaNodeIdArray &publishedVariableDataTypes, const UaInt32Array &publishedVariableValueRanks) |
Adds a PublishedDataSet to the configuration. More... | |
PublishedDataSet * | addDataSet (const UaString &name, const UaVersionTime &minorVersion, const UaVersionTime &majorVersion, const UaStringArray &fieldNames, const UaGuidArray &fieldIds, const UaNodeIdArray &publishedVariableNodeIds, const UaByteArray &publishedVariableBuiltInTypes, const UaNodeIdArray &publishedVariableDataTypes, const UaInt32Array &publishedVariableValueRanks) |
Adds a PublishedDataSet to the configuration. More... | |
PublishedDataSet * | addDataSet (const UaPublishedDataSetDataType &publishedDataSet) |
Adds a PublishedDataSet to the configuration. More... | |
PublishedDataSet * | addDataSet (const OpcUa_PublishedDataSetDataType &publishedDataSet) |
Adds a PublishedDataSet to the configuration. More... | |
OpcUa_UInt32 | dataSetCount () const |
Returns the number of DataSets. | |
PublishedDataSet * | getDataSet (OpcUa_UInt32 index) |
Returns the DataSet at index or NULL if index is outside the valid range. | |
UaStatus | removeDataSet (PublishedDataSet *pDataSet) |
Removes the passed DataSet. | |
void | setPubSubControlCallback (PubSubControlCallback *pPubSubControlCallback) |
Set PubSubControlCallback. | |
![]() | |
PubSubObject (PubSubResources *pPubSubResources, TransportFacet transportFacet, ConfigurationState configurationState) | |
Creates an instance of the PubSubObject. | |
UaMutex * | pConfigMutex () const |
Get the shared mutex for the complete configuration. | |
void | incrementErrorCounter () |
Increments the error counter for the PubSub object. | |
void | decrementErrorCounter () |
Decrements the error counter for the PubSub object. | |
![]() | |
ReferenceCounter () | |
construction | |
virtual | ~ReferenceCounter () |
destruction | |
Static Public Member Functions | |
static UaStatus | saveConfiguration (const UaString &sConfigurationFile, OpcUa_PubSubConfigurationDataType *pConfiguration, const UaStringArray &namespaces) |
Saves the PubSub configuration to an OPC UA Binary encoded file. More... | |
static UaStatus | saveConfiguration (const UaString &sConfigurationFile, OpcUa_PubSubConfigurationDataType *pConfiguration, const UaStringArray &namespaces, const UaStructureDescriptions &structureDataTypes, const UaEnumDescriptions &enumDataTypes, const UaSimpleTypeDescriptions &simpleDataTypes, const UaString &schemaLocation, const UaKeyValuePairs &fileHeader) |
Saves the PubSub configuration to an OPC UA Binary encoded file. More... | |
static UaStatus | saveConfiguration (UaByteString &bsConfiguration, OpcUa_PubSubConfigurationDataType *pConfiguration, const UaStringArray &namespaces) |
Saves the PubSub configuration to a binary blob. More... | |
Protected Member Functions | |
virtual | ~PubSubConfiguration () |
Destroys the PubSub Configuration object. | |
![]() | |
virtual | ~PubSubObject () |
Destroys the PubSubObject object. | |
Additional Inherited Members | |
![]() | |
enum | PubSubObjectType |
PubSub transport facet reflecting the defined TransportProfileUris. | |
enum | TransportFacet { TransportFacet_None = 0x0, TransportFacet_PubSub_UDP_UADP = 0x11, TransportFacet_PubSub_ETH_UADP = 0x21, TransportFacet_PubSub_AMQP_UADP = 0x31, TransportFacet_PubSub_MQTT_UADP = 0x41, TransportFacet_PubSub_CUSTOM = 0xFF } |
PubSub transport facet reflecting the defined TransportProfileUris. More... | |
enum | ConfigurationState { ConfigurationState_None, ConfigurationState_Deleted, ConfigurationState_InSyncWithStruct, ConfigurationState_New, ConfigurationState_Modified } |
PubSub configuration object state. More... | |
enum | PubSubHeaderLayout { PubSubHeaderLayout_Custom, PubSubHeaderLayout_UADP_PeriodicFixed, PubSubHeaderLayout_UADP_Dynamic } |
PubSub header configuration. More... | |
Management class for a PubSub configuration.
A PubSub configuration consist of the configuration for PubSub communication objects like PubSubConnection, WriterGroup, DataSetWriter and DataSetReader, the configuration of published DataSets and a table of namespaces used in the configuration.
The classes managing the configuration and the contained objects are reference counted. They are created with new and deleted with releaseReference().
PubSubBase::PubSubConfiguration::PubSubConfiguration | ( | ) |
Creates an instance of the PubSub Configuration object.
The class is reference counted and deletion is only possible with releaseReference().
PubSubConnection * PubSubBase::PubSubConfiguration::addConnection | ( | const UaPubSubConnectionDataType & | pubSubConnection | ) |
Adds a PubSub connection for the configuration.
[in] | pubSubConnection | Connection configuration structure |
PubSubConnection * PubSubBase::PubSubConfiguration::addConnection | ( | const OpcUa_PubSubConnectionDataType & | pubSubConnection | ) |
Adds a PubSub connection for the configuration.
[in] | pubSubConnection | Connection configuration structure |
PubSubConnection * PubSubBase::PubSubConfiguration::addConnection_Broker | ( | const UaString & | name, |
bool | enabled, | ||
const UaVariant & | publisherId, | ||
const UaString & | address, | ||
TransportFacet | transportFacet | ||
) |
Adds a PubSub connection for a Broker related transport to the configuration.
Fills a PubSubConnectionDataType with TransportSettings initialized to BrokerConnectionTransportDataType. The broker TransportSettings are initialized with empty strings.
The Address.NetworkInterface setting is initialized with an empty string.
[in] | name | Name of the connection |
[in] | enabled | Enable state of the connection |
[in] | publisherId | PublisherId for the connection |
[in] | address | Address used for the connection |
[in] | transportFacet | Transport facet for the connection. Valid options are AMQP-UADP and MQTT-UADP. |
PubSubConnection * PubSubBase::PubSubConfiguration::addConnection_Datagram | ( | const UaString & | name, |
bool | enabled, | ||
const UaVariant & | publisherId, | ||
const UaString & | address, | ||
const UaString & | networkInterface, | ||
const UaString & | discoveryAddress, | ||
TransportFacet | transportFacet = PubSubObject::TransportFacet_PubSub_UDP_UADP |
||
) |
Adds a PubSub connection for a Datagram related transport to the configuration.
Fills a PubSubConnectionDataType with TransportSettings initialized to DatagramConnectionTransportDataType. The Datagram TransportSetting DiscoveryAddress.NetworkInterface is configured with the networkInterface setting that is also used for the Connection Address.NetworkInterface.
[in] | name | Name of the connection |
[in] | enabled | Enable state of the connection |
[in] | publisherId | PublisherId for the connection |
[in] | address | Address used for the connection |
[in] | networkInterface | Network interface used for the Address and for Datagram transpor DiscoveryAddress |
[in] | discoveryAddress | Discovery address used for the Datagram transport settings |
[in] | transportFacet | Transport facet for the connection. Valid options are UDP-UADP and ETH-UADP. |
PublishedDataSet * PubSubBase::PubSubConfiguration::addDataSet | ( | const UaString & | name, |
const UaStringArray & | fieldNames, | ||
const UaNodeIdArray & | publishedVariableNodeIds, | ||
const UaByteArray & | publishedVariableBuiltInTypes, | ||
const UaInt32Array & | publishedVariableValueRanks | ||
) |
Adds a PublishedDataSet to the configuration.
[in] | name | Name of the DataSet |
[in] | fieldNames | Array of field names |
[in] | publishedVariableNodeIds | Array of NodeIds representing the published Variables wich are the source for the DataSet. The size of the array must match fieldNames. |
[in] | publishedVariableBuiltInTypes | Array of built-in types for the variables. The size of the array must match fieldNames. |
[in] | publishedVariableValueRanks | Array of value ranks for the variables. The size of the array must match fieldNames. |
PublishedDataSet * PubSubBase::PubSubConfiguration::addDataSet | ( | const UaString & | name, |
const UaStringArray & | fieldNames, | ||
const UaNodeIdArray & | publishedVariableNodeIds, | ||
const UaByteArray & | publishedVariableBuiltInTypes, | ||
const UaNodeIdArray & | publishedVariableDataTypes, | ||
const UaInt32Array & | publishedVariableValueRanks | ||
) |
Adds a PublishedDataSet to the configuration.
[in] | name | Name of the DataSet |
[in] | fieldNames | Array of field names |
[in] | publishedVariableNodeIds | Array of NodeIds representing the published Variables wich are the source for the DataSet. The size of the array must match fieldNames. |
[in] | publishedVariableBuiltInTypes | Array of built-in types for the variables. The size of the array must match fieldNames. |
[in] | publishedVariableDataTypes | Array of DataTypes. The size of the array must match fieldNames. If the array is empty, built-in types are used. |
[in] | publishedVariableValueRanks | Array of value ranks for the variables. The size of the array must match fieldNames. |
PublishedDataSet * PubSubBase::PubSubConfiguration::addDataSet | ( | const UaString & | name, |
const UaVersionTime & | minorVersion, | ||
const UaVersionTime & | majorVersion, | ||
const UaStringArray & | fieldNames, | ||
const UaGuidArray & | fieldIds, | ||
const UaNodeIdArray & | publishedVariableNodeIds, | ||
const UaByteArray & | publishedVariableBuiltInTypes, | ||
const UaNodeIdArray & | publishedVariableDataTypes, | ||
const UaInt32Array & | publishedVariableValueRanks | ||
) |
Adds a PublishedDataSet to the configuration.
[in] | name | Name of the DataSet |
[in] | minorVersion | Minor version for the DataSet |
[in] | majorVersion | Major version for the DataSet |
[in] | fieldNames | Array of field names |
[in] | fieldIds | Array of field IDs. The size of the array must match fieldNames. If the array is empty, the field IDs are generated. |
[in] | publishedVariableNodeIds | Array of NodeIds representing the published Variables wich are the source for the DataSet. The size of the array must match fieldNames. |
[in] | publishedVariableBuiltInTypes | Array of built-in types for the variables. The size of the array must match fieldNames. |
[in] | publishedVariableDataTypes | Array of DataTypes. The size of the array must match fieldNames. If the array is empty, built-in types are used. |
[in] | publishedVariableValueRanks | Array of value ranks for the variables. The size of the array must match fieldNames. |
PublishedDataSet * PubSubBase::PubSubConfiguration::addDataSet | ( | const UaPublishedDataSetDataType & | publishedDataSet | ) |
Adds a PublishedDataSet to the configuration.
[in] | publishedDataSet | Configuration structure for the new PublishedDataSet |
PublishedDataSet * PubSubBase::PubSubConfiguration::addDataSet | ( | const OpcUa_PublishedDataSetDataType & | publishedDataSet | ) |
Adds a PublishedDataSet to the configuration.
[in] | publishedDataSet | Configuration structure for the new PublishedDataSet |
void PubSubBase::PubSubConfiguration::addFileHeader | ( | const UaQualifiedName & | key, |
const UaVariant & | value | ||
) |
Add an entry to the additional header fields for the configuration.
If the key already exists, the value of the existing entry is overwritten.
UaEnumDescriptions PubSubBase::PubSubConfiguration::enumDataTypes | ( | ) | const |
Returns the description of enumeration DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
UaKeyValuePairs PubSubBase::PubSubConfiguration::fileHeader | ( | ) | const |
Returns the additional header fields for the configuration.
The header fields are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
Loads the PubSub configuration from a OPC UA Binary encoded file.
The file must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaString & | sConfigurationFile, |
bool | initializeStack | ||
) |
Loads the PubSub configuration from a OPC UA Binary encoded file.
The file must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
[in] | initializeStack | Flag indicating if the PubSub stack should be initialized with the configuration |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaString & | sConfigurationFile, |
bool | initializeStack, | ||
const UaStringArray & | targetNamepsaces | ||
) |
Loads the PubSub configuration from a OPC UA Binary encoded file.
The file must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
If the target namespaces are provided, the namespace index mapping is executed to convert any namespace index in the configuration to the corresponding target namesace index provided by the targetNamepsaces parameter.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
[in] | initializeStack | Flag indicating if the PubSub stack should be initialized with the configuration for communication |
[in] | targetNamepsaces | Target namespaces for the application. If the array is provided, a namespace index in the configuration is mapped to the target index. |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaByteString & | bsConfiguration, |
bool | initializeStack | ||
) |
Loads the PubSub configuration from a ByteString containing the UABinaryFileDataType as extension object.
The ByteString must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
[in] | bsConfiguration | Content of the PubSub configuration file |
[in] | initializeStack | Flag indicating if the PubSub stack should be initialized with the configuration for communication |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaByteString & | bsConfiguration, |
bool | initializeStack, | ||
const UaStringArray & | targetNamepsaces | ||
) |
Loads the PubSub configuration from a ByteString containing the UABinaryFileDataType as extension object.
The ByteString must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
If the target namespaces are provided, the namespace index mapping is executed to convert any namespace index in the configuration to the corresponding target namesace index provided by the targetNamepsaces parameter.
[in] | bsConfiguration | Content of the PubSub configuration file |
[in] | initializeStack | Flag indicating if the PubSub stack should be initialized with the configuration for communication |
[in] | targetNamepsaces | Target namespaces for the application. If the array is provided, a namespace index in the configuration is mapped to the target index. |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaStringArray & | namespaceTable, |
const UaPubSubConfigurationDataType & | pubSubConfiguration | ||
) |
Loads the PubSub configuration with a PubSubConfigurationDataType.
The ByteString must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
[in] | namespaceTable | Namespace table for the PubSub configuration structure |
[in] | pubSubConfiguration | PubSub configuration as structure |
UaStatus PubSubBase::PubSubConfiguration::loadConfiguration | ( | const UaStringArray & | namespaceTable, |
const UaPubSubConfigurationDataType & | pubSubConfiguration, | ||
bool | initializeStack | ||
) |
Loads the PubSub configuration with a PubSubConfigurationDataType.
The ByteString must contain an extension object with a UABinaryFileDataType. The UABinaryFileDataType must contain a PubSubConfigurationDataType structure with the PubSub configuration. The header of the UABinaryFileDataType provides a namespace table and data type definitions for the configuration data in the PubSubConfigurationDataType.
[in] | namespaceTable | Namespace table for the PubSub configuration structure |
[in] | pubSubConfiguration | PubSub configuration as structure |
[in] | initializeStack | Flag indicating if the PubSub stack should be initialized with the configuration for communication |
UaStatus PubSubBase::PubSubConfiguration::mapNamespaceTable | ( | const UaStringArray & | newNamespaceTable | ) |
Map the namespace indices of the configuration from the existing namespace table to the passed namespace table.
The index into the array is referred to as NamespaceIndex. The NamespaceIndex is used in NodeIds and QualifiedNames, rather than the longer namespace URI. NamespaceIndex 0 is reserved for the OPC UA namespace and it is not included in this array.
[in] | newNamespaceTable | New namespace array for the namespace table |
UaStringArray PubSubBase::PubSubConfiguration::namespaceTable | ( | ) | const |
Returns the namespace table currently used by the configuration.
The namespace table is part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
The index into the array is referred to as NamespaceIndex. The NamespaceIndex is used in NodeIds and QualifiedNames, rather than the longer namespace URI. NamespaceIndex 0 is reserved for the OPC UA namespace and it is not included in this array.
Saves the PubSub configuration to a OPC UA Binary encoded file.
The contend of the file is the UABinaryFileDataType UA binary encoded as ExtensionObject where the body of the UABinaryFileDataType is a UA binar encoded PubSubConfigurationDataType structure.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
UaStatus PubSubBase::PubSubConfiguration::saveConfiguration | ( | UaByteString & | bsConfiguration | ) |
Saves the PubSub configuration to a binary blob.
[out] | bsConfiguration | The UaByteString to store the config to |
UaStatus PubSubBase::PubSubConfiguration::saveConfiguration | ( | UaStringArray & | namespaceTable, |
UaPubSubConfigurationDataType & | pubSubConfiguration | ||
) |
Saves the PubSub configuration to a PubSubConfigurationDataType.
The contend of the file is the UABinaryFileDataType UA binary encoded as ExtensionObject where the body of the UABinaryFileDataType is a UA binar encoded PubSubConfigurationDataType structure.
[out] | namespaceTable | Namespace table for the PubSub configuration structure |
[out] | pubSubConfiguration | PubSub configuration as structure |
|
static |
Saves the PubSub configuration to an OPC UA Binary encoded file.
The contend of the file is the UABinaryFileDataType UA binary encoded as ExtensionObject where the body of the UABinaryFileDataType is a UA binar encoded PubSubConfigurationDataType structure.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
[in] | pConfiguration | Configuration structure to save |
[in] | namespaces | Namespaces for the configuration structure to save |
|
static |
Saves the PubSub configuration to an OPC UA Binary encoded file.
The contend of the file is the UABinaryFileDataType UA binary encoded as ExtensionObject where the body of the UABinaryFileDataType is a UA binar encoded PubSubConfigurationDataType structure.
[in] | sConfigurationFile | Path and name of PubSub configuration file |
[in] | pConfiguration | Configuration structure to save |
[in] | namespaces | Namespaces for the configuration structure to save |
[in] | structureDataTypes | The description of structure DataTypes used by the configuration |
[in] | enumDataTypes | The description of enumeration DataTypes used by the configuration |
[in] | simpleDataTypes | The description of simple DataTypes used by the configuration |
[in] | schemaLocation | Location of the schema file with the data types used for the configuration |
[in] | fileHeader | Additional header fields for the configuration |
|
static |
Saves the PubSub configuration to a binary blob.
[out] | bsConfiguration | The UaByteString to store the config to |
[in] | pConfiguration | Configuration structure to save |
[in] | namespaces | Namespaces for the configuration structure to save |
UaString PubSubBase::PubSubConfiguration::schemaLocation | ( | ) | const |
Returns the schema location used by the configuration.
The schema location is part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
The schema location is the reference to a file that contains the DataTypeSchemaHeader for the content of the UABinaryFileDataType. The schemaLocation is either a fully qualified URL or a URN which is a relative path to the file location. If the schemaLocation is provided, the DataType descriptions can be skipped but the namespaces used shall match the namespaces in the schema file.
void PubSubBase::PubSubConfiguration::setEnumDataTypes | ( | const UaEnumDescriptions & | enumDataTypes | ) |
Sets the description of enumeration DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
void PubSubBase::PubSubConfiguration::setFileHeader | ( | const UaKeyValuePairs & | fileHeader | ) |
Sets the additional header fields for the configuration.
The header fields are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
void PubSubBase::PubSubConfiguration::setNamespaceTable | ( | const UaStringArray & | namespaces | ) |
Sets the namespace table used by the configuration.
The index into the array is referred to as NamespaceIndex. The NamespaceIndex is used in NodeIds and QualifiedNames, rather than the longer namespace URI. NamespaceIndex 0 is reserved for the OPC UA namespace and it is not included in this array.
[in] | namespaces | New namespace array for the namespace table |
void PubSubBase::PubSubConfiguration::setSchemaLocation | ( | const UaString & | schemaLocation | ) |
Sets the schema location used by the configuration.
The schema location is part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
The schema location is the reference to a file that contains the DataTypeSchemaHeader for the content of the UABinaryFileDataType. The schemaLocation is either a fully qualified URL or a URN which is a relative path to the file location. If the schemaLocation is provided, the DataType descriptions can be skipped but the namespaces used shall match the namespaces in the schema file.
void PubSubBase::PubSubConfiguration::setSimpleDataTypes | ( | const UaSimpleTypeDescriptions & | simpleDataTypes | ) |
Sets the description of simple DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
void PubSubBase::PubSubConfiguration::setStructureDataTypes | ( | const UaStructureDescriptions & | structureDataTypes | ) |
Sets the description of structure DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
UaSimpleTypeDescriptions PubSubBase::PubSubConfiguration::simpleDataTypes | ( | ) |
Returns the description of simple DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.
UaStructureDescriptions PubSubBase::PubSubConfiguration::structureDataTypes | ( | ) | const |
Returns the description of structure DataTypes used by the configuration.
The DataTypes are part of the UABinaryFileDataType used as container for the PubSubConfiguration. It provides the schema header with namespaces and descriptions of data types used in the PubSubConfiguration.