class Origen::Parameters::Missing
An instance of this class is returned whenever the parameter context is set to a value for which no parameter set has been defined.
Sometime this may be valid in the case where the context is actually implemented by another object which shadows the context.
The missing allows the user to do params.context to retrieve the value of the current context, but it will error out with a useful error message if they try to do anything else (i.e. retrieve a parameter from it)
Attributes
owner[R]
Public Class Methods
new(options = {})
click to toggle source
# File lib/origen/parameters/missing.rb, line 15 def initialize(options = {}) @owner = options[:owner] end
Public Instance Methods
context()
click to toggle source
# File lib/origen/parameters/missing.rb, line 19 def context owner._parameter_current end
method_missing(_method, *_args, &_block)
click to toggle source
# File lib/origen/parameters/missing.rb, line 23 def method_missing(_method, *_args, &_block) owner.send(:_validate_parameter_set_name, context) end