Annotation Interface PageTitle
This defines a static title. For a title that needs to be computed without
creating an instance of the navigation target (for example for the routes of
a breadcrumb trail or a menu), annotate the route with
DynamicPageTitle instead; the value() declared here is then
available to the generator as a key. For a title that depends on the live
state of an already shown view, implement HasDynamicTitle.
- Since:
- 1.0
-
Required Element Summary
Required Elements
-
Element Details
-
value
String valueGets the title that should be used.Empty string will clear any previous page title. In that case the browser will decide what to show as the title, most likely the url.
When the route is also annotated with
DynamicPageTitle, this value is handed to the generator throughPageTitleContext.value()rather than used as the title directly, so a generic generator can use it as a key (for example an i18n message key) to resolve the title.You may dynamically update the title for an already shown view by implementing the
HasDynamicTitle.getPageTitle()method.- Returns:
- a page title string
-