public OnRoute view(String viewName) { options.view(viewName); return this; }
private void execHandlerJob(final Channel channel, final boolean isKeepAlive, final MediaType contentType, final Req req) { With.tag(CTX_TAG_HANDLER).exchange(req).run(() -> { try { req.response() .view(options.view()) .contentType(options.contentType()) .mvc(options.mvc()); handleWithWrappers(channel, isKeepAlive, contentType, req, wrappers.get()); } catch (Throwable e) { handleError(req, e); } }); }
public OnRoute view(String viewName) { options.view(viewName); return this; }
@Override public void run() { try { req.response() .view(options.view()) .contentType(options.contentType()) .mvc(options.mvc()); handleWithWrappers(channel, isKeepAlive, contentType, req, wrappers.get()); } catch (Throwable e) { handleError(req, e); } }