DeBot Framework


DeBot\Servers
core/Servers.php at line 17

Class Servers

Singleton
└─Servers

public class Servers
extends Singleton

DeBot Core - Servers Created by dab ??? ?? 2009 Last Edited: Aug 15 2010 This manages all of our known networks. I think a future need is to store newly added networks to a custom config. So you don't have to go and add the network to the bot again. Though that sort of disposes the use of the config. I'll make the propsition on the Codebase and see how others respond.

Author:
David (dab)
Version:
v1.0

Method Summary
void

add(string sName, string sServer, integer iPort, boolean bSSL)

Adds a server to the array list.

string

get(string sName)

Used before I realized what ArrayAccess was capable of.

void

load()

Load function parses config for the servers and stores them for future connections.

void

offsetExists(mixed sKey)

void

offsetGet(mixed sKey)

void

offsetSet(mixed sKey, mixed mValue)

void

offsetUnset(mixed sKey)

void

onMode(string sServer, string sName, string sMode, string sParams)

Called onmode changes/listing

void

onNames(string sServer, string sName, mixed aNames, $aNames The)

Called on a /names call return.

void

onTopic(string sServer, string sName, string sTopic)

When a topic is changed

Methods inherited from DeBot\Singleton
__construct, obj

Method Detail

core/Servers.php at line 56

add

public void add(string sName, string sServer, integer iPort, boolean bSSL)

Adds a server to the array list.

Parameters:
sName - The name of the server (for user/index)
sServer - The URL/IP of the server to connect to
iPort - the Port to connect via
bSSL - Connect via SSL?

core/Servers.php at line 119

get

public string get(string sName)

Used before I realized what ArrayAccess was capable of.

Deprecated:
since v0.01
Parameters:
sName - The server to fetch
Returns:
The server.

core/Servers.php at line 36

load

public void load()

Load function parses config for the servers and stores them for future connections.


core/Servers.php at line 130

offsetExists

public void offsetExists(mixed sKey)

core/Servers.php at line 150

offsetGet

public void offsetGet(mixed sKey)

core/Servers.php at line 172

offsetSet

public void offsetSet(mixed sKey, mixed mValue)

core/Servers.php at line 176

offsetUnset

public void offsetUnset(mixed sKey)

core/Servers.php at line 90

onMode

public void onMode(string sServer, string sName, string sMode, string sParams)

Called onmode changes/listing

Parameters:
sServer - The server being called on
sName - The channel
sMode - the modes to add
sParams - the params to the mode

core/Servers.php at line 73

onNames

public void onNames(string sServer, string sName, mixed aNames, $aNames The)

Called on a /names call return.

Parameters:
sServer - The server to which this applies to.
sName - The channel to where this is going
The - users in the channel

core/Servers.php at line 103

onTopic

public void onTopic(string sServer, string sName, string sTopic)

When a topic is changed

Parameters:
sServer - The server this applies to
sName - the channel
sTopic - the Topic to set

DeBot Framework