Net_SmartIRC
[ class tree: Net_SmartIRC ] [ index: Net_SmartIRC ] [ all elements ]

Class: Net_SmartIRC

Source Location: /Net_SmartIRC-1.1.14/Net/SmartIRC.php

Class Overview

Net_SmartIRC_irccommands
   |
   --Net_SmartIRC_messagehandler
      |
      --Net_SmartIRC

main SmartIRC class


Author(s):

Version:

  • 1.1.14

Variables

Methods


Inherited Variables

Inherited Methods

Class: Net_SmartIRC_messagehandler

Net_SmartIRC_messagehandler::_event_error()
Net_SmartIRC_messagehandler::_event_err_nicknameinuse()
Net_SmartIRC_messagehandler::_event_join()
Net_SmartIRC_messagehandler::_event_kick()
Net_SmartIRC_messagehandler::_event_mode()
Net_SmartIRC_messagehandler::_event_nick()
Net_SmartIRC_messagehandler::_event_part()
Net_SmartIRC_messagehandler::_event_ping()
Net_SmartIRC_messagehandler::_event_privmsg()
Net_SmartIRC_messagehandler::_event_quit()
Net_SmartIRC_messagehandler::_event_rpl_banlist()
Net_SmartIRC_messagehandler::_event_rpl_channelmodeis()
Net_SmartIRC_messagehandler::_event_rpl_endofbanlist()
Net_SmartIRC_messagehandler::_event_rpl_endofmotd()
Net_SmartIRC_messagehandler::_event_rpl_motd()
Net_SmartIRC_messagehandler::_event_rpl_motdstart()
Net_SmartIRC_messagehandler::_event_rpl_namreply()
Net_SmartIRC_messagehandler::_event_rpl_topic()
Net_SmartIRC_messagehandler::_event_rpl_umodeis()
Net_SmartIRC_messagehandler::_event_rpl_welcome()
Net_SmartIRC_messagehandler::_event_rpl_whoreply()
Net_SmartIRC_messagehandler::_event_topic()

Class: Net_SmartIRC_irccommands

Net_SmartIRC_irccommands::admin()
admins an user in the given channel
Net_SmartIRC_irccommands::ban()
bans a hostmask for the given channel or requests the current banlist
Net_SmartIRC_irccommands::changeNick()
changes the own nickname
Net_SmartIRC_irccommands::deadmin()
deadmins an user in the given channel
Net_SmartIRC_irccommands::defounder()
defounders an user in the given channel
Net_SmartIRC_irccommands::dehop()
dehops an user in the given channel
Net_SmartIRC_irccommands::deop()
deops an user in the given channel
Net_SmartIRC_irccommands::devoice()
devoice a user in the given channel
Net_SmartIRC_irccommands::founder()
founders an user in the given channel
Net_SmartIRC_irccommands::getList()
gets a list of one ore more channels
Net_SmartIRC_irccommands::getTopic()
gets the topic of a channel
Net_SmartIRC_irccommands::hop()
hops an user in the given channel
Net_SmartIRC_irccommands::invite()
invites a user to the specified channel
Net_SmartIRC_irccommands::join()
Joins one or more IRC channels with an optional key.
Net_SmartIRC_irccommands::kick()
Kicks one or more user from an IRC channel with an optional reason.
Net_SmartIRC_irccommands::message()
sends a new message
Net_SmartIRC_irccommands::mode()
sets or gets the mode of an user or channel
Net_SmartIRC_irccommands::names()
requests all nicknames of one or more channels
Net_SmartIRC_irccommands::op()
ops an user in the given channel
Net_SmartIRC_irccommands::part()
parts from one or more IRC channels with an optional reason
Net_SmartIRC_irccommands::quit()
sends QUIT to IRC server and disconnects
Net_SmartIRC_irccommands::setTopic()
sets a new topic of a channel
Net_SmartIRC_irccommands::unban()
unbans a hostmask on the given channel
Net_SmartIRC_irccommands::voice()
voice a user in the given channel
Net_SmartIRC_irccommands::who()
requests a 'WHO' from the specified target
Net_SmartIRC_irccommands::whois()
requests a 'WHOIS' from the specified target
Net_SmartIRC_irccommands::whowas()
requests a 'WHOWAS' from the specified target (if he left the IRC network)

