\Phergie\Irc\EventUserEvent

Class for an event sent by a user.

Summary

Methods
Properties
Constants
setMessage()
getMessage()
setConnection()
getConnection()
setParams()
getParams()
setCommand()
getCommand()
getPrefix()
setPrefix()
getNick()
setNick()
getUsername()
setUsername()
getHost()
setHost()
getTargets()
setTargets()
getSource()
No public properties found
No constants found
No protected methods found
$message
$connection
$params
$command
$prefix
$nick
$username
$host
$targets
N/A
No private methods found
No private properties found
N/A

Properties

$message

$message : string

Original unparsed message

Type

string

$connection

$connection : \Phergie\Irc\ConnectionInterface

Metadata for the connection over which the event was received

Type

\Phergie\Irc\ConnectionInterface

$params

$params : array

Command parameters parsed from the message

Type

array

$command

$command : string

Command parsed from the message

Type

string

$prefix

$prefix : string

Prefix identifying the sender of the command

Type

string

$nick

$nick : string

Nick portion of the prefix

Type

string

$username

$username : string

Username portion of the prefix

Type

string

$host

$host : string

Host portion of the prefix

Type

string

$targets

$targets : array

Targets parsed from the message, typically user nicks or channel names

Type

array

Methods

setMessage()

setMessage(string $message)

Sets the original unparsed message.

Parameters

string $message

getMessage()

getMessage() : string

Returns the original unparsed message.

Returns

string

setConnection()

setConnection(\Phergie\Irc\ConnectionInterface $connection)

Sets metadata for the connection over which the message was received.

Parameters

\Phergie\Irc\ConnectionInterface $connection

getConnection()

getConnection() : \Phergie\Irc\ConnectionInterface

Returns metadata for the connection over which the message was received.

Returns

\Phergie\Irc\ConnectionInterface

setParams()

setParams(array $params)

Sets the command parameters parsed from the message.

Parameters

array $params

Enumerated array of parameter values

getParams()

getParams() : array

Returns the command parameters parsed from the message.

Returns

array —

Enumerated array of parameter values

setCommand()

setCommand(string $command)

Sets the command parsed from the message.

Parameters

string $command

getCommand()

getCommand() : string

Returns the command parsed from the message.

Returns

string

getPrefix()

getPrefix() : string

Gets the prefix identifying the sender of the event.

Returns

string

setPrefix()

setPrefix(string $prefix)

Sets the prefix identifying the sender of the event.

Parameters

string $prefix

getNick()

getNick() : string

Returns the nick portion of the prefix identifying the sender of the event.

Returns

string

setNick()

setNick(string $nick)

Sets the nick portion of the prefix identifying the sender of the event.

Parameters

string $nick

getUsername()

getUsername() : string

Returns the username portion of the prefix identifying the sender of the event.

Returns

string

setUsername()

setUsername(string $username)

Sets the username portion of the prefix identifying the sender of the event.

Parameters

string $username

getHost()

getHost() : string

Returns the host portion of the prefix identifying the sender of the event.

Returns

string

setHost()

setHost(string $host)

Sets the host portion of the prefix identifying the sender of the event.

Parameters

string $host

getTargets()

getTargets() : array

Returns targets parsed from the message.

Returns

array

setTargets()

setTargets(array $targets)

Sets targets parsed from the message.

Parameters

array $targets

getSource()

getSource() : string

Returns the source of this event.

If the event occurred within a channel, this will be the channel name. If it was sent directly to the bot, this will be the nickname of the originating user.

Returns

string —

User nick or channel name