|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.restlet.engine.Helper
org.restlet.engine.RestletHelper<T>
org.restlet.engine.ConnectorHelper<Server>
org.restlet.engine.ServerHelper
org.restlet.engine.adapter.HttpServerHelper
org.restlet.ext.simple.SimpleServerHelper
public abstract class SimpleServerHelper
Abstract Simple Web server connector. Here is the list of parameters that are supported. They should be set in the Server's context before it is started:
Parameter name | Value type | Default value | Description |
---|---|---|---|
defaultThreads | int | 20 | Default number of polling threads for a handler object. |
maxWaitTimeMs | int | 200 | Maximum waiting time between polls of the input. |
Constructor Summary | |
---|---|
SimpleServerHelper(Server server)
Constructor. |
Method Summary | |
---|---|
protected InetSocketAddress |
getAddress()
Returns the socket address this server is listening to. |
protected Connection |
getConnection()
Returns the Simple connection. |
protected ContainerServer |
getContainerServer()
Returns the Simple container server. |
int |
getDefaultThreads()
Returns the default number of polling threads for a handler object. |
boolean |
isConfidential()
Indicates if this service is acting in HTTP or HTTPS mode. |
protected void |
setAddress(InetSocketAddress address)
Sets the socket address this server is listening to. |
protected void |
setConfidential(boolean confidential)
Indicates if this service is acting in HTTP or HTTPS mode. |
protected void |
setConnection(Connection connection)
Sets the Simple connection. |
protected void |
setContainerServer(ContainerServer container)
Sets the Simple container server. |
void |
start()
|
void |
stop()
|
Methods inherited from class org.restlet.engine.adapter.HttpServerHelper |
---|
getAdapter, handle, setAdapter |
Methods inherited from class org.restlet.engine.ServerHelper |
---|
handle, setEphemeralPort, setEphemeralPort |
Methods inherited from class org.restlet.engine.ConnectorHelper |
---|
getConnectorService, getContext, getProtocols, update |
Methods inherited from class org.restlet.engine.RestletHelper |
---|
getAttributes, getHelped, getHelpedParameters, getLogger, getMetadataService, setHelped |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SimpleServerHelper(Server server)
server
- The server to help.Method Detail |
---|
protected Connection getConnection()
public int getDefaultThreads()
protected ContainerServer getContainerServer()
protected InetSocketAddress getAddress()
public boolean isConfidential()
protected void setConfidential(boolean confidential)
confidential
- True if this service is acting in HTTP or HTTPS mode.protected void setConnection(Connection connection)
connection
- The Simple connection.protected void setContainerServer(ContainerServer container)
container
- The Simple containerServer.protected void setAddress(InetSocketAddress address)
address
- The socket address this server is listening to.public void start() throws Exception
start
in class ConnectorHelper<Server>
Exception
public void stop() throws Exception
stop
in class ServerHelper
Exception
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |