Gazebo Gazebo

API Reference

6.16.0
ElevatorStateMachinePrivate Class Reference

#include <ElevatorStateMachineImpl.hh>

Public Member Functions

 ElevatorStateMachinePrivate (const std::shared_ptr< ElevatorCommonPrivate > &_system)
 Constructor. More...
 
void EnqueueNewTarget (double _target)
 Adds a new target to the queue. More...
 
void SendCmd (transport::Node::Publisher &_pub, double _cmd)
 Publishes a command message. More...
 

Public Attributes

std::shared_ptr< ElevatorCommonPrivate > system
 Data of the enclosing system. More...
 
std::deque< int32_t > targets
 Floor target queue. More...
 

Constructor & Destructor Documentation

◆ ElevatorStateMachinePrivate()

ElevatorStateMachinePrivate ( const std::shared_ptr< ElevatorCommonPrivate > &  _system)

Constructor.

Parameters
[in]_systemData of the enclosing system

Member Function Documentation

◆ EnqueueNewTarget()

void EnqueueNewTarget ( double  _target)

Adds a new target to the queue.

If there is another target in the queue, and the new target is an intermediate stop, the new target will take precedence

Parameters
[in]_targetTarget to add to the queue

References deque< T >::cbegin(), deque< T >::cend(), std::endl(), std::find(), ignmsg, deque< T >::insert(), deque< T >::push_back(), ostringstream::str(), std::swap(), ElevatorStateMachinePrivate::system, and ElevatorStateMachinePrivate::targets.

◆ SendCmd()

void SendCmd ( transport::Node::Publisher _pub,
double  _cmd 
)

Publishes a command message.

Parameters
[in]_pubJoint command publisher
[in]_cmdJoint command

References Node::Publisher::Publish(), and Double::set_data().

Member Data Documentation

◆ system

std::shared_ptr<ElevatorCommonPrivate> system

Data of the enclosing system.

Referenced by ElevatorStateMachinePrivate::EnqueueNewTarget().

◆ targets

std::deque<int32_t> targets

Floor target queue.

Referenced by ElevatorStateMachinePrivate::EnqueueNewTarget().


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