public interface PageNode<P>
Thinking of the application flow as a directed graph, Pages are the nodes and
TransitionTos are the edges.
| Modifier and Type | Method and Description |
|---|---|
Class<P> |
contentType()
Returns the type of widget that this page node's
produceContent(CreationalCallback)
method will produce. |
void |
destroy(P page)
Used by the framework to destroy
Dependent scoped beans after a page is no longer
needed. |
String |
getURL()
Returns the URL template specified for this page by
Page.path(). |
String |
name()
Returns the name of this page.
|
void |
pageHidden(P page)
Called by the framework after this page has been removed from the navigation content panel.
|
void |
pageHiding(P page,
NavigationControl control)
Called by the framework when this page node is about to be removed from the navigation content
panel.
|
void |
pageShowing(P page,
HistoryToken state,
NavigationControl control)
Called by the framework when this page node is about to be displayed in the navigation content
panel.
|
void |
pageShown(P page,
HistoryToken state)
Called by the framework when this page node was displayed in the navigation content panel.
|
void |
pageUpdate(P page,
HistoryToken state)
Called by the framework when this page node state was updated
Navigation.updateState(Multimap). |
void |
produceContent(CreationalCallback<P> callback)
Retrieves the widget that provides this page's content from the client-side bean manager.
|
String name()
String getURL()
Page.path(). If no template is
specified, it returns the page name.void produceContent(CreationalCallback<P> callback)
callback - The callback that will receive the widget to display for this page. The Widget
will have the same runtime type as returned by contentType(), and will never be
null.Class<P> contentType()
produceContent(CreationalCallback)
method will produce.void pageShowing(P page, HistoryToken state, NavigationControl control)
If this method throws an exception when called, framework behaviour is undefined.
page - the page instance that was just returned from a call to
produceContent(CreationalCallback). Never null.state - the state of the page, parsed from the history token on the URL. Never null.void pageShown(P page, HistoryToken state)
If this method throws an exception when called, framework behaviour is undefined.
page - the page instance that was just returned from a call to
produceContent(CreationalCallback). Never null.state - the state of the page, parsed from the history token on the URL. Never null.void pageHiding(P page, NavigationControl control)
If this method throws an exception when called, framework behaviour is undefined.
page - the page instance (which is currently in the navigation content panel) that was
previously used in the call to #pageShowing(P, HistoryToken, NavigationControl).
Never null.void pageHidden(P page)
If this method throws an exception when called, framework behaviour is undefined.
page - the page instance (which was in the navigation content panel) that was previously
used in the call to #pageShowing(P, HistoryToken, NavigationControl). Never
null.void pageUpdate(P page, HistoryToken state)
Navigation.updateState(Multimap).
If this method throws an exception when called, framework behaviour is undefined.
page - the page instance that was just returned from a call to
produceContent(CreationalCallback). Never null.state - the state of the page, parsed from the history token on the URL. Never null.void destroy(P page)
Dependent scoped beans after a page is no longer
needed. For ApplicationScoped beans this method is a noop.page - The page instance that will be destroyed if it is a dependent-scoped bean. Never
null.Copyright © 2020 Treblereel. All rights reserved.