Class Details

[line 61]
main SmartIRC class


[ Top ]


Class Variables

$nreplycodes =

[line 386]

All numeric IRC replycodes, the index is the numeric replycode.
  • See: $SMARTIRC_nreplycodes
  • Access: public

Type:   array


[ Top ]

$_actionhandler = array()

[line 166]

  • Access: protected

Type:   array


[ Top ]

$_actionhandlerid =  0

[line 245]

  • Access: protected

Type:   integer


[ Top ]

$_address =

[line 116]

  • Access: protected

Type:   string


[ Top ]

$_autoretry =  false

[line 352]

  • Access: protected

Type:   boolean


[ Top ]

$_autoretrycount =  0

[line 362]

  • Access: protected

Type:   integer


[ Top ]

$_autoretrymax =  self::DEF_AUTORETRY_MAX

[line 357]

  • Access: protected

Type:   integer


[ Top ]

$_benchmark =  false

[line 230]

  • Access: protected

Type:   boolean


[ Top ]

$_benchmark_starttime =

[line 235]

  • Access: protected

Type:   integer


[ Top ]

$_benchmark_stoptime =

[line 240]

  • Access: protected

Type:   integer


[ Top ]

$_bindto =  '0:0'

[line 126]

  • Access: protected

Type:   string


[ Top ]

$_channels = array()

[line 267]

Stores all channels in this array where we are joined, works only if channelsyncing is activated.

Eg. for accessing a user, use it like this: (in this example the SmartIRC object is stored in $irc) $irc->getUser('#test', 'meebey')->nick;


Type:   array


[ Top ]

$_channelsyncing =  false

[line 272]

  • Access: protected

Type:   boolean


[ Top ]

$_connectionerror =  false

[line 367]

  • Access: protected

Type:   boolean


[ Top ]

$_ctcpversion =  SMARTIRC_VERSIONSTRING

[line 307]

  • Access: protected

Type:   string


[ Top ]

$_debuglevel =  SMARTIRC_DEBUG_NOTICE

[line 176]

  • Access: protected

Type:   integer


[ Top ]

$_disconnecttime =  self::DEF_DISCONNECT_TIME

[line 220]

  • Access: protected

Type:   integer


[ Top ]

$_interrupt =  false

[line 377]

  • Access: protected

Type:   boolean


[ Top ]

$_lastrx =

[line 332]

  • Access: protected

Type:   integer


[ Top ]

$_lastsentmsgtime =  0

[line 342]

  • Access: protected

Type:   mixed


[ Top ]

$_lasttx =

[line 337]

  • Access: protected

Type:   integer


[ Top ]

$_logdestination =  SMARTIRC_STDOUT

[line 205]

  • Access: protected

Type:   integer


[ Top ]

$_logfile =  self::DEF_LOGFILE

[line 215]

  • Access: protected

Type:   string


[ Top ]

$_logfilefp =  0

[line 210]

  • Access: protected

Type:   resource


[ Top ]

$_loggedin =  false

[line 225]

  • Access: protected

Type:   boolean


[ Top ]

$_maxtimer =  self::DEF_MAX_TIMER

[line 317]

  • Access: protected

Type:   integer


[ Top ]

$_messagebuffer = array(
      SMARTIRC_HIGH     => array(),SMARTIRC_MEDIUM=>array(),SMARTIRC_LOW=>array(),)

[line 181]

  • Access: protected

Type:   array


[ Top ]

$_messagebuffersize =

[line 190]

  • Access: protected

Type:   integer


[ Top ]

$_mintimer =  false

[line 312]

  • Access: protected

Type:   mixed


[ Top ]

$_modulepath =  '.'

[line 295]

Stores the path to the modules that can be loaded.
  • Access: protected

Type:   string


