Class PageStorageImpl

java.lang.Object
org.exoplatform.portal.mop.storage.PageStorageImpl
All Implemented Interfaces:
org.exoplatform.portal.mop.storage.PageStorage
Direct Known Subclasses:
CachePageStorage

public class PageStorageImpl extends Object implements org.exoplatform.portal.mop.storage.PageStorage
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected LayoutStorage
     
    protected org.exoplatform.services.listener.ListenerService
     
    protected PageDAO
     
    protected SiteDAO
     
  • Constructor Summary

    Constructors
    Constructor
    Description
    PageStorageImpl(org.exoplatform.services.listener.ListenerService listenerService, LayoutStorage layoutStorage, SiteDAO siteDAO, PageDAO pageDAO)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    broadcastEvent(String eventName, org.exoplatform.portal.mop.page.PageKey pageKey)
     
    protected org.exoplatform.portal.pom.data.PageData
     
    org.exoplatform.portal.mop.page.PageContext
    clone(org.exoplatform.portal.mop.page.PageKey srcPageKey, org.exoplatform.portal.mop.page.PageKey dstPageKey)
     
    boolean
    destroyPage(org.exoplatform.portal.mop.page.PageKey key)
     
    boolean
    destroyPages(org.exoplatform.portal.mop.SiteKey siteKey)
     
    org.exoplatform.portal.mop.QueryResult<org.exoplatform.portal.mop.page.PageContext>
    findPages(int from, int limit, org.exoplatform.portal.mop.SiteType siteType, String siteName, String pageName, String pageTitle)
     
    org.exoplatform.portal.config.model.Page
    getPage(long id)
     
    org.exoplatform.portal.config.model.Page
    getPage(String pageKey)
     
    org.exoplatform.portal.config.model.Page
    getPage(org.exoplatform.portal.mop.page.PageKey key)
     
    org.exoplatform.portal.pom.data.PageData
    getPage(org.exoplatform.portal.pom.data.PageKey key)
     
    protected org.exoplatform.portal.mop.page.PageKey
    getPageKey(long id)
     
    org.exoplatform.portal.mop.page.PageContext
    loadPage(org.exoplatform.portal.mop.page.PageKey key)
     
    List<org.exoplatform.portal.mop.page.PageContext>
    loadPages(org.exoplatform.portal.mop.SiteKey siteKey)
    Load all the pages of a specific site.
    void
    save(org.exoplatform.portal.pom.data.PageData page)
     
    boolean
    savePage(org.exoplatform.portal.mop.page.PageContext page)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • listenerService

      protected org.exoplatform.services.listener.ListenerService listenerService
    • layoutStorage

      protected LayoutStorage layoutStorage
    • siteDAO

      protected SiteDAO siteDAO
    • pageDAO

      protected PageDAO pageDAO
  • Constructor Details

    • PageStorageImpl

      public PageStorageImpl(org.exoplatform.services.listener.ListenerService listenerService, LayoutStorage layoutStorage, SiteDAO siteDAO, PageDAO pageDAO)
  • Method Details

    • getPage

      public org.exoplatform.portal.config.model.Page getPage(String pageKey)
      Specified by:
      getPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • getPage

      public org.exoplatform.portal.config.model.Page getPage(long id)
      Specified by:
      getPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • getPage

      public org.exoplatform.portal.config.model.Page getPage(org.exoplatform.portal.mop.page.PageKey key)
      Specified by:
      getPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • loadPage

      public org.exoplatform.portal.mop.page.PageContext loadPage(org.exoplatform.portal.mop.page.PageKey key)
      Specified by:
      loadPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • loadPages

      public List<org.exoplatform.portal.mop.page.PageContext> loadPages(org.exoplatform.portal.mop.SiteKey siteKey)

      Load all the pages of a specific site. Note that this method can potentially raise performance issues if the number of pages is very large and should be used with cautions. That's the motiviation for not having this method on the PageStorage interface.

      Specified by:
      loadPages in interface org.exoplatform.portal.mop.storage.PageStorage
      Parameters:
      siteKey - the site key
      Returns:
      the list of pages
      Throws:
      org.exoplatform.portal.mop.page.PageServiceException - anything that would prevent the operation to succeed
    • savePage

      public boolean savePage(org.exoplatform.portal.mop.page.PageContext page)
      Specified by:
      savePage in interface org.exoplatform.portal.mop.storage.PageStorage
    • destroyPage

      public boolean destroyPage(org.exoplatform.portal.mop.page.PageKey key)
      Specified by:
      destroyPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • destroyPages

      public boolean destroyPages(org.exoplatform.portal.mop.SiteKey siteKey)
      Specified by:
      destroyPages in interface org.exoplatform.portal.mop.storage.PageStorage
    • clone

      public org.exoplatform.portal.mop.page.PageContext clone(org.exoplatform.portal.mop.page.PageKey srcPageKey, org.exoplatform.portal.mop.page.PageKey dstPageKey)
      Specified by:
      clone in interface org.exoplatform.portal.mop.storage.PageStorage
    • findPages

      public org.exoplatform.portal.mop.QueryResult<org.exoplatform.portal.mop.page.PageContext> findPages(int from, int limit, org.exoplatform.portal.mop.SiteType siteType, String siteName, String pageName, String pageTitle)
      Specified by:
      findPages in interface org.exoplatform.portal.mop.storage.PageStorage
    • save

      public void save(org.exoplatform.portal.pom.data.PageData page)
      Specified by:
      save in interface org.exoplatform.portal.mop.storage.PageStorage
    • getPage

      public org.exoplatform.portal.pom.data.PageData getPage(org.exoplatform.portal.pom.data.PageKey key)
      Specified by:
      getPage in interface org.exoplatform.portal.mop.storage.PageStorage
    • buildPageData

      protected org.exoplatform.portal.pom.data.PageData buildPageData(PageEntity entity)
    • broadcastEvent

      protected void broadcastEvent(String eventName, org.exoplatform.portal.mop.page.PageKey pageKey)
    • getPageKey

      protected org.exoplatform.portal.mop.page.PageKey getPageKey(long id)