anatomist  5.1.2
3D neuroimaging data viewer
anatomist::ObjectConverter< T > Class Template Reference

Converts custom lower-level objects (generally aims objects) to Anatomist objects and vice versa. More...

#include <anatomist/object/objectConverter.h>

Static Public Member Functions

static AObjectaims2ana (T *x)
 Converts custom lower-level objects (generally aims objects) to Anatomist objects. More...
 
static AObjectaims2ana (carto::rc_ptr< T > x)
 this variant shares the converted object using ref-counting More...
 
static carto::rc_ptr< T > ana2aims (AObject *x, carto::Object options=carto::Object())
 extracts Aims object from an AObject (if any) More...
 
static bool setAims (AObject *x, carto::rc_ptr< T > y)
 set Aims contents in an existing AObject More...
 

Detailed Description

template<typename T>
class anatomist::ObjectConverter< T >

Converts custom lower-level objects (generally aims objects) to Anatomist objects and vice versa.

Definition at line 47 of file objectConverter.h.

Member Function Documentation

◆ aims2ana() [1/2]

template<typename T >
static AObject* anatomist::ObjectConverter< T >::aims2ana ( carto::rc_ptr< T >  x)
static

this variant shares the converted object using ref-counting

◆ aims2ana() [2/2]

template<typename T >
static AObject* anatomist::ObjectConverter< T >::aims2ana ( T *  x)
static

Converts custom lower-level objects (generally aims objects) to Anatomist objects.

After conversion, the new Anatomist object owns the input object, or deletes it if it needs to copy it: you mustn't delete it yourself unless conversion fails (no anatomist object can be constructed, aims2ana() returns null)

◆ ana2aims()

template<typename T >
static carto::rc_ptr<T> anatomist::ObjectConverter< T >::ana2aims ( AObject x,
carto::Object  options = carto::Object() 
)
static

extracts Aims object from an AObject (if any)

◆ setAims()

template<typename T >
static bool anatomist::ObjectConverter< T >::setAims ( AObject x,
carto::rc_ptr< T >  y 
)
static

set Aims contents in an existing AObject


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