
@Path(value="/v2/rules/") public class RulesHandler extends AbstractRestDbHandler
AbstractRestDbHandler handling all operations on the
host's transfer rule database.crud| Constructor and Description |
|---|
RulesHandler(byte crud) |
| Modifier and Type | Method and Description |
|---|---|
void |
addRule(io.netty.handler.codec.http.HttpRequest request,
io.cdap.http.HttpResponder responder)
Method called to add a new transfer rule in the server database.
|
void |
filterRules(io.netty.handler.codec.http.HttpRequest request,
io.cdap.http.HttpResponder responder,
String limitStr,
String offsetStr,
String orderStr,
String modeTransStr)
Method called to obtain a list of transfer rules based on the filters in
the query parameters.
|
void |
options(io.netty.handler.codec.http.HttpRequest request,
io.cdap.http.HttpResponder responder)
Method called to get a list of all allowed HTTP methods on this entry
point.
|
checkCRUD@GET @Consumes(value="application/x-www-form-urlencoded") public void filterRules(io.netty.handler.codec.http.HttpRequest request, io.cdap.http.HttpResponder responder, @QueryParam(value="limit") @DefaultValue(value="20") String limitStr, @QueryParam(value="offset") @DefaultValue(value="0") String offsetStr, @QueryParam(value="order") @DefaultValue(value="ascName") String orderStr, @QueryParam(value="modeTrans") @DefaultValue(value="") String modeTransStr)
request - the HttpRequest made on the resourceresponder - the HttpResponder which sends the reply to the
requestlimitStr - the maximum number of entries allowed in the
responseoffsetStr - the index of the first accepted entry in the
list of all valid answersorderStr - the criteria used to sort the entries and the
way of ordering themmodeTransStr - only keep rules that use this transfer mode@POST @Consumes(value="application/json") public void addRule(io.netty.handler.codec.http.HttpRequest request, io.cdap.http.HttpResponder responder)
request - the HttpRequest made on the resourceresponder - the HttpResponder which sends the reply to the
request.@OPTIONS @Consumes(value="*/*") public void options(io.netty.handler.codec.http.HttpRequest request, io.cdap.http.HttpResponder responder)
request - the HttpRequest made on the resourceresponder - The HttpResponder which sends the reply
to the request.Copyright © 2009–2020 Waarp. All rights reserved.