Class: ActsAsCalculatorEditor::ExportLookupTables
- Inherits:
-
Object
- Object
- ActsAsCalculatorEditor::ExportLookupTables
- Defined in:
- lib/acts_as_calculator_editor/export_lookup_tables.rb
Overview
The lookup_tables section of an import document. The core gem has no
SerializeLookupTable to borrow (docs/core-gem-contract.md ยง4.4), so the shape is built
from the migration's own columns.
Class Method Summary collapse
Instance Method Summary collapse
- #call ⇒ Object
-
#initialize(key: nil, scope: nil) ⇒ ExportLookupTables
constructor
A new instance of ExportLookupTables.
Constructor Details
#initialize(key: nil, scope: nil) ⇒ ExportLookupTables
Returns a new instance of ExportLookupTables.
12 13 14 15 |
# File 'lib/acts_as_calculator_editor/export_lookup_tables.rb', line 12 def initialize(key: nil, scope: nil) @key = key @scope = scope end |
Class Method Details
.call ⇒ Object
8 9 10 |
# File 'lib/acts_as_calculator_editor/export_lookup_tables.rb', line 8 def self.call(...) new(...).call end |
Instance Method Details
#call ⇒ Object
17 18 19 |
# File 'lib/acts_as_calculator_editor/export_lookup_tables.rb', line 17 def call tables.map { |table| entry(table) } end |