.NET Based OPC UA Client/Server SDK  2.6.1.422
UnifiedAutomation.UaBase.ByteString Class Reference

Represents a byte string value. More...

Inherits IList< byte >, IComparable, IFormattable, and ICloneable.

Public Member Functions

 ByteString (IEnumerable< byte > bytes)
 Creates a byte string from an IEnumerable. More...
 
 ByteString (byte[] bytes)
 Creates a byte string from an array (does not copy the the array). More...
 
int IndexOf (byte item)
 Determines the index of a specific item in the T:System.Collections.Generic.IList`1. More...
 
void Insert (int index, byte item)
 Inserts an item to the T:System.Collections.Generic.IList`1 at the specified index. More...
 
void RemoveAt (int index)
 Removes the T:System.Collections.Generic.IList`1 item at the specified index. More...
 
void Add (byte item)
 Adds an item to the T:System.Collections.Generic.ICollection`1. More...
 
void Clear ()
 Removes all items from the T:System.Collections.Generic.ICollection`1. More...
 
bool Contains (byte item)
 Determines whether the T:System.Collections.Generic.ICollection`1 contains a specific value. More...
 
void CopyTo (byte[] array, int arrayIndex)
 Copies the elements of the T:System.Collections.Generic.ICollection`1 to an T:System.Array, starting at a particular T:System.Array index. More...
 
bool Remove (byte item)
 Removes the first occurrence of a specific object from the T:System.Collections.Generic.ICollection`1. More...
 
IEnumerator< byte > GetEnumerator ()
 Returns an enumerator that iterates through the collection. More...
 
object Clone ()
 Creates a deep copy of the object. More...
 
override bool Equals (object obj)
 Returns true if the object is equal to the instance. More...
 
override int GetHashCode ()
 Returns a hash code for the instance. More...
 
int CompareTo (object obj)
 Compares the instance to another object. More...
 
override string ToString ()
 Formats the object as a string. More...
 
string ToString (string format, IFormatProvider formatProvider)
 Formats the object as a string. More...
 
string Format ()
 Formats a node id as a string. More...
 
void Format (StringBuilder buffer)
 Formats the node ids as string and adds it to the buffer. More...
 

Static Public Member Functions

static int GetHashCode (byte[] array)
 Creates a hash of a byte array. More...
 
static ByteString Parse (string buffer)
 Converts a hexadecimal string to an array of bytes. More...
 
static bool IsNull (ByteString value)
 Checks if the byte string is null. More...
 
static bool IsNull (byte[] value)
 Checks if the byte string is null. More...
 
static implicit operator byte[] (ByteString value)
 Converts a ByteString to a byte array. More...
 
static operator ByteString (byte[] value)
 Converts a byte array to a ByteString. More...
 
static bool operator== (ByteString value1, byte[] value2)
 Compares a ByteString to a byte array. More...
 
static bool operator!= (ByteString value1, byte[] value2)
 Compares a ByteString to a byte array. More...
 

Static Public Attributes

static readonly ByteString Null = new ByteString()
 A constant resprenting a Null ByteString value. More...
 

Properties

byte this[int index] [get, set]
 Gets or sets the element at the specified index. More...
 
int Count [get]
 Gets the number of elements contained in the T:System.Collections.Generic.ICollection`1. More...
 
bool IsReadOnly [get]
 Gets a value indicating whether the T:System.Collections.Generic.ICollection`1 is read-only. More...
 

Detailed Description

Represents a byte string value.

Constructor & Destructor Documentation

UnifiedAutomation.UaBase.ByteString.ByteString ( IEnumerable< byte >  bytes)
inline

Creates a byte string from an IEnumerable.

UnifiedAutomation.UaBase.ByteString.ByteString ( byte[]  bytes)
inline

Creates a byte string from an array (does not copy the the array).

Member Function Documentation

void UnifiedAutomation.UaBase.ByteString.Add ( byte  item)
inline

