|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectspellcast.net.WizardSocket
public class WizardSocket
A Wizard Socket encapsulates the network communication required to send and receive game events.
| Constructor Summary | |
|---|---|
WizardSocket(VersionDetails programVersionDetails)
|
|
| Method Summary | |
|---|---|
void |
close()
Immediately closes all input and output streams and closes the socket. |
Id |
getID()
Get the value of id. |
java.net.Socket |
getSocket()
Get the value of socket. |
boolean |
isConnected()
Indicates whether the IPC system has connected the client yet. |
GameEvent |
receive()
Receive a message from the socket. |
void |
send(GameEvent e)
Send the GameEvent down the socket. |
void |
setID(Id v)
Set the value of id. |
void |
setSocket(java.net.Socket v)
Set the value of socket. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public WizardSocket(VersionDetails programVersionDetails)
| Method Detail |
|---|
public GameEvent receive()
throws java.io.IOException
The format of the message is:
java.io.IOException - if an I/O error occursmarshalMessage,
unmarshalMessage
public void send(GameEvent e)
throws java.io.IOException
java.io.IOExceptionmarshalMessage,
unmarshalMessagepublic void close()
public java.net.Socket getSocket()
public void setSocket(java.net.Socket v)
throws java.io.IOException
v - Value to assign to socket.
java.io.IOExceptionpublic Id getID()
public void setID(Id v)
v - Value to assign to id.public boolean isConnected()
Id.NO_ONE.
isConnected in interface IPCHandleIPC.connect
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||