module OroGen::Gen::RTT_CPP::AttributeGeneration

Module that is used to add code generation functionality to Spec::Attribute

Public Instance Methods

register_for_generation() click to toggle source
# File lib/orogen/gen/tasks.rb, line 86
def register_for_generation
    constructor = []
    if default_value
        constructor << "_#{name}.set(#{cxx_default_value});"
    end
    constructor << "attributes()->addAttribute( _#{name} );"

    task.add_base_member("attribute", "_#{name}",
        "RTT::Attribute< #{type.cxx_name} >").
        initializer("_#{name}(\"#{name}\")").
        constructor(constructor.join("\n"))
    
    gen_dynamic_setter
end
used_types() click to toggle source
# File lib/orogen/gen/tasks.rb, line 82
def used_types
    each_interface_type.to_a
end