com.jme3.network.connection
クラス UDPConnection

java.lang.Object
  上位を拡張 com.jme3.network.connection.Connection
      上位を拡張 com.jme3.network.connection.UDPConnection
すべての実装されたインタフェース:
java.lang.Runnable

public class UDPConnection
extends Connection

The UDPConnection handles all UDP traffic.


コンストラクタの概要
UDPConnection(java.lang.String label)
           
 
メソッドの概要
 void accept(java.nio.channels.SelectableChannel channel)
          Accept an incoming connection.
 void bind(java.net.SocketAddress address)
          Bind to an address.
 void cleanup()
          Called when the connection implementation should clean up.
 void connect(java.nio.channels.SelectableChannel channel)
          Finish the connection.
 void connect(java.net.SocketAddress address)
          Connect to a server using this overload.
 void read(java.nio.channels.SelectableChannel channel)
          Read from the channel.
 void sendObject(Client client, java.lang.Object object)
          Send an object to the connector.
 void sendObject(java.lang.Object object)
          Send an object to the server.
 void write(java.nio.channels.SelectableChannel channel)
          Write to a channel.
 
クラス com.jme3.network.connection.Connection から継承されたメソッド
addConnectionListener, addConnectorFilter, addMessageListener, addMessageListener, addToDisconnectionQueue, getConnectors, getLocalConnectors, isAlive, removeConnectionListener, removeConnectorFilter, removeMessageListener, removeMessageListener, run, shouldFilterConnector
 
クラス java.lang.Object から継承されたメソッド
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

コンストラクタの詳細

UDPConnection

public UDPConnection(java.lang.String label)
メソッドの詳細

connect

public void connect(java.net.SocketAddress address)
             throws java.io.IOException
クラス Connection の記述:
Connect to a server using this overload.

定義:
クラス Connection 内の connect
パラメータ:
address - The address to connect to.
例外:
java.io.IOException - When a problem occurs.

bind

public void bind(java.net.SocketAddress address)
          throws java.io.IOException
クラス Connection の記述:
Bind to an address.

定義:
クラス Connection 内の bind
パラメータ:
address - The address to bind to.
例外:
java.io.IOException - When a problem occurs.

connect

public void connect(java.nio.channels.SelectableChannel channel)
             throws java.io.IOException
クラス Connection の記述:
Finish the connection.

定義:
クラス Connection 内の connect
パラメータ:
channel - The channel.
例外:
java.io.IOException - When a problem occurs.

accept

public void accept(java.nio.channels.SelectableChannel channel)
            throws java.io.IOException
クラス Connection の記述:
Accept an incoming connection.

定義:
クラス Connection 内の accept
パラメータ:
channel - The channel.
例外:
java.io.IOException - When a problem occurs.

read

public void read(java.nio.channels.SelectableChannel channel)
          throws java.io.IOException
クラス Connection の記述:
Read from the channel.

定義:
クラス Connection 内の read
パラメータ:
channel - The channel.
例外:
java.io.IOException - When a problem occurs.

sendObject

public void sendObject(java.lang.Object object)
                throws java.io.IOException
クラス Connection の記述:
Send an object to the server. If this is a server, it will be broadcast to all clients.

定義:
クラス Connection 内の sendObject
パラメータ:
object - The object to send.
例外:
java.io.IOException - When a writing error occurs.

sendObject

public void sendObject(Client client,
                       java.lang.Object object)
                throws java.io.IOException
クラス Connection の記述:
Send an object to the connector. Server method.

定義:
クラス Connection 内の sendObject
パラメータ:
client - The connector to send to.
object - The object to send.
例外:
java.io.IOException - When a writing error occurs.

cleanup

public void cleanup()
             throws java.io.IOException
クラス Connection の記述:
Called when the connection implementation should clean up.

定義:
クラス Connection 内の cleanup
例外:
java.io.IOException - When a problem occurs.

write

public void write(java.nio.channels.SelectableChannel channel)
           throws java.io.IOException
クラス Connection の記述:
Write to a channel.

定義:
クラス Connection 内の write
パラメータ:
channel - The channel to write to.
例外:
java.io.IOException - When a problem occurs.