Net_SmartIRC (line
336)
void constructor Net_SmartIRC ( )
Description:Constructor. Initiales the messagebuffer and "links" the replycodes from global into properties. Also some PHP runtime settings are configured.
Tags:
ban (line
1155)
void ban ( $channel, [$hostmask = null] )
Parameters:
Description:bans a hostmask for the given channel or requests the current banlist
The banlist will be requested if no hostmask is specified
Tags:
changeNick (line
1199)
void changeNick ( $newnick )
Parameters:
Description:changes the own nickname
Trys to set a new nickname, nickcollisions are handled.
Tags:
channel (line
923)
object &channel ( $channelname )
Parameters:
Description:returns an object reference to the specified channel
If the channel does not exist (because not joint) false will be returned.
Tags:
connect (line
731)
void connect ( $address, $port )
Parameters:
Description:Creates the sockets and connects to the IRC server on the given port.
Tags:
deop (line
1114)
void deop ( $channel, $nickname )
Parameters:
Description:deops an user in the given channel
Tags:
devoice (line
1140)
void devoice ( $channel, $nickname )
Parameters:
Description:devoice a user in the given channel
Tags:
disconnect (line
779)
boolean disconnect ( [$quickdisconnect = false] )
Parameters:
Description:disconnects from the IRC server nicely with a QUIT or just destroys the socket
disconnects from the IRC server in the given quickness mode. $quickdisconnect: true, just close the socket false, send QUIT and wait $_disconnectime before closing the socket
Tags:
getList (line
1012)
void getList ( [$channelarray = null] )
Parameters:
Description:gets a list of one ore more channels
Requests a full channellist if $channelarray is not given. (use it with care, usualy its a looooong list)
Tags:
getMotd (line
707)
array getMotd ( )
Description:returns the motd
Tags:
getTopic (line
1069)
void getTopic ( $channel )
Parameters:
Description:gets the topic of a channel
Tags:
getUsermode (line
718)
string getUsermode ( )
Description:returns the usermode
Tags:
invite (line
1185)
void invite ( $nickname, $channel )
Parameters:
Description:invites a user to the specified channel
Tags:
isJoined (line
1266)
boolean isJoined ( $channel )
Description:checks if the class is joined to the specified channel and returns the result
Tags:
join (line
940)
void join ( $channelarray, [$key = null] )
Parameters:
Description:Joins one or more IRC channels with an optional key.
Tags:
kick (line
987)
void kick ( $channel, $nicknamearray, [$reason = null] )
Parameters:
Description:Kicks one or more user from an IRC channel with an optional reason.
Tags:
listen (line
1284)
boolean listen ( )
Description: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!
Tags:
listenFor (line
1305)
array listenFor ( $messagetype )
Parameters:
Description:waits for a special message type and puts the answer in $result
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.
Tags:
log (line
668)
void log ( $level, $entry )
Parameters:
Description: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_NOTICE SMARTIRC_DEBUG_CONNECTION SMARTIRC_DEBUG_SOCKET SMARTIRC_DEBUG_IRCMESSAGES SMARTIRC_DEBUG_MESSAGETYPES SMARTIRC_DEBUG_ACTIONHANDLER SMARTIRC_DEBUG_TIMEHANDLER SMARTIRC_DEBUG_MESSAGEHANDLER
Tags:
login (line
852)
void login ( $nick, $realname, [$usermode = 0], [$username = null], [$password = null] )
Parameters:
Description:login and register nickname on the IRC network
Registers the nickname and user information on the IRC network.
Tags:
message (line
891)
boolean message ( $type, $destination, $message )
Parameters:
Description:sends a new message
Sends a message to a channel or user.
Tags:
mode (line
1084)
void mode ( $target, [$newmode = null] )
Parameters:
Description:sets or gets the mode of an user or channel
Changes/requests the mode of the given target.
Tags:
names (line
1035)
void names ( [$channelarray = null] )
Parameters:
Description:requests all nicknames of one or more channels
The requested nickname list also includes op and voice state
Tags:
op (line
1101)
void op ( $channel, $nickname )
Parameters:
Description:ops an user in the given channel
Tags:
part (line
963)
void part ( $channelarray, [$reason = null] )
Parameters:
Description:parts from one or more IRC channels with an optional reason
Tags:
quit (line
1248)
void quit ( [$quitmessage = null] )
Parameters:
Description:sends QUIT to IRC server and disconnects
Tags:
reconnect (line
821)
void reconnect ( )
Description:reconnects to the IRC server with the same login info, it also rejoins the channels
Tags:
registerActionhandler (line
1329)
integer registerActionhandler ( $handlertype, $regexhandler, &$object, $methodname )
Parameters:
Description: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.
Tags:
registerTimehandler (line
1414)
integer registerTimehandler ( $interval, &$object, $methodname )
Parameters:
Description: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.
Tags:
setAutoReconnect (line
553)
void setAutoReconnect ( $boolean )
Parameters:
Description:enables/disables autoreconnecting
Tags:
setAutoRetry (line
568)
void setAutoRetry ( $boolean )
Parameters:
Description:enables/disables autoretry for connecting to a server
Tags:
setBenchmark (line
410)
void setBenchmark ( $boolean )
Parameters:
Description:enables/disables the benchmark engine
Tags:
setChannelSynching (line
425)
void setChannelSynching ( $boolean )
Parameters:
Description:enables/disables channel synching
Tags:
setCtcpVersion (line
440)
void setCtcpVersion ( $versionstring )
Parameters:
Description:sets the CTCP version reply string
Tags:
setDebug (line
398)
void setDebug ( $level )
Parameters:
Description:sets the level of debug messages
Sets the debug level (bitwise), useful for testing/developing your code. A full list of avialable debug levels see 'Debug Levels'. Default: SMARTIRC_DEBUG_NOTICE
Tags:
setDisconnecttime (line
500)
void setDisconnecttime ( $milliseconds )
Parameters:
Description:sets the delaytime before closing the socket when disconnect
Tags:
setLogdestination (line
460)
void setLogdestination ( $type )
Parameters:
Description: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
Tags:
setLogfile (line
488)
void setLogfile ( $file )
Parameters:
Description: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!
Tags:
setReceivedelay (line
519)
void setReceivedelay ( $milliseconds )
Parameters:
Description: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
Tags:
setReceiveTimeout (line
586)
void setReceiveTimeout ( $seconds )
Parameters:
Description:sets the receive timeout
If the timeout occurs, the connection will be reinitialized Default: 300 seconds
Tags:
setSenddelay (line
538)
void setSenddelay ( $milliseconds )
Parameters:
Description:sets the delay for sending data to the IRC server
Sets the delaytime between messages that are sent, because IRC servers doesn't like floods. This will avoid sending your messages too fast to the IRC server. Default: 250
Tags:
setTopic (line
1057)
void setTopic ( $channel, $newtopic )
Parameters:
Description:sets a new topic of a channel
Tags:
setTransmitTimeout (line
604)
void setTransmitTimeout ( $seconds )
Parameters:
Description:sets the transmit timeout
If the timeout occurs, the connection will be reinitialized Default: 300 seconds
Tags:
setUseSockets (line
364)
void setUseSockets ( $boolean )
Parameters:
Description:enables/disables the usage of real sockets
Enables/disables the usage of real sockets instead of fsocks (works only if your PHP build has loaded the PHP socket extension) Default: false
Tags:
showBenchmark (line
643)
void showBenchmark ( )
Description:shows the benchmark result
Tags:
startBenchmark (line
618)
void startBenchmark ( )
Description:starts the benchmark (sets the counters)
Tags:
stopBenchmark (line
629)
void stopBenchmark ( )
Description:stops the benchmark and displays the result
Tags:
unban (line
1172)
void unban ( $channel, $hostmask )
Parameters:
Description:unbans a hostmask on the given channel
Tags:
unregisterActionhandler (line
1354)
boolean unregisterActionhandler ( $handlertype, $regexhandler, &$object, $methodname )
Parameters:
Description:unregisters an existing actionhandler
Tags:
unregisterActionid (line
1383)
boolean unregisterActionid ( $id )
Parameters:
Description:unregisters an existing actionhandler via the id
Tags:
unregisterTimeid (line
1442)
boolean unregisterTimeid ( $id )
Parameters:
Description:unregisters an existing timehandler via the id
Tags:
voice (line
1127)
void voice ( $channel, $nickname )
Parameters:
Description:voice a user in the given channel
Tags:
who (line
1211)
void who ( $target )
Parameters:
Description:requests a 'WHO' from the specified target
Tags:
whois (line
1223)
void whois ( $target )
Parameters:
Description:requests a 'WHOIS' from the specified target
Tags:
whowas (line
1236)
void whowas ( $target )
Parameters:
Description:requests a 'WHOWAS' from the specified target (if he left the IRC network)
Tags: