Class: Trestle::Scopes::Block::Evaluator
- Inherits:
-
Object
- Object
- Trestle::Scopes::Block::Evaluator
- Includes:
- EvaluationContext
- Defined in:
- lib/trestle/scopes/block.rb
Instance Attribute Summary collapse
-
#scopes ⇒ Object
readonly
Returns the value of attribute scopes.
Instance Method Summary collapse
-
#initialize(context = nil, **defaults) ⇒ Evaluator
constructor
A new instance of Evaluator.
- #scope(name, scope = nil, **options, &block) ⇒ Object
Constructor Details
#initialize(context = nil, **defaults) ⇒ Evaluator
Returns a new instance of Evaluator.
24 25 26 27 |
# File 'lib/trestle/scopes/block.rb', line 24 def initialize(context=nil, **defaults) @context, @defaults = context, defaults @scopes = [] end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Trestle::EvaluationContext
Instance Attribute Details
#scopes ⇒ Object (readonly)
Returns the value of attribute scopes.
22 23 24 |
# File 'lib/trestle/scopes/block.rb', line 22 def scopes @scopes end |