Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Panel
bgColor#FFFFFF
borderStyledashed
titleComponent hierarchy

Image Modified

Tipnote
titleMost of this page is shortened javadoc copy-paste. See Wicket javadocs for more information.

...

It is very similar to the base class WebMarkupContainer except that it adds the ability to process <wicket:head> tag. Though it may seem from the name of the class that its subclasses must have their own file with markup, it is not so. To create a component with associated markup file you should subclass Panel.

Anchor
pagePagepage
Page

Page

Page is an abstract base class for pages. As a MarkupContainer subclass, a Page can contain a component hierarchy and markup in some markup language such as HTML. Users of the framework should not attempt to subclass Page directly. Instead they should subclass WebPage.

  • Construction - When a page is constructed, it is automatically added to the current PageMap in the Session. When a Page is added to the Session's PageMap, the PageMap assigns the Page an id. A PageMap is roughly equivalent to a browser window and encapsulates a set of pages accessible through that window . When a popup window is created, a new PageMap is created for the popup.(see Page maps).
    Anchor
    bookmarkable pages
    bookmarkable pages
  • Bookmarkable Pages - Pages can be constructed with any constructor when they are being used in a Wicket session, but if you wish to link to a Page using a URL that is "bookmarkable" (which implies that the URL will not have any session information encoded in it, and that you can call this page directly without having a session first directly from your browser), you need to implement your Page with a no-arg constructor or with a constructor that accepts a PageParameters argument (which wraps any query string parameters for a request). In case the page has both constructors, the constructor with PageParameters will be used. See also Bookmarkable pages and links.
  • Models - Pages, like other Components, can have models (see IModel). A Page can be assigned a model by passing one to the Page's constructor, by overriding initModel() or with an explicit invocation of setModel(). If the model is a CompoundPropertyModel, Components on the Page can use the Page's model implicitly via container inheritance (see also Working with Wicket models).
    Anchor
    page versioning
    page versioning
  • Versioning - Versioning means that a page can remember changes made to it and all versioned child components and later reverse the changes. These changes include setting different object to a component model, changing the state of a component (for example making it disabled), replacing a component with another one or adding/removing a component from page's components hierarchy. By default all Pages support versioning. All versioned pages have its own instance of IPageVersionManager implementation which they use to manage changes.

...