Method Summary |
|
public void | clearAllPools() |
public Object | clone() Creates and returns a copy of this object. |
public void | closeAllPools() |
public void | configQuickServer(QuickServerConfig config) Configures QuickServer based on the passed QuickServerConfig object. |
public void | configQuickServer(QSAdminServerConfig config) Configures QSAdminServer based on the passed QuickServerConfig object. |
public void | configQuickServer() Configures QSAdminServer and QuickServer based on the
internal QuickServerConfig object. |
public Iterator | findAllClient() Returns an iterator containing all the
org.quickserver.net.server.ClientHandler that
are currently handling clients. |
public Iterator | findAllClientById(String pattern) Tries to find the Client by the matching pattern passed to the Id.
Note: This command is an expensive so do use it limitedly and
cache the returned object. |
public Iterator | findAllClientByKey(String pattern) Tries to find the Client by the matching pattern passed to the key.
Note: This command is an expensive so do use it limitedly and
cache the returned object. |
public ClientHandler | findClientByKey(String key) Tries to find the Client by the Key passed.
Note: This command is an expensive so do use it limitedly and
cache the returned object. |
public ClientHandler | findFirstClientById(String id) Tries to find the Client by the Id passed.
Note: This command is an expensive so do use it limitedly and
cache the returned object. |
public AccessConstraintConfig | getAccessConstraintConfig() Returns Access constraints if present else null . |
public Logger | getAppLogger() Returns the application logger associated with QuickServer. |
public String | getApplicationJarPath() Returns the applications jar/s path. |
public String | getAuthenticator() Returns the Authenticator class that
handles the authentication of a client. |
public BasicServerConfig | getBasicConfig() Returns the basic confiuration of the QuickServer. |
public InetAddress | getBindAddr() Returns the IP address binding to. |
public boolean | getBlockingMode() Returns the current blocking mode of the server. |
public ObjectPool | getByteBufferPool() Returns ObjectPool of java.nio.ByteBuffer class. |
public Class | getClass(String name, boolean reload) |
public ClassLoader | getClassLoader() Gets the classloader used to load the dynamicaly resolved
classes. |
public String | getClientAuthenticationHandler() Returns the ClientAuthenticationHandler class that
handles the authentication of a client. |
public String | getClientBinaryHandler() Returns the ClientBinaryHandler class that interacts with
client sockets. |
public String | getClientCommandHandler() Returns the ClientCommandHandler class that interacts with
client sockets. |
public long | getClientCount() Returns number of clients connected. |
public String | getClientData() |
public ObjectPool | getClientDataPool() Returns ObjectPool of
org.quickserver.net.server.ClientData
class. |
public String | getClientEventHandler() Returns the ClientEventHandler class that gets notified of
client events. |
public String | getClientExtendedEventHandler() Returns the ClientExtendedEventHandler class that gets notified of
extended client events. |
public ObjectPool | getClientHandlerPool() Returns ObjectPool of
org.quickserver.net.server.ClientHandler
class. |
public ClientIdentifier | getClientIdentifier() Returns the implementation that is used to do Client Identification. |
public String | getClientObjectHandler() Returns the ClientObjectHandler class that interacts with
client sockets. |
public ClientPool | getClientPool() Returns
org.quickserver.util.pool.thread.ClientPool class that
managing the pool of threads for handling clients. |
public String | getClientWriteHandler() Returns the ClientWriteHandler class that interacts with
client sockets (only used in non-blocking mode). |
public boolean | getCommunicationLogging() Returns the communication logging flag. |
public QuickServerConfig | getConfig() Returns the confiuration of the QuickServer. |
public String | getConsoleLoggingFormatter() Gets the console log handler formatter. |
public String | getConsoleLoggingLevel() Gets the console log handler level. |
public DBPoolUtil | getDBPoolUtil() Returns
org.quickserver.sql.DBPoolUtil object if
org.quickserver.util.xmlreader.DBObjectPoolConfig was set. |
public DataMode | getDefaultDataMode(DataType dataType) |
public java.util.Date | getLastStartTime() Returns the date/time when the server was last started.
last started time. |
public int | getMaxAuthTry() Returns max allowed login attempts. |
public String | getMaxAuthTryMsg() Returns message to be displayed when maximum allowed login
attempts has reached. |
public long | getMaxConnection() Returns the maximum number of client connection allowed. |
public String | getMaxConnectionMsg() Returns the message to be sent to any new client connected
after maximum client connection has reached. |
public String | getName() Returns the name of the QuickServer. |
public static String | getNewLine() Returns the new line string used by QuickServer. |
public int | getPort() Returns the port for the QuickServer. |
public QSAdminServer | getQSAdminServer() |
public String | getQSAdminServerAuthenticator() Returns the Authenticator or ClientAuthenticationHandler class of
QSAdminServer that handles the authentication of a client. |
public int | getQSAdminServerPort() Returns the port to run QSAdminServer on. |
public SSLContext | getSSLContext() Returns the SSLContext from Secure configuring. |
public SSLContext | getSSLContext(String protocol) Returns the SSLContext object that implements the specified
secure socket protocol from Secure configuring.
See Also: QuickServer.loadSSLContext Parameters: protocol - the standard name of the requested protocol. |
public SSLSocketFactory | getSSLSocketFactory() Returns a SSLSocketFactory object to be used for creating SSLSockets. |
public SSLSocketFactory | getSSLSocketFactory(String protocol) Returns a SSLSocketFactory object to be used for creating SSLSockets. |
public Secure | getSecure() |
public SecurityManager | getSecurityManager() |
public String | getSecurityManagerClass() |
public Selector | getSelector() Returns the Selector (NIO),if any. |
public String | getServerBanner() |
public ServerHooks | getServerHooks() Returns ServerHooks if present else null . |
public Throwable | getServiceError() Returns service error if any. |
public int | getServiceState() Returns the state of the process
As any constant of
Service interface. |
public Object[] | getStoreObjects() Returns store of objects from QuickServer, if nothing was set will
return null . |
public int | getTimeout() Returns the Client socket timeout in milliseconds. |
public String | getTimeoutMsg() Returns timeout message. |
final public static String | getVersion() Returns the version of the library. |
final public static float | getVersionNo() Returns the numerical version of the library. |
final public static float | getVersionNo(String ver) Returns the numerical version of the library. |
public String | info() Information about the service. |
public void | initAllPools() Initialise all Object and Thread pools. |
public synchronized void | initServer(Object param) Initialise and create the server. |
public synchronized void | initServer(QuickServerConfig qsConfig) Initialise and create the service. |
public synchronized boolean | initService(Object param) Initialise and create the service. |
public synchronized boolean | initService(QuickServerConfig qsConfig) Initialise and create the service. |
public boolean | isClosed() Returns the closed state of the QuickServer Socket. |
public boolean | isRunningSecure() |
public static QuickServer | load(String xml) Loads the server from the xml file name passed. |
protected void | loadBusinessLogic() |
public void | loadSSLContext() Loads the SSLContext from Secure configuring if set. |
public static void | main(String args) Usage: QuickServer [-options]
Where options include:
-about Opens About Dialogbox
-load [options] Loads the server from xml file. |
protected void | makeServerSocket() Returns a ServerSocket object to be used for listening. |
public void | nextClientIsTrusted() Sets next client has a trusted client. |
public boolean | registerChannel(SocketChannel channel, int ops, Object att) Register the given channel for the given operations. |
public void | restartServer() Restarts the QuickServer. |
public boolean | resumeService() Resume the service. |
public void | run() |
public void | setAccessConstraintConfig(AccessConstraintConfig accessConstraintConfig) |
public void | setAppLogger(Logger appLogger) |
protected void | setApplicationJarPath(String applicationJarPath) Sets the applications jar/s path. |
public void | setAuthenticator(String authenticator) Sets the Authenticator class that
handles the authentication of a client. |
public void | setBasicConfig(BasicServerConfig basicConfig) Sets the basic confiuration of the QuickServer. |
public void | setBindAddr(String bindAddr) Sets the Ip address to bind to. |
public void | setClassLoader(ClassLoader classLoader) |
public void | setClientAuthenticationHandler(String authenticator) Sets the ClientAuthenticationHandler class that
handles the authentication of a client. |
public void | setClientBinaryHandler(String handler) Sets the ClientBinaryHandler class that interacts with
client sockets to handle binary data. |
public void | setClientCommandHandler(String handler) Sets the ClientCommandHandler class that interacts with
client sockets. |
public void | setClientData(String data) Sets the ClientData class that carries client data. |
public void | setClientEventHandler(String handler) Sets the ClientEventHandler class that gets notified of
client events. |
public void | setClientExtendedEventHandler(String handler) Sets the ClientExtendedEventHandler class that gets notified of
extended client events. |
public void | setClientObjectHandler(String handler) Sets the ClientObjectHandler class that interacts with
client sockets to handle java objects. |
public void | setClientWriteHandler(String handler) Sets the ClientWriteHandler class that interacts with
client sockets to handle data write (only used in non-blocking mode). |
public void | setCommunicationLogging(boolean communicationLogging) Sets the communication logging flag. |
public void | setConfig(QuickServerConfig config) Sets the confiuration of the QuickServer. |
public void | setConsoleLoggingFormatter(String formatter) Sets the console log handler formatter. |
public void | setConsoleLoggingLevel(Level level) Sets the console log handler level. |
public void | setConsoleLoggingToMicro() |
public void | setConsoleLoggingToMini() |
public void | setDBObjectPoolConfig(DBObjectPoolConfig dBObjectPoolConfig) |
public static void | setDebugNonBlockingMode(boolean flag) |
public void | setDefaultDataMode(DataMode dataMode, DataType dataType) |
public void | setDefaultDataMode(DefaultDataMode defaultDataMode) |
public void | setLoggingLevel(Level level) Sets the level for all log handlers. |
public void | setMaxAuthTry(int authTry) Sets max allowed login attempts. |
public void | setMaxAuthTryMsg(String msg) Sets message to be displayed when maximum allowed login
attempts has reached. |
public void | setMaxConnection(long maxConnection) Sets the maximum number of client connection allowed. |
public void | setMaxConnectionMsg(String maxConnectionMsg) Sets the message to be sent to any new client connected after
maximum client connection has reached. |
public void | setName(String name) |
public void | setPort(int port) Sets the port for the QuickServer to listen on. |
public void | setQSAdminServer(QSAdminServer adminServer) |
public void | setQSAdminServerAuthenticator(String authenticator) Set the ClientAuthenticationHandler class of
QSAdminServer that handles the authentication of a client. |
public void | setQSAdminServerPort(int port) Set the port to run QSAdminServer on. |
public void | setRunningSecure(boolean runningSecure) |
public void | setSecure(Secure secure) |
public void | setSecurityManagerClass(String securityManagerClass) |
public void | setSelector(Selector selector) Sets the Selector (NIO). |
public void | setServerBanner(String banner) Sets the serverBanner for the QuickServer
that will be displayed on the standard output [console]
when server starts. |
public void | setServerHooks(ServerHooks serverHooks) |
public void | setServiceState(int state) Sets the state of the process
As any constant of
Service interface. |
public void | setStoreObjects(Object[] storeObjects) Sets the store of objects to QuickServer, it is an array of objects
that main program or the class that created QuickServer passes to
the QuickServer. |
public void | setTimeout(int time) Sets the client socket's timeout. |
public void | setTimeoutMsg(String msg) Sets timeout message. |
public void | startQSAdminServer(int port, String authenticator) Starts QSAdminServer for this QuickServer. |
public void | startQSAdminServer() Starts QSAdminServer for this QuickServer. |
public void | startServer() Starts the QuickServer. |
public boolean | startService() Start the service. |
public void | stopServer() Stops the QuickServer. |
public boolean | stopService() Stop the service. |
public boolean | suspendService() Suspends the service. |
public String | toString() Returns the Server name : port of the QuickServer. |