|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectoogp2p.ClientAdministrator
ClientAdministrator.java Contains all the Clients the person is connected to. Responsible for sending Nettables via the network model. Created: Thu Apr 24 15:55:41 2003
| Field Summary | |
private Client |
myClient
|
private java.util.Vector |
myConnectedClients
|
| Constructor Summary | |
ClientAdministrator()
|
|
ClientAdministrator(Client c)
|
|
| Method Summary | |
void |
broadcastToAll(Nettable nettable)
Broadcasts to all nettables. |
Client |
connect(java.net.InetAddress ipaddr)
|
boolean |
connectedTo(java.net.InetAddress inetAddr)
Checks to see if already connected to a given Server |
Client |
getClient(java.net.InetAddress inetAddr)
Returns the Client object that is connected to the given InetAddress |
Client |
getClient(java.lang.String connectedIPaddr)
DEPRECATED Returns the Client object that is connected to the given IP address All calls to this should be replaced by getClient(InetAddress) below |
java.net.InetAddress |
getmyIP()
|
java.lang.String |
getmyName()
|
boolean |
sendNettable(java.net.InetAddress clientIP,
Nettable n)
Sends a Nettable to the given clientIP. |
void |
sendToAllConsoles(java.lang.String text)
Sends text to all the console windows. |
void |
sendToConsole(java.lang.String text,
java.net.InetAddress ipAddr)
|
void |
setClientName(java.lang.String name)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
private java.util.Vector myConnectedClients
private Client myClient
| Constructor Detail |
public ClientAdministrator()
public ClientAdministrator(Client c)
| Method Detail |
public Client connect(java.net.InetAddress ipaddr)
public java.lang.String getmyName()
public void setClientName(java.lang.String name)
public java.net.InetAddress getmyIP()
public Client getClient(java.lang.String connectedIPaddr)
public Client getClient(java.net.InetAddress inetAddr)
public boolean connectedTo(java.net.InetAddress inetAddr)
public void sendToConsole(java.lang.String text,
java.net.InetAddress ipAddr)
public void sendToAllConsoles(java.lang.String text)
text - -- text to displaypublic void broadcastToAll(Nettable nettable)
nettable - -- nettable to broadcast
public boolean sendNettable(java.net.InetAddress clientIP,
Nettable n)
clientIP - -- IP of client to send ton - -- nettable to send
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||