RTT::types::EmptyTypeInfo Class Reference

#include <TypeInfoName.hpp>

Inheritance diagram for RTT::types::EmptyTypeInfo:
Inheritance graph
[legend]

List of all members.

Public Member Functions

base::DataSourceBase::shared_ptr buildActionAlias (base::ActionInterface *act, base::DataSourceBase::shared_ptr in) const
base::DataSourceBase::shared_ptr buildActionAlias (base::ActionInterface *act, base::DataSourceBase::shared_ptr in) const
base::AttributeBasebuildAlias (std::string name, base::DataSourceBase::shared_ptr in) const
base::AttributeBasebuildAlias (std::string name, base::DataSourceBase::shared_ptr in) const
base::AttributeBasebuildAttribute (std::string name, base::DataSourceBase::shared_ptr in) const
base::AttributeBasebuildAttribute (std::string name, base::DataSourceBase::shared_ptr in) const
virtual
base::ChannelElementBase::shared_ptr 
buildChannelInput (base::OutputPortInterface &port) const
virtual
base::ChannelElementBase::shared_ptr 
buildChannelInput (base::OutputPortInterface &port) const
virtual
base::ChannelElementBase::shared_ptr 
buildChannelOutput (base::InputPortInterface &port) const
virtual
base::ChannelElementBase::shared_ptr 
buildChannelOutput (base::InputPortInterface &port) const
base::AttributeBasebuildConstant (std::string name, base::DataSourceBase::shared_ptr dsb) const
base::AttributeBasebuildConstant (std::string name, base::DataSourceBase::shared_ptr dsb) const
virtual
base::ChannelElementBase::shared_ptr 
buildDataStorage (ConnPolicy const &policy) const
virtual
base::ChannelElementBase::shared_ptr 
buildDataStorage (ConnPolicy const &policy) const
virtual base::PropertyBasebuildProperty (const std::string &name, const std::string &desc, base::DataSourceBase::shared_ptr source=0) const
virtual base::PropertyBasebuildProperty (const std::string &name, const std::string &desc, base::DataSourceBase::shared_ptr source=0) const
virtual
base::DataSourceBase::shared_ptr 
buildReference (void *) const
virtual
base::DataSourceBase::shared_ptr 
buildReference (void *) const
virtual
base::DataSourceBase::shared_ptr 
buildValue () const
virtual
base::DataSourceBase::shared_ptr 
buildValue () const
base::AttributeBasebuildVariable (std::string name) const
base::AttributeBasebuildVariable (std::string name) const
virtual bool composeType (base::DataSourceBase::shared_ptr source, base::DataSourceBase::shared_ptr result) const
virtual bool composeType (base::DataSourceBase::shared_ptr source, base::DataSourceBase::shared_ptr result) const
base::DataSourceBase::shared_ptr construct (const std::vector< base::DataSourceBase::shared_ptr > &) const
base::DataSourceBase::shared_ptr construct (const std::vector< base::DataSourceBase::shared_ptr > &) const
virtual
base::DataSourceBase::shared_ptr 
decomposeType (base::DataSourceBase::shared_ptr source) const
virtual
base::DataSourceBase::shared_ptr 
decomposeType (base::DataSourceBase::shared_ptr source) const
 EmptyTypeInfo (std::string name)
 EmptyTypeInfo (std::string name)
virtual
base::DataSourceBase::shared_ptr 
getAssignable (base::DataSourceBase::shared_ptr arg) const
virtual
base::DataSourceBase::shared_ptr 
getAssignable (base::DataSourceBase::shared_ptr arg) const
virtual std::string getTypeIdName () const
virtual std::string getTypeIdName () const
virtual const std::string & getTypeName () const
virtual const std::string & getTypeName () const
virtual base::InputPortInterfaceinputPort (std::string const &name) const
virtual base::InputPortInterfaceinputPort (std::string const &name) const
bool installTypeInfoObject ()
bool installTypeInfoObject ()
virtual bool isStreamable () const
virtual bool isStreamable () const
virtual base::OutputPortInterfaceoutputPort (std::string const &name) const
virtual base::OutputPortInterfaceoutputPort (std::string const &name) const
virtual std::istream & read (std::istream &is, base::DataSourceBase::shared_ptr out) const
virtual std::istream & read (std::istream &is, base::DataSourceBase::shared_ptr out) const
virtual std::ostream & write (std::ostream &os, base::DataSourceBase::shared_ptr in) const
virtual std::ostream & write (std::ostream &os, base::DataSourceBase::shared_ptr in) const

