Class MemberIndexManager


  • public class MemberIndexManager
    extends java.lang.Object
    • Method Detail

      • getPublicationSet

        public java.util.Set<Publication> getPublicationSet​(Member mbr)
        Returns the publication set associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the publication set associated to the given member.
        Since:
        jcms-6.0.0
      • addPublication

        public boolean addPublication​(Member mbr,
                                      Publication pub)
        Adds the given publication to the publication set of the given member.
        Parameters:
        mbr - member with which this publication must be added.
        pub - publication to be added to this set.
        Returns:
        true if this set did not already contain the specified element.
        Since:
        jcms-6.0.0
      • removePublication

        public boolean removePublication​(Member mbr,
                                         Publication pub)
        Removes the given publication for the given member.
        Parameters:
        mbr - member with which this publication must be removed.
        pub - publication to be removed from this set, if present.
        Returns:
        true if the set contained the specified element.
        Since:
        jcms-6.0.0
      • getContentSet

        public java.util.Set<Content> getContentSet​(Member mbr)
        Returns the content set associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the content set associated to the given member.
        Since:
        jcms-6.0.0
      • addContent

        public boolean addContent​(Member mbr,
                                  Content content)
        Adds the given content to the content set of the given member.
        Parameters:
        mbr - ember with which this content must be added.
        content - content to be added to this set.
        Returns:
        true if this set did not already contain the specified element.
        Since:
        jcms-6.0.0
      • removeContent

        public boolean removeContent​(Member mbr,
                                     Content content)
        Removes the given content for the given member.
        Parameters:
        mbr - member with which this content must be removed.
        content - content to be removed from this set, if present.
        Returns:
        true if the set contained the specified element.
        Since:
        jcms-6.0.0
      • getWorkspaceSet

        public java.util.Set<Workspace> getWorkspaceSet​(Member mbr)
        Returns the workspace set associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the workspace set associated to the given member.
        Since:
        jcms-6.0.0
      • setWorkspaceSet

        public void setWorkspaceSet​(Member mbr,
                                    java.util.Set<Workspace> set)
        Sets the workspace set associated to the given member.
        Parameters:
        mbr - the member
        set - the workspace set to associate to the given member. MUST NOT be null.
        Since:
        jcms-7.0.2
      • clearWorkspaceSet

        public void clearWorkspaceSet​(Member mbr)
        Clears the workspace set associated to the given member.
        Parameters:
        mbr - the member
        Since:
        jcms-6.0.0
      • addWorkspace

        public boolean addWorkspace​(Member mbr,
                                    Workspace workspace)
        Adds the given workspace to the workspace set of the given member.
        Parameters:
        mbr - ember with which this workspace must be added.
        workspace - workspace to be added to this set.
        Returns:
        true if this set did not already contain the specified element.
        Since:
        jcms-6.0.0
      • removeWorkspace

        public boolean removeWorkspace​(Member mbr,
                                       Workspace workspace)
        Removes the given workspace for the given member.
        Parameters:
        mbr - member with which this workspace must be removed.
        workspace - workspace to be removed from this set, if present.
        Returns:
        true if the set contained the specified element.
        Since:
        jcms-6.0.0
      • getDelegateSet

        public java.util.Set<Member> getDelegateSet​(Member mbr)
        Returns the delegate set associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the delegate set associated to the given member.
        Since:
        jcms-6.0.0
      • addDelegate

        public boolean addDelegate​(Member mbr,
                                   Member delegate)
        Adds the given delegate to the delegate set of the given member.
        Parameters:
        mbr - member with which this delegate must be added.
        delegate - delegate to be added to this set.
        Returns:
        true if this set did not already contain the specified element.
        Since:
        jcms-6.0.0
      • removeDelegate

        public boolean removeDelegate​(Member mbr,
                                      Member delegate)
        Removes the given delegate for the given member.
        Parameters:
        mbr - member with which this workspace must be removed.
        delegate - delegate to be removed from this set, if present.
        Returns:
        true if the set contained the specified element.
        Since:
        jcms-6.0.0
      • getCanPublishContentMap

        public java.util.Map<Workspace,​java.lang.Boolean> getCanPublishContentMap​(Member mbr)
        Returns the publish rights map associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the publish rights map associated to the given member.
        Since:
        jcms-6.0.0
      • clearCanPublishContentMap

        public void clearCanPublishContentMap​(Member mbr)
        Clears the publish rights map associated to the given member.
        Parameters:
        mbr - the member
        Since:
        jcms-6.0.0
      • putCanPublishContent

        public void putCanPublishContent​(Member mbr,
                                         Workspace workspace,
                                         boolean bool)
        Adds the given entry to the publish rights map of the given member.
        Parameters:
        mbr - ember with which this workspace must be added.
        workspace - workspace to be added to this set.
        bool - true if member can publish in specified workspace, false if member cannot
        Since:
        jcms-6.0.0
      • removeCanPublishContent

        public void removeCanPublishContent​(Member mbr,
                                            Workspace workspace)
        Removes the given entry for the given member.
        Parameters:
        mbr - member with which this workspace must be removed.
        workspace - workspace to be removed from this set, if present.
        Since:
        jcms-6.0.0
      • getCanUpdateDeleteContentMap

        public java.util.Map<Workspace,​java.lang.Boolean> getCanUpdateDeleteContentMap​(Member mbr)
        Returns the updateDelete map associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the workspace set associated to the given member.
        Since:
        jcms-6.0.0
      • clearCanUpdateDeleteContentMap

        public void clearCanUpdateDeleteContentMap​(Member mbr)
        Clears the updateDelete map associated to the given member.
        Parameters:
        mbr - the member
        Since:
        jcms-6.0.0
      • putCanUpdateDeleteContent

        public void putCanUpdateDeleteContent​(Member mbr,
                                              Workspace workspace,
                                              boolean bool)
        Adds the given entry to the workspace set of the given member.
        Parameters:
        mbr - ember with which this workspace must be added.
        workspace - workspace to be added to this set.
        bool - true if member can update or delete content in the specified workspace, false if member cannot
        Since:
        jcms-6.0.0
      • removeCanUpdateDeleteContent

        public void removeCanUpdateDeleteContent​(Member mbr,
                                                 Workspace workspace)
        Removes the given entry for the given member.
        Parameters:
        mbr - member with which this workspace must be removed.
        workspace - workspace to be removed from this set, if present.
        Since:
        jcms-6.0.0
      • getIsWorker

        public java.lang.Boolean getIsWorker​(Member mbr,
                                             Workspace workspace)
        Returns the isWorker status for the specified member.
        Parameters:
        mbr - the member, must not be null
        workspace - an optional workspace in which to check the isWorker status (if null isWorker status relates to all workspace)
        Returns:
        isWorker status for the given member (in the specified workspace if any), may return null if computation was never performed.
        Since:
        jcms-9.0.5 - JCMS-5683
      • putIsWorker

        public void putIsWorker​(Member mbr,
                                Workspace workspace,
                                boolean isWorker)
        Add the member isWorker status.
        Parameters:
        mbr - Member for which isWorker status was computed, must not be null
        workspace - an optional workspace for which isWorker status was computed (if null isWorker status relates to all workspace)
        isWorker - true if member was computed as a worker, false otherwise
        Since:
        jcms-9.0.5 - JCMS-5683
      • clearIsWorker

        public void clearIsWorker​(Member mbr)
        Clears the isWorker status cache.
        Parameters:
        mbr - an optional mbr for which cache should be cleared, if null cache is cleared for ALL members.
        Since:
        jcms-9.0.5 - JCMS-5683
      • isExplicitMemberManager

        public boolean isExplicitMemberManager​(Member mbr)
        Check if the specified member was specified at least once as declared manager of a JStore Member.

        Warning: this does NOT check if the specified member manages any DBMember, use isExplicitDBMemberManager(Member)

        Parameters:
        mbr - the member to check
        Returns:
        true if member is manager of at least once JStore Member, false if member is not a manager of any JStore member
        Since:
        jcms-10.0.7 / JCMS-9477
        See Also:
        GroupIndexManager.isExplicitGroupManager(Member)
      • isExplicitDBMemberManager

        public boolean isExplicitDBMemberManager​(Member mbr)
        Check if the specified member was specified at least once as declared manager of a DBMember.

        Warning: this does NOT check if the specified member manages any JStore Member, use isExplicitMemberManager(Member)

        Parameters:
        mbr - the member to check
        Returns:
        true if member is manager of at least once DB Member, false if member is not a manager of any DB member
        Since:
        jcms-10.0.7 / JCMS-9477
        See Also:
        GroupIndexManager.isExplicitGroupManager(Member)
      • getManagedMemberSet

        public java.util.Set<java.lang.String> getManagedMemberSet​(Member mbr)
        Returns the id of managed member set associated to the given member.
        Parameters:
        mbr - the member
        Returns:
        the managed member set associated to the given member.
        Since:
        jcms-10.0.2
      • setManagedMemberSet

        public void setManagedMemberSet​(Member mbr,
                                        java.util.Set<java.lang.String> set)
        Sets the id of managed member set associated to the given member.
        Parameters:
        mbr - the member
        set - the managed member set to associate to the given member. MUST NOT be null.
        Since:
        jcms-10.0.2
      • clearManagedMemberSet

        public void clearManagedMemberSet​(Member mbr)
        Clears the managed member set associated to the given member.
        Parameters:
        mbr - the member
        Since:
        jcms-10.0.2
      • clearManagedMemberIndex

        public void clearManagedMemberIndex()