Class PublicLinkManager

    • Method Detail

      • isEnabled

        public boolean isEnabled()
        Returns:
        true if the Public Link feature is enabled.
        Since:
        jcms-10.0.5
      • getPublicLink

        public PublicLink getPublicLink​(java.lang.String accessId)
        Parameters:
        accessId - the access id
        Returns:
        the PublicLink bound to the given accessId
        Since:
        jcms-10.0.5
      • generateAccessId

        public java.lang.String generateAccessId()
        Returns:
        a random access ID.
        Since:
        jcms-10.0.5
      • generateAccessCode

        public java.lang.String generateAccessCode()
        Returns:
        a random access code
        Since:
        jcms-10.0.5
      • getAccessCodeLength

        public int getAccessCodeLength()
        Returns:
        the length of the access code
        Since:
        jcms-10.0.5
      • generateAccessCode

        public java.lang.String generateAccessCode​(int length)
        Parameters:
        length - the number of digit of the code
        Returns:
        a random access code
        Since:
        jcms-10.0.5
      • buildAccessUrl

        public java.lang.String buildAccessUrl​(java.lang.String accessId)
        Parameters:
        accessId - the access ID
        Returns:
        the access URL for the given accessId.
        Since:
        jcms-10.0.5
      • canManagePublicLink

        public boolean canManagePublicLink​(Member mbr)
        Parameters:
        mbr - the member
        Returns:
        true if the given member can manage all public links
        Since:
        jcms-10.0.5
      • canCreatePublicLink

        public boolean canCreatePublicLink​(Member mbr)
        Parameters:
        mbr - the member
        Returns:
        true if the given member can create public links
        Since:
        jcms-10.0.5
      • propertiesChange

        public void propertiesChange​(JProperties properties)
        Description copied from interface: JPropertiesListener
        Invoked after properties have been modified in JCMS and save on disk.

        You cannot alter the value received in parameters.

        Note that properties parameter may be null, a limited set of site properties, or all site properties.

        To check that a property has been modified, reload the "current" property instead using channel.getProperties or channel.getProperty.

        Specified by:
        propertiesChange in interface JPropertiesListener
        Parameters:
        properties - the properties which have been submitted to change
      • processDocumentDeletion

        public void processDocumentDeletion​(FileDocument doc)
        Delete or update PublicLink when a document is deleted
        Parameters:
        doc - the document
        Since:
        jcms-10.0.6