YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
yarp::dev::DriverCreator Class Referenceabstract

A base class for factories that create driver objects. More...

#include <yarp/dev/Drivers.h>

+ Inheritance diagram for yarp::dev::DriverCreator:

Public Member Functions

virtual ~DriverCreator ()
 Destructor.
 
virtual std::string toString () const =0
 Returns a simple description of devices the factory can make.
 
virtual DeviceDrivercreate () const =0
 Create a device.
 
virtual std::string getName () const =0
 Get the common name of the device.
 
virtual std::string getWrapper () const =0
 Get the common name of a device that can wrap this one.
 
virtual std::string getCode () const =0
 Get the name of the C++ class associated with this device.
 
virtual PolyDriverowner ()
 For "links" to other devices.
 

Detailed Description

A base class for factories that create driver objects.

The DriverCreatorOf class is probably what you want.

Definition at line 27 of file Drivers.h.

Constructor & Destructor Documentation

◆ ~DriverCreator()

virtual yarp::dev::DriverCreator::~DriverCreator ( )
inlinevirtual

Destructor.

Definition at line 32 of file Drivers.h.

Member Function Documentation

◆ create()

virtual DeviceDriver * yarp::dev::DriverCreator::create ( ) const
pure virtual

Create a device.

Implemented in yarp::dev::DriverCreatorOf< T >, and yarp::dev::StubDriverCreator.

◆ getCode()

virtual std::string yarp::dev::DriverCreator::getCode ( ) const
pure virtual

Get the name of the C++ class associated with this device.

Returns
the name of the C++ class associated with this device.

Implemented in yarp::dev::DriverCreatorOf< T >, and yarp::dev::StubDriverCreator.

◆ getName()

virtual std::string yarp::dev::DriverCreator::getName ( ) const
pure virtual

Get the common name of the device.

Returns
the common name of the device this creates.

Implemented in yarp::dev::DriverCreatorOf< T >, and yarp::dev::StubDriverCreator.

◆ getWrapper()

virtual std::string yarp::dev::DriverCreator::getWrapper ( ) const
pure virtual

Get the common name of a device that can wrap this one.

Returns
the common name of the device that can wrap this one for the network.

Implemented in yarp::dev::DriverCreatorOf< T >, and yarp::dev::StubDriverCreator.

◆ owner()

virtual PolyDriver * yarp::dev::DriverCreator::owner ( )
inlinevirtual

For "links" to other devices.

Default implementation returns NULL, which is correct for all real devices talking to hardware.

Returns
the object managing the device.

Definition at line 72 of file Drivers.h.

◆ toString()

virtual std::string yarp::dev::DriverCreator::toString ( ) const
pure virtual

Returns a simple description of devices the factory can make.

Returns
a description of what this factory makes

Implemented in yarp::dev::DriverCreatorOf< T >, and yarp::dev::StubDriverCreator.


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