Module: Stella::Report::Plugin::ClassMethods
- Defined in:
- lib/stella/report.rb
Instance Attribute Summary collapse
-
#plugin ⇒ Object
readonly
Returns the value of attribute plugin.
Instance Method Summary collapse
Instance Attribute Details
#plugin ⇒ Object (readonly)
Returns the value of attribute plugin.
52 53 54 |
# File 'lib/stella/report.rb', line 52 def plugin @plugin end |
Instance Method Details
#process(*args) ⇒ Object
61 62 63 |
# File 'lib/stella/report.rb', line 61 def process *args raise StellaError, "Must override run" end |
#register(plugin) ⇒ Object
53 54 55 56 57 58 59 60 |
# File 'lib/stella/report.rb', line 53 def register(plugin) @plugin = plugin extra_methods = eval "#{self}::ReportMethods" rescue nil Stella::Report.send(:include, extra_methods) if extra_methods Stella::Report.field plugin => self Stella::Report.plugins[plugin] = self Stella::Report.plugin_order << plugin end |