| 1 | <?php |
||
| 10 | class Week extends PeriodAbstract implements \Iterator |
||
| 11 | { |
||
| 12 | /** |
||
| 13 | * @var null|PeriodInterface |
||
| 14 | */ |
||
| 15 | private $current = null; |
||
| 16 | |||
| 17 | /** |
||
| 18 | * @return int |
||
|
|
|||
| 19 | */ |
||
| 20 | public function getNumber() |
||
| 24 | |||
| 25 | /** |
||
| 26 | * Returns the period as a DatePeriod. |
||
| 27 | * |
||
| 28 | * @return \DatePeriod |
||
| 29 | */ |
||
| 30 | public function getDatePeriod() |
||
| 34 | |||
| 35 | /** |
||
| 36 | * @param \DateTime $start |
||
| 37 | * |
||
| 38 | * @return bool |
||
| 39 | */ |
||
| 40 | public static function isValid(\DateTime $start) |
||
| 48 | |||
| 49 | /** |
||
| 50 | * {@inheritdoc} |
||
| 51 | */ |
||
| 52 | public function current() |
||
| 56 | |||
| 57 | /** |
||
| 58 | * {@inheritdoc} |
||
| 59 | */ |
||
| 60 | public function next() |
||
| 71 | |||
| 72 | /** |
||
| 73 | * {@inheritdoc} |
||
| 74 | */ |
||
| 75 | public function key() |
||
| 79 | |||
| 80 | /** |
||
| 81 | * {@inheritdoc} |
||
| 82 | */ |
||
| 83 | public function valid() |
||
| 87 | |||
| 88 | /** |
||
| 89 | * {@inheritdoc} |
||
| 90 | */ |
||
| 91 | public function rewind() |
||
| 96 | |||
| 97 | /** |
||
| 98 | * Returns the week number. |
||
| 99 | * |
||
| 100 | * @return string |
||
| 101 | */ |
||
| 102 | public function __toString() |
||
| 106 | |||
| 107 | /** |
||
| 108 | * Returns a \DateInterval equivalent to the period. |
||
| 109 | * |
||
| 110 | * @return \DateInterval |
||
| 111 | */ |
||
| 112 | public static function getDateInterval() |
||
| 116 | } |
||
| 117 |
This check compares the return type specified in the
@returnannotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.