1 | <?php |
||
9 | class TimeInterval extends Base implements QueryInterface |
||
10 | { |
||
11 | protected $currentDate; |
||
12 | protected $interval; |
||
13 | protected $dateTimeField; |
||
14 | |||
15 | /** |
||
16 | * Define the time range to use for each query set |
||
17 | * |
||
18 | * @param \DateInterval $interval |
||
19 | * @return $this |
||
20 | */ |
||
21 | public function setIntervalDateTime(\DateInterval $interval) |
||
27 | |||
28 | /** |
||
29 | * Set the "current" time that the query will work from |
||
30 | * |
||
31 | * @param \DateTime $dateTime |
||
32 | * @return $this |
||
33 | */ |
||
34 | public function setHeadDateTime(\DateTime $dateTime) |
||
40 | |||
41 | /** |
||
42 | * Define the database field which will be used as the DateTime handler |
||
43 | * |
||
44 | * @param string $fieldName |
||
45 | * @return $this |
||
46 | */ |
||
47 | public function setDateTimeField($fieldName) |
||
53 | |||
54 | /** |
||
55 | * For this report type, add the custom logic to query |
||
56 | * |
||
57 | * @return type |
||
58 | */ |
||
59 | public function prepareQuery() |
||
73 | |||
74 | /** |
||
75 | * Stringify the current data set |
||
76 | * |
||
77 | * @return string |
||
78 | */ |
||
79 | public function getTitle() |
||
86 | |||
87 | /** |
||
88 | * Return the field reference that is being used to define time |
||
89 | * |
||
90 | * @return string |
||
91 | */ |
||
92 | public function getDatetimeField() |
||
96 | } |
||
97 |