[ Top ]

$_modules = array()

[line 302]

Stores all objects of the modules.
  • Access: protected

Type:   string


[ Top ]

$_motd = array()

[line 255]

  • Access: protected

Type:   array


[ Top ]

$_nick =

[line 131]

  • Access: protected

Type:   string


[ Top ]

$_password =

[line 151]

  • Access: protected

Type:   string


[ Top ]

$_performs = array()

[line 156]

  • Access: protected

Type:   array


[ Top ]

$_port =

[line 121]

  • Access: protected

Type:   integer


[ Top ]

$_realname =

[line 141]

  • Access: protected

Type:   string


[ Top ]

$_receivedelay =  self::DEF_RECEIVE_DELAY

[line 195]

  • Access: protected

Type:   integer


[ Top ]

$_reconnectdelay =  self::DEF_RECONNECT_DELAY

[line 347]

  • Access: protected

Type:   integer


[ Top ]

$_runasdaemon =  false

[line 372]

  • Access: protected

Type:   boolean


[ Top ]

$_rxtimeout =  self::DEF_TX_RX_TIMEOUT

[line 327]

  • Access: protected

Type:   integer


[ Top ]

$_senddelay =  self::DEF_SEND_DELAY

[line 200]

  • Access: protected

Type:   integer


[ Top ]

$_socket =

[line 111]

  • Access: protected

Type:   resource


[ Top ]

$_state =  SMARTIRC_STATE_DISCONNECTED

[line 161]

  • Access: protected

Type:   boolean


[ Top ]

$_timehandler = array()

[line 171]

  • Access: protected

Type:   array


[ Top ]

$_timehandlerid =  0

[line 250]

  • Access: protected

Type:   integer


[ Top ]

$_txtimeout =  self::DEF_TX_RX_TIMEOUT

[line 322]

  • Access: protected

Type:   integer


[ Top ]

$_usermode =

[line 146]

  • Access: protected

Type:   string


[ Top ]

$_username =

[line 136]

  • Access: protected

Type:   string


[ Top ]

$_users = array()

[line 283]

Stores all users that had/have contact with us (channel/query/notice etc.), works only if usersyncing is activated.

Eg. for accessing a user, use it like this: (in this example the SmartIRC object is stored in $irc) $irc->user['meebey']->host;


Type:   array


[ Top ]

$_usersyncing =  false

[line 288]

  • Access: protected

Type:   boolean


[ Top ]



Method Detail

connect   [line 1056]

boolean|Net_SmartIRC connect( string $addr, [integer $port = 6667], [bool $reconnecting = false])

Creates the sockets and connects to the IRC server on the given port.

Returns this SmartIRC object on success, and false on failure.

  • Access: public

Parameters:

string   $addr   — 
integer   $port   — 
bool   $reconnecting   —  For internal use only

[ Top ]

__construct (Constructor)   [line 396]

object __construct( [array $params = array()])

Constructor. Initiates the messagebuffer and "links" the replycodes from global into properties. Also some PHP runtime settings are configured.
  • Access: public

Parameters:

array   $params   —  Properties to set during instantiation

[ Top ]

disconnect   [line 1125]

boolean|Net_SmartIRC disconnect( [boolean $quick = false])

Disconnects from the IRC server nicely with a QUIT or just destroys the socket.

Disconnects from the IRC server in the given quickness mode. $quick:

  • true, just close the socket
  • false, send QUIT and wait $_disconnectime before closing the socket


Parameters:

boolean   $quick   —  default: false

[ Top ]

getChannel   [line 999]

object &getChannel( string $channelname)

Returns a reference to the channel object of the specified channelname.
  • Access: public

Parameters:

string   $channelname   — 

[ Top ]

getMotd   [line 976]

array getMotd( )

Returns the full motd.
  • Access: public

[ Top ]

getUser   [line 1030]

object &getUser( string $channelname, string $username)

Returns a reference to the user object for the specified username and channelname.
  • Access: public

Parameters:

string   $channelname   — 
string   $username   — 