Adds an item to the T:System.Collections.Generic.ICollection`1.

Parameters
itemThe object to add to the T:System.Collections.Generic.ICollection`1.
Exceptions
T:System.NotSupportedExceptionThe T:System.Collections.Generic.ICollection`1 is read-only.
void UnifiedAutomation.UaBase.ByteString.Clear ( )
inline

Removes all items from the T:System.Collections.Generic.ICollection`1.

Exceptions
T:System.NotSupportedExceptionThe T:System.Collections.Generic.ICollection`1 is read-only.
object UnifiedAutomation.UaBase.ByteString.Clone ( )
inline

Creates a deep copy of the object.

int UnifiedAutomation.UaBase.ByteString.CompareTo ( object  obj)
inline

Compares the instance to another object.

Parameters
objThe object to compare to this object
bool UnifiedAutomation.UaBase.ByteString.Contains ( byte  item)
inline

Determines whether the T:System.Collections.Generic.ICollection`1 contains a specific value.

Parameters
itemThe object to locate in the T:System.Collections.Generic.ICollection`1.
Returns
true if item is found in the T:System.Collections.Generic.ICollection`1; otherwise, false.
void UnifiedAutomation.UaBase.ByteString.CopyTo ( byte[]  array,
int  arrayIndex 
)
inline

Copies the elements of the T:System.Collections.Generic.ICollection`1 to an T:System.Array, starting at a particular T:System.Array index.

Parameters
arrayThe one-dimensional T:System.Array that is the destination of the elements copied from T:System.Collections.Generic.ICollection`1. The T:System.Array must have zero-based indexing.
arrayIndexThe zero-based index in array at which copying begins.
Exceptions
T:System.ArgumentNullExceptionarray is null.
Exceptions
T:System.ArgumentOutOfRangeExceptionarrayIndex is less than 0.
Exceptions
T:System.ArgumentExceptionarray is multidimensional. -or- arrayIndex is equal to or greater than the length of array . -or- The number of elements in the source T:System.Collections.Generic.ICollection`1 is greater than the available space from arrayIndex to the end of the destination array .
override bool UnifiedAutomation.UaBase.ByteString.Equals ( object  obj)
inline

Returns true if the object is equal to the instance.

string UnifiedAutomation.UaBase.ByteString.Format ( )
inline

Formats a node id as a string.

void UnifiedAutomation.UaBase.ByteString.Format ( StringBuilder  buffer)
inline

Formats the node ids as string and adds it to the buffer.

IEnumerator<byte> UnifiedAutomation.UaBase.ByteString.GetEnumerator ( )
inline

Returns an enumerator that iterates through the collection.

Returns
A T:System.Collections.Generic.IEnumerator`1 that can be used to iterate through the collection.
override int UnifiedAutomation.UaBase.ByteString.GetHashCode ( )
inline

Returns a hash code for the instance.

static int UnifiedAutomation.UaBase.ByteString.GetHashCode ( byte[]  array)
inlinestatic

Creates a hash of a byte array.

Parameters
array
Returns
The hash.
int UnifiedAutomation.UaBase.ByteString.IndexOf ( byte  item)
inline

Determines the index of a specific item in the T:System.Collections.Generic.IList`1.

Parameters
itemThe object to locate in the T:System.Collections.Generic.IList`1.
Returns
The index of item if found in the list; otherwise, -1.
void UnifiedAutomation.UaBase.ByteString.Insert ( int  index,
byte  item 
)
inline

Inserts an item to the T:System.Collections.Generic.IList`1 at the specified index.

Parameters
indexThe zero-based index at which item should be inserted.
itemThe object to insert into the T:System.Collections.Generic.IList`1.
Exceptions
T:System.ArgumentOutOfRangeExceptionindex is not a valid index in the T:System.Collections.Generic.IList`1.
Exceptions
T:System.NotSupportedExceptionThe T:System.Collections.Generic.IList`1 is read-only.
static bool UnifiedAutomation.UaBase.ByteString.IsNull ( ByteString  value)
inlinestatic

