Class MockPersonService

  • All Implemented Interfaces:
    Serializable, org.alfresco.service.cmr.security.PersonService

    public class MockPersonService
    extends Object
    implements org.alfresco.service.cmr.security.PersonService, Serializable
    See Also:
    Serialized Form
    • Constructor Detail

      • MockPersonService

        public MockPersonService()
    • Method Detail

      • getPerson

        public org.alfresco.service.cmr.repository.NodeRef getPerson​(String userName)
        Specified by:
        getPerson in interface org.alfresco.service.cmr.security.PersonService
      • getPersonOrNull

        public org.alfresco.service.cmr.repository.NodeRef getPersonOrNull​(String userName)
        Specified by:
        getPersonOrNull in interface org.alfresco.service.cmr.security.PersonService
      • getPerson

        public org.alfresco.service.cmr.repository.NodeRef getPerson​(String userName,
                                                                     boolean autoCreateHomeFolderAndMissingPersonIfAllowed)
        Specified by:
        getPerson in interface org.alfresco.service.cmr.security.PersonService
      • getPerson

        public org.alfresco.service.cmr.security.PersonService.PersonInfo getPerson​(org.alfresco.service.cmr.repository.NodeRef personRef)
                                                                             throws org.alfresco.service.cmr.security.NoSuchPersonException
        Specified by:
        getPerson in interface org.alfresco.service.cmr.security.PersonService
        Throws:
        org.alfresco.service.cmr.security.NoSuchPersonException
      • personExists

        public boolean personExists​(String userName)
        Specified by:
        personExists in interface org.alfresco.service.cmr.security.PersonService
      • createMissingPeople

        public boolean createMissingPeople()
        Specified by:
        createMissingPeople in interface org.alfresco.service.cmr.security.PersonService
      • setCreateMissingPeople

        public void setCreateMissingPeople​(boolean createMissing)
        Specified by:
        setCreateMissingPeople in interface org.alfresco.service.cmr.security.PersonService
      • getMutableProperties

        public Set<org.alfresco.service.namespace.QName> getMutableProperties()
        Specified by:
        getMutableProperties in interface org.alfresco.service.cmr.security.PersonService
      • setPersonProperties

        public void setPersonProperties​(String userName,
                                        Map<org.alfresco.service.namespace.QName,​Serializable> properties)
        Specified by:
        setPersonProperties in interface org.alfresco.service.cmr.security.PersonService
      • setPersonProperties

        public void setPersonProperties​(String userName,
                                        Map<org.alfresco.service.namespace.QName,​Serializable> properties,
                                        boolean autoCreateHomeFolder)
        Specified by:
        setPersonProperties in interface org.alfresco.service.cmr.security.PersonService
      • isMutable

        public boolean isMutable()
        Specified by:
        isMutable in interface org.alfresco.service.cmr.security.PersonService
      • createPerson

        public org.alfresco.service.cmr.repository.NodeRef createPerson​(Map<org.alfresco.service.namespace.QName,​Serializable> properties)
        Specified by:
        createPerson in interface org.alfresco.service.cmr.security.PersonService
      • createPerson

        public org.alfresco.service.cmr.repository.NodeRef createPerson​(Map<org.alfresco.service.namespace.QName,​Serializable> properties,
                                                                        Set<String> zones)
        Specified by:
        createPerson in interface org.alfresco.service.cmr.security.PersonService
      • notifyPerson

        public void notifyPerson​(String userName,
                                 String password)
        Specified by:
        notifyPerson in interface org.alfresco.service.cmr.security.PersonService
      • deletePerson

        public void deletePerson​(String userName)
        Specified by:
        deletePerson in interface org.alfresco.service.cmr.security.PersonService
      • deletePerson

        public void deletePerson​(org.alfresco.service.cmr.repository.NodeRef personRef)
        Specified by:
        deletePerson in interface org.alfresco.service.cmr.security.PersonService
      • deletePerson

        public void deletePerson​(org.alfresco.service.cmr.repository.NodeRef personRef,
                                 boolean deleteAuthentication)
        Specified by:
        deletePerson in interface org.alfresco.service.cmr.security.PersonService
      • getAllPeople

        public Set<org.alfresco.service.cmr.repository.NodeRef> getAllPeople()
        Specified by:
        getAllPeople in interface org.alfresco.service.cmr.security.PersonService
      • getPeople

        public org.alfresco.query.PagingResults<org.alfresco.service.cmr.security.PersonService.PersonInfo> getPeople​(String pattern,
                                                                                                                      List<org.alfresco.service.namespace.QName> filterProps,
                                                                                                                      List<org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​Boolean>> sortProps,
                                                                                                                      org.alfresco.query.PagingRequest pagingRequest)
        Specified by:
        getPeople in interface org.alfresco.service.cmr.security.PersonService
      • getPeople

        public org.alfresco.query.PagingResults<org.alfresco.service.cmr.security.PersonService.PersonInfo> getPeople​(List<org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​String>> stringPropFilters,
                                                                                                                      boolean filterIgnoreCase,
                                                                                                                      List<org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​Boolean>> sortProps,
                                                                                                                      org.alfresco.query.PagingRequest pagingRequest)
        Specified by:
        getPeople in interface org.alfresco.service.cmr.security.PersonService
      • getPeople

        public org.alfresco.query.PagingResults<org.alfresco.service.cmr.security.PersonService.PersonInfo> getPeople​(String pattern,
                                                                                                                      List<org.alfresco.service.namespace.QName> filterStringProps,
                                                                                                                      Set<org.alfresco.service.namespace.QName> inclusiveAspects,
                                                                                                                      Set<org.alfresco.service.namespace.QName> exclusiveAspects,
                                                                                                                      boolean includeAdministraotrs,
                                                                                                                      List<org.alfresco.util.Pair<org.alfresco.service.namespace.QName,​Boolean>> sortProps,
                                                                                                                      org.alfresco.query.PagingRequest pagingRequest)
        Specified by:
        getPeople in interface org.alfresco.service.cmr.security.PersonService
      • getPeopleFilteredByProperty

        public Set<org.alfresco.service.cmr.repository.NodeRef> getPeopleFilteredByProperty​(org.alfresco.service.namespace.QName propertyKey,
                                                                                            Serializable propertyValue,
                                                                                            int count)
        Specified by:
        getPeopleFilteredByProperty in interface org.alfresco.service.cmr.security.PersonService
      • getPeopleContainer

        public org.alfresco.service.cmr.repository.NodeRef getPeopleContainer()
        Specified by:
        getPeopleContainer in interface org.alfresco.service.cmr.security.PersonService
      • getUserNamesAreCaseSensitive

        public boolean getUserNamesAreCaseSensitive()
        Specified by:
        getUserNamesAreCaseSensitive in interface org.alfresco.service.cmr.security.PersonService
      • getUserIdentifier

        public String getUserIdentifier​(String caseSensitiveUserName)
        Specified by:
        getUserIdentifier in interface org.alfresco.service.cmr.security.PersonService
      • countPeople

        public int countPeople()
        Specified by:
        countPeople in interface org.alfresco.service.cmr.security.PersonService
      • isEnabled

        public boolean isEnabled​(String userName)
        Specified by:
        isEnabled in interface org.alfresco.service.cmr.security.PersonService