[ Top ]

getUsermode   [line 987]

string getUsermode( )

Returns the usermode.
  • Access: public

[ Top ]

interrupt   [line 1597]

boolean interrupt( [bool $ival = true])

Provides a mechanism to interrupt a listen() loop by a bot or something
  • Access: public

Parameters:

bool   $ival   —  Whether to interrupt the next listen iteration

[ Top ]

isAdmin   [line 1458]

boolean isAdmin( string $channel, [string $nickname = null])

Checks if we or the given user is admin on the specified channel and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

isBanned   [line 1574]

boolean isBanned( string $channel, string $hostmask)

Checks if the hostmask is on the specified channel banned and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $hostmask   — 

[ Top ]

isConnected   [line 1365]

boolean isConnected( )

checks if the bot is connected
  • Access: public

[ Top ]

isError   [line 2702]

void isError( $object)

  • Access: public

Parameters:

   $object   — 

[ Top ]

isFounder   [line 1429]

boolean isFounder( string $channel, [string $nickname = null])

Checks if we or the given user is founder on the specified channel and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

isHopped   [line 1516]

boolean isHopped( string $channel, [string $nickname = null])

Checks if we or the given user is hopped on the specified channel and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

isJoined   [line 1392]

boolean isJoined( string $channel, [string $nickname = null])

checks if we or the given user is joined to the specified channel and returns the result ChannelSyncing is required for this.

Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

isMe   [line 1377]

boolean isMe( string $nickname)

checks if the passed nickname is our own nickname
  • Access: public

Parameters:

string   $nickname   — 

[ Top ]

isOpped   [line 1487]

boolean isOpped( string $channel, [string $nickname = null])

Checks if we or the given user is opped on the specified channel and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

isVoiced   [line 1545]

boolean isVoiced( string $channel, [string $nickname = null])

Checks if we or the given user is voiced on the specified channel and returns the result.

ChannelSyncing is required for this.


Parameters:

string   $channel   — 
string   $nickname   — 

[ Top ]

listen   [line 1611]

Net_SmartIRC listen( )

goes into receive mode

Goes into receive and idle mode. Only call this if you want to "spawn" the bot. No further lines of PHP code will be processed after this call, only the bot methods!

  • Access: public

[ Top ]

listenFor   [line 2085]

array listenFor( integer $messagetype, [string $regex = '.*'])

waits for a special message type and returns the answer

Creates a special actionhandler for that given TYPE and returns the answer. This will only receive the requested type, immediately quit and disconnect from the IRC server. Made for showing IRC statistics on your homepage, or other IRC related information.

  • Return: answer from the IRC server for this $messagetype
  • Access: public

Parameters:

integer   $messagetype   —  see in the documentation 'Message Types'
string   $regex   —  the pattern to match on

[ Top ]

listenOnce   [line 1627]

boolean|Net_SmartIRC listenOnce( )

goes into receive mode _only_ for one pass

Goes into receive mode. It will return when one pass is complete. Use this when you want to connect to multiple IRC servers.

  • Access: public

[ Top ]

loadedModules   [line 2445]

array loadedModules( )

Returns an array of the module names that are currently loaded
  • Access: public

[ Top ]

loadModule   [line 2311]

boolean|Net_SmartIRC loadModule( string $name)

loads a module using preset path and given name
  • Access: public

Parameters:

string   $name   — 

[ Top ]

log   [line 901]

boolean log( integer $level, string $entry, [string|null $file = null], [int|null $line = null])

Adds an entry to the log.

Adds an entry to the log with Linux style log format. Possible $level constants (can also be combined with "|"s) SMARTIRC_DEBUG_NONE SMARTIRC_DEBUG_NOTICE SMARTIRC_DEBUG_CONNECTION SMARTIRC_DEBUG_SOCKET SMARTIRC_DEBUG_IRCMESSAGES SMARTIRC_DEBUG_MESSAGETYPES SMARTIRC_DEBUG_ACTIONHANDLER SMARTIRC_DEBUG_TIMEHANDLER SMARTIRC_DEBUG_MESSAGEHANDLER SMARTIRC_DEBUG_CHANNELSYNCING SMARTIRC_DEBUG_MODULES SMARTIRC_DEBUG_USERSYNCING SMARTIRC_DEBUG_ALL


