Class: Parametric::Context
- Inherits:
-
Object
- Object
- Parametric::Context
- Defined in:
- lib/parametric/context.rb
Instance Method Summary collapse
- #add_error(msg) ⇒ Object
- #errors ⇒ Object
-
#initialize(path = nil, top = Top.new) ⇒ Context
constructor
A new instance of Context.
- #sub(key) ⇒ Object
Constructor Details
Instance Method Details
#add_error(msg) ⇒ Object
25 26 27 |
# File 'lib/parametric/context.rb', line 25 def add_error(msg) top.add_error(string_path, msg) end |
#errors ⇒ Object
21 22 23 |
# File 'lib/parametric/context.rb', line 21 def errors top.errors end |
#sub(key) ⇒ Object
29 30 31 |
# File 'lib/parametric/context.rb', line 29 def sub(key) self.class.new(path + [key], top) end |