OpenLB 1.8.1
Loading...
Searching...
No Matches
olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM > Class Template Reference

Efficient indexing of dynamically allocated data fields. More...

#include <data.h>

+ Collaboration diagram for olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >:

Public Member Functions

template<typename FIELD_TYPE >
bool provides () const
 Returns true iff FIELD_TYPE is registered.
 
template<typename FIELD_TYPE >
const AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * get () const
 Return read-only pointer to FIELD_TYPE data.
 
template<typename FIELD_TYPE >
AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * get ()
 Return pointer to FIELD_TYPE data.
 
template<typename FIELD_TYPE >
void track (AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > *fieldType)
 Track newly allocated FIELD_TYPE.
 

Detailed Description

template<typename T, typename DESCRIPTOR, Platform PLATFORM>
class olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >

Efficient indexing of dynamically allocated data fields.

May be specialized to manage platform specific access structures

Definition at line 261 of file data.h.

Member Function Documentation

◆ get() [1/2]

template<typename T , typename DESCRIPTOR , Platform PLATFORM>
template<typename FIELD_TYPE >
AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::get ( )
inline

Return pointer to FIELD_TYPE data.

FIELD_TYPE must be registered

Definition at line 288 of file data.h.

288 {
289 return _index.template get<FIELD_TYPE>();
290 }
const AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * get() const
Return read-only pointer to FIELD_TYPE data.
Definition data.h:280

References olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::get().

+ Here is the call graph for this function:

◆ get() [2/2]

template<typename T , typename DESCRIPTOR , Platform PLATFORM>
template<typename FIELD_TYPE >
const AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::get ( ) const
inline

Return read-only pointer to FIELD_TYPE data.

FIELD_TYPE must be registered

Definition at line 280 of file data.h.

280 {
281 return _index.template get<FIELD_TYPE>();
282 }

References olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::get().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ provides()

template<typename T , typename DESCRIPTOR , Platform PLATFORM>
template<typename FIELD_TYPE >
bool olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::provides ( ) const
inline

Returns true iff FIELD_TYPE is registered.

FIELD_TYPE is registered if track<FIELD_TYPE> was called previously

Definition at line 271 of file data.h.

271 {
272 return _index.template provides<FIELD_TYPE>();
273 }
bool provides() const
Returns true iff FIELD_TYPE is registered.
Definition data.h:271

References olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::provides().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ track()

template<typename T , typename DESCRIPTOR , Platform PLATFORM>
template<typename FIELD_TYPE >
void olb::FieldTypeRegistry< T, DESCRIPTOR, PLATFORM >::track ( AnyFieldTypeD< T, DESCRIPTOR, PLATFORM > * fieldType)
inline

Track newly allocated FIELD_TYPE.

Definition at line 294 of file data.h.

294 {
295 _index.template set<FIELD_TYPE>(fieldType);
296 }

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