Interface PageVersion

    • Method Detail

      • getId

        @ReferField
        int getId()
        Description copied from interface: Wrapper
        Returns the ID of the wrapped object.
        Specified by:
        getId in interface Wrapper
        Returns:
        the ID of the wrapped object.
      • setTitle

        void setTitle​(String value)
        Sets the page title.
        Parameters:
        value - the page title
      • getShortTitle

        String getShortTitle()
        Returns the short title.
        Returns:
        short title.
      • setShortTitle

        void setShortTitle​(String value)
        Sets the short title.
        Parameters:
        value - the short title
      • getHtmlTitle

        String getHtmlTitle()
        Returns the HTML title. This is a title string which is suitable for use in the HTML TITLE tag. If no HTML title has been explicietly specified for the page then an empty string is returned.
        Returns:
        HTML title, or "" if none has been specified.
      • getFriendlyURLTitle

        String getFriendlyURLTitle()
        Returns friendly URL title.
        Returns:
        friendly URL title.
      • getAlternativeURLPath

        String getAlternativeURLPath()
        Returns the alternative URL path. Links only uses this alternative URL path if friendly URL functionality is turned on.
        Returns:
        alternative URL path.
      • setAlternativeUrlPath

        void setAlternativeUrlPath​(String alternativeUrlPath)
        Sets the alternative url path
        Parameters:
        alternativeUrlPath -
      • setHtmlTitle

        void setHtmlTitle​(String value)
        Sets the page html title.
        Parameters:
        value - the page html title
      • setUrlTitle

        void setUrlTitle​(String value)
        Sets the page url title to override the default friendly URL for this page version.
        Parameters:
        value - the page url title
      • getUrlTitle

        @Field
        String getUrlTitle()
        Returns page url title; this is used to override the default friendly URL for this page version.
        Returns:
        value the page url title
      • getIncludeInSearchEngine

        boolean getIncludeInSearchEngine()
        Returns if this page version is included to be found by a search engine.
        Returns:
        is included in search engine
      • setIncludeInSearchEngine

        void setIncludeInSearchEngine​(boolean value)
        Sets if this page version is included to be found by a search engine.
        Parameters:
        value - set included in search engine
      • getResourceInstance

        ResourceInstance getResourceInstance()
        Return database id (if this is a database id) or 0.
        Returns:
        database id (if this is a database id) or 0.
      • getResourceEntity

        @Document
        ResourceEntity getResourceEntity()
        Returns database page or null if it is not a database page.
        Returns:
        database page or null if it is not a database page.
      • getSubPages

        Page[] getSubPages()
        Returns the sub pages of this version. The order in which these sub pages are returned reflects the order configured in WebManager. Only these sub pages are returned which are not marked invisible for navigation in WebManager.
        Returns:
        sub pages.
        See Also:
        getSubPagesWithCurrent(), Page.getSubPages()
      • getSubPagesWithCurrent

        Page[] getSubPagesWithCurrent()
        Returns array of sub pages, which have a current version.
        Returns:
        array of sub pages, which have a current version.
        See Also:
        getSubPages(), Page.getSubPages()
      • setMetaKeywords

        void setMetaKeywords​(String keywords)
        Sets the meta keywords for this page version.
        Parameters:
        keywords - the meta keywords value
      • getMetaKeywords

        String getMetaKeywords()
        Gets the meta keywords for this page version.
        Returns:
        The meta keywords
      • getMetaTags

        MetaTag[] getMetaTags()
        Return the meta tags for this page version.
        Returns:
        array of MetaTag.
      • getPreviewJavascript

        String getPreviewJavascript​(boolean containsContentElements)
        Used to generate javascript for previewing this page (WebManager needs this to function properly).
        Parameters:
        containsContentElements - if true, the page/frame contains the WebManager content.
        Returns:
        javascript
      • getPreviewForms

        String getPreviewForms​(boolean containsContentElements)
        Returns the forms necessary for WebManager to function properly in the preview mode.
        Parameters:
        containsContentElements - if true, the page/frame contains the WebManager content.
        Returns:
        the forms necessary for WebManager to function properly in the preview mode.
      • getPreviewTopBody

        String getPreviewTopBody​(boolean containsContentElements)
        Return the top of the body necessary for WebManager to function properly in the layout mode.
        Parameters:
        containsContentElements - if true, the page/frame contains the WebManager content.
        Returns:
        the top of the body necessary for WebManager to function properly in the layout mode.
      • isAuthorized

        boolean isAuthorized​(String permission)
        Return true if the user is authorized to preview this page.
        Returns:
        true if the user is authorized for this page.
      • isAuthorizedToPreview

        boolean isAuthorizedToPreview()
        Returns true if the current user is authorizaed to preview this PageVersion object.
        Returns:
        true if the current user is authorizaed to preview this PageVersion object
      • getMetaDescription

        @Field(boost=0.6)
        String getMetaDescription()
        Returns the meta description.
        Returns:
        meta description
        Since:
        10.13
      • setMetaDescription

        void setMetaDescription​(String value)
        Sets the meta description.
        Parameters:
        value - the meta description
        Since:
        10.13
      • getHasRedirect

        boolean getHasRedirect()
        Returns if this page has a redirect.
        Returns:
        true if the page has a redirect, false otherwise
      • getSeeEvent

        @Deprecated
        String getSeeEvent()
        Deprecated.
        Returns the see event.
        Returns:
        see event.
      • setRedirect

        void setRedirect​(int statusCode,
                         RelatedLink relatedLink)
        Sets a redirect for this page version. Any redirect already assigned is removed.
        Parameters:
        statusCode - Redirect status code to set. Must be 301 or 302, or else an IllegalArgumentException is thrown.
        relatedLink - The related link to point the redirect to
      • getInlineModeTag

        String getInlineModeTag()
        Returns the inline mode tag.
        Returns:
        constant inline mode tag: "<!-- Content -->".
      • getExcludeScriptsTag

        String getExcludeScriptsTag()
        Returns exclude scripts tag for use in frames.
        Returns:
        constant exclude script tag: "<!-- ExcludeScripts -->".
      • getBlocks

        @Deprecated
        Page[] getBlocks​(BlockLabel[] labels)
        Deprecated.
        Returns the page objects for the given page section labels. Deprecated, use getBlocks(BlockLabel[] labels) from Page object
        Parameters:
        labels - Array of page section labels
        Returns:
        Page objects
      • getPersonalizationItem

        PersonalizationItem getPersonalizationItem()
        Returns the personalization assigned to this page version or null if none is assigned.
        Returns:
        the personalization assigned to this page version or null if none is assigned
      • getStyleSheets

        StyleSheet[] getStyleSheets()
        Returns stylesheets for this page.
        Returns:
        stylesheets for this page.
      • setLastModifiedDate

        void setLastModifiedDate​(Date value)
        Sets the last modified date of the page version.
        Parameters:
        value - last modified date of the page version.
      • getLastModifiedUsername

        String getLastModifiedUsername()
        Returns last modified user name of the page version.
        Returns:
        last modified user name of the page version.
      • setLastModifiedUser

        void setLastModifiedUser​(User user)
        Sets the last modified user of the page version.
        Parameters:
        user - last modified user of the page version.
      • isSecure

        boolean isSecure()
        Returns whether this page version is accessed over a secure connection.
        Returns:
        true if the page is accessed over a secure connection, false otherwise.
      • getXslUrl

        String getXslUrl()
        Returns the URL to the page xsl.
        Returns:
        URL to the page xsl.
      • getXslFoUrl

        String getXslFoUrl()
        Returns URL to the page xsl.
        Returns:
        URL to the page xsl.
      • getLabels

        @Deprecated
        String[] getLabels()
        Deprecated.
        This method is deprecated, use getPageLabels() instead.
        Returns the page labels.
        Returns:
        page labels.
      • getPageLabels

        PageLabel[] getPageLabels()
        Returns the page labels.
        Returns:
        page labels.
      • setPageLabels

        void setPageLabels​(PageLabel[] pageLabels)
        Sets the page labels for this page version. The provides array of page labels will overrule all page labels currently set on this page version.
        Parameters:
        pageLabels - The page labels to set.
      • addPageLabel

        void addPageLabel​(PageLabel pageLabel)
        Appends a page label to this page version. If the page label is already assigned to this page version, this method does nothing.
        Parameters:
        pageLabel - The page label to append to this page version.
      • removePageLabel

        void removePageLabel​(PageLabel pageLabel)
        Removes the specified page label from this page version. This method does nothing if this page label is not assigned to this page version.
        Parameters:
        pageLabel - The page label to remove from this page version.
      • getMediaItemPageVersion

        MediaItemPageVersion getMediaItemPageVersion()
        Returns the media item page version associated with this page version.
        Returns:
        the media item page version associated with this page version
        Since:
        10.32.0
      • getExpire

        int getExpire()
        Returns the page expire.
        Returns:
        page expire.
      • getBlockConfigId

        int getBlockConfigId()
        Returns id of the page's page section config. Note that the names "block" and "page section" both refer to the same concept.
        Returns:
        id of the page's page section config.
      • synchronizeMediaItemPageVersion

        void synchronizeMediaItemPageVersion()
        Checks if a media item page version is connected to the page version and if so it synchronizes it with the page version.
      • processHttpServletRequest

        void processHttpServletRequest​(List<NameValuePair> dynamicAttributes)
        Processes the HttpServletRequest of the page submission for this page version.
        Parameters:
        dynamicAttributes - List of NameValuePair objects based on the qs parameter
      • getNoReadAccessText

        String getNoReadAccessText()
        Returns text for a user indicating he has no read access for this page version.
        Returns:
        text for a user indicating he has no read access for this page version
      • getPageMetaData

        @Document(inheritLanguage=true)
        PageMetaData[] getPageMetaData()
        Returns the meta data objects assigned to this page version.
        Returns:
        the meta data objects assigned to this page version
      • synchronizePageMetaData

        void synchronizePageMetaData()
        Makes sure each page has exactly one object for each available page meta data component.
      • getPageMetaDataFBOMap

        Map<String,​PageMetaData> getPageMetaDataFBOMap()
        Constructs and returns an FBO map for page meta data.
        Returns:
        map of PageMetaData form backing objects, cataloged by their UUID.
      • getSEOPriority

        SEOPriority getSEOPriority()
        Returns the SEO priority used for generating the Google sitemaps xml. This property determines the value of the 'priority' attribute in the URL section for this article. For more information, see https://www.sitemaps.org/protocol.html#prioritydef
        Returns:
        the SEO priority used for generating the Google sitemaps xml
      • setSEOPriority

        void setSEOPriority​(SEOPriority priority)
        Sets the SEO priority used for generating the Google sitemaps xml. This property determines the value of the 'priority' attribute in the URL section for this article. For more information, see https://www.sitemaps.org/protocol.html#prioritydef
        Parameters:
        priority - the SEO priority to use for generating the Google sitemaps xml
      • getSEOUpdateFrequency

        SEOUpdateFrequency getSEOUpdateFrequency()
        Returns the SEO update frequency used for generating the Google sitemaps xml. This property determines the value of the 'changefreq' attribute in the URL section for this article. For more information, see https://www.sitemaps.org/protocol.html#changefreqdef
        Returns:
        The SEO update frequency used for generating the Google sitemaps xml
      • setSEOUpdateFrequency

        void setSEOUpdateFrequency​(SEOUpdateFrequency frequency)
        Sets the SEO update frequency used for generating the Google sitemaps xml. This property determines the value of the 'changefreq' attribute in the URL section for this article. For more information, see https://www.sitemaps.org/protocol.html#changefreqdef
        Parameters:
        frequency - The SEO update frequency to use for generating the Google sitemaps xml
      • setTitleVolatile

        void setTitleVolatile​(String title)
        Sets the title, but does not save to the JCR.
        Parameters:
        title - the title to set
      • setElementsVolatile

        void setElementsVolatile​(ElementHolder elementHolder)
        Sets the elements, but does not save to the JCR.
        Parameters:
        elementHolder - the element holder to set
      • setAttachedLeadImage

        void setAttachedLeadImage​(org.springframework.web.multipart.MultipartFile imageMultiPartFile)
        Sets the lead image of this page version as an upload file associated with this particular page version. The image cannot be reused by other page versions. To reuse lead images, assign it from the content repository and use ContentItemVersion.setLeadImageMediaItem(nl.gx.webmanager.cms.mediarepository.MediaItem) instead. If null is passed, any existing upload lead image will be removed.
        Parameters:
        imageMultiPartFile - The multipart file holding the image to assign as lead image to this page version
        Since:
        10.32.0