SMACC2
|
#include <smacc_client.hpp>
Public Member Functions | |
ISmaccClient () | |
virtual | ~ISmaccClient () |
virtual void | onInitialize () |
virtual std::string | getName () const |
template<typename TComponent > | |
TComponent * | getComponent () |
template<typename TComponent > | |
TComponent * | getComponent (std::string name) |
template<typename TComponent > | |
TComponent * | getComponent (int index) |
virtual smacc2::introspection::TypeInfo::Ptr | getType () |
ISmaccStateMachine * | getStateMachine () |
template<typename TSmaccSignal , typename T > | |
void | connectSignal (TSmaccSignal &signal, void(T::*callback)(), T *object) |
template<typename SmaccClientType > | |
void | requiresClient (SmaccClientType *&storage) |
void | getComponents (std::vector< std::shared_ptr< ISmaccComponent > > &components) |
template<typename EventType > | |
void | postEvent (const EventType &ev) |
template<typename EventType > | |
void | postEvent () |
Protected Member Functions | |
template<typename TOrthogonal , typename TSourceObject > | |
void | onOrthogonalAllocation () |
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs> | |
SmaccComponentType * | createComponent (TArgs... targs) |
template<typename SmaccComponentType , typename TOrthogonal , typename TClient , typename... TArgs> | |
SmaccComponentType * | createNamedComponent (std::string name, TArgs... targs) |
rclcpp::Node::SharedPtr | getNode () |
rclcpp::Logger | getLogger () |
Protected Attributes | |
std::map< ComponentKey, std::shared_ptr< smacc2::ISmaccComponent > > | components_ |
Private Member Functions | |
void | initialize () |
void | setStateMachine (ISmaccStateMachine *stateMachine) |
void | setOrthogonal (ISmaccOrthogonal *orthogonal) |
Private Attributes | |
ISmaccStateMachine * | stateMachine_ |
ISmaccOrthogonal * | orthogonal_ |
Friends | |
class | ISmaccOrthogonal |
class | ISmaccComponent |
Definition at line 44 of file smacc_client.hpp.
smacc2::ISmaccClient::ISmaccClient | ( | ) |
Definition at line 26 of file client.cpp.
|
virtual |
Definition at line 28 of file client.cpp.
void smacc2::ISmaccClient::connectSignal | ( | TSmaccSignal & | signal, |
void(T::*)() | callback, | ||
T * | object | ||
) |
Definition at line 138 of file smacc_client_impl.hpp.
References smacc2::ISmaccStateMachine::createSignalConnection(), and getStateMachine().
|
protected |
Definition at line 131 of file smacc_client_impl.hpp.
Referenced by smacc2::ClientHandler< TOrthogonal, TClient >::createComponent(), and smacc2::ISmaccComponent::createSiblingComponent().
|
protected |
Definition at line 91 of file smacc_client_impl.hpp.
References components_, getLogger(), getName(), and getStateMachine().
Referenced by smacc2::ClientHandler< TOrthogonal, TClient >::createNamedComponent(), and smacc2::ISmaccComponent::createSiblingNamedComponent().
TComponent * smacc2::ISmaccClient::getComponent |
Definition at line 41 of file smacc_client_impl.hpp.
Referenced by smacc2::ISmaccComponent::requiresComponent().
TComponent * smacc2::ISmaccClient::getComponent | ( | int | index | ) |
Definition at line 47 of file smacc_client_impl.hpp.
References components_.
TComponent * smacc2::ISmaccClient::getComponent | ( | std::string | name | ) |
Definition at line 71 of file smacc_client_impl.hpp.
References components_.
void smacc2::ISmaccClient::getComponents | ( | std::vector< std::shared_ptr< ISmaccComponent > > & | components | ) |
Definition at line 34 of file client.cpp.
References components_.
|
inlineprotected |
Definition at line 103 of file smacc_client.hpp.
References getNode().
Referenced by smacc2::client_bases::SmaccActionClientBase< ActionType >::cancelGoal(), smacc2::client_bases::SmaccPublisherClient::configure(), createNamedComponent(), smacc2::ISmaccComponent::getLogger(), smacc2::client_bases::SmaccServiceClient< ServiceType >::onInitialize(), smacc2::client_bases::SmaccSubscriberClient< MessageType >::onInitialize(), cl_multirole_sensor::ClMultiroleSensor< MessageType >::onInitialize(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onOrthogonalAllocation(), cl_keyboard::ClKeyboard::onOrthogonalAllocation(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onResult(), cl_keyboard::ClKeyboard::postKeyEvent(), smacc2::client_bases::SmaccActionClientBase< ActionType >::postResultEvent(), and smacc2::client_bases::SmaccActionClientBase< ActionType >::sendGoal().
|
virtual |
Reimplemented in smacc2::client_bases::ISmaccActionClient.
Definition at line 42 of file client.cpp.
References smacc2::introspection::demangleSymbol().
Referenced by smacc2::client_bases::SmaccPublisherClient::configure(), createNamedComponent(), smacc2::client_bases::SmaccServiceClient< ServiceType >::onInitialize(), and smacc2::client_bases::SmaccSubscriberClient< MessageType >::onInitialize().
|
protected |
Definition at line 60 of file client.cpp.
References smacc2::ISmaccStateMachine::getNode(), and getStateMachine().
Referenced by smacc2::client_bases::SmaccActionClientBase< ActionType >::cancelGoal(), smacc2::client_bases::SmaccPublisherClient::configure(), getLogger(), smacc2::ISmaccComponent::getNode(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onInitialize(), smacc2::client_bases::SmaccServiceClient< ServiceType >::onInitialize(), smacc2::client_bases::SmaccSubscriberClient< MessageType >::onInitialize(), cl_multirole_sensor::ClMultiroleSensor< MessageType >::onInitialize(), and cl_ros_timer::ClRosTimer::onInitialize().
|
inline |
Definition at line 88 of file smacc_client_impl.hpp.
References stateMachine_.
Referenced by connectSignal(), createNamedComponent(), getNode(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onAborted(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onCancelled(), smacc2::client_bases::SmaccSubscriberClient< MessageType >::onFirstMessageReceived(), cl_keyboard::ClKeyboard::OnKeyPress(), smacc2::client_bases::SmaccSubscriberClient< MessageType >::onMessageReceived(), cl_multirole_sensor::ClMultiroleSensor< MessageType >::onMessageTimeout(), smacc2::client_bases::SmaccActionClientBase< ActionType >::onSucceeded(), and cl_ros_timer::ClRosTimer::onTimerTick().
|
virtual |
Definition at line 55 of file client.cpp.
References smacc2::introspection::TypeInfo::getFromStdTypeInfo().
|
private |
Definition at line 30 of file client.cpp.
References onInitialize().
|
virtual |
Reimplemented in smacc2::client_bases::SmaccActionClientBase< ActionType >, smacc2::client_bases::SmaccServiceClient< ServiceType >, smacc2::client_bases::SmaccSubscriberClient< MessageType >, smacc2::client_bases::SmaccSubscriberClient< std_msgs::msg::UInt16 >, smacc2::client_bases::SmaccSubscriberClient< TMsg >, cl_keyboard::ClKeyboard, cl_multirole_sensor::ClMultiroleSensor< MessageType >, and cl_ros_timer::ClRosTimer.
Definition at line 32 of file client.cpp.
Referenced by initialize().
|
inlineprotected |
Definition at line 88 of file smacc_client.hpp.
void smacc2::ISmaccClient::postEvent |
Definition at line 35 of file smacc_client_impl.hpp.
References smacc2::ISmaccStateMachine::postEvent(), and stateMachine_.
Referenced by smacc2::client_bases::SmaccActionClientBase< ActionType >::onOrthogonalAllocation(), smacc2::client_bases::SmaccSubscriberClient< MessageType >::onOrthogonalAllocation(), cl_multirole_sensor::ClMultiroleSensor< MessageType >::onOrthogonalAllocation(), and smacc2::client_bases::SmaccActionClientBase< ActionType >::postResultEvent().
void smacc2::ISmaccClient::postEvent | ( | const EventType & | ev | ) |
Definition at line 29 of file smacc_client_impl.hpp.
References smacc2::ISmaccStateMachine::postEvent(), and stateMachine_.
void smacc2::ISmaccClient::requiresClient | ( | SmaccClientType *& | storage | ) |
Definition at line 144 of file smacc_client_impl.hpp.
References orthogonal_, and smacc2::ISmaccOrthogonal::requiresClient().
Referenced by smacc2::ISmaccComponent::requiresClient().
|
private |
|
private |
Definition at line 48 of file client.cpp.
References stateMachine_.
|
friend |
Definition at line 121 of file smacc_client.hpp.
|
friend |
Definition at line 120 of file smacc_client.hpp.
|
protected |
Definition at line 93 of file smacc_client.hpp.
Referenced by createNamedComponent(), getComponent(), and getComponents().
|
private |
Definition at line 108 of file smacc_client.hpp.
Referenced by requiresClient(), and setOrthogonal().
|
private |
Definition at line 107 of file smacc_client.hpp.
Referenced by getStateMachine(), postEvent(), and setStateMachine().