gazebo-yarp-plugins
Gazebo Plugins exposing YARP interfaces.
Loading...
Searching...
No Matches
GazeboYarpPlugins::ClockServer Class Reference

#include <ClockServer.h>

Inheritance diagram for GazeboYarpPlugins::ClockServer:
Collaboration diagram for GazeboYarpPlugins::ClockServer:

Public Member Functions

 ClockServer ()
 
virtual void pauseSimulation ()
 Pause the simulation if it was running.
 
virtual void continueSimulation ()
 Resume the simulation if it was paused.
 
virtual void stepSimulation (const std::int32_t numberOfSteps=1)
 Steps the simulation for the provided number of steps.
 
virtual void stepSimulationAndWait (const std::int32_t numberOfSteps=1)
 Steps the simulation for the provided number of steps.
 
virtual void resetSimulationTime ()
 Reset the simulation time back to zero.
 
virtual double getSimulationTime ()
 Get the current simulation time.
 
virtual double getStepSize ()
 Get the current step size in seconds.
 
virtual void resetSimulation ()
 Reset the simulation state and time.
 
virtual void resetSimulationState ()
 Reset the simulation state back to initial pose.
 
virtual std::vector< std::string > help (const std::string &functionName="--all")
 
bool read (yarp::os::ConnectionReader &connection) override
 
 ClockServer ()
 
virtual void pauseSimulation ()
 Pause the simulation if it was running.
 
virtual void continueSimulation ()
 Resume the simulation if it was paused.
 
virtual void stepSimulation (const std::int32_t numberOfSteps=1)
 Steps the simulation for the provided number of steps.
 
virtual void stepSimulationAndWait (const std::int32_t numberOfSteps=1)
 Steps the simulation for the provided number of steps.
 
virtual void resetSimulationTime ()
 Reset the simulation time back to zero.
 
virtual double getSimulationTime ()
 Get the current simulation time.
 
virtual double getStepSize ()
 Get the current step size in seconds.
 
virtual void resetSimulation ()
 Reset the simulation state and time.
 
virtual void resetSimulationState ()
 Reset the simulation state back to initial pose.
 
virtual std::vector< std::string > help (const std::string &functionName="--all")
 
bool read (yarp::os::ConnectionReader &connection) override
 

Constructor & Destructor Documentation

◆ ClockServer() [1/2]

GazeboYarpPlugins::ClockServer::ClockServer ( )

◆ ClockServer() [2/2]

GazeboYarpPlugins::ClockServer::ClockServer ( )

Member Function Documentation

◆ pauseSimulation() [1/2]

void GazeboYarpPlugins::ClockServer::pauseSimulation ( )
virtual

Pause the simulation if it was running.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ continueSimulation() [1/2]

void GazeboYarpPlugins::ClockServer::continueSimulation ( )
virtual

Resume the simulation if it was paused.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ stepSimulation() [1/2]

void GazeboYarpPlugins::ClockServer::stepSimulation ( const std::int32_t numberOfSteps = 1)
virtual

Steps the simulation for the provided number of steps.

The input parameter is the number of steps, not the time (Usually 1 step = 1ms but this is not guaranteed)

Note
: this function (will be) not blocking, i.e. it will return immediately. Currently calling this function twice before the previous call actually ends its computation gives and undefined behavior.
Parameters
numberOfStepsnumber of steps to simulate

◆ stepSimulationAndWait() [1/2]

void GazeboYarpPlugins::ClockServer::stepSimulationAndWait ( const std::int32_t numberOfSteps = 1)
virtual

Steps the simulation for the provided number of steps.

The input parameter is the number of steps, not the time (Usually 1 step = 1ms but this is not guaranteed)

Note
: this function is blocking
Parameters
numberOfStepsnumber of steps to simulate

◆ resetSimulationTime() [1/2]

void GazeboYarpPlugins::ClockServer::resetSimulationTime ( )
virtual

Reset the simulation time back to zero.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ getSimulationTime() [1/2]

double GazeboYarpPlugins::ClockServer::getSimulationTime ( )
virtual

Get the current simulation time.

Returns
the simulation time.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ getStepSize() [1/2]

double GazeboYarpPlugins::ClockServer::getStepSize ( )
virtual

Get the current step size in seconds.

Returns
the step size in seconds

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ resetSimulation() [1/2]

void GazeboYarpPlugins::ClockServer::resetSimulation ( )
virtual

Reset the simulation state and time.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ resetSimulationState() [1/2]

void GazeboYarpPlugins::ClockServer::resetSimulationState ( )
virtual

Reset the simulation state back to initial pose.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ help() [1/2]

std::vector< std::string > GazeboYarpPlugins::ClockServer::help ( const std::string & functionName = "--all")
virtual

◆ read() [1/2]

bool GazeboYarpPlugins::ClockServer::read ( yarp::os::ConnectionReader & connection)
override

◆ pauseSimulation() [2/2]

virtual void GazeboYarpPlugins::ClockServer::pauseSimulation ( )
virtual

Pause the simulation if it was running.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ continueSimulation() [2/2]

virtual void GazeboYarpPlugins::ClockServer::continueSimulation ( )
virtual

Resume the simulation if it was paused.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ stepSimulation() [2/2]

virtual void GazeboYarpPlugins::ClockServer::stepSimulation ( const std::int32_t numberOfSteps = 1)
virtual

Steps the simulation for the provided number of steps.

The input parameter is the number of steps, not the time (Usually 1 step = 1ms but this is not guaranteed)

Note
: this function (will be) not blocking, i.e. it will return immediately. Currently calling this function twice before the previous call actually ends its computation gives and undefined behavior.
Parameters
numberOfStepsnumber of steps to simulate

◆ stepSimulationAndWait() [2/2]

virtual void GazeboYarpPlugins::ClockServer::stepSimulationAndWait ( const std::int32_t numberOfSteps = 1)
virtual

Steps the simulation for the provided number of steps.

The input parameter is the number of steps, not the time (Usually 1 step = 1ms but this is not guaranteed)

Note
: this function is blocking
Parameters
numberOfStepsnumber of steps to simulate

◆ resetSimulationTime() [2/2]

virtual void GazeboYarpPlugins::ClockServer::resetSimulationTime ( )
virtual

Reset the simulation time back to zero.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ getSimulationTime() [2/2]

virtual double GazeboYarpPlugins::ClockServer::getSimulationTime ( )
virtual

Get the current simulation time.

Returns
the simulation time.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ getStepSize() [2/2]

virtual double GazeboYarpPlugins::ClockServer::getStepSize ( )
virtual

Get the current step size in seconds.

Returns
the step size in seconds

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ resetSimulation() [2/2]

virtual void GazeboYarpPlugins::ClockServer::resetSimulation ( )
virtual

Reset the simulation state and time.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ resetSimulationState() [2/2]

virtual void GazeboYarpPlugins::ClockServer::resetSimulationState ( )
virtual

Reset the simulation state back to initial pose.

Reimplemented in GazeboYarpPlugins::ClockServerImpl.

◆ help() [2/2]

virtual std::vector< std::string > GazeboYarpPlugins::ClockServer::help ( const std::string & functionName = "--all")
virtual

◆ read() [2/2]

bool GazeboYarpPlugins::ClockServer::read ( yarp::os::ConnectionReader & connection)
override

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