Class PackageMapper

  • All Implemented Interfaces:
    IRequestMapper

    public class PackageMapper
    extends AbstractBookmarkableMapper
    A request mapper that mounts all bookmarkable pages in a given package.

    To mount this mapper onto a path use the WebApplication.mountPackage(String, Class), ex:

     MyApp#init() {
    
       super.init();
       mountPackage("/my/path", MyPage.class);
     }
     
    will result in urls like /my/path/MyPage

      Page Class - Render (BookmarkablePageRequestHandler)
      /MyPage
      (will redirect to hybrid alternative if page is not stateless)
    
      Page Instance - Render Hybrid (RenderPageRequestHandler for pages that were created using bookmarkable URLs)
      /MyPage?2
    
      Page Instance - Bookmarkable Listener (BookmarkableListenerRequestHandler)
      /MyPage?2-click-foo-bar-baz
      /MyPage?2-click.1-foo-bar-baz (1 is behavior index)
      (these will redirect to hybrid if page is not stateless)