/** * Commands that intercept requests before the rest of the application handles them. Used by Evolutions. * * @return the application web commands. */ default WebCommands webCommands() { return new DefaultWebCommands(); }
/** * An ExecutionContext that executes work on the application's internal * ActorSystem dispatcher. The current thread's context ClassLoader and * Http.Context are captured when this method is called and preserved * for all executed tasks. */ public static ExecutionContextExecutor defaultContext() { return HttpExecutionContext.fromThread(Execution.internalContext()); }
public ApplicationProvider(Application application) { this.application = application; this.underlying = play.core.ApplicationProvider$.MODULE$.apply(application.asScala()); }
/** * Transform this call to a relative path. * @param startPath the URL to make this Call relative to. * @return the relative path string */ public String relativeTo(String startPath) { return Paths.relative(startPath, this.url()) + this.appendFragment(); }
/** * Transform this path into its canonical form. * @return the canonical path. */ public String canonical() { return Paths.canonical(this.url()) + this.appendFragment(); }
@Override public play.api.libs.streams.Accumulator<ByteString, play.api.mvc.Result> apply(play.api.mvc.RequestHeader rh) { return apply(rh.asJava()) .map(Result::asScala, Execution.trampoline()) .asScala(); }
/** * Handle a request directly, without using the application. * @param requestHeader the request made. * * @deprecated Deprecated as of 2.7.0. WebCommands are now handled by the DefaultHttpRequestHandler. */ @Deprecated public Optional<Result> handleWebCommand(Http.RequestHeader requestHeader) { return OptionConverters .toJava(this.underlying.handleWebCommand(requestHeader.asScala())) .map(play.api.mvc.Result::asJava); } }
/** * Commands that intercept requests before the rest of the application handles them. Used by Evolutions. * * @return the application web commands. */ default WebCommands webCommands() { return new DefaultWebCommands(); }
/** * Transform this call to a relative path. * @param startPath the URL to make this Call relative to. * @return the relative path string */ public String relativeTo(String startPath) { return Paths.relative(startPath, this.url()) + this.appendFragment(); }
/** * Transform this path into its canonical form. * @return the canonical path. */ public String canonical() { return Paths.canonical(this.url()) + this.appendFragment(); }
public ApplicationProvider(Application application) { this.application = application; this.underlying = play.core.ApplicationProvider$.MODULE$.apply(application.asScala()); }
@Override public play.api.libs.streams.Accumulator<ByteString, play.api.mvc.Result> apply(play.api.mvc.RequestHeader rh) { return apply(rh.asJava()) .map(Result::asScala, Execution.trampoline()) .asScala(); }
/** * Commands that intercept requests before the rest of the application handles them. Used by Evolutions. * * @return the application web commands. */ default WebCommands webCommands() { return new DefaultWebCommands(); }
/** * Transform this call to a relative path. * @param startPath the URL to make this Call relative to. * @return the relative path string */ public String relativeTo(String startPath) { return Paths.relative(startPath, this.url()) + this.appendFragment(); }
/** * Transform this path into its canonical form. * @return the canonical path. */ public String canonical() { return Paths.canonical(this.url()) + this.appendFragment(); }
public ApplicationProvider(Application application) { this.application = application; this.underlying = play.core.ApplicationProvider$.MODULE$.apply(application.asScala()); }
@Override public play.api.libs.streams.Accumulator<ByteString, play.api.mvc.Result> apply(play.api.mvc.RequestHeader rh) { return apply(rh.asJava()) .map(Result::asScala, Execution.trampoline()) .asScala(); }
private WebCommands createWebCommands() { return new DefaultWebCommands(); }
private WebCommands createWebCommands() { return new DefaultWebCommands(); }
private WebCommands createWebCommands() { return new DefaultWebCommands(); }