The latest release of
Waffle (0.7) can now fully support
ParaNamer as an alternative to annotations. ParaNamer provides "method parameter name access for versions of Java PRIOR TO Java 7.0". ParaNamer combined with Waffle will allow you to utilize your
ActionMethod parameter names directly. In the example below Waffle will use "itemId" and "quantity" to resolve the arguments for the
void removeFromCart(Long, int) action method.
public class ShoppingCartAction implements Serializable {
...
// No annotation is necessary when utilizing ParaNamer
public void removeFromCart(Long itemId, int quantity) {
cart.remove(itemId, quantity);
}
}
For complete details on this please see the documentation on
Waffle ActionMethods.