1 | <?php |
||
19 | class Aggregate implements ProviderInterface |
||
20 | { |
||
21 | /** |
||
22 | * @var ProviderInterface[] |
||
23 | */ |
||
24 | private $providers; |
||
25 | |||
26 | /** |
||
27 | * @param ProviderInterface[] $providers |
||
28 | * |
||
29 | * @throws \InvalidArgumentException |
||
30 | */ |
||
31 | public function __construct(array $providers) |
||
40 | |||
41 | /** |
||
42 | * Adds a provider. |
||
43 | * |
||
44 | * @param ProviderInterface $provider |
||
45 | * |
||
46 | * @return Aggregate |
||
47 | */ |
||
48 | public function add(ProviderInterface $provider) |
||
54 | |||
55 | /** |
||
56 | * Return events that matches to $begin && $end |
||
57 | * $end date should be exclude. |
||
58 | * |
||
59 | * @param \DateTime $begin |
||
60 | * @param \DateTime $end |
||
61 | * @param array $options |
||
62 | * |
||
63 | * @return \CalendR\Event\EventInterface |
||
|
|||
64 | */ |
||
65 | public function getEvents(\DateTime $begin, \DateTime $end, array $options = array()) |
||
75 | } |
||
76 |
This check compares the return type specified in the
@return
annotation of a function or method doc comment with the types returned by the function and raises an issue if they mismatch.