function once(string $event, callable $listener) {
        if(!isset($this->onceListeners[$event])) {
            $this->onceListeners[$event] = array();
        }
        
        $this->onceListeners[$event][] = $listener;
        
        return $this;
    }
function once(string $event, callable $listener) {
        if(!isset($this->onceListeners[$event])) {
            $this->onceListeners[$event] = array();
        }
        
        $this->onceListeners[$event][] = $listener;
        
        return $this;
    }
function once ( string $ event , callable $ listener ) { if ( ! isset ( $ this -> onceListeners [ $ event ] ) ) { $ this -> onceListeners [ $ event ] = array ( ) ; } $ this -> onceListeners [ $ event ] [ ] = $ listener ; return $ this ; }
Attach a listener to an event, for exactly once.
@param string    $event
@param callable  $listener
@return $this
Attach a listener to an event for exactly once .