|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface UIProvider
| Method Summary | |
|---|---|
UI |
createInstance(WrappedRequest request,
java.lang.Class<? extends UI> type)
|
UI |
getExistingUI(WrappedRequest request)
Finds an existing UI for a request. |
java.lang.String |
getPageTitle(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
|
java.lang.String |
getTheme(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
Finds the theme to use for a specific UI. |
java.lang.Class<? extends UI> |
getUIClass(WrappedRequest request)
|
java.lang.String |
getWidgetset(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
Finds the widgetset to use for a specific UI. |
boolean |
isPreservedOnRefresh(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
Checks whether the same UI state should be reused if the framework can detect that the application is opened in a browser window where it has previously been open. |
| Method Detail |
|---|
java.lang.Class<? extends UI> getUIClass(WrappedRequest request)
UI createInstance(WrappedRequest request,
java.lang.Class<? extends UI> type)
java.lang.String getPageTitle(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
boolean isPreservedOnRefresh(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
request - uiClass -
trueif the same UI instance should be reused e.g.
when the browser window is refreshed.
java.lang.String getWidgetset(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
null is returned.
The default implementation uses the @Widgetset annotation if it's
defined for the UI class.
request - the wrapped request for which to get a widgetsetuiClass - the UI class to get a widgetset for
null if the default
widgetset should be used
java.lang.String getTheme(WrappedRequest request,
java.lang.Class<? extends UI> uiClass)
null is returned.
TODO Tell what the default implementation does once it does something.
uI - the UI to get a theme for
null if the default theme
should be usedUI getExistingUI(WrappedRequest request)
UI for a request.
Implementations should take care to not return an UI instance that might be used in some other browser as that might cause synchronization issues when changes from one browser window are not present in the other.
If no UI provider returns an existing UI, the framework does also check
the window.name for an existing instance with
isPreservedOnRefresh(WrappedRequest, Class) before falling back to
bootstrapping and creating a new UI instance.
request - the request for which a UI is desired
null if this UI
provider doesn't have an existing UI for the request.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||