예제 #1
0
    void loadStdTypes(TypeInfoRepository::shared_ptr ti)
    {
        // string is a special case for assignment, we need to assign from the c_str() instead of from the string(),
        // the latter causes capacity changes, probably due to the copy-on-write implementation of string(). Assignment
        // from a c-style string obviously disables a copy-on-write connection.
#ifndef RTT_NO_STD_TYPES
        ti->addType( new StdStringTypeInfo() );
        ti->addType( new SequenceTypeInfo<std::vector<double> >("array") );
#endif
#ifdef OS_RT_MALLOC
        ti->addType( new RTStringTypeInfo() );
#endif
    }
 // load the Orocos specific types:
 void loadOrocosTypes( TypeInfoRepository::shared_ptr ti ) {
     ti->addType( new StdTypeInfo<FlowStatus>("FlowStatus"));
     ti->addType( new StdTypeInfo<SendStatus>("SendStatus"));
     ti->addType( new TemplateTypeInfo<PropertyBag, true>("PropertyBag") );
     ti->addType( new StdVectorTypeInfo("array") );
     ti->addType( new StructTypeInfo<ConnPolicy,false>("ConnPolicy") );
     ti->addType( new TemplateTypeInfo<EmptySendHandle>("SendHandle") ); //dummy, replaced by real stuff when seen by parser.
     ti->addType( new TemplateTypeInfo<TaskContext*>("TaskContext"));
 }