PanNDE
All Classes Namespaces Functions Pages
Public Member Functions | List of all members
HostData::HostArray< T > Class Template Reference
Inheritance diagram for HostData::HostArray< T >:
PanNDE::Array< T >

Public Member Functions

T & at (int64_t idx) override
 
int64_t size () override
 
void resize (int64_t newsize) override
 
T * data () override
 
void copy (PanNDE::Array< T > *other) override
 
void copy (std::shared_ptr< PanNDE::Array< T >> other) override
 
void copy (PanNDE::CArray< T > &other) override
 
const PanNDE::CArray< T > getCArray () override
 
- Public Member Functions inherited from PanNDE::Array< T >
virtual void copy (std::shared_ptr< PanNDE::Array< T >> other)=0
 

Member Function Documentation

◆ at()

template<typename T >
T& HostData::HostArray< T >::at ( int64_t  idx)
inlineoverridevirtual

Get array value by reference.

Parameters
idxarray index to access

Implements PanNDE::Array< T >.

◆ copy() [1/3]

template<typename T >
void HostData::HostArray< T >::copy ( PanNDE::Array< T > *  other)
inlineoverridevirtual

Copy other array to the local array

Parameters
otherC-pointer to source array for copy.

Implements PanNDE::Array< T >.

◆ copy() [2/3]

template<typename T >
void HostData::HostArray< T >::copy ( PanNDE::CArray< T > &  other)
inlineoverridevirtual

Copy other array to the local array. This is not recommended for general use, CArray has no overrun protections. This is primarily for inter-process or device communications where low-level access is required.

Parameters
otherreference to Carray wrapped struct for copy.

Implements PanNDE::Array< T >.

◆ copy() [3/3]

template<typename T >
void HostData::HostArray< T >::copy ( std::shared_ptr< PanNDE::Array< T >>  other)
inlineoverride

Copy other array to the local array

Parameters
othershared pointer to source array for copy.

◆ data()

template<typename T >
T* HostData::HostArray< T >::data ( )
inlineoverridevirtual

Get C-pointer to head of array. Only use when low-level access is required.

Implements PanNDE::Array< T >.

◆ getCArray()

template<typename T >
const PanNDE::CArray<T> HostData::HostArray< T >::getCArray ( )
inlineoverridevirtual

Get array data as CArray struct. This is not recommended for general use, CArray has no overrun protections. This is primarily for inter-process or device communications where low-level access is required.

Implements PanNDE::Array< T >.

◆ resize()

template<typename T >
void HostData::HostArray< T >::resize ( int64_t  newsize)
inlineoverridevirtual

Resize array. Array contents not guaranteed to be preserved

Parameters
newsizenew size of array.

Implements PanNDE::Array< T >.

◆ size()

template<typename T >
int64_t HostData::HostArray< T >::size ( )
inlineoverridevirtual

Get array size.

Implements PanNDE::Array< T >.


The documentation for this class was generated from the following file: