cisst-saw
Loading...
Searching...
No Matches
mtsComponentState Class Reference

#include <mtsComponentState.h>

Public Types

enum  Enum {
  CONSTRUCTED , INITIALIZING , READY , ACTIVE ,
  FINISHING , FINISHED
}
typedef mtsComponentState ThisType

Public Member Functions

 mtsComponentState (void)
 mtsComponentState (const mtsComponentState &other)
mtsComponentStateoperator= (const mtsComponentState &other)
 ~mtsComponentState ()
void GetState (mtsComponentState::Enum &placeHolder) const
mtsComponentState::Enum GetState (void) const
void SetState (const mtsComponentState::Enum &newValue)
const mtsComponentState::EnumState (void) const
mtsComponentState::EnumState (void)
const ThisTypeoperator= (const Enum &value)
bool operator== (const ThisType &state) const
bool operator!= (const ThisType &state) const
bool operator< (const ThisType &state) const
bool operator<= (const ThisType &state) const
bool operator> (const ThisType &state) const
bool operator>= (const ThisType &state) const
 mtsComponentState (const mtsComponentState::Enum &newState)
void SerializeRaw (std::ostream &outputStream) const
void DeSerializeRaw (std::istream &inputStream)
void ToStream (std::ostream &outputStream) const
void ToStreamRaw (std::ostream &outputStream, const char delimiter=' ', bool headerOnly=false, const std::string &headerPrefix="") const
void Copy (const mtsComponentState &source)
bool ScalarNumberIsFixed (void) const
size_t ScalarNumber (void) const

Static Public Member Functions

static const std::vector< std::string > & EnumVectorString (void)

Public Attributes

void SerializeBinary(std::ostream &outputStream) const CISST_THROW(std void DeSerializeBinary(std::istream &inputStream, const cmnDataFormat &localFormat, const cmnDataFormat &remoteFormat) CISST_THROW(std void SerializeText(std::ostream &outputStream, const char delimiter=',') const CISST_THROW(std std::string SerializeDescription (const char delimiter=',', const std::string &userDescription="") const
void DeSerializeText(std::istream &inputStream, const char delimiter=',') CISST_THROW(std std::string HumanReadable (void) const

Static Public Attributes

static std::string static EnumToString(const Enum &value) CISST_THROW(std Enum static EnumFromString(const std::string &value) CISST_THROW(std const std::vector< int > & EnumVectorInt (void)

Protected Attributes

mtsComponentState::Enum mState

Member Typedef Documentation

◆ ThisType

Member Enumeration Documentation

◆ Enum

The possible component states: CONSTRUCTED – Initial state set by mtsTask constructor. INITIALIZING – Set by mtsComponent::Create. The task stays in this state until the thread calls mtsTask::RunInternal, which calls mtsTask::StartupInternal and the user-supplied mtsTask::Startup. If a new thread is created, the call to mtsTask::RunInternal happens some time after the call to mtsTask::Create. READY – Set by mtsTask::StartupInternal. This means that the task is ready to be used (i.e., all interfaces have been initialized). Also, a task can return to the READY state (from the ACTIVE state) in response to a call to mtsTask::Suspend. ACTIVE – Set by mtsTask::Start. This is the normal running state, where the task is calling the user-supplied mtsTask::Run method. FINISHING – Set by mtsTask::Kill. If the mtsTask::Run method is currently executing, it will finish, but no further calls will be made. The task will then call mtsTask::CleanupInternal, which calls the user-supplied mtsTask::Cleanup. The state will then be set to FINISHED. FINISHED – The task has finished.

Enumerator
CONSTRUCTED 
INITIALIZING 
READY 
ACTIVE 
FINISHING 
FINISHED 

Constructor & Destructor Documentation

◆ mtsComponentState() [1/3]

mtsComponentState::mtsComponentState ( void )

◆ mtsComponentState() [2/3]

mtsComponentState::mtsComponentState ( const mtsComponentState & other)

◆ ~mtsComponentState()

mtsComponentState::~mtsComponentState ( )

◆ mtsComponentState() [3/3]

mtsComponentState::mtsComponentState ( const mtsComponentState::Enum & newState)

Member Function Documentation

◆ Copy()

void mtsComponentState::Copy ( const mtsComponentState & source)

◆ DeSerializeRaw()

void mtsComponentState::DeSerializeRaw ( std::istream & inputStream)

◆ EnumVectorString()

const std::vector< std::string > & mtsComponentState::EnumVectorString ( void )
static

◆ GetState() [1/2]

void mtsComponentState::GetState ( mtsComponentState::Enum & placeHolder) const

◆ GetState() [2/2]

mtsComponentState::Enum mtsComponentState::GetState ( void ) const
inline

◆ operator!=()

bool mtsComponentState::operator!= ( const ThisType & state) const

◆ operator<()

bool mtsComponentState::operator< ( const ThisType & state) const

Lesser or equal operators

◆ operator<=()

bool mtsComponentState::operator<= ( const ThisType & state) const

◆ operator=() [1/2]

const ThisType & mtsComponentState::operator= ( const Enum & value)

Assignment operator.

◆ operator=() [2/2]

mtsComponentState & mtsComponentState::operator= ( const mtsComponentState & other)

◆ operator==()

bool mtsComponentState::operator== ( const ThisType & state) const

Equality operators

◆ operator>()

bool mtsComponentState::operator> ( const ThisType & state) const

Greater or equal operators

◆ operator>=()

bool mtsComponentState::operator>= ( const ThisType & state) const

◆ ScalarNumber()

size_t mtsComponentState::ScalarNumber ( void ) const

◆ ScalarNumberIsFixed()

bool mtsComponentState::ScalarNumberIsFixed ( void ) const

◆ SerializeRaw()

void mtsComponentState::SerializeRaw ( std::ostream & outputStream) const

◆ SetState()

void mtsComponentState::SetState ( const mtsComponentState::Enum & newValue)

◆ State() [1/2]

mtsComponentState::Enum & mtsComponentState::State ( void )

◆ State() [2/2]

const mtsComponentState::Enum & mtsComponentState::State ( void ) const

◆ ToStream()

void mtsComponentState::ToStream ( std::ostream & outputStream) const

◆ ToStreamRaw()

void mtsComponentState::ToStreamRaw ( std::ostream & outputStream,
const char delimiter = ' ',
bool headerOnly = false,
const std::string & headerPrefix = "" ) const

Member Data Documentation

◆ EnumVectorInt

std::string static EnumToString(const Enum &value) CISST_THROW(std Enum static EnumFromString(const std::string &value) CISST_THROW(std const std::vector< int > & mtsComponentState::EnumVectorInt(void)
static

◆ HumanReadable

void DeSerializeText(std::istream &inputStream, const char delimiter=',') CISST_THROW(std std::string mtsComponentState::HumanReadable(void) const

◆ mState

mtsComponentState::Enum mtsComponentState::mState
protected

◆ SerializeDescription

void SerializeBinary(std::ostream &outputStream) const CISST_THROW(std void DeSerializeBinary(std::istream &inputStream, const cmnDataFormat &localFormat, const cmnDataFormat &remoteFormat) CISST_THROW(std void SerializeText(std::ostream &outputStream, const char delimiter=',') const CISST_THROW(std std::string mtsComponentState::SerializeDescription(const char delimiter=',', const std::string &userDescription="") const

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