Package play
Class DefaultApplication
- Object
-
- play.DefaultApplication
-
- All Implemented Interfaces:
Application
@Singleton public class DefaultApplication extends Object implements Application
Default implementation of a Play Application.Application creation is handled by the framework engine.
-
-
Constructor Summary
Constructors Constructor Description DefaultApplication(play.api.Application application, com.typesafe.config.Config config, Injector injector)
Deprecated.DefaultApplication(play.api.Application application, com.typesafe.config.Config config, Injector injector, Environment environment)
Create an application that wraps a Scala application.DefaultApplication(play.api.Application application, Injector injector)
Create an application that wraps a Scala application.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description play.api.Application
asScala()
Get the application as a Scala application.com.typesafe.config.Config
config()
Get the application configuration.Environment
environment()
Get the application environment.play.api.Application
getWrappedApplication()
Deprecated.Injector
injector()
Get the injector for this application.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface play.Application
classloader, isDev, isProd, isTest, path
-
-
-
-
Constructor Detail
-
DefaultApplication
@Inject public DefaultApplication(play.api.Application application, com.typesafe.config.Config config, Injector injector, Environment environment)
Create an application that wraps a Scala application.- Parameters:
application
- the application to wrapconfig
- the new application's configurationinjector
- the new application's injector
-
DefaultApplication
@Deprecated public DefaultApplication(play.api.Application application, com.typesafe.config.Config config, Injector injector)
Deprecated.Create an application that wraps a Scala application.- Parameters:
application
- the application to wrapconfig
- the new application's configurationinjector
- the new application's injector
-
DefaultApplication
public DefaultApplication(play.api.Application application, Injector injector)
Create an application that wraps a Scala application.- Parameters:
application
- the application to wrapinjector
- the new application's injector
-
-
Method Detail
-
getWrappedApplication
@Deprecated public play.api.Application getWrappedApplication()
Deprecated.Get the underlying Scala application.- Specified by:
getWrappedApplication
in interfaceApplication
- Returns:
- the underlying application
- See Also:
method
-
asScala
public play.api.Application asScala()
Get the application as a Scala application.- Specified by:
asScala
in interfaceApplication
- Returns:
- this application as a Scala application.
- See Also:
Application
-
environment
public Environment environment()
Get the application environment.- Specified by:
environment
in interfaceApplication
- Returns:
- the environment.
-
config
public com.typesafe.config.Config config()
Get the application configuration.- Specified by:
config
in interfaceApplication
- Returns:
- the configuration
-
injector
public Injector injector()
Get the injector for this application.- Specified by:
injector
in interfaceApplication
- Returns:
- the injector
-
-