protected static class BootstrapHandler.BootstrapContext extends Object
Modifier | Constructor and Description |
---|---|
protected |
BootstrapContext(VaadinRequest request,
VaadinResponse response,
VaadinSession session,
UI ui)
Creates a new context instance using the given parameters.
|
Modifier and Type | Method and Description |
---|---|
String |
getAppId()
Gets the application id.
|
elemental.json.JsonObject |
getApplicationParameters()
Gets the application parameters specified by the BootstrapHandler.
|
<T extends Annotation> |
getPageConfigurationAnnotation(Class<T> annotationType)
Gets an annotation from the topmost class in the current navigation
target hierarchy.
|
<T extends Annotation> |
getPageConfigurationAnnotations(Class<T> annotationType)
Gets a a list of annotations from the topmost class in the current
navigation target hierarchy.
|
PushMode |
getPushMode()
Gets the push mode to use.
|
VaadinRequest |
getRequest()
Gets the Vaadin/HTTP request.
|
VaadinResponse |
getResponse()
Gets the Vaadin/HTTP response.
|
VaadinSession |
getSession()
Gets the Vaadin session.
|
protected Optional<ThemeDefinition> |
getTheme()
Gets the
ThemeDefinition associated with the
pageConfigurationHolder of this context, if any. |
UI |
getUI()
Gets the UI.
|
BootstrapHandler.BootstrapUriResolver |
getUriResolver()
Gets the URI resolver to use for bootstrap resources.
|
boolean |
isProductionMode()
Checks if the application is running in production mode.
|
protected BootstrapContext(VaadinRequest request, VaadinResponse response, VaadinSession session, UI ui)
request
- the request objectresponse
- the response objectsession
- the current sessionui
- the UI objectpublic VaadinResponse getResponse()
public VaadinRequest getRequest()
public VaadinSession getSession()
public UI getUI()
public PushMode getPushMode()
public String getAppId()
VaadinService.getMainDivId(VaadinSession, VaadinRequest)
public elemental.json.JsonObject getApplicationParameters()
public BootstrapHandler.BootstrapUriResolver getUriResolver()
public boolean isProductionMode()
true
if in production mode, false
otherwise.public <T extends Annotation> Optional<T> getPageConfigurationAnnotation(Class<T> annotationType)
T
- the type of the annotationannotationType
- the type of the annotation to getpublic <T extends Annotation> List<T> getPageConfigurationAnnotations(Class<T> annotationType)
T
- the type of the annotationsannotationType
- the type of the annotation to getprotected Optional<ThemeDefinition> getTheme()
ThemeDefinition
associated with the
pageConfigurationHolder of this context, if any.null
UI.getThemeFor(Class, String)
Copyright © 2018. All rights reserved.