Classes | Namespaces | Macros | Functions
Registrar.h File Reference
#include "Parametrizable.h"
#include "PointMatcher.h"
#include <boost/format.hpp>
#include <boost/typeof/typeof.hpp>
Include dependency graph for Registrar.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  PointMatcherSupport::Registrar< Interface >::ClassDescriptor
 The interface for class descriptors. More...
 
struct  PointMatcherSupport::Registrar< Interface >::GenericClassDescriptor< C >
 A descriptor for a class C that provides parameters. More...
 
struct  PointMatcherSupport::Registrar< Interface >::GenericClassDescriptorNoParam< C >
 A descriptor for a class C that does not provide any parameter. More...
 
struct  PointMatcherSupport::InvalidElement
 An exception thrown when one tries to instanciate an element that does not exist in the registrar. More...
 
struct  PointMatcherSupport::Registrar< Interface >
 A factor for subclasses of Interface. More...
 

Namespaces

 PointMatcherSupport
 Functions and classes that are not dependant on scalar type are defined in this namespace.
 
 YAML_PM
 

Macros

#define ADD_TO_REGISTRAR(name, elementName, element)
 
#define ADD_TO_REGISTRAR_NO_PARAM(name, elementName, element)
 
#define DEF_REGISTRAR(name)   PointMatcherSupport::Registrar< name > name##Registrar;
 
#define DEF_REGISTRAR_IFACE(name, ifaceName)   PointMatcherSupport::Registrar< ifaceName > name##Registrar;
 
#define REG(name)   name##Registrar
 

Functions

void PointMatcherSupport::getNameParamsFromYAML (const YAML::Node &module, std::string &name, Parametrizable::Parameters &params)
 Retrieve name and parameters from a yaml node. More...
 

Macro Definition Documentation

◆ ADD_TO_REGISTRAR

#define ADD_TO_REGISTRAR (   name,
  elementName,
  element 
)
Value:
{ \
typedef typename PointMatcherSupport::Registrar< name >::template GenericClassDescriptor< element > Desc; \
name##Registrar.reg(# elementName, std::make_shared<Desc>() ); \
}
A factor for subclasses of Interface.
Definition: Registrar.h:76
void reg(const std::string &name, std::shared_ptr< ClassDescriptor > descriptor)
Register a class by storing an instance of a descriptor helper class.
Definition: Registrar.h:156

Definition at line 223 of file Registrar.h.

◆ ADD_TO_REGISTRAR_NO_PARAM

#define ADD_TO_REGISTRAR_NO_PARAM (   name,
  elementName,
  element 
)
Value:
{ \
typedef typename PointMatcherSupport::Registrar< name >::template GenericClassDescriptorNoParam< element > Desc; \
name##Registrar.reg(# elementName, std::make_shared<Desc>() ); \
}
A factor for subclasses of Interface.
Definition: Registrar.h:76
void reg(const std::string &name, std::shared_ptr< ClassDescriptor > descriptor)
Register a class by storing an instance of a descriptor helper class.
Definition: Registrar.h:156

Definition at line 227 of file Registrar.h.

◆ DEF_REGISTRAR

#define DEF_REGISTRAR (   name)    PointMatcherSupport::Registrar< name > name##Registrar;

Definition at line 221 of file Registrar.h.

◆ DEF_REGISTRAR_IFACE

#define DEF_REGISTRAR_IFACE (   name,
  ifaceName 
)    PointMatcherSupport::Registrar< ifaceName > name##Registrar;

Definition at line 222 of file Registrar.h.

◆ REG

#define REG (   name)    name##Registrar

Definition at line 220 of file Registrar.h.



libpointmatcher
Author(s):
autogenerated on Sat May 27 2023 02:38:03