use of com.willshex.blogwt.server.api.page.action.CreatePageActionHandler in project blogwt by billy1380.
the class PageJsonServlet method processAction.
@Override
protected String processAction(String action, JsonObject request) {
String output = "null";
if ("SubmitForm".equals(action)) {
SubmitFormRequest input = new SubmitFormRequest();
input.fromJson(request);
output = new SubmitFormActionHandler().handle(input).toString();
} else if ("GetPages".equals(action)) {
GetPagesRequest input = new GetPagesRequest();
input.fromJson(request);
output = new GetPagesActionHandler().handle(input).toString();
} else if ("GetPage".equals(action)) {
GetPageRequest input = new GetPageRequest();
input.fromJson(request);
output = new GetPageActionHandler().handle(input).toString();
} else if ("UpdatePage".equals(action)) {
UpdatePageRequest input = new UpdatePageRequest();
input.fromJson(request);
output = new UpdatePageActionHandler().handle(input).toString();
} else if ("DeletePage".equals(action)) {
DeletePageRequest input = new DeletePageRequest();
input.fromJson(request);
output = new DeletePageActionHandler().handle(input).toString();
} else if ("CreatePage".equals(action)) {
CreatePageRequest input = new CreatePageRequest();
input.fromJson(request);
output = new CreatePageActionHandler().handle(input).toString();
}
return output;
}
Aggregations