public class App extends Object
main(...) method.| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
logger |
| Constructor and Description |
|---|
App(org.spincast.core.server.IServer server,
IAppConfig config,
IAppRouter router,
IAppController appController,
org.spincast.core.filters.ISpincastFilters<IAppRequestContext> spincastFilters)
The application constructor which Guice will call
with the required dependencies.
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
addRoutes()
Adds the application routes.
|
static com.google.inject.Injector |
createApp()
Creates an
App instance and returns the Guice injector. |
static com.google.inject.Injector |
createApp(String[] args)
Creates an
App instance using the given
parameters and returns the Guice injector. |
protected void |
displayStartedMessage()
Displays a message when the application is started.
|
protected IAppController |
getAppController() |
protected IAppConfig |
getConfig() |
protected IAppRouter |
getRouter() |
protected org.spincast.core.server.IServer |
getServer() |
protected org.spincast.core.filters.ISpincastFilters<IAppRequestContext> |
getSpincastFilters() |
static void |
main(String[] args)
The entry point for the application.
|
protected void |
start()
Once the application instance is created by Guice, start() is called
and the real work begins!
|
@Inject
public App(org.spincast.core.server.IServer server,
IAppConfig config,
IAppRouter router,
IAppController appController,
org.spincast.core.filters.ISpincastFilters<IAppRequestContext> spincastFilters)
public static void main(String[] args)
public static com.google.inject.Injector createApp()
App instance and returns the Guice injector.public static com.google.inject.Injector createApp(String[] args)
App instance using the given
parameters and returns the Guice injector.protected IAppConfig getConfig()
protected org.spincast.core.server.IServer getServer()
protected IAppRouter getRouter()
protected IAppController getAppController()
protected org.spincast.core.filters.ISpincastFilters<IAppRequestContext> getSpincastFilters()
protected void start()
protected void addRoutes()
protected void displayStartedMessage()
Copyright © 2016. All rights reserved.