org.apache.activeio.xnet
public class ServiceDaemon extends java.lang.Object implements ServerService
Constructor and Description |
---|
ServiceDaemon(SocketService socketService,
java.net.InetAddress address,
int port) |
ServiceDaemon(java.lang.String name,
SocketService socketService,
java.net.InetAddress address,
int port) |
Modifier and Type | Method and Description |
---|---|
java.net.InetAddress |
getAddress()
Gets the inetAddress number that the
daemon is listening on.
|
java.lang.String |
getIP()
Gets the ip number that the
daemon is listening on.
|
java.lang.String |
getName()
Gets the name of the service.
|
int |
getPort()
Gets the port number that the
daemon is listening on.
|
java.lang.String |
getServiceName() |
int |
getSoTimeout() |
void |
init(java.util.Properties props) |
void |
service(java.net.Socket socket) |
void |
setSoTimeout(int timeout) |
void |
start() |
void |
stop() |
public ServiceDaemon(SocketService socketService, java.net.InetAddress address, int port)
public ServiceDaemon(java.lang.String name, SocketService socketService, java.net.InetAddress address, int port)
public void setSoTimeout(int timeout) throws java.net.SocketException
java.net.SocketException
public int getSoTimeout() throws java.io.IOException
java.io.IOException
public java.lang.String getServiceName()
public java.net.InetAddress getAddress()
public void init(java.util.Properties props) throws java.lang.Exception
init
in interface ServerService
java.lang.Exception
public void start() throws ServiceException
start
in interface ServerService
ServiceException
public void stop() throws ServiceException
stop
in interface ServerService
ServiceException
public java.lang.String getIP()
ServerService
getIP
in interface ServerService
public int getPort()
getPort
in interface ServerService
public void service(java.net.Socket socket) throws ServiceException, java.io.IOException
service
in interface SocketService
ServiceException
java.io.IOException
public java.lang.String getName()
SocketService
getName
in interface SocketService
Copyright © 2005-2014. All Rights Reserved.