YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
DeviceTemplate Class Reference

#include </home/runner/work/yarp-documentation/yarp-documentation/yarp/opt-modules/yarp-device-template/src/devices/deviceTemplate/DeviceTemplate.h>

+ Inheritance diagram for DeviceTemplate:

Public Member Functions

 DeviceTemplate ()
 
 DeviceTemplate (const DeviceTemplate &)=delete
 
 DeviceTemplate (DeviceTemplate &&) noexcept=delete
 
DeviceTemplateoperator= (const DeviceTemplate &)=delete
 
DeviceTemplateoperator= (DeviceTemplate &&) noexcept=delete
 
 ~DeviceTemplate () override=default
 
bool open (yarp::os::Searchable &config) override
 Open the DeviceDriver.
 
bool close () override
 Close the DeviceDriver.
 
- Public Member Functions inherited from yarp::dev::DeviceDriver
 DeviceDriver ()
 
 DeviceDriver (const DeviceDriver &other)=delete
 
 DeviceDriver (DeviceDriver &&other) noexcept=delete
 
DeviceDriveroperator= (const DeviceDriver &other)=delete
 
DeviceDriveroperator= (DeviceDriver &&other) noexcept=delete
 
virtual ~DeviceDriver ()
 
virtual std::string id () const
 Return the id assigned to the PolyDriver.
 
virtual void setId (const std::string &id)
 Set the id for this device.
 
template<class T >
bool view (T *&x)
 Get an interface to the device driver.
 
virtual DeviceDrivergetImplementation ()
 Some drivers are bureaucrats, pointing at others.
 
- Public Member Functions inherited from DeviceTemplate_ParamsParser
 ~DeviceTemplate_ParamsParser () override=default
 
bool parseParams (const yarp::os::Searchable &config) override
 Parse the DeviceDriver parameters.
 
std::string getDeviceType () const override
 
std::string getDocumentationOfDeviceParams () const override
 Get the documentation of the DeviceDriver's parameters.
 
std::vector< std::string > getListOfParams () const override
 Return a list of all params used by the device.
 
- Public Member Functions inherited from yarp::dev::IDeviceDriverParams
virtual ~IDeviceDriverParams ()
 
virtual std::string getDeviceClassName () const =0
 Get the name of the DeviceDriver class.
 
virtual std::string getDeviceName () const =0
 Get the name of the device (i.e.
 

Additional Inherited Members

- Public Attributes inherited from DeviceTemplate_ParamsParser
const std::string m_device_type = {"DeviceTemplate"}
 
bool m_parser_is_strict = false
 
std::string m_dummy_group_dummy_param1 = {"dummy_default_value"}
 
double m_dummy_param2 = {9.81}
 

Detailed Description

Definition at line 12 of file DeviceTemplate.h.

Constructor & Destructor Documentation

◆ DeviceTemplate() [1/3]

DeviceTemplate::DeviceTemplate ( )

Definition at line 24 of file DeviceTemplate.cpp.

◆ DeviceTemplate() [2/3]

DeviceTemplate::DeviceTemplate ( const DeviceTemplate )
delete

◆ DeviceTemplate() [3/3]

DeviceTemplate::DeviceTemplate ( DeviceTemplate &&  )
deletenoexcept

◆ ~DeviceTemplate()

DeviceTemplate::~DeviceTemplate ( )
overridedefault

Member Function Documentation

◆ close()

bool DeviceTemplate::close ( )
overridevirtual

Close the DeviceDriver.

Returns
true/false on success/failure.

Reimplemented from yarp::dev::DeviceDriver.

Definition at line 37 of file DeviceTemplate.cpp.

◆ open()

bool DeviceTemplate::open ( yarp::os::Searchable config)
overridevirtual

Open the DeviceDriver.

Parameters
configis a list of parameters for the device. Which parameters are effective for your device can vary. See device invocation examples. If there is no example for your device, you can run the "yarpdev" program with the verbose flag set to probe what parameters the device is checking. If that fails too, you'll need to read the source code (please nag one of the yarp developers to add documentation for your device).
Returns
true/false upon success/failure

Reimplemented from yarp::dev::DeviceDriver.

Definition at line 29 of file DeviceTemplate.cpp.

◆ operator=() [1/2]

DeviceTemplate & DeviceTemplate::operator= ( const DeviceTemplate )
delete

◆ operator=() [2/2]

DeviceTemplate & DeviceTemplate::operator= ( DeviceTemplate &&  )
deletenoexcept

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