/** * Returns the default coding strategy given a mount path and class. * @param mountPath * @param pageClass * @return {@link BookmarkablePageRequestTargetUrlCodingStrategy} */ public IRequestTargetUrlCodingStrategy getDefaultStrategy(String mountPath, Class<? extends Page> pageClass) { return new BookmarkablePageRequestTargetUrlCodingStrategy(mountPath, pageClass, null); } }
/** * Mounts a bookmarkable page class to the given path. * * @param path * the path to mount the bookmarkable page class on * @param bookmarkablePageClass * the bookmarkable page class to mount */ public final void mountBookmarkablePage(final String path, final Class bookmarkablePageClass) { mount(new BookmarkablePageRequestTargetUrlCodingStrategy(path, bookmarkablePageClass, null)); }
/** * A convenience method that uses a default coding strategy. * * @param path the path on which the page is to be mounted * @param pageClass the class to mount on this mount point using the default strategy */ public void addMountPoint(String path, Class<? extends Page> pageClass) { LOGGER.debug("Adding mount point for path {}", path); addMountPoint(path, new BookmarkablePageRequestTargetUrlCodingStrategy(path, pageClass, null)); }
/** * Mounts a bookmarkable page class to the given pagemap and path. * * @param path * the path to mount the bookmarkable page class on * @param pageMapName * name of the pagemap this mount is for * @param bookmarkablePageClass * the bookmarkable page class to mount */ public final void mountBookmarkablePage(final String path, final String pageMapName, final Class bookmarkablePageClass) { mount(new BookmarkablePageRequestTargetUrlCodingStrategy(path, bookmarkablePageClass, pageMapName)); }
/** * Mounts a bookmarkable page class to the given path. * * @param <T> * type of page * * @param path * the path to mount the bookmarkable page class on * @param bookmarkablePageClass * the bookmarkable page class to mount */ public final <T extends Page> void mountBookmarkablePage(final String path, final Class<T> bookmarkablePageClass) { mount(new BookmarkablePageRequestTargetUrlCodingStrategy(path, bookmarkablePageClass, null)); }
/** * Mounts a bookmarkable page class to the given pagemap and path. * * @param <T> * type of page * * @param path * the path to mount the bookmarkable page class on * @param pageMapName * name of the pagemap this mount is for * @param bookmarkablePageClass * the bookmarkable page class to mount */ public final <T extends Page> void mountBookmarkablePage(final String path, final String pageMapName, final Class<T> bookmarkablePageClass) { mount(new BookmarkablePageRequestTargetUrlCodingStrategy(path, bookmarkablePageClass, pageMapName)); }