class OroGen::Gen::RTT_CPP::BuildDependency

Attributes

context[R]
pkg_name[R]
var_name[R]

Public Class Methods

new(var_name, pkg_name) click to toggle source
# File lib/orogen/gen/base.rb, line 54
def initialize(var_name, pkg_name)
    @var_name = var_name.gsub(/[^\w]/, '_')
    @pkg_name = pkg_name
    @context = []
end

Public Instance Methods

in_context(*args) click to toggle source
# File lib/orogen/gen/base.rb, line 60
def in_context(*args)
    context << args.to_set
    self
end
in_context?(*args) click to toggle source
# File lib/orogen/gen/base.rb, line 74
def in_context?(*args)
    args = args.to_set
    context.any? do |ctx|
        (args & ctx).size == args.size
    end
end
remove_context(*args) click to toggle source
# File lib/orogen/gen/base.rb, line 65
def remove_context(*args)
    args = args.to_set
    @context = context.dup
    context.delete_if do |ctx|
        (args & ctx).size == args.size
    end
    self
end