Class PublicationFollowerHandler

    • Field Detail

      • followedPublication

        protected Publication followedPublication
      • opFollow

        protected java.lang.Boolean opFollow
    • Constructor Detail

      • PublicationFollowerHandler

        public PublicationFollowerHandler()
    • Method Detail

      • init

        protected void init()
        Description copied from class: JcmsFormHandler
        Method to implement if you need to initialize your handler from parameter received, prior to all security validation.

        You must absolutely not perform any action which modify data or site configuration.

        Therefore it is strongly recommend NOT TO implement this method, or use very wisely.

        init in class JcmsFormHandler
      • processAction

        public boolean processAction()
        Description copied from class: JcmsFormHandler
        Method to be implemented to check/validate action to be performed and process them.

        Default implementation is to return false. No need to call super method.

        This method may NOT be invoked at all if security validation are not met.

        You must ensure your handler and JSP can work properly without any code invoked in this method.

        processAction in class JcmsFormHandler
        false if no redirection is needed, true otherwise
        Throws: - IO Exception
      • getFollowLinkDataAttribute

        public java.lang.String getFollowLinkDataAttribute()
      • getFollowLinkDataAttributes

        public DataAttribute getFollowLinkDataAttributes()
      • showFollow

        public boolean showFollow()
      • validateFollow

        protected boolean validateFollow()
      • performFollow

        protected boolean performFollow()
      • setFollowedPublication

        public void setFollowedPublication​(java.lang.String followedPublication)
      • getAvailableFollowedPublication

        public Publication getAvailableFollowedPublication()
      • setOpFollow

        public void setOpFollow​(java.lang.Boolean follow)
        Set whether publication should be followed or unfollowed by logged member.
        follow - true to follow, false to unfollow, default to true if invalid value is specified
      • setFollow

        public void setFollow​(java.lang.String str)
        Set legacy follow parameter. Do not use for new code, this will trigger a redirect by rewriting param follow=... to opFollow=....
        str - value of the legacy "follow" parameter, "true" or "false"