Protected Attributes

const std::string tname

Detailed Description

Empty implementation of TypeInfo interface.

Definition at line 53 of file install/include/rtt/types/TypeInfoName.hpp.


Constructor & Destructor Documentation

RTT::types::EmptyTypeInfo::EmptyTypeInfo ( std::string  name  )  [inline]

Definition at line 59 of file install/include/rtt/types/TypeInfoName.hpp.

RTT::types::EmptyTypeInfo::EmptyTypeInfo ( std::string  name  )  [inline]

Definition at line 59 of file rtt/types/TypeInfoName.hpp.


Member Function Documentation

base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildActionAlias ( base::ActionInterface action,
base::DataSourceBase::shared_ptr  source 
) const [inline, virtual]

Returns a DataSource that first executes an action and returns the result of another data source. If source is an AssignableDataSource, an AssignableDataSource is returned of the same type, otherwise, a plain DataSource is returned.

Implements RTT::types::TypeInfo.

Definition at line 99 of file rtt/types/TypeInfoName.hpp.

base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildActionAlias ( base::ActionInterface action,
base::DataSourceBase::shared_ptr  source 
) const [inline, virtual]

Returns a DataSource that first executes an action and returns the result of another data source. If source is an AssignableDataSource, an AssignableDataSource is returned of the same type, otherwise, a plain DataSource is returned.

Implements RTT::types::TypeInfo.

Definition at line 99 of file install/include/rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildAlias ( std::string  name,
base::DataSourceBase::shared_ptr  b 
) const [inline, virtual]

build an alias with b as the value. If b is of the wrong type, 0 will be returned..

Implements RTT::types::TypeInfo.

Definition at line 92 of file rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildAlias ( std::string  name,
base::DataSourceBase::shared_ptr  b 
) const [inline, virtual]

build an alias with b as the value. If b is of the wrong type, 0 will be returned..

Implements RTT::types::TypeInfo.

Definition at line 92 of file install/include/rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildAttribute ( std::string  name,
base::DataSourceBase::shared_ptr  source 
) const [inline, virtual]

Build an Attribute of this type.

Implements RTT::types::TypeInfo.

Definition at line 85 of file rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildAttribute ( std::string  name,
base::DataSourceBase::shared_ptr  source 
) const [inline, virtual]

Build an Attribute of this type.

Implements RTT::types::TypeInfo.

