src/Liip/Drupal/Modules/EventManager/EventSubject.php
public function attach(EventObserverInterface $observer)
    {
        $key = $this->getRegistrationKey($observer);

        if (empty($this->observers[$key])) {
            $this->observers[$key] = $observer;
        }
    }
public function attach(EventObserverInterface $observer)
    {
        $key = $this->getRegistrationKey($observer);

        if (empty($this->observers[$key])) {
            $this->observers[$key] = $observer;
        }
    }
public function attach ( EventObserverInterface $ observer ) { $ key = $ this -> getRegistrationKey ( $ observer ) ; if ( empty ( $ this -> observers [ $ key ] ) ) { $ this -> observers [ $ key ] = $ observer ; } }
Attach an EventObserver

@param \Liip\Drupal\Modules\EventManager\EventObserverInterface $observer

@link http://php.net/manual/en/splsubject.attach.php
Attach an EventObserver