Orocos Real-Time Toolkit
2.8.3
|
#include <rtt/types/StreamFactory.hpp>
Public Member Functions | |
virtual | ~StreamFactory () |
Conversion to/from text | |
Used to convert data to human readable text and vice versa. | |
virtual std::ostream & | write (std::ostream &os, base::DataSourceBase::shared_ptr in) const =0 |
Output this datasource as a human readable string. More... | |
virtual std::istream & | read (std::istream &os, base::DataSourceBase::shared_ptr out) const =0 |
Read a new value for this datasource from a human readable string. More... | |
virtual std::string | toString (base::DataSourceBase::shared_ptr in) const |
Usability function which converts data to a string. More... | |
virtual bool | fromString (const std::string &value, base::DataSourceBase::shared_ptr out) const |
Usability function which converts a string to data. More... | |
virtual bool | isStreamable () const =0 |
Returns true if this type is directly streamable using read()/write() or toString()/fromString(). More... | |
Definition at line 16 of file StreamFactory.hpp.
|
inlinevirtual |
Definition at line 19 of file StreamFactory.hpp.
|
virtual |
Usability function which converts a string to data.
Definition at line 23 of file StreamFactory.cpp.
|
pure virtual |
Returns true if this type is directly streamable using read()/write() or toString()/fromString().
Implemented in RTT::types::PrimitiveTypeInfo< T, use_ostream >, RTT::types::PrimitiveTypeInfo< bool, use_ostream >, RTT::types::PrimitiveTypeInfo< T, has_ostream >, RTT::types::PrimitiveTypeInfo< rt_string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< double >, use_ostream >, RTT::types::PrimitiveTypeInfo< std::string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< T >, use_ostream >, and RTT::types::BoolTypeInfo.
|
pure virtual |
Read a new value for this datasource from a human readable string.
The default does nothing.
Implemented in RTT::types::PrimitiveTypeInfo< T, use_ostream >, RTT::types::PrimitiveTypeInfo< bool, use_ostream >, RTT::types::PrimitiveTypeInfo< T, has_ostream >, RTT::types::PrimitiveTypeInfo< rt_string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< double >, use_ostream >, RTT::types::PrimitiveTypeInfo< std::string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< T >, use_ostream >, and RTT::types::BoolTypeInfo.
|
virtual |
Usability function which converts data to a string.
Definition at line 12 of file StreamFactory.cpp.
|
pure virtual |
Output this datasource as a human readable string.
The default just writes the type name in parentheses to os.
Implemented in RTT::types::PrimitiveTypeInfo< T, use_ostream >, RTT::types::PrimitiveTypeInfo< bool, use_ostream >, RTT::types::PrimitiveTypeInfo< T, has_ostream >, RTT::types::PrimitiveTypeInfo< rt_string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< double >, use_ostream >, RTT::types::PrimitiveTypeInfo< std::string, use_ostream >, RTT::types::PrimitiveTypeInfo< std::vector< T >, use_ostream >, and RTT::types::BoolTypeInfo.