Workspace 6.21.5
Public Member Functions | List of all members
ArrayNdPermutation Class Referenceabstract

Acts as a permutation of an ArrayNd set, without having to copy the data. Is not specific to any data type.

#include <DataAnalysis/DataStructures/arrayndpermutation.h>

Inheritance diagram for ArrayNdPermutation:
[legend]

Public Member Functions

virtual ArrayNdgetAsArrayNd ()=0
 
virtual bool setBaseData (ArrayNd &data, const QStringList &orderedDimensions, bool ownsData=false)=0
 

Member Function Documentation

◆ getAsArrayNd()

virtual ArrayNd * getAsArrayNd ( )
pure virtual

Returns the permutation safely cast to an ArrayNd type. The caller does not take ownership of the ptr.

Implemented in ArrayNdPermutationTyped< T >.

◆ setBaseData()

virtual bool setBaseData ( ArrayNd data,
const QStringList orderedDimensions,
bool  ownsData = false 
)
pure virtual
Parameters
dataThe N-dimensional dataset which we are permuting.
orderedDimensionsThe dimensions that make up the permutation. The dimensions are permuted such that they match the order specified by this parameter.
ownsDataWhether or not this structure owns its data and should be responsible for cleaning it up.
Returns
true if the base data was set successfully. Will return false if the number of dimensions in orderedDimensions does not exactly match the number of dimensions in data, or if the data factory of data does not match the type of this data structure.

Sets the underlying data that we are permuting. Must be called before any of the other functions on the permutation will work correctly.

Implemented in ArrayNdPermutationTyped< T >.