Plugins
ug::promesh::ProMeshRegistry Class Reference

Register functions for ug-script and ProMesh through this class. More...

#include <promesh_registry.h>

Public Types

typedef ProMeshFunctionSet::const_iterator const_func_iter_t
 
typedef ProMeshFunctionSet::iterator func_iter_t
 
typedef std::multiset< detail::ProMeshFunctionProMeshFunctionSet
 

Public Member Functions

template<typename TClass >
bridge::ExportedClass< TClass > & add_class_ (std::string className, std::string group="", std::string tooltip="")
 Register a class at this registry. More...
 
template<typename TClass , typename TBaseClass >
bridge::ExportedClass< TClass > & add_class_ (std::string className, std::string group="", std::string tooltip="")
 Register a class at this registry together with its base class. More...
 
template<typename TClass , typename TBaseClass1 , typename TBaseClass2 >
bridge::ExportedClass< TClass > & add_class_ (std::string className, std::string group="", std::string tooltip="")
 Register a class at this registry together with two base classes. More...
 
template<typename TFunc >
ProMeshRegistryadd_function (std::string funcName, TFunc func, std::string group="", std::string retValInfos="", std::string paramInfos="", std::string tooltip="", std::string help="", unsigned int target=RT_DEFAULT, int shortcutKey=0, ModifierKeys modifyerKey=MK_NONE)
 adds a function to the registry More...
 
func_iter_t functions_begin ()
 
const_func_iter_t functions_begin () const
 
func_iter_t functions_end ()
 
const_func_iter_t functions_end () const
 
 ProMeshRegistry (bridge::Registry *reg)
 
bridge::Registryregistry ()
 returns a pointer to the ug::bridge::Registry which is encapsulated by this class. More...
 

Private Attributes

int m_counter
 
ProMeshFunctionSet m_funcSet
 
std::map< std::string, int > m_groupPriority
 
bridge::Registrym_reg
 

Detailed Description

Register functions for ug-script and ProMesh through this class.

The ProMeshRegistry is a small wrapper for ug::bridge::Registry and allows for the specification of additional parameters, which are later on used by ProMesh to automatically generate tools for all registered functions.

Member Typedef Documentation

◆ const_func_iter_t

typedef ProMeshFunctionSet::const_iterator ug::promesh::ProMeshRegistry::const_func_iter_t

◆ func_iter_t

typedef ProMeshFunctionSet::iterator ug::promesh::ProMeshRegistry::func_iter_t

◆ ProMeshFunctionSet

Constructor & Destructor Documentation

◆ ProMeshRegistry()

ug::promesh::ProMeshRegistry::ProMeshRegistry ( bridge::Registry reg)
inline

Member Function Documentation

◆ add_class_() [1/3]

template<typename TClass >
bridge::ExportedClass<TClass>& ug::promesh::ProMeshRegistry::add_class_ ( std::string  className,
std::string  group = "",
std::string  tooltip = "" 
)
inline

Register a class at this registry.

Parameters
classNamename of the class to appear in the registry
groupregistry group. use / for subgroups e.g. ug4/mygroup/mysubgroup (optional)
toolTipdescribing text for the class (optional)

Referenced by ug::promesh::RegisterElementIterators(), ug::promesh::RegisterMesh(), and ug::promesh::RegisterMisc().

◆ add_class_() [2/3]

template<typename TClass , typename TBaseClass >
bridge::ExportedClass<TClass>& ug::promesh::ProMeshRegistry::add_class_ ( std::string  className,
std::string  group = "",
std::string  tooltip = "" 
)
inline

Register a class at this registry together with its base class.

Parameters
classNamename of the class to appear in the registry
groupregistry group. use / for subgroups e.g. ug4/mygroup/mysubgroup (optional)
toolTipdescribing text for the class (optional)

◆ add_class_() [3/3]

template<typename TClass , typename TBaseClass1 , typename TBaseClass2 >
bridge::ExportedClass<TClass>& ug::promesh::ProMeshRegistry::add_class_ ( std::string  className,
std::string  group = "",
std::string  tooltip = "" 
)
inline

Register a class at this registry together with two base classes.

Parameters
classNamename of the class to appear in the registry
groupregistry group. use / for subgroups e.g. ug4/mygroup/mysubgroup (optional)
toolTipdescribing text for the class (optional)

◆ add_function()

template<typename TFunc >
ProMeshRegistry& ug::promesh::ProMeshRegistry::add_function ( std::string  funcName,
TFunc  func,
std::string  group = "",
std::string  retValInfos = "",
std::string  paramInfos = "",
std::string  tooltip = "",
std::string  help = "",
unsigned int  target = RT_DEFAULT,
int  shortcutKey = 0,
ModifierKeys  modifyerKey = MK_NONE 
)
inline

adds a function to the registry

Parameters
funcNamethe name of the function
funcfunction pointer of the function
groupregistry group. use / for subgroups e.g. ug4/mygroup/mysubgroup (optional)
retValInfosstring documenting what the function returns (optional)
paramInfosstring documenting the parameters of the function seperate parameters with an # e.g. "x#y#z" (don't specify the type of the values) (optional)
toolTipsmall documentation for the function (optional)
helphelp string for the function
See also
pageUG4Registry
secSTHowToSpecifyParameterInformation

References the template function proxy_function<TFunc> and stores it with the FuntionWrapper.

References target().

Referenced by ug::promesh::RegisterCoordinateTransformTools(), ug::promesh::RegisterMeshingTools(), ug::promesh::RegisterMisc(), ug::promesh::RegisterSelectionTools(), and ug::promesh::RegisterSubsetTools().

◆ functions_begin() [1/2]

func_iter_t ug::promesh::ProMeshRegistry::functions_begin ( )
inline

◆ functions_begin() [2/2]

const_func_iter_t ug::promesh::ProMeshRegistry::functions_begin ( ) const
inline

◆ functions_end() [1/2]

func_iter_t ug::promesh::ProMeshRegistry::functions_end ( )
inline

◆ functions_end() [2/2]

const_func_iter_t ug::promesh::ProMeshRegistry::functions_end ( ) const
inline

◆ registry()

bridge::Registry* ug::promesh::ProMeshRegistry::registry ( )
inline

returns a pointer to the ug::bridge::Registry which is encapsulated by this class.

Member Data Documentation

◆ m_counter

int ug::promesh::ProMeshRegistry::m_counter
private

◆ m_funcSet

ProMeshFunctionSet ug::promesh::ProMeshRegistry::m_funcSet
private

◆ m_groupPriority

std::map<std::string, int> ug::promesh::ProMeshRegistry::m_groupPriority
private

◆ m_reg

bridge::Registry* ug::promesh::ProMeshRegistry::m_reg
private

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