GEOSX
Public Member Functions | List of all members
geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS > Class Template Referencefinal

Class to hold allocation capability for specific target derived types. More...

#include <ObjectCatalog.hpp>

Inheritance diagram for geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >:
Inheritance graph
[legend]

Public Member Functions

 CatalogEntry ()
 Default constructor.
 
 ~CatalogEntry () override
 Default destructor.
 
 CatalogEntry (CatalogEntry const &source)
 Copy constructor. More...
 
 CatalogEntry (CatalogEntry &&source)
 Move constructor. More...
 
CatalogEntryoperator= (CatalogEntry const &source)
 Copy assignment operator. More...
 
CatalogEntryoperator= (CatalogEntry &&source)
 Move assignment operator. More...
 
virtual std::unique_ptr< BASETYPE > allocate (ARGS... args) const override
 Create a new object that derives from BASETYPE. More...
 
- Public Member Functions inherited from geos::dataRepository::CatalogInterface< BASETYPE, ARGS... >
 CatalogInterface ()
 Default constructor.
 
 CatalogInterface (CatalogInterface const &)=default
 Copy constructor.
 
 CatalogInterface (CatalogInterface &&)=default
 Move constructor.
 
virtual ~CatalogInterface ()
 Default destructor.
 
CatalogInterfaceoperator= (CatalogInterface const &)=default
 Copy assignment operator. More...
 
CatalogInterfaceoperator= (CatalogInterface &&)=default
 Move assignment operator. More...
 

Additional Inherited Members

- Public Types inherited from geos::dataRepository::CatalogInterface< BASETYPE, ARGS... >
typedef std::unordered_map< std::string, std::unique_ptr< CatalogInterface< BASETYPE, ARGS... > > > CatalogType
 This is the type that will be used for the catalog. The catalog is actually instantiated in the BASETYPE.
 
- Static Public Member Functions inherited from geos::dataRepository::CatalogInterface< BASETYPE, ARGS... >
static CatalogTypegetCatalog ()
 Get the catalog from that is stored in the target base class. More...
 
static bool hasKeyName (std::string const &objectTypeName)
 Check if catalog contains a given key. More...
 
static std::list< typename CatalogType::key_type > getKeys ()
 Returns the product keys of the catalog. Keys are sorted in alphabetical order, case insensitive. More...
 
static std::unique_ptr< BASETYPE > factory (std::string const &objectTypeName, ARGS... args)
 Static method to create a new object that derives from BASETYPE. More...
 
static TYPE & catalogCast (BASETYPE &object)
 Downcast base type reference to derived type. More...
 

Detailed Description

template<typename BASETYPE, typename TYPE, typename ... ARGS>
class geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >

Class to hold allocation capability for specific target derived types.

Template Parameters
TYPEthis is the derived type
BASETYPEthis is the base class that TYPE derives from
ARGSconstructor arguments

Definition at line 241 of file ObjectCatalog.hpp.

Constructor & Destructor Documentation

◆ CatalogEntry() [1/2]

template<typename BASETYPE , typename TYPE , typename ... ARGS>
geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >::CatalogEntry ( CatalogEntry< BASETYPE, TYPE, ARGS > const &  source)
inline

Copy constructor.

Parameters
sourceobject to copy

Definition at line 275 of file ObjectCatalog.hpp.

◆ CatalogEntry() [2/2]

template<typename BASETYPE , typename TYPE , typename ... ARGS>
geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >::CatalogEntry ( CatalogEntry< BASETYPE, TYPE, ARGS > &&  source)
inline

Move constructor.

Parameters
sourceobject to move from

Definition at line 283 of file ObjectCatalog.hpp.

Member Function Documentation

◆ allocate()

template<typename BASETYPE , typename TYPE , typename ... ARGS>
virtual std::unique_ptr< BASETYPE > geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >::allocate ( ARGS...  args) const
inlineoverridevirtual

Create a new object that derives from BASETYPE.

Parameters
argsthese are the arguments to the constructor of the target type
Returns
a unique_ptr<BASETYPE> to the newly allocated class.

Implements geos::dataRepository::CatalogInterface< BASETYPE, ARGS... >.

Definition at line 313 of file ObjectCatalog.hpp.

◆ operator=() [1/2]

template<typename BASETYPE , typename TYPE , typename ... ARGS>
CatalogEntry& geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >::operator= ( CatalogEntry< BASETYPE, TYPE, ARGS > &&  source)
inline

Move assignment operator.

Parameters
sourceobject to move from
Returns
reference to this object

Definition at line 302 of file ObjectCatalog.hpp.

◆ operator=() [2/2]

template<typename BASETYPE , typename TYPE , typename ... ARGS>
CatalogEntry& geos::dataRepository::CatalogEntry< BASETYPE, TYPE, ARGS >::operator= ( CatalogEntry< BASETYPE, TYPE, ARGS > const &  source)
inline

Copy assignment operator.

Parameters
sourceobject to copy
Returns
reference to this object

Definition at line 292 of file ObjectCatalog.hpp.


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