1 | <?php |
||
13 | class ModuleOptions extends AbstractOptions |
||
14 | { |
||
15 | /** |
||
16 | * @var float |
||
17 | */ |
||
18 | protected $hoursInDay = 7.5; |
||
19 | |||
20 | /** |
||
21 | * @var bool |
||
22 | */ |
||
23 | protected $skipWeekends = true; |
||
24 | |||
25 | /** |
||
26 | * @var float |
||
27 | */ |
||
28 | protected $lunchDuration = 1; |
||
29 | |||
30 | /** |
||
31 | * @var bool |
||
32 | */ |
||
33 | protected $cappedCreditEnabled = false; |
||
34 | |||
35 | /** |
||
36 | * @var array |
||
37 | */ |
||
38 | protected $creditCaps = []; |
||
39 | |||
40 | /** |
||
41 | * @param float $hoursInDay |
||
42 | * @return \JhFlexiTime\Options\ModuleOptions |
||
43 | */ |
||
44 | public function setHoursInDay($hoursInDay) |
||
49 | |||
50 | /** |
||
51 | * @return float |
||
52 | */ |
||
53 | public function getHoursInDay() |
||
57 | |||
58 | /** |
||
59 | * @param float $lunchDuration |
||
60 | * @return \JhFlexiTime\Options\ModuleOptions |
||
61 | */ |
||
62 | public function setLunchDuration($lunchDuration) |
||
67 | |||
68 | /** |
||
69 | * @return float |
||
70 | */ |
||
71 | public function getLunchDuration() |
||
75 | |||
76 | /** |
||
77 | * @param boolean $skipWeekends |
||
78 | * @return \JhFlexiTime\Options\ModuleOptions |
||
79 | */ |
||
80 | public function setSkipWeekends($skipWeekends) |
||
85 | |||
86 | /** |
||
87 | * @return boolean |
||
88 | */ |
||
89 | public function getSkipWeekends() |
||
93 | |||
94 | /** |
||
95 | * @return boolean |
||
96 | */ |
||
97 | public function skipWeekends() |
||
101 | |||
102 | /** |
||
103 | * @param bool $enabled |
||
104 | */ |
||
105 | public function setCreditCapEnabled($enabled) |
||
109 | |||
110 | /** |
||
111 | * @return bool |
||
112 | */ |
||
113 | public function getCreditCapEnabled() |
||
117 | |||
118 | /** |
||
119 | * @return bool |
||
120 | */ |
||
121 | public function creditCapEnabled() |
||
125 | |||
126 | /** |
||
127 | * @param array $caps |
||
128 | */ |
||
129 | public function setCreditCaps(array $caps) |
||
149 | |||
150 | /** |
||
151 | * @return array |
||
152 | */ |
||
153 | public function getCreditCaps() |
||
157 | |||
158 | /** |
||
159 | * @param DateTime $date |
||
160 | * |
||
161 | * @return float|null |
||
162 | */ |
||
163 | public function getCreditCapForDate(DateTime $date) |
||
172 | } |
||
173 |