Rich Platform project for Java web applications.
This project is maintained by aktion-hip
The use case's control center is formed by the controller classes. A Ripla controller is a Java class implementing the org.ripla.web.interfaces.IPluggable interface and annotated with the class annotation @org.ripla.web.annotations.UseCaseController.
To make use case development easier, controller classes should extend org.ripla.web.controllers.AbstractController which provides basic functionality useful for all controllers. By extending AbstractController, use case implementors can focus on the business logic as the only thing they have to do is to provide implementations for the abstract methods AbstractController.needsPermission() and AbstractController.runChecked(). See Use Case Controller Class for an example.
Ripla offers two methods how controller classes provided by a use case bundles are looked up. IUseCase.getControllerClasses() returns a package (java.lang.Package) within the use case bundle. The Ripla application will register all classes found in the specified package at the application's controller manager, provided they implement the IPluggable interface and are annoteted with @UseCaseController.
An alternative approach is provided by the IUseCase.getControllerSet() method. In this case, the use case implementer has to specify the controller classes in the org.ripla.web.interfaces.IControllerSet returned.
public interface IControllerSet { IControllerConfiguration[] getControllerConfigurations(); } public interface IControllerConfiguration { Bundle getBundle(); String getControllerName(); }
IControllerSet.getControllerConfigurations() returns an array of objects implementing the org.ripla.web.interfaces.IControllerConfiguration interface. The controller configuration has to specify the bundle providing the controller (IControllerConfiguration.getBundle()) and the (fully qualified) name of the controller class (IControllerConfiguration.getControllerName()). Again, the controller class specified this way has to implement the IPluggable interface.