C# Class SharpNeat.Phenomes.MappingSignalArray

MappingSignalArray wraps a native array along with an indirection/mapping array. The resulting MappingSignalArray provides indexed access to the underlying native array via a level of indirection/mapping. See SignalArray for more info.
Inheritance: ISignalArray
Afficher le fichier Open project: colgreen/sharpneat Class Usage Examples

Méthodes publiques

Méthode Description
CopyFrom ( double sourceArray, int targetIndex ) : void

Copies all elements from the source array writing them into the current MappingSignalArray starting at the specified targetIndex.

CopyFrom ( double sourceArray, int targetIndex, int length ) : void

Copies length elements from the source array writing them to the current MappingSignalArray starting at the specified targetIndex.

CopyFrom ( double sourceArray, int sourceIndex, int targetIndex, int length ) : void

Copies length elements starting from sourceIndex on sourceArray to the current MappingSignalArray starting at the specified targetIndex.

CopyTo ( double targetArray, int targetIndex ) : void

Copies all elements from the current MappingSignalArray to the specified target array starting at the specified target Array index.

CopyTo ( double targetArray, int targetIndex, int length ) : void

Copies length elements from the current MappingSignalArray to the specified target array starting at the specified target Array index.

CopyTo ( double targetArray, int targetIndex, int sourceIndex, int length ) : void

Copies length elements from the current MappingSignalArray to the specified target starting from targetIndex on the target array and sourceIndex on the current source SignalArray.

MappingSignalArray ( double wrappedArray, int map ) : System.Diagnostics

Construct a SignalArray that wraps the provided wrappedArray.

Reset ( ) : void

Reset all array elements to zero.

this ( int index ) : double

Gets or sets the single value at the specified index. We assert that the index is within the defined range of the signal array. Throwing an exception would be more correct but the check would affect performance of problem domains with large I/O throughput.

Private Methods

Méthode Description
ValidateMapIndexes ( ) : bool

Validate the indexes within _map. Returns true if they are all valid (within the indexable range of _wrappedArray)

Method Details

CopyFrom() public méthode

Copies all elements from the source array writing them into the current MappingSignalArray starting at the specified targetIndex.
public CopyFrom ( double sourceArray, int targetIndex ) : void
sourceArray double The array to copy elements from.
targetIndex int The index into the current SignalArray at which copying begins.
Résultat void

CopyFrom() public méthode

Copies length elements from the source array writing them to the current MappingSignalArray starting at the specified targetIndex.
public CopyFrom ( double sourceArray, int targetIndex, int length ) : void
sourceArray double The array to copy elements from.
targetIndex int The index into the current SignalArray at which copying begins.
length int The number of elements to copy.
Résultat void

CopyFrom() public méthode

Copies length elements starting from sourceIndex on sourceArray to the current MappingSignalArray starting at the specified targetIndex.
public CopyFrom ( double sourceArray, int sourceIndex, int targetIndex, int length ) : void
sourceArray double The array to copy elements from.
sourceIndex int The sourceArray index at which copying begins.
targetIndex int The index into the current SignalArray at which copying begins.
length int The number of elements to copy.
Résultat void

CopyTo() public méthode

Copies all elements from the current MappingSignalArray to the specified target array starting at the specified target Array index.
public CopyTo ( double targetArray, int targetIndex ) : void
targetArray double The array to copy elements to.
targetIndex int The targetArray index at which copying to begins.
Résultat void

CopyTo() public méthode

Copies length elements from the current MappingSignalArray to the specified target array starting at the specified target Array index.
public CopyTo ( double targetArray, int targetIndex, int length ) : void
targetArray double The array to copy elements to.
targetIndex int The targetArray index at which storing begins.
length int The number of elements to copy.
Résultat void

CopyTo() public méthode

Copies length elements from the current MappingSignalArray to the specified target starting from targetIndex on the target array and sourceIndex on the current source SignalArray.
public CopyTo ( double targetArray, int targetIndex, int sourceIndex, int length ) : void
targetArray double The array to copy elements to.
targetIndex int The targetArray index at which copying begins.
sourceIndex int The index into the current SignalArray at which copying begins.
length int The number of elements to copy.
Résultat void

MappingSignalArray() public méthode

Construct a SignalArray that wraps the provided wrappedArray.
public MappingSignalArray ( double wrappedArray, int map ) : System.Diagnostics
wrappedArray double
map int
Résultat System.Diagnostics

Reset() public méthode

Reset all array elements to zero.
public Reset ( ) : void
Résultat void

this() public méthode

Gets or sets the single value at the specified index. We assert that the index is within the defined range of the signal array. Throwing an exception would be more correct but the check would affect performance of problem domains with large I/O throughput.
public this ( int index ) : double
index int
Résultat double