Class: FlexStationData::DefaultSampleMap
- Inherits:
-
Object
- Object
- FlexStationData::DefaultSampleMap
- Defined in:
- lib/flex_station_data/default_sample_map.rb
Instance Attribute Summary collapse
-
#columns ⇒ Object
readonly
Returns the value of attribute columns.
-
#rows ⇒ Object
readonly
Returns the value of attribute rows.
-
#wells_per_sample ⇒ Object
readonly
Returns the value of attribute wells_per_sample.
Instance Method Summary collapse
- #[](sample_label) ⇒ Object
-
#initialize(rows, columns, wells_per_sample) ⇒ DefaultSampleMap
constructor
A new instance of DefaultSampleMap.
Constructor Details
#initialize(rows, columns, wells_per_sample) ⇒ DefaultSampleMap
Returns a new instance of DefaultSampleMap.
7 8 9 10 11 |
# File 'lib/flex_station_data/default_sample_map.rb', line 7 def initialize(rows, columns, wells_per_sample) @rows = rows @columns = columns @wells_per_sample = wells_per_sample end |
Instance Attribute Details
#columns ⇒ Object (readonly)
Returns the value of attribute columns.
5 6 7 |
# File 'lib/flex_station_data/default_sample_map.rb', line 5 def columns @columns end |
#rows ⇒ Object (readonly)
Returns the value of attribute rows.
5 6 7 |
# File 'lib/flex_station_data/default_sample_map.rb', line 5 def rows @rows end |
#wells_per_sample ⇒ Object (readonly)
Returns the value of attribute wells_per_sample.
5 6 7 |
# File 'lib/flex_station_data/default_sample_map.rb', line 5 def wells_per_sample @wells_per_sample end |
Instance Method Details
#[](sample_label) ⇒ Object
13 14 15 16 |
# File 'lib/flex_station_data/default_sample_map.rb', line 13 def [](sample_label) sample_label = Integer(sample_label) map[sample_label] ||= map_sample(sample_label) end |