Definition at line 85 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildChannelInput ( base::OutputPortInterface port  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 175 of file rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildChannelInput ( base::OutputPortInterface port  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 175 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildChannelOutput ( base::InputPortInterface port  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 173 of file rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildChannelOutput ( base::InputPortInterface port  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 173 of file install/include/rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildConstant ( std::string  name,
base::DataSourceBase::shared_ptr  dsb 
) const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 71 of file rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildConstant ( std::string  name,
base::DataSourceBase::shared_ptr  dsb 
) const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 71 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildDataStorage ( ConnPolicy const &  policy  )  const [inline, virtual]

Creates single data or buffered storage for this type.

Parameters:
policy Describes the kind of storage requested by the user
Returns:
a storage element.

Implements RTT::types::TypeInfo.

Definition at line 171 of file rtt/types/TypeInfoName.hpp.

virtual base::ChannelElementBase::shared_ptr RTT::types::EmptyTypeInfo::buildDataStorage ( ConnPolicy const &  policy  )  const [inline, virtual]

Creates single data or buffered storage for this type.

Parameters:
policy Describes the kind of storage requested by the user
Returns:
a storage element.

Implements RTT::types::TypeInfo.

Definition at line 171 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::PropertyBase* RTT::types::EmptyTypeInfo::buildProperty ( const std::string &  name,
const std::string &  desc,
base::DataSourceBase::shared_ptr  source = 0 
) const [inline, virtual]

Build a Property of this type.

Implements RTT::types::TypeInfo.

Definition at line 108 of file rtt/types/TypeInfoName.hpp.

virtual base::PropertyBase* RTT::types::EmptyTypeInfo::buildProperty ( const std::string &  name,
const std::string &  desc,
base::DataSourceBase::shared_ptr  source = 0 
) const [inline, virtual]

Build a Property of this type.

Implements RTT::types::TypeInfo.

Definition at line 108 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildReference ( void *  ptr  )  const [inline, virtual]

Build a internal::ReferenceDataSource of this type, pointing to the given pointer

Implements RTT::types::TypeInfo.

Definition at line 120 of file rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildReference ( void *  ptr  )  const [inline, virtual]

Build a internal::ReferenceDataSource of this type, pointing to the given pointer

Implements RTT::types::TypeInfo.

Definition at line 120 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildValue (  )  const [inline, virtual]

Build a internal::ValueDataSource of this type.

Implements RTT::types::TypeInfo.

Definition at line 114 of file rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::buildValue (  )  const [inline, virtual]

Build a internal::ValueDataSource of this type.

Implements RTT::types::TypeInfo.

Definition at line 114 of file install/include/rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildVariable ( std::string  name  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 78 of file rtt/types/TypeInfoName.hpp.

base::AttributeBase* RTT::types::EmptyTypeInfo::buildVariable ( std::string  name  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 78 of file install/include/rtt/types/TypeInfoName.hpp.

virtual bool RTT::types::EmptyTypeInfo::composeType ( base::DataSourceBase::shared_ptr  source,
base::DataSourceBase::shared_ptr  target 
) const [inline, virtual]

Compose a type (target) from a DataSourceBase (source) containing its members. The default behavior tries to assign source to target. If that fails, it tries to decompose target into its members and update the members of target with the contents of source.

The default implementation in TemplateTypeInfo works for most types, but can be overridden in case there are multiple versions/possibilities to make a target from a source. For example, in order to support legacy formats or in order to do the inverse of decomposeType().

Parameters:
source A data source of the same type as target OR a PropertyBag that contains the parts of target to be refreshed.
target A data source of the same type as this TypeInfo object which contains the data to be updated from source.
Returns:
true if source could be updated, false otherwise.
See also:
types::propertyDecomposition and types::typeDecomposition for the inverse function, decomposing a type into datasources and hierarchical properties.
decomposeType to do the inverse operation.

Implements RTT::types::TypeInfo.

Definition at line 159 of file rtt/types/TypeInfoName.hpp.

virtual bool RTT::types::EmptyTypeInfo::composeType ( base::DataSourceBase::shared_ptr  source,
base::DataSourceBase::shared_ptr  target 
) const [inline, virtual]

Compose a type (target) from a DataSourceBase (source) containing its members. The default behavior tries to assign source to target. If that fails, it tries to decompose target into its members and update the members of target with the contents of source.

The default implementation in TemplateTypeInfo works for most types, but can be overridden in case there are multiple versions/possibilities to make a target from a source. For example, in order to support legacy formats or in order to do the inverse of decomposeType().

Parameters:
source A data source of the same type as target OR a PropertyBag that contains the parts of target to be refreshed.
target A data source of the same type as this TypeInfo object which contains the data to be updated from source.
Returns:
true if source could be updated, false otherwise.
See also:
types::propertyDecomposition and types::typeDecomposition for the inverse function, decomposing a type into datasources and hierarchical properties.
decomposeType to do the inverse operation.

Implements RTT::types::TypeInfo.

Definition at line 159 of file install/include/rtt/types/TypeInfoName.hpp.

base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::construct ( const std::vector< base::DataSourceBase::shared_ptr > &  args  )  const [inline, virtual]

Constructor syntax: construct a internal::DataSource which returns an instance of data depending on the given arguments. When args is empty, the default 'variable' is returned.

Reimplemented from RTT::types::TypeInfo.

Definition at line 127 of file rtt/types/TypeInfoName.hpp.

base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::construct ( const std::vector< base::DataSourceBase::shared_ptr > &  args  )  const [inline, virtual]

Constructor syntax: construct a internal::DataSource which returns an instance of data depending on the given arguments. When args is empty, the default 'variable' is returned.

Reimplemented from RTT::types::TypeInfo.

Definition at line 127 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::decomposeType ( base::DataSourceBase::shared_ptr  source  )  const [inline, virtual]

Specialize this function to return an alternate type which represents this one in a compatible way. For example, a short converts to an long or an enum to an int or a string. If your return a datasource containing a property bag, then this function should do the inverse of composeType: the returned property bag contains all parts of the current type (source) which can be modified and merged back into this type with composeType. Mathematically: composeType( decomposeType( A ), B); assert( A == B );

Returns:
null if this type is not convertible to anything else. You may return source itself in order to prevent any further decomposition of your type (using getMember(), which is used as fall-back by the rest of the software). For example, to avoid that a string is decomposed into a sequence of chars.

Reimplemented from RTT::types::TypeInfo.

Definition at line 153 of file rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::decomposeType ( base::DataSourceBase::shared_ptr  source  )  const [inline, virtual]

Specialize this function to return an alternate type which represents this one in a compatible way. For example, a short converts to an long or an enum to an int or a string. If your return a datasource containing a property bag, then this function should do the inverse of composeType: the returned property bag contains all parts of the current type (source) which can be modified and merged back into this type with composeType. Mathematically: composeType( decomposeType( A ), B); assert( A == B );

Returns:
null if this type is not convertible to anything else. You may return source itself in order to prevent any further decomposition of your type (using getMember(), which is used as fall-back by the rest of the software). For example, to avoid that a string is decomposed into a sequence of chars.

Reimplemented from RTT::types::TypeInfo.

Definition at line 153 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::getAssignable ( base::DataSourceBase::shared_ptr  arg  )  const [inline, virtual]

Definition at line 133 of file rtt/types/TypeInfoName.hpp.

virtual base::DataSourceBase::shared_ptr RTT::types::EmptyTypeInfo::getAssignable ( base::DataSourceBase::shared_ptr  arg  )  const [inline, virtual]

Definition at line 133 of file install/include/rtt/types/TypeInfoName.hpp.

virtual std::string RTT::types::EmptyTypeInfo::getTypeIdName (  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 165 of file rtt/types/TypeInfoName.hpp.

virtual std::string RTT::types::EmptyTypeInfo::getTypeIdName (  )  const [inline, virtual]

Implements RTT::types::TypeInfo.

Definition at line 165 of file install/include/rtt/types/TypeInfoName.hpp.

virtual const std::string& RTT::types::EmptyTypeInfo::getTypeName (  )  const [inline, virtual]

Return unique the type name.

Implements RTT::types::TypeInfo.

Definition at line 106 of file rtt/types/TypeInfoName.hpp.

virtual const std::string& RTT::types::EmptyTypeInfo::getTypeName (  )  const [inline, virtual]

Return unique the type name.

Implements RTT::types::TypeInfo.

Definition at line 106 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::InputPortInterface* RTT::types::EmptyTypeInfo::inputPort ( std::string const &  name  )  const [inline, virtual]

Returns a new InputPort<T> object where T is the type represented by this TypeInfo object.

Implements RTT::types::TypeInfo.

Definition at line 167 of file rtt/types/TypeInfoName.hpp.

virtual base::InputPortInterface* RTT::types::EmptyTypeInfo::inputPort ( std::string const &  name  )  const [inline, virtual]

Returns a new InputPort<T> object where T is the type represented by this TypeInfo object.

Implements RTT::types::TypeInfo.

Definition at line 167 of file install/include/rtt/types/TypeInfoName.hpp.

bool RTT::types::EmptyTypeInfo::installTypeInfoObject (  )  [inline, virtual]

Installs the type info object in the global data source type info handler. This will be called by the TypeInfoRepository, prior to registering this type. If installation fails the TypeInfoRepository will delete this object, and all its associated constructors.

Return values:
true installation succeeded. This object should not be deleted during the execution of the current process.
false installation failed. This object is not used and may be deleted.

Implements RTT::types::TypeInfo.

Reimplemented in RTT::types::TypeInfoName< T >, and RTT::types::TypeInfoName< T >.

Definition at line 67 of file rtt/types/TypeInfoName.hpp.

bool RTT::types::EmptyTypeInfo::installTypeInfoObject (  )  [inline, virtual]

Installs the type info object in the global data source type info handler. This will be called by the TypeInfoRepository, prior to registering this type. If installation fails the TypeInfoRepository will delete this object, and all its associated constructors.

Return values:
true installation succeeded. This object should not be deleted during the execution of the current process.
false installation failed. This object is not used and may be deleted.

Implements RTT::types::TypeInfo.

Reimplemented in RTT::types::TypeInfoName< T >, and RTT::types::TypeInfoName< T >.

Definition at line 67 of file install/include/rtt/types/TypeInfoName.hpp.

virtual bool RTT::types::EmptyTypeInfo::isStreamable (  )  const [inline, virtual]

Returns true if this type is directly streamable using read()/write() or toString()/fromString().

Implements RTT::types::TypeInfo.

Definition at line 151 of file rtt/types/TypeInfoName.hpp.

virtual bool RTT::types::EmptyTypeInfo::isStreamable (  )  const [inline, virtual]

Returns true if this type is directly streamable using read()/write() or toString()/fromString().

Implements RTT::types::TypeInfo.

Definition at line 151 of file install/include/rtt/types/TypeInfoName.hpp.

virtual base::OutputPortInterface* RTT::types::EmptyTypeInfo::outputPort ( std::string const &  name  )  const [inline, virtual]

Returns a new OutputPort<T> object where T is the type represented by this TypeInfo object.

Implements RTT::types::TypeInfo.

Definition at line 169 of file rtt/types/TypeInfoName.hpp.

virtual base::OutputPortInterface* RTT::types::EmptyTypeInfo::outputPort ( std::string const &  name  )  const [inline, virtual]

Returns a new OutputPort<T> object where T is the type represented by this TypeInfo object.

Implements RTT::types::TypeInfo.

Definition at line 169 of file install/include/rtt/types/TypeInfoName.hpp.

virtual std::istream& RTT::types::EmptyTypeInfo::read ( std::istream &  os,
base::DataSourceBase::shared_ptr  out 
) const [inline, virtual]

Read a new value for this datasource from a human readable string. The default does nothing.

Implements RTT::types::TypeInfo.

Definition at line 146 of file rtt/types/TypeInfoName.hpp.

virtual std::istream& RTT::types::EmptyTypeInfo::read ( std::istream &  os,
base::DataSourceBase::shared_ptr  out 
) const [inline, virtual]

Read a new value for this datasource from a human readable string. The default does nothing.

Implements RTT::types::TypeInfo.

Definition at line 146 of file install/include/rtt/types/TypeInfoName.hpp.

virtual std::ostream& RTT::types::EmptyTypeInfo::write ( std::ostream &  os,
base::DataSourceBase::shared_ptr  in 
) const [inline, virtual]

Output this datasource as a human readable string. The default just writes the type name in parentheses to os.

Implements RTT::types::TypeInfo.

Definition at line 137 of file rtt/types/TypeInfoName.hpp.

virtual std::ostream& RTT::types::EmptyTypeInfo::write ( std::ostream &  os,
base::DataSourceBase::shared_ptr  in 
) const [inline, virtual]

Output this datasource as a human readable string. The default just writes the type name in parentheses to os.

Implements RTT::types::TypeInfo.

Definition at line 137 of file install/include/rtt/types/TypeInfoName.hpp.


Member Data Documentation

const std::string RTT::types::EmptyTypeInfo::tname [protected]

Definition at line 57 of file install/include/rtt/types/TypeInfoName.hpp.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines


rtt
Author(s): RTT Developers
autogenerated on Fri Jan 11 09:50:17 2013