Erebot
latest
A modular IRC bot for PHP 7.0+
|
A filter which matches when the source of the event equals some predefined value. More...
Public Member Functions | |
__construct ($source) | |
getSource () | |
match (\Erebot\Interfaces\Event\Base\Generic $event) | |
setSource ($source) | |
Protected Attributes | |
$source | |
Source to use in the comparison, as a string. | |
A filter which matches when the source of the event equals some predefined value.
Definition at line 31 of file Source.php.
Erebot\Event\Match\Source::__construct | ( | $source | ) |
Creates a new instance of the filter.
$source | string|object Source to match incoming events against. |
Erebot::InvalidValueException | The given source is invalid. |
Definition at line 45 of file Source.php.
References Erebot\Event\Match\Source\$source, and Erebot\Event\Match\Source\setSource().
Erebot\Event\Match\Source::getSource | ( | ) |
Returns the source associated with this filter.
string | Source associated with this filter. |
Definition at line 56 of file Source.php.
References Erebot\Event\Match\Source\$source.
Erebot\Event\Match\Source::setSource | ( | $source | ) |
Sets the source used in comparisons.
$source | string|object Source to match incoming events against. |
Erebot::InvalidValueException | The given source is invalid. |
Definition at line 70 of file Source.php.
References Erebot\Event\Match\Source\$source.
Referenced by Erebot\Event\Match\Source\__construct().