com.superhac.JXBStreamer.Core
Class XBMSPServerMessageHandler

java.lang.Object
  extended by com.superhac.JXBStreamer.Core.XBMSPServerMessageHandler

public class XBMSPServerMessageHandler
extends java.lang.Object

Handles all the messaging for client communication with the server.

More information can be found at Superhac.com


Constructor Summary
protected XBMSPServerMessageHandler(java.nio.channels.SocketChannel sc, java.util.ArrayList<java.io.File> virtualRoot)
           
 
Method Summary
protected  long getLastTransmissionDelay()
          Gets the number of seconds since client last sent a message.
protected  java.nio.channels.SocketChannel getSocketChannel()
          Gets the socket channel that assigned to this message handler.
 ConnectedClientStatus getStatus()
          Gets the clients status for this message handler.
protected  void IncommingMessage(java.nio.ByteBuffer message)
          Processes the incoming messages
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

XBMSPServerMessageHandler

protected XBMSPServerMessageHandler(java.nio.channels.SocketChannel sc,
                                    java.util.ArrayList<java.io.File> virtualRoot)
Parameters:
sc - The socket channel for this client
virtualRoot - the shared directorys for the virtual roots.
Method Detail

IncommingMessage

protected void IncommingMessage(java.nio.ByteBuffer message)
Processes the incoming messages

Parameters:
message - the buffer from socket.

getSocketChannel

protected java.nio.channels.SocketChannel getSocketChannel()
Gets the socket channel that assigned to this message handler.

Returns:
the socket channel

getStatus

public ConnectedClientStatus getStatus()
Gets the clients status for this message handler.

Returns:
a ConnectedClientStatus

getLastTransmissionDelay

protected long getLastTransmissionDelay()
Gets the number of seconds since client last sent a message.

Returns:
the number of seconds since the client sent a message.