1 #ifndef ORO_SEQUENCE_TYPE_INFO_HPP 2 #define ORO_SEQUENCE_TYPE_INFO_HPP 16 template<
class T,
bool has_ostream=false>
17 class SequenceTypeInfo
18 :
public TemplateTypeInfo<T,has_ostream>,
public SequenceTypeInfoBase<T>,
public MemberFactory
This template class allows user types to be used in all Orocos primitives.
bool resize(base::DataSourceBase::shared_ptr arg, int size) const
std::vector< std::string > getMemberNames() const
virtual base::DataSourceBase::shared_ptr decomposeType(base::DataSourceBase::shared_ptr source) const
A primitive type is decomposed into itself.
virtual base::DataSourceBase::shared_ptr getMember(base::DataSourceBase::shared_ptr item, const std::string &name) const
Returns a member of a given data source struct identified by its name.
SequenceTypeInfo(std::string name)
base::DataSourceBase::shared_ptr getMember(base::DataSourceBase::shared_ptr item, const std::string &name) const
virtual base::DataSourceBase::shared_ptr getMember(base::DataSourceBase::shared_ptr item, base::DataSourceBase::shared_ptr id) const
Returns a member of a given data source identified by a data source id.
An attribute is a minimalistic, named placeholder for data.
base::DataSourceBase::shared_ptr decomposeType(base::DataSourceBase::shared_ptr source) const
Use getMember() for decomposition...
virtual bool composeType(base::DataSourceBase::shared_ptr dssource, base::DataSourceBase::shared_ptr dsresult) const
bool installTypeInfoObject(TypeInfo *ti)
Installs the type info object in the global data source type info handler and adds any additional fea...
A class for representing a user type, and which can build instances of that type. ...
base::AttributeBase * buildVariable(std::string name, int size) const
void setMemberFactory(MemberFactoryPtr mf)
bool composeType(base::DataSourceBase::shared_ptr dssource, base::DataSourceBase::shared_ptr dsresult) const
Specialize to resize result given the size of source.
Template for data types that are C++ STL Sequences with operator[], size() and capacity() methods...
bool installTypeInfoObject(TypeInfo *ti)
bool installTypeInfoObject(TypeInfo *ti)
Installs the type info object in the global data source type info handler and adds any additional fea...
virtual std::vector< std::string > getMemberNames() const
Returns the list of struct member names of this type.
boost::intrusive_ptr< DataSourceBase > shared_ptr
Use this type to store a pointer to a DataSourceBase.
Contains TaskContext, Activity, OperationCaller, Operation, Property, InputPort, OutputPort, Attribute.
Old-style SequenceTypeInfo which offers type info for sequences which can be sent over flow ports...
base::AttributeBase * buildVariable(std::string name, int size) const
Build a modifyable instance of this type.
virtual bool resize(base::DataSourceBase::shared_ptr arg, int size) const
Tries to resize a data source in case it's a resizable sequence.
boost::shared_ptr< PrimitiveTypeInfo< T, use_ostream > > getSharedPtr()