Class AbstractPersistentPageStore

    • Constructor Detail

      • AbstractPersistentPageStore

        protected AbstractPersistentPageStore​(java.lang.String applicationName)
    • Method Detail

      • destroy

        public void destroy()
        Description copied from interface: IPageStore
        Destroy the store.
        Specified by:
        destroy in interface IPageStore
      • getPage

        public IManageablePage getPage​(IPageContext context,
                                       int id)
        Description copied from interface: IPageStore
        Restores a page from storage.
        Specified by:
        getPage in interface IPageStore
        Parameters:
        context - the context of the page
        id - the id of the page.
        Returns:
        the page
      • getPersistedPage

        protected abstract IManageablePage getPersistedPage​(java.lang.String sessionIdentifier,
                                                            int id)
      • removePersistedPage

        protected abstract void removePersistedPage​(java.lang.String sessionIdentifier,
                                                    IManageablePage page)
      • removeAllPages

        public void removeAllPages​(IPageContext context)
        Description copied from interface: IPageStore
        All pages should be removed from storage for the given context.
        Specified by:
        removeAllPages in interface IPageStore
        Parameters:
        context - the context of the pages
      • removeAllPersistedPages

        protected abstract void removeAllPersistedPages​(java.lang.String sessionIdentifier)
      • addPersistedPage

        protected abstract void addPersistedPage​(java.lang.String sessionIdentifier,
                                                 IManageablePage page)
        Add a page.
        Parameters:
        sessionIdentifier - identifier of session
        page - page to add
      • createSessionIdentifier

        protected java.lang.String createSessionIdentifier​(IPageContext context)
        Create an identifier for the given context.

        Default implementation uses IPageContext#getSessionId().

        Parameters:
        context - context
        Returns:
        identifier for the session
      • getSessionIdentifier

        public java.lang.String getSessionIdentifier​(IPageContext context)