Parameters:

integer   $level   —  bit constants (SMARTIRC_DEBUG_*)
string   $entry   —  the new log entry
string|null   $file   —  The source file originating the log() call
int|null   $line   —  The line of code that called log()

[ Top ]

login   [line 1251]

Net_SmartIRC login( string $nick, string $realname, [integer $usermode = 0], [string $username = null], [string $password = null])

login and register nickname on the IRC network

Registers the nickname and user information on the IRC network.

  • Access: public

Parameters:

string   $nick   — 
string   $realname   — 
integer   $usermode   — 
string   $username   — 
string   $password   — 

[ Top ]

perform   [line 1314]

Net_SmartIRC perform( string $cmd)

adds a command to the list of commands to be sent after login() info
  • Access: public

Parameters:

string   $cmd   —  the command to add to the perform list

[ Top ]

reconnect   [line 1176]

boolean|Net_SmartIRC reconnect( )

Reconnects to the IRC server with the same login info, it also rejoins the channels
  • Access: public

[ Top ]

registerActionHandler   [line 2107]

integer registerActionHandler( integer $handlertype, string $regexhandler, object|callable $object, [string $methodname = ''])

registers a new actionhandler and returns the assigned id

Registers an actionhandler in Net_SmartIRC for calling it later. The actionhandler id is needed for unregistering the actionhandler.

  • Return: assigned actionhandler id
  • See: example.php
  • Access: public

Parameters:

integer   $handlertype   —  bits constants, see in this documentation Message Types
string   $regexhandler   —  the message that has to be in the IRC message in regex syntax
object|callable   $object   —  either an object with the method, or a callable
string   $methodname   —  the methodname that will be called when the handler happens

[ Top ]

registerTimeHandler   [line 2231]

integer registerTimeHandler( integer $interval, object|callable $object, [string $methodname = ''])

registers a timehandler and returns the assigned id

Registers a timehandler in Net_SmartIRC, which will be called in the specified interval. The timehandler id is needed for unregistering the timehandler.

  • Return: assigned timehandler id
  • See: example7.php
  • Access: public

Parameters:

integer   $interval   —  interval time in milliseconds
object|callable   $object   —  either an object with the method, or a callable
string   $methodname   —  the methodname that will be called when the handler happens

[ Top ]

send   [line 1335]

boolean|Net_SmartIRC send( string $data, [integer $priority = SMARTIRC_MEDIUM])

sends an IRC message

Adds a message to the messagequeue, with the optional priority. $priority: SMARTIRC_CRITICAL SMARTIRC_HIGH SMARTIRC_MEDIUM SMARTIRC_LOW

  • Access: public

Parameters:

string   $data   — 
integer   $priority   —  must be one of the priority constants

[ Top ]

setAutoRetry   [line 475]

boolean setAutoRetry( boolean $boolean)

Enables/disables autoretry for connecting to a server.
  • Access: public

Parameters:

boolean   $boolean   — 

[ Top ]

setAutoRetryMax   [line 488]

integer setAutoRetryMax( [integer|null $autoretrymax = null])

Sets the maximum number of attempts to connect to a server before giving up.
  • Access: public

Parameters:

integer|null   $autoretrymax   — 

[ Top ]

setBenchmark   [line 509]

boolean setBenchmark( boolean $boolean)

Enables/disables the benchmark engine.
  • Access: public

Parameters:

boolean   $boolean   — 

[ Top ]

setBindAddress   [line 525]

string setBindAddress( [string $addr = '0'], [int $port = 0])

Sets an IP address (and optionally, a port) to bind the socket to.

Limits the bot to claiming only one of the machine's IPs as its home. Call with no parameters to unbind.

  • Return: The bound address with port
  • Access: public

Parameters:

