1010data .NET SDK
TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString > Class Template Reference

Provides functionality for indexing into a sequence of INamed items. More...

Inherits IEnumerable< T >.

Public Member Functions

TOfInt IntNamed (String name)
 Get a TOfInt by name. More...
 
TOfLong LongNamed (String name)
 Get a TOfLong by name. More...
 
TOfInt128 Int128Named (String name)
 Get a TOfInt128 by name. More...
 
TOfDouble DoubleNamed (String name)
 Get a TOfDouble by name. More...
 
TOfString StringNamed (String name)
 Get a TOfString by name. More...
 

Public Attributes

readonly ICollection< String > Names
 The names of all the items in this IndexedSet.
 
readonly IEnumerable< TOfInt > Ints
 An enumerable of TOfInt data.
 
readonly IEnumerable< TOfLong > Longs
 An enumerable of TOfLong data.
 
readonly IEnumerable< TOfInt128 > Int128s
 An enumerable of TOfInt128 data.
 
readonly IEnumerable< TOfDouble > Doubles
 An enumerable of TOfDouble data.
 
readonly IEnumerable< TOfString > Strings
 An enumerable of TOfString data.
 

Properties

this[int i] [get]
 Index by position. More...
 
this[String name] [get]
 Index by name. More...
 

Detailed Description

Provides functionality for indexing into a sequence of INamed items.

Type Constraints
T :INamed 
TOfInt :T 
TOfLong :T 
TOfInt128 :T 
TOfDouble :T 
TOfString :T 

Member Function Documentation

TOfDouble TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.DoubleNamed ( String  name)

Get a TOfDouble by name.

Parameters
nameName of the item to get.
Returns
The item with the given name.
Exceptions
KeyNotFoundExceptionIf no item has the given name.
InvalidCastExceptionWhen the item exists but is not TOfDouble.
TOfInt128 TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.Int128Named ( String  name)

Get a TOfInt128 by name.

Parameters
nameName of the item to get.
Returns
The item with the given name.
Exceptions
KeyNotFoundExceptionIf no item has the given name.
InvalidCastExceptionWhen the item exists but is not TOfInt128.
TOfInt TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.IntNamed ( String  name)

Get a TOfInt by name.

Parameters
nameName of the item to get.
Returns
The item with the given name.
Exceptions
KeyNotFoundExceptionIf no item has the given name.
InvalidCastExceptionWhen the item exists but is not TOfInt.
TOfLong TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.LongNamed ( String  name)

Get a TOfLong by name.

Parameters
nameName of the item to get.
Returns
The item with the given name.
Exceptions
KeyNotFoundExceptionIf no item has the given name.
InvalidCastExceptionWhen the item exists but is not TOfLong.
TOfString TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.StringNamed ( String  name)

Get a TOfString by name.

Parameters
nameName of the item to get.
Returns
The item with the given name.
Exceptions
KeyNotFoundExceptionIf no item has the given name.
InvalidCastExceptionWhen the item exists but is not TOfStrings.

Property Documentation

T TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.this[int i]
get

Index by position.

Parameters
iWhat item to get.
Returns
The item at the i'th position.
Exceptions
ArgumentOutOfRangeExceptionUnless 0 <= i < this.IndexedData.Length.
T TenTenSDK.IndexedSequence< T, TOfInt, TOfLong, TOfInt128, TOfDouble, TOfString >.this[String name]
get

Index by name.

Parameters
nameName of the item to get.
Returns
The item at the named position.
Exceptions
KeyNotFoundExceptionWhen the name is an available key.