com.badlogic.gdx.net
Interface ServerSocket

All Superinterfaces:
Disposable

public interface ServerSocket
extends Disposable

A server socket that accepts new incoming connections, returning Socket instances. The accept(SocketHints) method should preferably be called in a separate thread as it is blocking.

Author:
mzechner, noblemaster

Method Summary
 Socket accept(SocketHints hints)
          Accepts a new incoming connection from a client Socket.
 Net.Protocol getProtocol()
           
 
Methods inherited from interface com.badlogic.gdx.utils.Disposable
dispose
 

Method Detail

getProtocol

Net.Protocol getProtocol()
Returns:
the Protocol used by this socket

accept

Socket accept(SocketHints hints)
Accepts a new incoming connection from a client Socket. The given hints will be applied to the accepted socket. Blocking, call on a separate thread.

Parameters:
hints - additional SocketHints applied to the accepted Socket. Input null to use the default setting provided by the system.
Returns:
the accepted Socket
Throws:
GdxRuntimeException - in case an error ocurred


Copyright © 2013. All Rights Reserved.