string   $addr   — 
int   $port   — 

[ Top ]

setChannelSyncing   [line 543]

boolean setChannelSyncing( boolean $boolean)

Enables/disables channel syncing.

Channel syncing means, all users on all channel we are joined are tracked in the channel array. This makes it very handy for botcoding.

  • Access: public

Parameters:

boolean   $boolean   — 

[ Top ]

setCtcpVersion   [line 568]

string setCtcpVersion( string $versionstring)

Sets the CTCP version reply string.
  • Access: public

Parameters:

string   $versionstring   — 

[ Top ]

setDebugLevel   [line 600]

integer setDebugLevel( integer $level)

Sets the level of debug messages.

Sets the debug level (bitwise), useful for testing/developing your code. Here the list of all possible debug levels: SMARTIRC_DEBUG_NONE SMARTIRC_DEBUG_NOTICE SMARTIRC_DEBUG_CONNECTION SMARTIRC_DEBUG_SOCKET SMARTIRC_DEBUG_IRCMESSAGES SMARTIRC_DEBUG_MESSAGETYPES SMARTIRC_DEBUG_ACTIONHANDLER SMARTIRC_DEBUG_TIMEHANDLER SMARTIRC_DEBUG_MESSAGEHANDLER SMARTIRC_DEBUG_CHANNELSYNCING SMARTIRC_DEBUG_MODULES SMARTIRC_DEBUG_USERSYNCING SMARTIRC_DEBUG_ALL

Default: SMARTIRC_DEBUG_NOTICE


Parameters:

integer   $level   — 

[ Top ]

setDisconnectTime   [line 612]

integer setDisconnectTime( [integer|null $milliseconds = null])

Sets the delaytime before closing the socket when disconnect.
  • Access: public

Parameters:

integer|null   $milliseconds   — 

[ Top ]

setLogDestination   [line 639]

integer setLogDestination( integer $type)

Sets the destination of all log messages.

Sets the destination of log messages. $type can be: SMARTIRC_FILE for saving the log into a file SMARTIRC_STDOUT for echoing the log to stdout SMARTIRC_SYSLOG for sending the log to the syslog Default: SMARTIRC_STDOUT


Parameters:

integer   $type   —  must be on of the constants

[ Top ]

setLogFile   [line 669]

string setLogFile( string $file)

Sets the file for the log if the destination is set to file.

Sets the logfile, if logdestination is set to SMARTIRC_FILE. This should be only used with full path!

  • Access: public

Parameters:

string   $file   — 

[ Top ]

setModulePath   [line 681]

string setModulePath( integer $path)

Sets the paths for the modules.
  • Access: public

Parameters:

integer   $path   — 

[ Top ]

setReceiveDelay   [line 697]

integer setReceiveDelay( [integer|null $milliseconds = null])

Sets the delay for receiving data from the IRC server.

Sets the delaytime between messages that are received, this reduces your CPU load. Don't set this too low (min 100ms). Default: 100

  • Access: public

Parameters:

integer|null   $milliseconds   — 

[ Top ]

setReceiveTimeout   [line 775]

integer setReceiveTimeout( [integer|null $seconds = null])

Sets the receive timeout.

If the timeout occurs, the connection will be reinitialized Default: 300 seconds

  • Access: public

Parameters:

integer|null   $seconds   — 

[ Top ]

setReconnectDelay   [line 717]

integer setReconnectDelay( [integer|null $milliseconds = null])

Sets the delaytime before attempting reconnect.

Value of 0 disables the delay entirely.

  • Access: public

Parameters:

integer|null   $milliseconds   — 

[ Top ]

setRunAsDaemon   [line 735]

boolean setRunAsDaemon( boolean $boolean)

Sets whether the script should be run as a daemon or not ( actually disables/enables ignore_user_abort() )
  • Access: public

Parameters:

boolean   $boolean   — 

[ Top ]

setSendDelay   [line 755]

integer setSendDelay( [integer|null $milliseconds = null])

Sets the delay for sending data to the IRC server.

