Interface Revision


public interface Revision
Defines the interface of a CQ page revision.
  • Method Details

    • getVersion

      Version getVersion()
      Returns the underlying version.
      Returns:
      the JCR version
      Since:
      5.5
    • getProperties

      ValueMap getProperties()
      Returns a property map of the page content. If the page has no content an empty property map is returned.
      Returns:
      a value map
      See Also:
    • getProperties

      ValueMap getProperties(String relPath)
      Returns a property map of the address content of the page. Respective content does not exit, null is returned.
      Parameters:
      relPath - relative path to the content
      Returns:
      a value map or null
      Throws:
      IllegalArgumentException - of the given path is not relative.
    • getLabel

      String getLabel()
      Return the version label.
      Returns:
      version label
    • getId

      String getId()
      Return the unique version id.
      Returns:
      version id
    • isDeleted

      boolean isDeleted()
      Return a flag indicating whether this revision belongs to a deleted page.
      Returns:
      true if the associated page is deleted; false otherwise
    • isBaseVersion

      boolean isBaseVersion()
      Indicates if this revision is the current base version of the respective page.
      Returns:
      true if base version.
      Since:
      5.5
    • getName

      String getName()
      Returns the name of the page. this is the last path segment of the page path.
      Returns:
      page name
    • getParentPath

      String getParentPath()
      Return the parent path of the page.
      Returns:
      parent path
    • getTitle

      String getTitle()
      Returns the title of the page or null if none defined. The title is a short form of the page title, usually displayed in the site admin.
      Returns:
      title of the page
    • getDescription

      String getDescription()
      Returns the description of this resource.
      Returns:
      the description of this resource or null if not defined.
    • getPageTitle

      String getPageTitle()
      Returns the page title of the page or null if none defined.
      Returns:
      page title
    • getNavigationTitle

      String getNavigationTitle()
      Returns the navigation title of the page or null if none defined. The navigation title is usually used when drawing navigation links.
      Returns:
      navigation title
    • isHideInNav

      boolean isHideInNav()
      Returns the "hideInNav" flag or false if non defined. The hideInNav flag is usually used to control if a page should be displayed in a navigation.
      Returns:
      hide in navigation flag
    • hasContent

      boolean hasContent()
      Checks if the page has content attached.
      Returns:
      true if the page has content; false otherwise.
    • getVanityUrl

      String getVanityUrl()
      Returns the vanity url.
      Returns:
      The vanity url for this page or null
    • getCreated

      Calendar getCreated()
      Return the creation date.
      Returns:
      creation date
    • getComment

      String getComment()
      Return the optional comment for this revision.
      Returns:
      comment or null
    • getExistingPagePath

      String getExistingPagePath()
      Returns the path of the existing page if exists.
      Returns:
      the path of the existing page.