Class: Eg::Book::Rent::CalculateLateHours
- Inherits:
-
Fit::ColumnFixture
- Object
- Fit::Fixture
- Fit::ColumnFixture
- Eg::Book::Rent::CalculateLateHours
- Defined in:
- lib/eg/book/rent/calculate_late_hours.rb
Constant Summary
Constants inherited from Fit::Fixture
Fit::Fixture::GRAY, Fit::Fixture::GREEN, Fit::Fixture::RED, Fit::Fixture::YELLOW
Instance Attribute Summary collapse
-
#count_grace ⇒ Object
writeonly
Sets the attribute count_grace.
-
#grace ⇒ Object
writeonly
Sets the attribute grace.
-
#high_demand ⇒ Object
writeonly
Sets the attribute high_demand.
-
#hours_late ⇒ Object
writeonly
Sets the attribute hours_late.
Attributes inherited from Fit::Fixture
#args, #counts, #listener, #summary
Instance Method Summary collapse
Methods inherited from Fit::ColumnFixture
#check, #do_cell, #do_row, #do_rows, #execute, #reset
Methods inherited from Fit::Fixture
camel, #check, #do_cell, #do_cells, #do_row, #do_rows, #do_table, #do_tables, #error, escape, #exception, #find_class, #fixture_name, #get_args_for_table, #get_linked_fixture_with_args, gray, #ignore, #info, #initialize, #interpret_following_tables, #interpret_tables, label, metadata, #parse, #right, #total_errors, #totals, #wrong
Constructor Details
This class inherits a constructor from Fit::Fixture
Instance Attribute Details
#count_grace=(string) ⇒ Object (writeonly)
Sets the attribute count_grace
9 10 11 |
# File 'lib/eg/book/rent/calculate_late_hours.rb', line 9 def count_grace=(value) @count_grace = value end |
#grace=(value) ⇒ Object (writeonly)
Sets the attribute grace
8 9 10 |
# File 'lib/eg/book/rent/calculate_late_hours.rb', line 8 def grace=(value) @grace = value end |
#high_demand=(value) ⇒ Object (writeonly)
Sets the attribute high_demand
8 9 10 |
# File 'lib/eg/book/rent/calculate_late_hours.rb', line 8 def high_demand=(value) @high_demand = value end |
#hours_late=(value) ⇒ Object (writeonly)
Sets the attribute hours_late
8 9 10 |
# File 'lib/eg/book/rent/calculate_late_hours.rb', line 8 def hours_late=(value) @hours_late = value end |
Instance Method Details
#extra_hours ⇒ Object
13 14 15 16 |
# File 'lib/eg/book/rent/calculate_late_hours.rb', line 13 def extra_hours late_returns = LateReturns.new @count_grace late_returns.extra_hours @hours_late, @grace, @high_demand end |