Search in sources :

Example 1 with AbstractResourceAction

use of com.manydesigns.portofino.resourceactions.AbstractResourceAction in project Portofino by ManyDesigns.

the class ActionsAction method getResourceAction.

protected AbstractResourceAction getResourceAction() {
    String actionPath = StringUtils.join(parameters, "/");
    Resource resource = getResource(actionPath);
    if (resource instanceof AbstractResourceAction) {
        return ((AbstractResourceAction) resource);
    } else {
        logger.error("Not a ResourceAction: " + resource);
        throw new WebApplicationException();
    }
}
Also used : Resource(com.manydesigns.portofino.dispatcher.Resource) AbstractResourceAction(com.manydesigns.portofino.resourceactions.AbstractResourceAction)

Aggregations

Resource (com.manydesigns.portofino.dispatcher.Resource)1 AbstractResourceAction (com.manydesigns.portofino.resourceactions.AbstractResourceAction)1