Class: XTeamSchedule::Composer
- Inherits:
-
Object
- Object
- XTeamSchedule::Composer
- Defined in:
- lib/xteam_schedule/facilitation/composer.rb
Instance Attribute Summary collapse
-
#hash ⇒ Object
Returns the value of attribute hash.
-
#schedule ⇒ Object
Returns the value of attribute schedule.
Class Method Summary collapse
Instance Method Summary collapse
- #compose ⇒ Object
-
#initialize(schedule) ⇒ Composer
constructor
A new instance of Composer.
Constructor Details
#initialize(schedule) ⇒ Composer
Returns a new instance of Composer.
9 10 11 12 13 |
# File 'lib/xteam_schedule/facilitation/composer.rb', line 9 def initialize(schedule) schedule.save! self.schedule = schedule self.hash = {} end |
Instance Attribute Details
#hash ⇒ Object
Returns the value of attribute hash.
3 4 5 |
# File 'lib/xteam_schedule/facilitation/composer.rb', line 3 def hash @hash end |
#schedule ⇒ Object
Returns the value of attribute schedule.
3 4 5 |
# File 'lib/xteam_schedule/facilitation/composer.rb', line 3 def schedule @schedule end |
Class Method Details
.compose(schedule) ⇒ Object
5 6 7 |
# File 'lib/xteam_schedule/facilitation/composer.rb', line 5 def self.compose(schedule) new(schedule).compose end |
Instance Method Details
#compose ⇒ Object
15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/xteam_schedule/facilitation/composer.rb', line 15 def compose compose_resource_groups! compose_resources! compose_assignment_groups! compose_assignments! compose_working_times! compose_interface! compose_weekly_working_schedule! compose_holidays! compose_schedule! hash end |