public class ServerSession
extends java.lang.Object
| Constructor and Description |
|---|
ServerSession()
Constructs ServerSession
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Closes the Server Session.
|
ISingleCollection<java.net.InetSocketAddress> |
getClientsConnectionInfo()
Retrieves list of connection info for all currently active clients
|
IProcessHandler |
getIProcessHandler()
Gets the IProcessHandler.
|
int |
getTimeOut()
Returns setting for Socket read timeout of this session,
0 returns implies that the option is disabled (i.e., timeout of infinity).
|
boolean |
isClientConnected(java.net.InetSocketAddress objAddress)
Shows current status of client,whether it is active or not, for given Inet Socket Address
|
int |
noOfClientsConnected()
Retrieves number of clients currently connected to Service Provider.
|
void |
setBatchProcessor(IBatchProcessor objIBatchProcessor)
Sets the Batch Processor
|
void |
setFragmentProcessor(IFragmentProcessor objIFragmentProcessor)
Sets the Fragment Processor
|
void |
setIProcessHandler(IProcessHandler objIProcessHandler)
Sets the IProcessHandler.
|
void |
setMLLPProcessor(IMLLP objIMLLP)
Sets the MLLP Processor.
|
void |
setReadWriteLength(int iReadLength,
int iWriteLength)
Sets max length limit of reading and writing.
|
void |
setTimeOut(int itimeout)
sets Socket read timeout of this session, in
milliseconds.
|
void |
start(java.net.InetAddress ip,
int iPort) |
void |
start(java.net.InetSocketAddress addr)
Starts UserSession on Socket Address
|
void |
start(int iPort) |
void |
start(java.net.Socket socket)
Starts ClientSession on Socket
|
void |
start(java.lang.String strIP,
int iPort)
Start.
|
public ServerSession()
throws java.io.IOException
java.io.IOExceptionpublic void setFragmentProcessor(IFragmentProcessor objIFragmentProcessor)
objIFragmentProcessor - the objIFragmentProcessor to setpublic void setMLLPProcessor(IMLLP objIMLLP)
objIMLLP - the MLLP processor to set.public void setBatchProcessor(IBatchProcessor objIBatchProcessor)
objIBatchProcessor - the BatchProcessor to setpublic IProcessHandler getIProcessHandler()
public void setIProcessHandler(IProcessHandler objIProcessHandler)
objIProcessHandler - new IIProcessHandlerpublic void setReadWriteLength(int iReadLength,
int iWriteLength)
iReadLength - value of Reading max lengthiWriteLength - value of Writing max lengthpublic void start(java.lang.String strIP,
int iPort)
throws java.io.IOException
strIP - the ip address of serveriPort - the port on which server should listenjava.io.IOException - Signals that an I/O exception has occurred.public void start(int iPort)
throws java.io.IOException
iPort - int value of port.java.io.IOException - Signals that an I/O exception has occurred.public void start(java.net.InetAddress ip,
int iPort)
throws java.io.IOException
ip - instance of INet Address.iPort - int value of port.java.io.IOException - Signals that an I/O exception has occurred.public void start(java.net.InetSocketAddress addr)
throws java.io.IOException
addr - specified addressjava.io.IOExceptionpublic void start(java.net.Socket socket)
throws java.io.IOException
objSocket - Specifies object of Socket on Client Session.java.io.IOExceptionpublic int noOfClientsConnected()
public boolean isClientConnected(java.net.InetSocketAddress objAddress)
objAddress - InetSocketAddress of clientpublic ISingleCollection<java.net.InetSocketAddress> getClientsConnectionInfo()
public void close()
throws java.io.IOException
java.io.IOExceptionpublic int getTimeOut()
public void setTimeOut(int itimeout)
timeout - the specified timeout, in milliseconds.