31 # const ON_CONNECTFAIL = 50; 32 # const ON_DCCSERVER = 80; 33 # const ON_ERROR = 130; 34 # const ON_FILERCVD = 150; 35 # const ON_FILESENT = 160; 36 # const ON_GETFAIL = 170; 37 # const ON_MODE = 240; // * 38 # const ON_NOSOUND = 260; 39 # const ON_SENDFAIL = 350; 40 # const ON_SERV = 360; 41 # const ON_SERVERMODE = 370; 42 # const ON_SERVEROP = 380; 43 # const ON_SNOTICE = 390; 44 # const ON_WALLOPS = 440; 74 if ($prevent !== null) {
75 if (!is_bool($prevent)) {
76 throw new \Erebot\InvalidValueException(
'Bad prevention value');
79 $this->halt = $prevent;
$connection
Connection the event originated from.
preventDefault($prevent=null)
$halt
Whether the default action should be prevented or not.
Interface for a generic Event.
__construct(\Erebot\Interfaces\Connection $connection)