Class ArrayType<TLogixType>
A LogixType that represents an array of other logix types (either atomic or structure).
public sealed class ArrayType<TLogixType> : ArrayType, ILogixSerializable, IEnumerable<TLogixType>, IEnumerable where TLogixType : LogixType
Type Parameters
TLogixType
- Inheritance
-
ArrayType<TLogixType>
- Implements
-
IEnumerable<TLogixType>
- Inherited Members
Constructors
ArrayType(Array)
Creates a new ArrayType<TLogixType> initialized with the provided one dimensional array.
public ArrayType(Array array)
Parameters
arrayArrayThe one dimensional array to initialize the array type with.
Exceptions
- ArgumentNullException
arrayis null.- ArgumentException
arrayis empty, containsnullorNullTypeelements, or is an array of more than one logix type.
ArrayType(XElement)
public ArrayType(XElement element)
Parameters
elementXElementThe element to parse.
Exceptions
- ArgumentNullException
elementis null.- InvalidOperationException
elementdoes not have required attributes or child elements.
ArrayType(TLogixType[,,])
Creates a new ArrayType<TLogixType> initialized with the provided three dimensional array.
public ArrayType(TLogixType[,,] array)
Parameters
arrayTLogixType[,,]The three dimensional array to initialize the array type with.
Exceptions
- ArgumentNullException
arrayis null.- ArgumentException
arrayis empty, containsnullorNullTypeelements, or is an array of more than one logix type.
ArrayType(TLogixType[,])
Creates a new ArrayType<TLogixType> initialized with the provided two dimensional array.
public ArrayType(TLogixType[,] array)
Parameters
arrayTLogixType[,]The two dimensional array to initialize the array type with.
Exceptions
- ArgumentNullException
arrayis null.- ArgumentException
arrayis empty, containsnullorNullTypeelements, or is an array of more than one logix type.
ArrayType(TLogixType[])
Creates a new ArrayType<TLogixType> initialized with the provided one dimensional array.
public ArrayType(TLogixType[] array)
Parameters
arrayTLogixType[]The one dimensional array to initialize the array type with.
Exceptions
- ArgumentNullException
arrayis null.- ArgumentException
arrayis empty, containsnullorNullTypeelements, or is an array of more than one logix type.
Properties
this[ushort]
Gets the LogixType instance at the specified index.
public TLogixType this[ushort x] { get; set; }
Parameters
xushortThe index of the array element
Property Value
- TLogixType
Exceptions
- ArgumentOutOfRangeException
indexis out of range of the array.
this[ushort, ushort]
Gets the LogixType instance at the specified index.
public TLogixType this[ushort x, ushort y] { get; set; }
Parameters
Property Value
- TLogixType
Exceptions
- ArgumentOutOfRangeException
indexis out of range of the array.
this[ushort, ushort, ushort]
Gets the LogixType instance at the specified index.
public TLogixType this[ushort x, ushort y, ushort z] { get; set; }
Parameters
xushortThe x index of the array element
yushortThe y index of the array element
zushortThe z index of the array element
Property Value
- TLogixType
Exceptions
- ArgumentOutOfRangeException
indexis out of range of the array.
Methods
GetEnumerator()
Returns an enumerator that iterates through the collection.
public IEnumerator<TLogixType> GetEnumerator()
Returns
- IEnumerator<TLogixType>
An enumerator that can be used to iterate through the collection.
Operators
implicit operator ArrayType<TLogixType>(TLogixType[,,])
Implicitly converts the provided array of logix type objects to an ArrayType<TLogixType>.
public static implicit operator ArrayType<TLogixType>(TLogixType[,,] array)
Parameters
arrayTLogixType[,,]
Returns
- ArrayType<TLogixType>
A new ArrayType<TLogixType> containing the elements of the provided array.
implicit operator ArrayType<TLogixType>(TLogixType[,])
Implicitly converts the provided array of logix type objects to an ArrayType<TLogixType>.
public static implicit operator ArrayType<TLogixType>(TLogixType[,] array)
Parameters
arrayTLogixType[,]
Returns
- ArrayType<TLogixType>
A new ArrayType<TLogixType> containing the elements of the provided array.
implicit operator ArrayType<TLogixType>(TLogixType[])
Implicitly converts the provided array of logix type objects to an ArrayType<TLogixType>.
public static implicit operator ArrayType<TLogixType>(TLogixType[] array)
Parameters
arrayTLogixType[]
Returns
- ArrayType<TLogixType>
A new ArrayType<TLogixType> containing the elements of the provided array.