Class: Export
- Inherits:
-
Object
- Object
- Export
- Includes:
- ActiveModel::AttributeAssignment
- Defined in:
- app/models/export.rb
Overview
An export is a means of generating a file for export, usually CSV containing data about the plate.
Constant Summary collapse
- NotFound =
Raise if there is an attempt to find a non-existent model
Class.new(StandardError)
Instance Attribute Summary collapse
-
#ancestor_purpose ⇒ Object
Returns the value of attribute ancestor_purpose.
-
#ancestor_tube_purpose ⇒ Object
Returns the value of attribute ancestor_tube_purpose.
-
#csv ⇒ Object
Returns the value of attribute csv.
-
#file_extension ⇒ Object
Returns the value of attribute file_extension.
-
#filename ⇒ Object
Returns the value of attribute filename.
-
#plate_includes ⇒ Object
Returns the value of attribute plate_includes.
-
#tube_includes ⇒ Object
Returns the value of attribute tube_includes.
-
#tube_selects ⇒ Object
Returns the value of attribute tube_selects.
-
#workflow ⇒ Object
Returns the value of attribute workflow.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(args = {}) ⇒ Export
constructor
A new instance of Export.
Constructor Details
#initialize(args = {}) ⇒ Export
Returns a new instance of Export.
34 35 36 |
# File 'app/models/export.rb', line 34 def initialize(args = {}) assign_attributes(args) end |
Instance Attribute Details
#ancestor_purpose ⇒ Object
Returns the value of attribute ancestor_purpose.
24 25 26 |
# File 'app/models/export.rb', line 24 def ancestor_purpose @ancestor_purpose end |
#ancestor_tube_purpose ⇒ Object
Returns the value of attribute ancestor_tube_purpose.
24 25 26 |
# File 'app/models/export.rb', line 24 def ancestor_tube_purpose @ancestor_tube_purpose end |
#csv ⇒ Object
Returns the value of attribute csv.
24 25 26 |
# File 'app/models/export.rb', line 24 def csv @csv end |
#file_extension ⇒ Object
Returns the value of attribute file_extension.
24 25 26 |
# File 'app/models/export.rb', line 24 def file_extension @file_extension end |
#filename ⇒ Object
Returns the value of attribute filename.
24 25 26 |
# File 'app/models/export.rb', line 24 def filename @filename end |
#plate_includes ⇒ Object
Returns the value of attribute plate_includes.
24 25 26 |
# File 'app/models/export.rb', line 24 def plate_includes @plate_includes end |
#tube_includes ⇒ Object
Returns the value of attribute tube_includes.
24 25 26 |
# File 'app/models/export.rb', line 24 def tube_includes @tube_includes end |
#tube_selects ⇒ Object
Returns the value of attribute tube_selects.
24 25 26 |
# File 'app/models/export.rb', line 24 def tube_selects @tube_selects end |
#workflow ⇒ Object
Returns the value of attribute workflow.
24 25 26 |
# File 'app/models/export.rb', line 24 def workflow @workflow end |
Class Method Details
.find(id) ⇒ Object
18 19 20 21 |
# File 'app/models/export.rb', line 18 def find(id) attributes = loader.config.fetch(id) { raise NotFound, "Could not find export #{id}" } Export.new(attributes) end |
.loader ⇒ Object
14 15 16 |
# File 'app/models/export.rb', line 14 def loader @loader ||= ConfigLoader::ExportsLoader.new end |