DualArray<T1, T2>
Maintains and synchronizes two arrays. Note: this is probably useless now that Tuples are part of the lang.spec.
Type parameters:
| T1 | |
| T2 |
Constructors
DualArray
#Create a new multi-array from collections.
Parameters:
| aItems (IEnumerable<T1>) | Collection of T1 items. |
| bItems (IEnumerable<T2>) | Collection of T2 items. |
DualArray
#public DualArray(T1 a, T2 b)
Create a new, singular pair dual array.
Parameters:
| a (T1) | |
| b (T2) |
Properties
Methods
Add
#public void Add(T1 a, T2 b)
Add a pair to this multi array.
Parameters:
| a (T1) | A value. |
| b (T2) | B value. |
ContainsA
#Gets whether a value equal to item is already part of the T1 array.
Parameters:
| item (T1) | Item to check. |
Returns: True if item is part of T1 array.
ContainsB
#Gets whether a value equal to item is already part of the T2 array.
Parameters:
| item (T2) | Item to check. |
Returns: True if item is part of T2 array.
EnsureCapacity
#Ensure the capacity of this multi-array is at least the given amount.
Parameters:
| capacity (int) | Required capacity. |
FindA
#Find the first occurence of a T1 item.
Parameters:
| item (T1) | Item to find. |
| startIndex (int) | First index to take into account. |
Returns: First index of matching item or -1.
FindA
#Find the first occurence of a T1 item.
Parameters:
| item (T1) | Item to find. |
Returns: First index of matching item or -1.
FindB
#Find the first occurence of a T2 item.
Parameters:
| item (T2) | Item to find. |
| startIndex (int) | First index to take into account. |
Returns: First index of matching item or -1.
FindB
#Find the first occurence of a T2 item.
Parameters:
| item (T2) | Item to find. |
Returns: First index of matching item or -1.