WARPXM v1.10.0
Loading...
Searching...
No Matches
WxCreatorMap< B > Class Template Reference

#include <wxcreator.h>

Inheritance diagram for WxCreatorMap< B >:
WxCreatorMapBase< B >

Static Public Member Functions

static B * getNew (const std::string &nm)
 Get a new object whose creator has the given name and base class has a default constructor.
 
static B * getNew (const std::string &nm, const WmConstOpaquePtr &parentPointer)
 Get a new object whose creator has the given name and base class has a constructor taking one WxAny argument for parentPointer.
 
static const std::string getRegisteredName (const std::type_info &type)
 Returns the first registered name string associated with a particular derived type.
 
- Static Public Member Functions inherited from WxCreatorMapBase< B >
static wxm::detail::creator_baseaddCreator (const std::string &nm, wxm::detail::creator_base *b)
 Add a new creator object into the list of available creators for base classes that have default constructor.
 
static wxm::detail::creator_baseaddCreatorForChildren (const std::string &nm, wxm::detail::creator_base *b)
 Add a new creator object into the list of available creators for base classes that have a parent pointer constructor.
 
static void removeCreatorForDefault (const std::string &nm)
 Remove a creator from the list of default constructor creators.
 
static void removeCreatorForChild (const std::string &nm)
 Remove a creator from the list of parent pointer constructor creators.
 

Member Function Documentation

◆ getNew() [1/2]

template<class B >
static B * WxCreatorMap< B >::getNew ( const std::string &  nm)
inlinestatic

Get a new object whose creator has the given name and base class has a default constructor.

The returned object points to the base class.

Parameters
nmName of the creator.
Returns
pointer to new instance as a base class pointer

◆ getNew() [2/2]

template<class B >
static B * WxCreatorMap< B >::getNew ( const std::string &  nm,
const WmConstOpaquePtr parentPointer 
)
inlinestatic

Get a new object whose creator has the given name and base class has a constructor taking one WxAny argument for parentPointer.

The returned object points to the base class.

Parameters
nmName of the creator.
parentPointerwrapper around a pointer to the new instance's parent
Returns
pointer to new instance as a base class pointer

◆ getRegisteredName()

template<class B >
static const std::string WxCreatorMap< B >::getRegisteredName ( const std::type_info &  type)
inlinestatic

Returns the first registered name string associated with a particular derived type.

Parameters
typereferences a type_info object of the derived type for which to find a name
Returns
a string containing the registered name, or a empty string if not found

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