public class MappedJavaHandlerComponents
extends java.lang.Object
implements play.core.j.JavaHandlerComponents
But this implementation does not uses an Injector. Instead, the necessary Action
and BodyParser
must be added here manually. This is way we
avoid mixing runtime dependency injector components with compile time injected ones.
Constructor and Description |
---|
MappedJavaHandlerComponents(ActionCreator actionCreator,
play.api.http.HttpConfiguration httpConfiguration,
scala.concurrent.ExecutionContext executionContext,
play.core.j.JavaContextComponents contextComponents) |
Modifier and Type | Method and Description |
---|---|
ActionCreator |
actionCreator() |
<A extends Action<?>> |
addAction(java.lang.Class<A> clazz,
java.util.function.Supplier<A> actionSupplier) |
<B extends BodyParser<?>> |
addBodyParser(java.lang.Class<B> clazz,
java.util.function.Supplier<B> bodyParserSupplier) |
play.core.j.JavaContextComponents |
contextComponents() |
scala.concurrent.ExecutionContext |
executionContext() |
<A extends Action<?>> |
getAction(java.lang.Class<A> actionClass) |
<A extends BodyParser<?>> |
getBodyParser(java.lang.Class<A> parserClass) |
play.api.http.HttpConfiguration |
httpConfiguration() |
public MappedJavaHandlerComponents(ActionCreator actionCreator, play.api.http.HttpConfiguration httpConfiguration, scala.concurrent.ExecutionContext executionContext, play.core.j.JavaContextComponents contextComponents)
public <A extends BodyParser<?>> A getBodyParser(java.lang.Class<A> parserClass)
getBodyParser
in interface play.core.j.JavaHandlerComponents
public <A extends Action<?>> A getAction(java.lang.Class<A> actionClass)
getAction
in interface play.core.j.JavaHandlerComponents
public ActionCreator actionCreator()
actionCreator
in interface play.core.j.JavaHandlerComponents
public play.api.http.HttpConfiguration httpConfiguration()
httpConfiguration
in interface play.core.j.JavaHandlerComponents
public scala.concurrent.ExecutionContext executionContext()
executionContext
in interface play.core.j.JavaHandlerComponents
public play.core.j.JavaContextComponents contextComponents()
contextComponents
in interface play.core.j.JavaHandlerComponents
public <A extends Action<?>> MappedJavaHandlerComponents addAction(java.lang.Class<A> clazz, java.util.function.Supplier<A> actionSupplier)
public <B extends BodyParser<?>> MappedJavaHandlerComponents addBodyParser(java.lang.Class<B> clazz, java.util.function.Supplier<B> bodyParserSupplier)