|
Robot Raconteur Core C++ Library
|
Class for function member definitions. More...
#include <ServiceDefinition.h>
Public Member Functions | |
| FunctionDefinition (const boost::shared_ptr< ServiceEntryDefinition > &ServiceEntry) | |
| Construct a new empty FunctionDefinition object. | |
| RR_OVIRTUAL std::string | ToString () RR_OVERRIDE |
| Convert member to a string. | |
| void | FromString (boost::string_ref s, const ServiceDefinitionParseInfo *parse_info=NULL) |
| Parse a function definition from string. | |
| RR_OVIRTUAL void | Reset () RR_OVERRIDE |
| Clear all fields. | |
| bool | IsGenerator () |
| Check if function member is a generator function. | |
| virtual MemberDefinition_NoLock | NoLock () const |
| Get member locking behavior. | |
Public Attributes | |
| boost::shared_ptr< TypeDefinition > | ReturnType |
| The return type of the function. May be void. | |
| std::vector< boost::shared_ptr< TypeDefinition > > | Parameters |
| The parameter types and names of the function. | |
| std::string | Name |
| The name of the member. | |
| RR_WEAK_PTR< ServiceEntryDefinition > | ServiceEntry |
| The parent service entry definition. | |
| std::vector< std::string > | Modifiers |
| Modifiers for this member. | |
| ServiceDefinitionParseInfo | ParseInfo |
| Parsing diagnostic information. | |
| std::string | DocString |
| Documentation string for the member. | |
Class for function member definitions.
FunctionDefinition is used to store Function member definitions used with an Object parent.
See service_definitions.md for more information.
| RobotRaconteur::FunctionDefinition::FunctionDefinition | ( | const boost::shared_ptr< ServiceEntryDefinition > & | ServiceEntry | ) |
Construct a new empty FunctionDefinition object.
Must be constructed with boost::make_shared<FunctionDefinition>()
| ServiceEntry | The parent service entry definition |
| void RobotRaconteur::FunctionDefinition::FromString | ( | boost::string_ref | s, |
| const ServiceDefinitionParseInfo * | parse_info = NULL ) |
Parse a function definition from string.
| s | The function definition as a string |
| parse_info | Parsing diagnostic information |
| bool RobotRaconteur::FunctionDefinition::IsGenerator | ( | ) |
Check if function member is a generator function.
Function members are generators if the return and/or last parameter type have a {generator} container type. These functions will return a Generator instance when called.
|
virtualinherited |
Get member locking behavior.
Members may use modifiers to change behavior when an object is locked using RobotRaconteurNode::RequestObjectLock() or ServerContext::RequestObjectLock() By default, access to the object is protected against other users/sessions. Members can be declared nolock or nolockread to allow objects to be unlocked, or unlocked for read operations. See object_locks.md for more information.
|
virtual |
Convert member to a string.
Returned member string is in Service Definition IDL format
Reimplemented from RobotRaconteur::MemberDefinition.
|
inherited |
Modifiers for this member.
Modifiers are used to modify the behavior of the member. See service_definitions.md for more information on valid modifiers.
|
inherited |
Parsing diagnostic information.
The ParseInfo field is populated by the FromString() function of the member
|
inherited |
The parent service entry definition.
Stored as a weak_ptr to prevent circular reference counts