public final class TreeTankMediator extends Object implements JaxRx
Constructor and Description |
---|
TreeTankMediator()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
String |
add(InputStream input,
ResourcePath path)
This method is called by the POST method.
|
javax.ws.rs.core.StreamingOutput |
command(String command,
ResourcePath path)
This method is called by the GET and the POST method, if
QueryParameter.COMMAND was specified in the HTTP request. |
String |
delete(ResourcePath path)
This method is called by the DELETE method.
|
javax.ws.rs.core.StreamingOutput |
get(ResourcePath path)
This method is called by the GET and the POST method.
|
Set<QueryParameter> |
getParameters()
This method returns all query parameters which are supported by the
implementation.
|
javax.ws.rs.core.StreamingOutput |
query(String query,
ResourcePath path)
This method is called by the GET and the POST method, if
QueryParameter.QUERY was specified in the HTTP request. |
javax.ws.rs.core.StreamingOutput |
run(String file,
ResourcePath path)
This method is called by the GET and the POST method, if
QueryParameter.RUN was specified in the HTTP request. |
String |
update(InputStream input,
ResourcePath path)
This method is called by the PUT method.
|
public TreeTankMediator() throws TTException
TTException
public String add(InputStream input, ResourcePath path) throws JaxRxException
JaxRx
add
in interface JaxRx
input
- The object containing the new content.path
- Resource and parameter infoJaxRxException
- thrown if
public javax.ws.rs.core.StreamingOutput command(String command, ResourcePath path) throws JaxRxException
JaxRx
QueryParameter.COMMAND
was specified in the HTTP request. This
method performs a database command, based on the given resource path.command
in interface JaxRx
command
- The command to be executedpath
- Resource and parameter infoStreamingOutput
containing the query output.JaxRxException
- thrown if
public String update(InputStream input, ResourcePath path) throws JaxRxException
JaxRx
update
in interface JaxRx
input
- The incoming InputStream
.path
- Resource and parameter infoJaxRxException
- thrown if
public String delete(ResourcePath path) throws JaxRxException
JaxRx
delete
in interface JaxRx
path
- Resource and parameter infoJaxRxException
- thrown if
public javax.ws.rs.core.StreamingOutput get(ResourcePath path) throws JaxRxException
JaxRx
get
in interface JaxRx
path
- Resource and parameter infoStreamingOutput
containing the query output.JaxRxException
- thrown if
public Set<QueryParameter> getParameters()
JaxRx
getParameters
in interface JaxRx
Set
containing the allowed parameters specified in
QueryParameter
.public javax.ws.rs.core.StreamingOutput query(String query, ResourcePath path) throws JaxRxException
JaxRx
QueryParameter.QUERY
was specified in the HTTP request. This
method performs a query, based on the given resource path.query
in interface JaxRx
query
- The query to be executedpath
- Resource and parameter infoStreamingOutput
containing the query output.JaxRxException
- thrown if
public javax.ws.rs.core.StreamingOutput run(String file, ResourcePath path) throws JaxRxException
JaxRx
QueryParameter.RUN
was specified in the HTTP request. This method
runs a server-side query file, based on the given resource path.run
in interface JaxRx
file
- The file to be runpath
- Resource and parameter infoStreamingOutput
containing the query outputJaxRxException
- thrown if
Copyright © 2013. All Rights Reserved.