public function isEqual(Event $event)
    {
        try {
            return $this->getName() === $event->getName()
            && $this->get('id') === $event->get('id')
            && self::getSortedKeys($this->getParameters()) === self::getSortedKeys($event->getParameters());
        } catch (\Exception $e) {
        }

        return false;
    }
public function isEqual(Event $event)
    {
        try {
            return $this->getName() === $event->getName()
            && $this->get('id') === $event->get('id')
            && self::getSortedKeys($this->getParameters()) === self::getSortedKeys($event->getParameters());
        } catch (\Exception $e) {
        }

        return false;
    }
public function isEqual ( Event $ event ) { try { return $ this -> getName ( ) === $ event -> getName ( ) && $ this -> get ( 'id' ) === $ event -> get ( 'id' ) && self :: getSortedKeys ( $ this -> getParameters ( ) ) === self :: getSortedKeys ( $ event -> getParameters ( ) ) ; } catch ( \ Exception $ e ) { } return false ; }
They're equal if this is the same type of event and the same id
Allows to know if an event concerns a same type of action on the same object.
Very useful to delete doubles.

@param  Event $event
@return boolean
They re equal if this is the same type of event and the same id Allows to know if an event concerns a same type of action on the same object . Very useful to delete doubles .