@RenderWith(NoneActionResult.class) public class NoResult { public static NoResult value() { return new NoResult(); } }
/** * Permanent redirection. * @see Redirect */ @RenderWith(ServletPermanentRedirectActionResult.class) public class PermRedirect extends PathResult { public static PermRedirect to(final String target) { return new PermRedirect(target); } public static <T> PermRedirect to(final Class<T> target, final Consumer<T> consumer) { return new PermRedirect(target, consumer); } // ---------------------------------------------------------------- ctor public <T> PermRedirect(final Class<T> target, final Consumer<T> consumer) { super(target, consumer); } public PermRedirect(final String path) { super(path); } }
/** * Chain result. */ @RenderWith(ChainActionResult.class) public class Chain extends PathResult { public static Chain to(final String target) { return new Chain(target); } public static <T> Chain to(final Class<T> target, final Consumer<T> consumer) { return new Chain(target, consumer); } @SuppressWarnings("unchecked") public static <T> Chain to(final T target, final Consumer<T> consumer) { return new Chain((Class<T>) target.getClass(), consumer); } // ---------------------------------------------------------------- ctor public <T> Chain(final Class<T> target, final Consumer<T> consumer) { super(target, consumer); } public Chain(final String path) { super(path); } }
@RenderWith(ServletDispatcherActionResult.class) public class Forward extends PathResult {
@RenderWith(ServletRedirectActionResult.class) public class Redirect extends PathResult {
@RenderWith(TextActionResult.class) public class TextResult {
@RenderWith(RawActionResult.class) public class RawData {
@RenderWith(JsonActionResult.class) public class JsonResult {
/** * @author zqq90 */ @RenderWith(WitResult.class) public class WitData { public final String path; public final String contentType; public WitData(String path, String contentType) { this.path = path; this.contentType = contentType; } }