ATLAS Offline Software
Public Member Functions | Private Types | Private Attributes | Friends | List of all members
CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false > Class Template Reference

#include <Helpers.h>

Collaboration diagram for CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >:

Public Member Functions

CUDA_HOS_DEV indexer size () const
 
CUDA_HOS_DEV T & operator[] (const indexer i)
 
CUDA_HOS_DEV const T & operator[] (const indexer i) const
 
CUDA_HOS_DEV SimpleContainer ()
 
CUDA_HOS_DEV SimpleContainer (T *other_array, const indexer sz)
 
template<class other_indexer , bool other_hold>
CUDA_HOS_DEV SimpleContainer (const SimpleContainer< T, other_indexer, Context, other_hold > &other)
 
CUDA_HOS_DEV SimpleContaineroperator= (const SimpleContainer &other)
 
template<class other_indexer , bool other_hold>
CUDA_HOS_DEV SimpleContaineroperator= (const SimpleContainer< T, other_indexer, Context, other_hold > &other)
 
CUDA_HOS_DEV operator const T * () const
 
CUDA_HOS_DEV operator T* ()
 

Private Types

using Manager = MemoryManagement< T, indexer >
 

Private Attributes

T * m_array
 
indexer m_size
 

Friends

template<class a , class b , class c , bool d>
class SimpleContainer
 

Detailed Description

template<class T, class indexer, class Context>
class CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >

Definition at line 962 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

Member Typedef Documentation

◆ Manager

template<class T , class indexer , class Context >
using CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::Manager = MemoryManagement<T, indexer>
private

Definition at line 968 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

Constructor & Destructor Documentation

◆ SimpleContainer() [1/3]

template<class T , class indexer , class Context >
CUDA_HOS_DEV CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::SimpleContainer ( )
inline

Definition at line 991 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

991  : m_array(nullptr), m_size(0)
992  {
993  }

◆ SimpleContainer() [2/3]

template<class T , class indexer , class Context >
CUDA_HOS_DEV CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::SimpleContainer ( T *  other_array,
const indexer  sz 
)
inline
Warning
We assume the pointer is in a valid memory location!

Definition at line 1000 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1000  : m_array(other_array), m_size(sz)
1001  {
1002  }

◆ SimpleContainer() [3/3]

template<class T , class indexer , class Context >
template<class other_indexer , bool other_hold>
CUDA_HOS_DEV CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::SimpleContainer ( const SimpleContainer< T, other_indexer, Context, other_hold > &  other)
inline

Definition at line 1007 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1008  {
1009  m_size = other.m_size;
1010  m_array = other.m_array;
1011  }

Member Function Documentation

◆ operator const T *()

template<class T , class indexer , class Context >
CUDA_HOS_DEV CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator const T * ( ) const
inline

Definition at line 1039 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1040  {
1041  return m_array;
1042  }

◆ operator T*()

template<class T , class indexer , class Context >
CUDA_HOS_DEV CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator T* ( )
inline

Definition at line 1044 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1045  {
1046  return m_array;
1047  }

◆ operator=() [1/2]

template<class T , class indexer , class Context >
CUDA_HOS_DEV SimpleContainer& CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator= ( const SimpleContainer< T, indexer, Context, false > &  other)
inline

Definition at line 1015 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1016  {
1017  if (this == &other)
1018  {
1019  return (*this);
1020  }
1021  else
1022  {
1023  m_array = other.m_array;
1024  m_size = other.m_size;
1025  return (*this);
1026  }
1027  }

◆ operator=() [2/2]

template<class T , class indexer , class Context >
template<class other_indexer , bool other_hold>
CUDA_HOS_DEV SimpleContainer& CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator= ( const SimpleContainer< T, other_indexer, Context, other_hold > &  other)
inline

Definition at line 1032 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

1033  {
1034  m_size = other.m_size;
1035  m_array = other.m_array;
1036  return (*this);
1037  }

◆ operator[]() [1/2]

template<class T , class indexer , class Context >
CUDA_HOS_DEV T& CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator[] ( const indexer  i)
inline

Definition at line 979 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

980  {
981  return m_array[i];
982  }

◆ operator[]() [2/2]

template<class T , class indexer , class Context >
CUDA_HOS_DEV const T& CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::operator[] ( const indexer  i) const
inline

Definition at line 984 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

985  {
986  return m_array[i];
987  }

◆ size()

template<class T , class indexer , class Context >
CUDA_HOS_DEV indexer CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::size ( ) const
inline

Definition at line 974 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

975  {
976  return m_size;
977  }

Friends And Related Function Documentation

◆ SimpleContainer

template<class T , class indexer , class Context >
template<class a , class b , class c , bool d>
friend class SimpleContainer
friend

Definition at line 970 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

Member Data Documentation

◆ m_array

template<class T , class indexer , class Context >
T* CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::m_array
private

Definition at line 965 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.

◆ m_size

template<class T , class indexer , class Context >
indexer CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::m_size
private

Definition at line 966 of file Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h.


The documentation for this class was generated from the following file:
fitman.sz
sz
Definition: fitman.py:527
lumiFormat.i
int i
Definition: lumiFormat.py:92
CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::m_array
T * m_array
Definition: Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h:964
InDetDD::other
@ other
Definition: InDetDD_Defs.h:16
CaloRecGPU::Helpers::SimpleContainer< T, indexer, Context, false >::m_size
indexer m_size
Definition: Calorimeter/CaloRecGPU/CaloRecGPU/Helpers.h:966