Sets the delay time between sending messages, to avoid flooding IRC servers. If your bot has special flooding permissions on the network you're connected to, you can set this quite low to send messages faster. Default: 250

  • Access: public

Parameters:

integer|null   $milliseconds   — 

[ Top ]

setTransmitTimeout   [line 795]

integer setTransmitTimeout( [integer|null $seconds = null])

Sets the transmit timeout.

If the timeout occurs, the connection will be reinitialized Default: 300 seconds

  • Access: public

Parameters:

integer|null   $seconds   — 

[ Top ]

setUserSyncing   [line 815]

boolean setUserSyncing( boolean $boolean)

Enables/disables user syncing.

User syncing means, all users we have or had contact with through channel, query or notice are tracked in the $irc->user array. This is very handy for botcoding.

  • Access: public

Parameters:

boolean   $boolean   — 

[ Top ]

showBenchmark   [line 865]

Net_SmartIRC showBenchmark( )

Shows the benchmark result.
  • Access: public

[ Top ]

startBenchmark   [line 835]

Net_SmartIRC startBenchmark( )

Starts the benchmark (sets the counters).
  • Access: public

[ Top ]

stopBenchmark   [line 848]

Net_SmartIRC stopBenchmark( )

Stops the benchmark and displays the result.
  • Access: public

[ Top ]

throwError   [line 2709]

void throwError( $message)

  • Access: protected

Parameters:

   $message   — 

[ Top ]

unloadModule   [line 2414]

boolean|Net_SmartIRC unloadModule( string $name)

unloads a module by the name originally loaded with
  • Access: public

Parameters:

string   $name   — 

[ Top ]

unregisterActionHandler   [line 2145]

boolean unregisterActionHandler( integer $handlertype, string $regexhandler, object $object, [string $methodname = ''])

unregisters an existing actionhandler
  • Access: public

Parameters:

integer   $handlertype   — 
string   $regexhandler   — 
object   $object   — 
string   $methodname   — 

[ Top ]

unregisterActionId   [line 2190]

boolean|void unregisterActionId( integer|array $id)

unregisters an existing actionhandler via the id
  • Access: public

Parameters:

integer|array   $id   — 

[ Top ]

unregisterTimeId   [line 2264]

boolean unregisterTimeId( integer $id)

unregisters an existing timehandler via the id

Parameters:

integer   $id   — 

[ Top ]

_adduser   [line 2459]

Net_SmartIRC _adduser( &$channel, &$newuser, object $channel, object $newuser)

adds an user to the channelobject or updates his info
  • Access: protected

Parameters:

object   $channel   — 
object   $newuser   — 
   &$channel   — 
   &$newuser   — 

[ Top ]

_callTimeHandlers   [line 2510]

void _callTimeHandlers( )

looks for any time handlers that have timed out and calls them if valid
  • Access: protected

[ Top ]

_pingcheck   [line 2548]

void _pingcheck( )

An active-pinging system to keep the bot from dropping the connection
  • Access: protected

[ Top ]

_rawsend   [line 2568]

boolean _rawsend( string $data)

sends a raw message to the IRC server

Don't use this directly! Use message() or send() instead.

  • Access: protected

Parameters:

string   $data   — 

[ Top ]

_removeuser   [line 2597]

Net_SmartIRC _removeuser( object $ircdata)

removes an user from one channel or all if he quits
  • Access: protected

Parameters:

object   $ircdata   — 

[ Top ]

_updatestate   [line 2685]

boolean _updatestate( )

updates and returns the current connection state
  • Access: protected

[ Top ]

__call   [line 439]

mixed|void __call( string $method, array $args)

Handle calls to renamed or deprecated functions
  • Access: public

Parameters:

string   $method   — 
array   $args   — 

[ Top ]

__get   [line 422]

mixed __get( string $name)

Keeps BC since private properties were once publicly accessible.
  • Return: the property's value
  • Access: public

Parameters:

string   $name   —  The property name asked for

[ Top ]


Documentation generated on Thu, 25 Jul 2019 12:49:09 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.