Class: Context::DSL::PluginBlock
Overview
make plugin statement
Instance Attribute Summary
Attributes inherited from Block
#child_statements, #context_dsl, #parent_block
Instance Method Summary collapse
-
#initialize(context_dsl, parent_block, name) ⇒ PluginBlock
constructor
A new instance of PluginBlock.
-
#method_missing(name, *args) ⇒ Object
delegating of @statement.
- #to_statement ⇒ Object
Methods inherited from Block
Constructor Details
#initialize(context_dsl, parent_block, name) ⇒ PluginBlock
Returns a new instance of PluginBlock.
39 40 41 42 |
# File 'lib/mashfeed/dsl.rb', line 39 def initialize(context_dsl, parent_block, name) super @statement = Statement.new(Mashfeed::Plugin[name.to_s].new) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(name, *args) ⇒ Object
delegating of @statement
45 46 47 |
# File 'lib/mashfeed/dsl.rb', line 45 def method_missing(name, *args) @statement.send(name, *args) end |
Instance Method Details
#to_statement ⇒ Object
49 50 51 |
# File 'lib/mashfeed/dsl.rb', line 49 def to_statement @statement end |