Class: Appydave::Tools::Jump::Formatters::Base
- Inherits:
-
Object
- Object
- Appydave::Tools::Jump::Formatters::Base
- Defined in:
- lib/appydave/tools/jump/formatters/base.rb
Overview
Base formatter class providing common functionality
Direct Known Subclasses
Instance Attribute Summary collapse
-
#data ⇒ Object
readonly
Returns the value of attribute data.
-
#options ⇒ Object
readonly
Returns the value of attribute options.
Instance Method Summary collapse
-
#format ⇒ String
Format the data.
-
#initialize(data, options = {}) ⇒ Base
constructor
A new instance of Base.
Constructor Details
#initialize(data, options = {}) ⇒ Base
Returns a new instance of Base.
11 12 13 14 |
# File 'lib/appydave/tools/jump/formatters/base.rb', line 11 def initialize(data, = {}) @data = data @options = end |
Instance Attribute Details
#data ⇒ Object (readonly)
Returns the value of attribute data.
9 10 11 |
# File 'lib/appydave/tools/jump/formatters/base.rb', line 9 def data @data end |
#options ⇒ Object (readonly)
Returns the value of attribute options.
9 10 11 |
# File 'lib/appydave/tools/jump/formatters/base.rb', line 9 def @options end |
Instance Method Details
#format ⇒ String
Format the data
19 20 21 |
# File 'lib/appydave/tools/jump/formatters/base.rb', line 19 def format raise NotImplementedError, 'Subclasses must implement #format' end |