|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface defines needed methods for connecting to another device on a remote backgammon game.
Method Summary | |
void |
close()
Closes all resources opened in this connection. |
boolean |
connectClient(java.lang.Object serverInfo)
Connects a client to a server. |
javax.microedition.io.StreamConnection |
getConnection()
If server has got a client or client is connected to a server, this method returns the connection. |
java.io.DataInputStream |
getInput()
If server has got a client or client is connected to a server, this method returns the input stream. |
java.io.DataOutputStream |
getOutput()
If server has got a client or client is connected to a server, this method returns the output stream. |
boolean |
isAwaitingClient()
Returns true if this connection is awaiting a client already. |
boolean |
isClosed()
Returns if this connection has been closed or not. |
void |
waitForClient()
Opens a server and waits for client. |
Method Detail |
public void waitForClient() throws java.io.IOException
java.io.IOException
public boolean isAwaitingClient()
public boolean connectClient(java.lang.Object serverInfo) throws java.io.IOException
serverInfo
- Any info needed to connect to the server.
java.io.IOException
public javax.microedition.io.StreamConnection getConnection() throws java.io.IOException
java.io.IOException
public java.io.DataInputStream getInput()
public java.io.DataOutputStream getOutput()
public void close() throws java.io.IOException
java.io.IOException
public boolean isClosed()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |