public sealed class ComplexMatrixRowCollection : ReadOnlyObservableCollection<ComplexMatrixRow>Public NotInheritable Class ComplexMatrixRowCollection
Inherits ReadOnlyObservableCollection(Of ComplexMatrixRow)public ref class ComplexMatrixRowCollection sealed : public ReadOnlyObservableCollection<ComplexMatrixRow^>[<SealedAttribute>]
type ComplexMatrixRowCollection =
class
inherit ReadOnlyObservableCollection<ComplexMatrixRow>
endInstantiation
You cannot directly instantiate a ComplexMatrixRowCollection. Instead, the collection of all rows in a ComplexMatrix instance can be obtained by calling AsRowCollection, or you can collect rows having specific indexes by calling AsRowCollection(IndexCollection). Such methods return a ComplexMatrixRowCollection object, whose items have type ComplexMatrixRow.
In the following example, the rows of a matrix are enumerated.
using System;
using System.Numerics;
namespace Novacta.Analytics.CodeExamples
{
public class ComplexRowsEnumeratorExample0
{
public void Main()
{
// Create a matrix.
var data = new Complex[8] {
new(1, -1), new(5, -5),
new(2, -2), new(6, -6),
new(3, -3), new(7, -7),
new(4, -4), new(8, -8)
};
var matrix = ComplexMatrix.Dense(4, 2, data, StorageOrder.RowMajor);
Console.WriteLine("Data matrix:");
Console.WriteLine(matrix);
Console.WriteLine();
// Get the collection of matrix rows.
var rows = matrix.AsRowCollection();
// Enumerate matrix rows.
foreach (var row in rows)
{
Console.WriteLine("Row {0}: ", row.Index);
Console.WriteLine(row);
}
}
}
}
// Executing method Main() produces the following output:
//
// Data matrix:
// ( 1, -1) ( 5, -5)
// ( 2, -2) ( 6, -6)
// ( 3, -3) ( 7, -7)
// ( 4, -4) ( 8, -8)
//
//
//
// Row 0:
// ( 1, -1) ( 5, -5)
// Row 1:
// ( 2, -2) ( 6, -6)
// Row 2:
// ( 3, -3) ( 7, -7)
// Row 3:
// ( 4, -4) ( 8, -8)| Count | Gets the number of elements contained in the ReadOnlyCollectionT instance. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| Item | Gets the element at the specified index. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| Items | Returns the IListT that the ReadOnlyCollectionT wraps. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| Matrix | Gets the Matrix whose rows this instance collects. |
| XDataColumn | Gets or sets the column index of the entries which are to be returned by the XData property of the rows in the collection. |
| YDataColumn | Gets or sets the column index of the entries which are to be returned by the YData property of the rows in the collection. |
| ZDataColumn | Gets or sets the column index of the entries which are to be returned by the ZData property of the rows in the collection. |
| Contains | Determines whether an element is in the ReadOnlyCollectionT. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| CopyTo | Copies the entire ReadOnlyCollectionT to a compatible one-dimensional Array, starting at the specified index of the target array. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object) |
| Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object) |
| GetEnumerator | Returns an enumerator that iterates through the ReadOnlyCollectionT. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| GetHashCode | Serves as the default hash function. (Inherited from Object) |
| GetType | Gets the Type of the current instance. (Inherited from Object) |
| IndexOf | Searches for the specified object and returns the zero-based index of the first occurrence within the entire ReadOnlyCollectionT. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object) |
| OnCollectionChanged | Raises the CollectionChanged event using the provided arguments. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| OnPropertyChanged | Raises the PropertyChanged event using the provided arguments. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| ToComplexMatrix | Converts from ComplexMatrixRowCollection to ComplexMatrix. |
| ToString | Returns a string that represents the current object. (Inherited from Object) |
| CollectionChanged | Occurs when an item is added or removed. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| PropertyChanged | Occurs when a property value changes. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| (ComplexMatrixRowCollection to ComplexMatrix) | Performs an implicit conversion from ComplexMatrixRowCollection to ComplexMatrix. |
| ICollectionTAdd | Adds an item to the ICollectionT. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListAdd | Adds an item to the IList. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| ICollectionTClear | Removes all items from the ICollectionT. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListClear | Removes all items from the IList. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| INotifyCollectionChangedCollectionChanged | Occurs when the collection changes. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| IListContains | Determines whether the IList contains a specific value. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| ICollectionCopyTo | Copies the elements of the ICollection to an Array, starting at a particular Array index. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IEnumerableGetEnumerator | Returns an enumerator that iterates through a collection. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListIndexOf | Determines the index of a specific item in the IList. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListTInsert | Inserts an item to the IListT at the specified index. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListInsert | Inserts an item to the IList at the specified index. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListIsFixedSize | Gets a value indicating whether the IList has a fixed size. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| ICollectionTIsReadOnly | Gets a value indicating whether the ICollectionT is read-only. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListIsReadOnly | Gets a value indicating whether the IList is read-only. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| ICollectionIsSynchronized | Gets a value indicating whether access to the ICollection is synchronized (thread safe). (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListTItem | Gets the element at the specified index. An NotSupportedException occurs if you try to set the item at the specified index. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListItem | Gets the element at the specified index. A NotSupportedException occurs if you try to set the item at the specified index. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| INotifyPropertyChangedPropertyChanged | Occurs when a property value changes. (Inherited from ReadOnlyObservableCollectionComplexMatrixRow) |
| ICollectionTRemove | Removes the first occurrence of a specific object from the ICollectionT. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListRemove | Removes the first occurrence of a specific object from the IList. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListTRemoveAt | Removes the IListT item at the specified index. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| IListRemoveAt | Removes the IList item at the specified index. This implementation always throws NotSupportedException. (Inherited from ReadOnlyCollectionComplexMatrixRow) |
| ICollectionSyncRoot | Gets an object that can be used to synchronize access to the ICollection. (Inherited from ReadOnlyCollectionComplexMatrixRow) |