UA Server SDK C++ Bundle  1.4.1.271
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
UaRegisteredServer Class Reference

Wrapper class for the UA stack structure OpcUa_RegisteredServer. More...

#include <uaregisteredserver.h>

Public Member Functions

 UaRegisteredServer ()
 Constructs an instance of the class UaRegisteredServer with empty default values.
 
 UaRegisteredServer (const UaRegisteredServer &other)
 Constructs an instance of the class UaRegisteredServer with values from another UaRegisteredServer object. More...
 
 UaRegisteredServer (const OpcUa_RegisteredServer &other)
 Constructs an instance of the class UaRegisteredServer with values from another OpcUa_RegisteredServer structure. More...
 
 UaRegisteredServer (const UaString &serverUri, const UaString &productUri, const UaLocalizedTextArray &serverNames, OpcUa_ApplicationType serverType, const UaString &gatewayServerUri, const UaStringArray &discoveryUrls, const UaString &semaphoreFilePath, OpcUa_Boolean isOnline)
 Constructs an instance of the class UaRegisteredServer with values provided in the constructor.
 
 UaRegisteredServer (const UaExtensionObject &extensionObject)
 Constructs an instance of the class UaRegisteredServer initialized with value from a UaExtensionObject. More...
 
 UaRegisteredServer (const OpcUa_ExtensionObject &extensionObject)
 Constructs an instance of the class UaRegisteredServer initialized with value from an OpcUa_ExtensionObject structure. More...
 
 ~UaRegisteredServer ()
 Destroys the UaRegisteredServer object.
 
void clear ()
 Clear the data of the UaRegisteredServer. More...
 
bool operator== (const UaRegisteredServer &other) const
 Compare two UaRegisteredServer if they are similar. More...
 
bool operator!= (const UaRegisteredServer &other) const
 Returns true if the other UaRegisteredServer is not equal to this. More...
 
UaRegisteredServeroperator= (const UaRegisteredServer &other)
 Assignment operator. More...
 
OpcUa_RegisteredServer * copy () const
 Copy UaRegisteredServer data to a newly allocated OpcUa_RegisteredServer. More...
 
void copyTo (OpcUa_RegisteredServer *pDst) const
 Copy UaRegisteredServer data to an existing OpcUa_RegisteredServer structure. More...
 
void attach (OpcUa_RegisteredServer *pValue)
 Attaches the data of the parameter pValue. More...
 
OpcUa_RegisteredServer * detach (OpcUa_RegisteredServer *pDst)
 Detaches the internal RegisteredServer structure from this class. More...
 

Static Public Member Functions

static OpcUa_RegisteredServer * clone (const OpcUa_RegisteredServer &source)
 Copy OpcUa_RegisteredServer data to a newly allocated OpcUa_RegisteredServer. More...
 
static void cloneTo (const OpcUa_RegisteredServer &source, OpcUa_RegisteredServer &copy)
 Copy OpcUa_RegisteredServer data to an existing OpcUa_RegisteredServer structure. More...
 

Detailed Description

Wrapper class for the UA stack structure OpcUa_RegisteredServer.

This class encapsulates the native OpcUa_RegisteredServer structure and handles memory allocation and cleanup for you. UaRegisteredServer uses implicit sharing to avoid needless copying and to boost the performance. Only if you modify a shared RegisteredServer it creates a copy for that (copy-on-write). So assigning another UaRegisteredServer or passing it as parameter needs constant time and is nearly as fast as assigning a pointer.

Constructor & Destructor Documentation

UaRegisteredServer::UaRegisteredServer ( const UaRegisteredServer other)

Constructs an instance of the class UaRegisteredServer with values from another UaRegisteredServer object.

Parameters
otherthe other UaRegisteredServer used to initialize the object
UaRegisteredServer::UaRegisteredServer ( const OpcUa_RegisteredServer &  other)

Constructs an instance of the class UaRegisteredServer with values from another OpcUa_RegisteredServer structure.

Parameters
otherthe other OpcUa_RegisteredServer used to initialize the object
UaRegisteredServer::UaRegisteredServer ( const UaExtensionObject extensionObject)

Constructs an instance of the class UaRegisteredServer initialized with value from a UaExtensionObject.

Parameters
extensionObjectthe extension object containing the RegisteredServer
UaRegisteredServer::UaRegisteredServer ( const OpcUa_ExtensionObject &  extensionObject)

Constructs an instance of the class UaRegisteredServer initialized with value from an OpcUa_ExtensionObject structure.

Parameters
extensionObjectthe extension object containing the RegisteredServer

Member Function Documentation

void UaRegisteredServer::attach ( OpcUa_RegisteredServer *  pValue)

Attaches the data of the parameter pValue.

Don't clear the data of pValue afterwards manually, because UaRegisteredServer is responsible for it now.

Parameters
[in]pValueParameter to attach to.
void UaRegisteredServer::clear ( )

Clear the data of the UaRegisteredServer.

OpcUa_RegisteredServer * UaRegisteredServer::clone ( const OpcUa_RegisteredServer &  source)
static

Copy OpcUa_RegisteredServer data to a newly allocated OpcUa_RegisteredServer.

Parameters
sourceSource to clone.
Returns
new copy.
void UaRegisteredServer::cloneTo ( const OpcUa_RegisteredServer &  source,
OpcUa_RegisteredServer &  copy 
)
static

Copy OpcUa_RegisteredServer data to an existing OpcUa_RegisteredServer structure.

Parameters
sourcethe source of the clone operation.
copythe destination of the clone operation.
OpcUa_RegisteredServer * UaRegisteredServer::copy ( ) const

Copy UaRegisteredServer data to a newly allocated OpcUa_RegisteredServer.

Returns
data to a newly allocated OpcUa_RegisteredServer.
void UaRegisteredServer::copyTo ( OpcUa_RegisteredServer *  pDst) const

Copy UaRegisteredServer data to an existing OpcUa_RegisteredServer structure.

Parameters
pDstthe destination of this copy operation.
OpcUa_RegisteredServer * UaRegisteredServer::detach ( OpcUa_RegisteredServer *  pDst)

Detaches the internal RegisteredServer structure from this class.

This way you take over the control of releasing the RegisteredServer data. If more than one reference exists, the data is copied to pDst instead of being detached.

Returns
If the function succeeds, pDst is returned, otherwise 0 is returned.
Parameters
[out]pDstPointer to OpcUa_RegisteredServer structure that receives the RegisteredServer data.
bool UaRegisteredServer::operator!= ( const UaRegisteredServer other) const

Returns true if the other UaRegisteredServer is not equal to this.

See Also
operator==
Parameters
otherthe UaRegisteredServer to compare.
Returns
true if other is not equal to this.
UaRegisteredServer & UaRegisteredServer::operator= ( const UaRegisteredServer other)

Assignment operator.

Parameters
otherthe UaRegisteredServer to assign.
Returns
Assignment operator.
bool UaRegisteredServer::operator== ( const UaRegisteredServer other) const

Compare two UaRegisteredServer if they are similar.

Parameters
otherthe UaRegisteredServer to compare.
Returns
true if similar, false if not.

The documentation for this class was generated from the following files: