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.
Loading history...
32
*/
33
public function getIterator()
34
{
35
return new ArrayIterator($this->eventListeners);
36
}
37
38
/**
39
* @return string
40
*/
41
public function getEventName()
42
{
43
return $this->eventName;
44
}
45
46
/**
47
* @param EventListenerInterface $eventListener
48
*/
49
public function add(EventListenerInterface $eventListener)
50
{
51
if ($eventListener->getSupportedEventClassName() !== $this->eventName) {
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.