Templated factory which informs objects created by it what their class identifier string was. More...
#include <class_id_recording_factory.h>
Public Member Functions | |
virtual Type * | make (const QString &class_id, QString *error_return=nullptr) |
Instantiate and return a instance of a subclass of Type using makeRaw(). More... | |
Public Member Functions inherited from rviz::Factory | |
virtual QString | getClassDescription (const QString &class_id) const =0 |
virtual QString | getClassName (const QString &class_id) const =0 |
virtual QString | getClassPackage (const QString &class_id) const =0 |
virtual QStringList | getDeclaredClassIds ()=0 |
virtual QIcon | getIcon (const QString &class_id) const =0 |
virtual | ~Factory () |
Protected Member Functions | |
virtual Type * | makeRaw (const QString &class_id, QString *error_return=nullptr)=0 |
Templated factory which informs objects created by it what their class identifier string was.
Calls a setClassId() function on any instance created by a protected makeRaw() function (pure virtual in this class).
Definition at line 41 of file class_id_recording_factory.h.
|
inlinevirtual |
Instantiate and return a instance of a subclass of Type using makeRaw().
class_id | A string identifying the class uniquely among classes of its parent class. rviz::GridDisplay might be rviz/Grid, for example. |
error_return | If non-NULL and there is an error, error_return is set to a description of the problem. |
If make() returns NULL and error_return is not NULL, *error_return will be set. On success, *error_return will not be changed.
Definition at line 55 of file class_id_recording_factory.h.
|
protectedpure virtual |