Checks if the byte string is null.

Parameters
valueThe value.
Returns
true if the specified value is null; otherwise, false.
static bool UnifiedAutomation.UaBase.ByteString.IsNull ( byte[]  value)
inlinestatic

Checks if the byte string is null.

Parameters
valueThe value.
Returns
true if the specified value is null; otherwise, false.
static implicit UnifiedAutomation.UaBase.ByteString.operator byte[] ( ByteString  value)
inlinestatic

Converts a ByteString to a byte array.

Parameters
valueThe value.
Returns
The result of the conversion.
static UnifiedAutomation.UaBase.ByteString.operator ByteString ( byte[]  value)
inlineexplicitstatic

Converts a byte array to a ByteString.

Parameters
valueThe value.
Returns
The result of the conversion.
static bool UnifiedAutomation.UaBase.ByteString.operator!= ( ByteString  value1,
byte[]  value2 
)
inlinestatic

Compares a ByteString to a byte array.

Parameters
value1The value1.
value2The value2.
Returns
The result of the operator.
static bool UnifiedAutomation.UaBase.ByteString.operator== ( ByteString  value1,
byte[]  value2 
)
inlinestatic

Compares a ByteString to a byte array.

Parameters
value1The value1.
value2The value2.
Returns
The result of the operator.
static ByteString UnifiedAutomation.UaBase.ByteString.Parse ( string  buffer)
inlinestatic

Converts a hexadecimal string to an array of bytes.

bool UnifiedAutomation.UaBase.ByteString.Remove ( byte  item)
inline

Removes the first occurrence of a specific object from the T:System.Collections.Generic.ICollection`1.

Parameters
itemThe object to remove from the T:System.Collections.Generic.ICollection`1.
Returns
true if item was successfully removed from the T:System.Collections.Generic.ICollection`1; otherwise, false. This method also returns false if item is not found in the original T:System.Collections.Generic.ICollection`1.
Exceptions
T:System.NotSupportedExceptionThe T:System.Collections.Generic.ICollection`1 is read-only.
void UnifiedAutomation.UaBase.ByteString.RemoveAt ( int  index)
inline

Removes the T:System.Collections.Generic.IList`1 item at the specified index.

Parameters
indexThe zero-based index of the item to remove.
Exceptions
T:System.ArgumentOutOfRangeExceptionindex is not a valid index in the T:System.Collections.Generic.IList`1.
Exceptions
T:System.NotSupportedExceptionThe T:System.Collections.Generic.IList`1 is read-only.
override string UnifiedAutomation.UaBase.ByteString.ToString ( )
inline

Formats the object as a string.

string UnifiedAutomation.UaBase.ByteString.ToString ( string  format,
IFormatProvider  formatProvider 
)
inline

Formats the object as a string.

Member Data Documentation

readonly ByteString UnifiedAutomation.UaBase.ByteString.Null = new ByteString()
static

A constant resprenting a Null ByteString value.

Property Documentation

int UnifiedAutomation.UaBase.ByteString.Count
get

Gets the number of elements contained in the T:System.Collections.Generic.ICollection`1.

Returns
The number of elements contained in the T:System.Collections.Generic.ICollection`1.
bool UnifiedAutomation.UaBase.ByteString.IsReadOnly
get

Gets a value indicating whether the T:System.Collections.Generic.ICollection`1 is read-only.

Returns
true if the T:System.Collections.Generic.ICollection`1 is read-only; otherwise, false.
byte UnifiedAutomation.UaBase.ByteString.this[int index]
getset

Gets or sets the element at the specified index.

Returns
The element at the specified index.
Exceptions
T:System.ArgumentOutOfRangeExceptionindex is not a valid index in the T:System.Collections.Generic.IList`1.
Exceptions
T:System.NotSupportedExceptionThe property is set and the T:System.Collections.Generic.IList`1 is read-only.

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