Skip to main content
Namespace: OpenTD.Results.Dataset
Assembly: OpenTD.Results.dll
A collection of DataArrays, with some metadata describing them.

Inheritance

object ← DataArrayCollection

Implements

IList<DataArray>, ICollection<DataArray>, IEnumerable<DataArray>, IEnumerable

Inherited Members

object.ToString(), object.Equals(object), object.Equals(object, object), object.ReferenceEquals(object, object), object.GetHashCode(), object.GetType(), object.MemberwiseClone()

Constructors

DataArrayCollection()

DataArrayCollection(IEnumerable<DataArray>)

Parameters

collection IEnumerable<DataArray>

DataArrayCollection(StandardDataSubtypes, IEnumerable<IEnumerable<double>>, UnitsData, IDataset, ItemIdentifier)

Parameters

subtype StandardDataSubtypes collection IEnumerable<IEnumerable<double>> units UnitsData sourceDataset IDataset sourceItem ItemIdentifier

DataArrayCollection(DataSubtype, IEnumerable<IEnumerable<double>>, UnitsData, IDataset, ItemIdentifier)

Parameters

subtype DataSubtype collection IEnumerable<IEnumerable<double>> units UnitsData sourceDataset IDataset sourceItem ItemIdentifier

DataArrayCollection(DataArrayCollection)

Parameters

collection DataArrayCollection

Properties

AutoCommenter

Property Value

AutoCommenter

AutoNamer

Property Value

AutoNamer

Comment

Property Value

string

Count

Gets the number of elements contained in the ICollection`1.

Property Value

int

DataItemCount

If all the DataArrays in the collection have the same number of items, this will equal that. Otherwise this will be -1.

Property Value

int

Dimension

If all the DataArrays in the collection have the same physical dimension, this will equal that. Otherwise this will be UnitsData.UnitsType.UNITS_NOT_SET.

Property Value

UnitsData.UnitsType

InternalSuggestedComment

Property Value

string

InternalSuggestedName

Property Value

string

IsReadOnly

Gets a value indicating whether the ICollection`1 is read-only.

Property Value

bool

MaxDataItemCount

The maximum item count found in the arrays of the collection.

Property Value

int

MinDataItemCount

The minimum item count found in the arrays of the collection.

Property Value

int

Name

Property Value

string

SourceDataItemIdentifiers

The SourceDataItemIdentifiers associated with the DataArrays in this collection.

Property Value

DataItemIdentifierCollection

SourceDataset

If all the DataArrays in the collection have the same SourceDataset, this will equal that. Otherwise this will be null.

Property Value

IDataset

SourceItem

If all the DataArrays in the collection have the same SourceItem, this will equal that. Otherwise this will be null.

Property Value

ItemIdentifier

SourceItemIdentifiers

The SourceItemIdentifiers associated with the DataArrays in this collection.

Property Value

ItemIdentifierCollection

SourceItemSubmodel

If all the DataArrays in the collection have the same SourceItem submodel, this will equal that. Otherwise this will be null.

Property Value

string

Subtype

If all the DataArrays in the collection have the same data subtype, this will equal that. Otherwise this will be null.

Property Value

DataSubtype

this[int]

Gets or sets the element at the specified index.

Property Value

DataArray

Exceptions

ArgumentOutOfRangeException index is not a valid index in the IList`1. NotSupportedException The property is set and the IList`1 is read-only.

Methods

Add(DataArray)

Adds an item to the ICollection`1.

Parameters

x DataArray

Exceptions

NotSupportedException The ICollection`1 is read-only.

AddRange(IEnumerable<DataArray>)

Parameters

collection IEnumerable<DataArray>

Clear()

Removes all items from the ICollection`1.

Exceptions

NotSupportedException The ICollection`1 is read-only.

Contains(DataArray)

Determines whether the ICollection`1 contains a specific value.

Parameters

item DataArray The object to locate in the ICollection`1.

Returns

bool true if item is found in the ICollection`1; otherwise, false.

CopyTo(DataArray[], int)

Copies the elements of the ICollection`1 to an Array, starting at a particular Array index.

Parameters

array DataArray[] The one-dimensional Array that is the destination of the elements copied from ICollection`1. The Array must have zero-based indexing. arrayIndex int The zero-based index in array at which copying begins.

Exceptions

ArgumentNullException array is null. ArgumentOutOfRangeException arrayIndex is less than 0. ArgumentException The number of elements in the source ICollection`1 is greater than the available space from arrayIndex to the end of the destination array.

Filter(DataItemIdentifierCollection)

Parameters

dataItems DataItemIdentifierCollection

Returns

DataArrayCollection

GetEnumerator()

Returns an enumerator that iterates through the collection.

Returns

IEnumerator<DataArray> An enumerator that can be used to iterate through the collection.

GetSelfSuggestedComment()

Returns

string

GetSelfSuggestedName()

Returns

string

GetTranspose()

Returns

DataArrayCollection

GetValues()

Returns

List<List<double>>

GetValues(UnitsData)

Parameters

units UnitsData

Returns

List<List<double>>

IndexOf(DataArray)

Determines the index of a specific item in the IList`1.

Parameters

item DataArray The object to locate in the IList`1.

Returns

int The index of item if found in the list; otherwise, -1.

Insert(int, DataArray)

Inserts an item to the IList`1 at the specified index.

Parameters

index int The zero-based index at which item should be inserted. item DataArray The object to insert into the IList`1.

Exceptions

ArgumentOutOfRangeException index is not a valid index in the IList`1. NotSupportedException The IList`1 is read-only.

InsertRange(int, IEnumerable<DataArray>)

Parameters

index int collection IEnumerable<DataArray>

Remove(DataArray)

Removes the first occurrence of a specific object from the ICollection`1.

Parameters

x DataArray

Returns

bool true if item was successfully removed from the ICollection1; otherwise, [false](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool). This method also returns [false](https://learn.microsoft.com/dotnet/csharp/language-reference/builtin-types/bool) if <code className="paramref">item</code> is not found in the original ICollection1.

Exceptions

NotSupportedException The ICollection`1 is read-only.

RemoveAt(int)

Removes the IList`1 item at the specified index.

Parameters

index int The zero-based index of the item to remove.

Exceptions

ArgumentOutOfRangeException index is not a valid index in the IList`1. NotSupportedException The IList`1 is read-only.

RemoveRange(int, int)

Parameters

index int count int

ToString()

Returns a string that represents the current object.

Returns

string A string that represents the current object.

See Also

IAutoName, ICollection<T>, IEnumerable<T>, IList<T>