.NET Based OPC UA Client/Server SDK  3.3.3.537
UnifiedAutomation.UaBase.Utils Class Reference

A class which generic helper functions that don't have a better place to be. More...

Static Public Member Functions

static uint IncrementIdentifier (ref long identifier)
 Increments a identifier (wraps around if max exceeded). More...
 
static int IncrementIdentifier (ref int identifier)
 Increments a identifier (wraps around if max exceeded). More...
 
static long GetTickCount ()
 Gets the tick count. More...
 
static void InitializeTickCounting ()
 Must be called at the start up of the process. Is called by ApplicationInstanceBase.Start. More...
 
static TimeZoneDataType GetTimeZoneInfo ()
 Returns the TimeZone information for the current local time. More...
 
static T ParseExtension< T > (IDictionary< XmlQualifiedName, byte[]> extensions, XmlQualifiedName elementName)
 Looks for an extension with the specified type and uses the DataContractSerializer to parse it. More...
 
static void UpdateExtension< T > (IDictionary< XmlQualifiedName, byte[]> extensions, XmlQualifiedName elementName, object value)
 Looks for an extension with the specified type and uses the DataContractSerializer to serializes its replacement. More...
 
static bool Match (string target, string pattern, bool caseSensitive)
 Checks if the target matches the patternet. More...
 
static object Clone (object value)
 Returns a deep copy of the value. More...
 
static bool IsEqual (object value1, object value2)
 Checks if two values are equal. More...
 
static XmlReaderSettings DefaultXmlReaderSettings ()
 Returns a new instance of XmlReaderSettings with default settings. More...
 

Properties

static long TimeBase [get]
 The time base used by UA encoder/decoders (Jan 1, 1601). More...
 

Detailed Description

A class which generic helper functions that don't have a better place to be.

Member Function Documentation

static object UnifiedAutomation.UaBase.Utils.Clone ( object  value)
static

Returns a deep copy of the value.

static XmlReaderSettings UnifiedAutomation.UaBase.Utils.DefaultXmlReaderSettings ( )
static

Returns a new instance of XmlReaderSettings with default settings.

Returns
static long UnifiedAutomation.UaBase.Utils.GetTickCount ( )
static

Gets the tick count.

Returns
The milliseconds since the process started.
static TimeZoneDataType UnifiedAutomation.UaBase.Utils.GetTimeZoneInfo ( )
static

Returns the TimeZone information for the current local time.

Returns
The TimeZone information for the current local time.
static uint UnifiedAutomation.UaBase.Utils.IncrementIdentifier ( ref long  identifier)
static

Increments a identifier (wraps around if max exceeded).

Parameters
identifierThe identifier to increment.
Returns
The incremented value.
static int UnifiedAutomation.UaBase.Utils.IncrementIdentifier ( ref int  identifier)
static

Increments a identifier (wraps around if max exceeded).

Parameters
identifierThe identifier to increment.
Returns
The incremented value.
static void UnifiedAutomation.UaBase.Utils.InitializeTickCounting ( )
static

Must be called at the start up of the process. Is called by ApplicationInstanceBase.Start.

static bool UnifiedAutomation.UaBase.Utils.IsEqual ( object  value1,
object  value2 
)
static

Checks if two values are equal.

static bool UnifiedAutomation.UaBase.Utils.Match ( string  target,
string  pattern,
bool  caseSensitive 
)
static

Checks if the target matches the patternet.

Parameters
targetThe target.
patternThe pattern.
caseSensitiveif set to true [case sensitive].
Returns
static T UnifiedAutomation.UaBase.Utils.ParseExtension< T > ( IDictionary< XmlQualifiedName, byte[]>  extensions,
XmlQualifiedName  elementName 
)
static

Looks for an extension with the specified type and uses the DataContractSerializer to parse it.

Template Parameters
TThe type of extension.
Parameters
extensionsThe list of extensions to search.
elementNameName of the element (use type name if null).
Returns
The deserialized extension. Null if an error occurs.

If the elementName is not null the type passed must support DataContract serialization or have the XmlRoot attribute defined.

static void UnifiedAutomation.UaBase.Utils.UpdateExtension< T > ( IDictionary< XmlQualifiedName, byte[]>  extensions,
XmlQualifiedName  elementName,
object  value 
)
static

Looks for an extension with the specified type and uses the DataContractSerializer to serializes its replacement.

Template Parameters
TThe type of the extension.
Parameters
extensionsThe list of extensions to update.
elementNameName of the element (use type name if null).
valueThe value.

Adds a new extension if the it does not already exist. Deletes the extension if the value is null. The containing element must use the name and namespace uri specified by the DataContractAttribute for the type.

Property Documentation

long UnifiedAutomation.UaBase.Utils.TimeBase
staticget

The time base used by UA encoder/decoders (Jan 1, 1601).


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