|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.restlet.Restlet
org.restlet.Connector
org.restlet.Client
org.restlet.engine.TemplateDispatcher
public class TemplateDispatcher
Base call dispatcher capable of resolving target resource URI templates. Concurrency note: instances of this class or its subclasses can be invoked by several threads at the same time and therefore must be thread-safe. You should be especially careful when storing state as member variables.
Constructor Summary | |
---|---|
TemplateDispatcher(Context context)
Constructor. |
Method Summary | |
---|---|
protected void |
doHandle(Request request,
Response response)
Actually handles the call. |
Context |
getContext()
Returns the context. |
void |
handle(Request request,
Response response)
Handles the call after resolving any URI template on the request's target resource reference. |
void |
setContext(Context context)
Sets the context. |
Methods inherited from class org.restlet.Client |
---|
getConnectTimeout, handle, handle, handle, isAvailable, setConnectTimeout, start, stop |
Methods inherited from class org.restlet.Connector |
---|
getProtocols, setProtocols |
Methods inherited from class org.restlet.Restlet |
---|
finalize, getApplication, getAuthor, getDescription, getLogger, getName, getOwner, isStarted, isStopped, setAuthor, setDescription, setName, setOwner |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TemplateDispatcher(Context context)
context
- The context.Method Detail |
---|
protected void doHandle(Request request, Response response)
Request.getOriginalRef()
with the the
targeted one, it must be overridden by subclasses.
request
- The request to handle.response
- The response to update.public Context getContext()
Restlet
.
getContext
in class Restlet
public void handle(Request request, Response response)
handle
in interface Uniform
handle
in class Client
request
- The request to handle.response
- The response to update.public void setContext(Context context)
Restlet
.
setContext
in class Restlet
context
- The context to set.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |