Basic double matrix.
Inherits Rx::Interop::Runtime30::IMemory2D.
Public Member Functions | |
CRxArray2DBase () | |
CRxArray2DBase (size_t nRows, size_t nCols) | |
CRxArray2DBase (const CRxArray2DBase &xMatrix) | |
~CRxArray2DBase () | |
virtual void | CopyFrom (const IMemory2DAccess *pMemory) |
virtual void | CopyFrom (const IMemory2DAccess *pMemory)=0 |
Copies the memory block described by pMemory into this memory block. This memory block is automatically resized. The function throws an exception if the element sizes of the given memory block does not agree with the element size of this memory block. More... | |
virtual void | Delete () |
Deletes this memory block. More... | |
TValue * | GetDataPtr () |
const TValue * | GetDataPtr () const |
virtual size_t | GetElementSize () const |
Gets the element size. The memory block is made up of blocks of the given number of bytes. The function Length() returns the number of elements in the memory block, where each element is of the size given in GetElementSize(). For example, an array of 10 doubles has element size 8 and length 10. More... | |
virtual void * | GetPointer () |
Gets the pointer to the memory block. More... | |
virtual const void * | GetPointer () const |
Gets the pointer to memory. More... | |
virtual void | GetSize (size_t &nRows, size_t &nCols) const |
Gets the number of elements in the memory block. The total number of bytes allocated by the memory block is given by the nRows times nCols times the element size. More... | |
virtual bool | IsValid () const |
Query if this object is valid. This function returns also true if the object itself is valid but the memory block has size zero. More... | |
virtual void | New (size_t nRows, size_t nCols) |
Creates a new memory block of nRows times nCols elements. The size of an element is fixed by the implementation and can be read out with the function GetElementSize(). More... | |
TValue & | operator() (size_t nRow, size_t nCol) |
const TValue & | operator() (size_t nRow, size_t nCol) const |
CRxArray2DBase & | operator= (const CRxArray2DBase &xMatrix) |
virtual void | Reset () |
Reset all values in the memory block. The actual value the elements in the memory block are reset to depends on the implementation. More... | |
virtual void | Resize (size_t nRows, size_t nCols) |
Resizes the memory block to the given number of elements. The size of an element is fixed by the implementation and can be read out with the function GetElementSize(). More... | |
Protected Attributes | |
void * | m_pvData |
Rx::CRxArray2DBase< TValue >::CRxArray2DBase | ( | ) |
Rx::CRxArray2DBase< TValue >::CRxArray2DBase | ( | size_t | nRows, |
size_t | nCols | ||
) |
Rx::CRxArray2DBase< TValue >::CRxArray2DBase | ( | const CRxArray2DBase< TValue > & | xMatrix | ) |
Rx::CRxArray2DBase< TValue >::~CRxArray2DBase | ( | ) |
|
virtual |
|
pure virtualinherited |
Copies the memory block described by pMemory into this memory block. This memory block is automatically resized. The function throws an exception if the element sizes of the given memory block does not agree with the element size of this memory block.
pMemory | [in] The memory to copy into this memory block. |
|
virtual |
Deletes this memory block.
Implements Rx::Interop::Runtime30::IMemory2D.
TValue* Rx::CRxArray2DBase< TValue >::GetDataPtr | ( | ) |
const TValue* Rx::CRxArray2DBase< TValue >::GetDataPtr | ( | ) | const |
|
virtual |
Gets the element size. The memory block is made up of blocks of the given number of bytes. The function Length() returns the number of elements in the memory block, where each element is of the size given in GetElementSize(). For example, an array of 10 doubles has element size 8 and length 10.
Implements Rx::Interop::Runtime30::IMemory2DAccess.
|
inlinevirtual |
Gets the pointer to the memory block.
Implements Rx::Interop::Runtime30::IMemory2D.
|
inlinevirtual |
Gets the pointer to memory.
Implements Rx::Interop::Runtime30::IMemory2DAccess.
|
virtual |
Gets the number of elements in the memory block. The total number of bytes allocated by the memory block is given by the nRows times nCols times the element size.
Implements Rx::Interop::Runtime30::IMemory2DAccess.
|
virtual |
Query if this object is valid. This function returns also true if the object itself is valid but the memory block has size zero.
Implements Rx::Interop::Runtime30::IMemory2DAccess.
|
virtual |
Creates a new memory block of nRows times nCols elements. The size of an element is fixed by the implementation and can be read out with the function GetElementSize().
nRows | The amount of rows to allocate. |
nCols | The amount of cols to allocate. |
Implements Rx::Interop::Runtime30::IMemory2D.
TValue& Rx::CRxArray2DBase< TValue >::operator() | ( | size_t | nRow, |
size_t | nCol | ||
) |
const TValue& Rx::CRxArray2DBase< TValue >::operator() | ( | size_t | nRow, |
size_t | nCol | ||
) | const |
CRxArray2DBase& Rx::CRxArray2DBase< TValue >::operator= | ( | const CRxArray2DBase< TValue > & | xMatrix | ) |
|
virtual |
Reset all values in the memory block. The actual value the elements in the memory block are reset to depends on the implementation.
Implements Rx::Interop::Runtime30::IMemory2D.
|
virtual |
Resizes the memory block to the given number of elements. The size of an element is fixed by the implementation and can be read out with the function GetElementSize().
nRows | The amount of rows to allocate. |
nCols | The amount of cols to allocate. |
Implements Rx::Interop::Runtime30::IMemory2D.
|
protected |