Class: SampleManifestExcel::Download
- Inherits:
-
Object
- Object
- SampleManifestExcel::Download
- Includes:
- ActiveModel::Model, SequencescapeExcel::Helpers::Download
- Defined in:
- app/sample_manifest_excel/sample_manifest_excel/download.rb
Overview
Download
Instance Attribute Summary collapse
-
#column_list ⇒ Object
readonly
Returns the value of attribute column_list.
-
#data_worksheet ⇒ Object
readonly
Returns the value of attribute data_worksheet.
-
#range_list ⇒ Object
readonly
Returns the value of attribute range_list.
-
#ranges_worksheet ⇒ Object
readonly
Returns the value of attribute ranges_worksheet.
-
#sample_manifest ⇒ Object
readonly
Returns the value of attribute sample_manifest.
Instance Method Summary collapse
-
#initialize(sample_manifest, column_list, range_list) ⇒ Download
constructor
A new instance of Download.
- #password ⇒ Object
Methods included from SequencescapeExcel::Helpers::Download
Constructor Details
#initialize(sample_manifest, column_list, range_list) ⇒ Download
Returns a new instance of Download.
14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 14 def initialize(sample_manifest, column_list, range_list) @sample_manifest = sample_manifest @range_list = range_list @column_list = column_list return unless valid? @ranges_worksheet = SequencescapeExcel::Worksheet::RangesWorksheet.new(ranges: range_list, workbook: workbook, password: password) @data_worksheet = Worksheet::DataWorksheet.new( workbook: workbook, columns: column_list, sample_manifest: sample_manifest, ranges: range_list, password: password ) end |
Instance Attribute Details
#column_list ⇒ Object (readonly)
Returns the value of attribute column_list.
12 13 14 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 12 def column_list @column_list end |
#data_worksheet ⇒ Object (readonly)
Returns the value of attribute data_worksheet.
12 13 14 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 12 def data_worksheet @data_worksheet end |
#range_list ⇒ Object (readonly)
Returns the value of attribute range_list.
12 13 14 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 12 def range_list @range_list end |
#ranges_worksheet ⇒ Object (readonly)
Returns the value of attribute ranges_worksheet.
12 13 14 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 12 def ranges_worksheet @ranges_worksheet end |
#sample_manifest ⇒ Object (readonly)
Returns the value of attribute sample_manifest.
12 13 14 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 12 def sample_manifest @sample_manifest end |
Instance Method Details
#password ⇒ Object
33 34 35 |
# File 'app/sample_manifest_excel/sample_manifest_excel/download.rb', line 33 def password @password ||= SecureRandom.base64 end |