22 if (index >= (
int) (v.
rows()) || index < 0)
29 if (index >= (
int) (v.
rows()) || index < 0)
41 #if (RTT_VERSION_MAJOR*100+RTT_VERSION_MINOR) >= 206 42 ,
public MemberFactory
49 #if (RTT_VERSION_MAJOR*100+RTT_VERSION_MINOR) >= 206 50 bool installTypeInfoObject(TypeInfo* ti) {
52 boost::shared_ptr< JntArrayTypeInfo > mthis = boost::dynamic_pointer_cast<
JntArrayTypeInfo >( this->getSharedPtr() );
57 ti->setMemberFactory( mthis );
80 sz = source.
find(
"size");
85 result.resize( sz_ds->
get() );
90 result.resize( source.
size() );
101 assert(result.rows() == source.
size());
102 assert(source.
size() == target.size());
103 assert(source.
size() == decomp.size());
105 Logger::log() <<Logger::Debug<<
"Successfuly composed type from "<< source.
getType() <<Logger::endl;
122 if (arg->isAssignable()) {
124 asarg->
set().resize( size );
133 std::vector<std::string> result;
134 result.push_back(
"size");
135 result.push_back(
"capacity");
142 unsigned int indx = boost::lexical_cast<
unsigned int>(name);
156 if ( id_name->
get() ==
"size" || id_name->
get() ==
"capacity") {
165 if ( item->isAssignable() )
172 log(
Error) <<
"JntArrayTypeInfo: No such member : " << id_name->
get() << endlog();
175 log(
Error) <<
"JntArrayTypeInfo: Invalid index : " << id_indx->
get() <<
":"<< id_indx->
getTypeName() << endlog();
177 if ( !id_name && ! id_indx)
178 log(
Error) <<
"JntArrayTypeInfo: Not a member or index : " <<
id <<
":"<<
id->getTypeName() << endlog();
186 RTT::types::Types()->addType(
new SequenceTypeInfo<std::vector< JntArray > >(
"KDL.JntArray[]") );
base::DataSourceBase::shared_ptr getMember(base::DataSourceBase::shared_ptr item, const std::string &name) const
virtual result_t get() const =0
unsigned int rows() const
bool resize(base::DataSourceBase::shared_ptr arg, int size) const
boost::call_traits< value_t >::reference reference_t
INLINE Rall1d< T, V, S > log(const Rall1d< T, V, S > &arg)
const std::string & getType() const
bool refreshProperties(const PropertyBag &target, const PropertyBag &source, bool allprops)
virtual void set(param_t t)=0
bool RTT_API composePropertyBag(PropertyBag const &sourcebag, PropertyBag &target)
base::DataSourceBase * newFunctorDataSource(Function f, const std::vector< base::DataSourceBase::shared_ptr > &args)
double get_item_copy(const JntArray &v, int index)
bool composeType(base::DataSourceBase::shared_ptr dssource, base::DataSourceBase::shared_ptr dsresult) const
base::PropertyBase * find(const std::string &name) const
virtual const_reference_t rvalue() const =0
base::DataSourceBase::shared_ptr getMember(base::DataSourceBase::shared_ptr item, base::DataSourceBase::shared_ptr id) const
virtual std::vector< std::string > getMemberNames() const
static AssignableDataSource< T > * narrow(base::DataSourceBase *db)
TypeInfoRepository::shared_ptr Types()
bool typeDecomposition(base::DataSourceBase::shared_ptr dsb, PropertyBag &targetbag, bool recurse)
boost::intrusive_ptr< DataSource< T > > shared_ptr
boost::intrusive_ptr< AssignableDataSource< T > > shared_ptr
static DataSource< T > * narrow(base::DataSourceBase *db)
base::DataSourceBase::shared_ptr decomposeType(base::DataSourceBase::shared_ptr source) const
bool installTypeInfoObject(TypeInfo *ti)
virtual std::string getTypeName() const
double & get_item(JntArray &v, int index)
boost::intrusive_ptr< DataSourceBase > shared_ptr
virtual DataSourceBase::shared_ptr getDataSource() const =0