Klasse MockUserManager

java.lang.Object
org.apache.sling.testing.mock.jcr.MockUserManager
Alle implementierten Schnittstellen:
org.apache.jackrabbit.api.security.user.UserManager

public class MockUserManager extends Object implements org.apache.jackrabbit.api.security.user.UserManager
Mock UserManager implementation.
  • Felddetails

    • session

      protected javax.jcr.Session session
    • authorizables

      protected Map<String,org.apache.jackrabbit.api.security.user.Authorizable> authorizables
  • Konstruktordetails

    • MockUserManager

      @Deprecated public MockUserManager()
      Veraltet.
    • MockUserManager

      public MockUserManager(javax.jcr.Session session)
      Parameter:
      session - the jcr session where the people state is stored
  • Methodendetails

    • isAutoSave

      public boolean isAutoSave()
      Angegeben von:
      isAutoSave in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
    • autoSave

      public void autoSave(boolean autoSave) throws javax.jcr.RepositoryException
      Angegeben von:
      autoSave in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createGroup

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.Group createGroup(@NotNull @NotNull String groupID) throws javax.jcr.RepositoryException
      Angegeben von:
      createGroup in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createGroup

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.Group createGroup(@NotNull @NotNull Principal principal) throws javax.jcr.RepositoryException
      Angegeben von:
      createGroup in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createGroup

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.Group createGroup(@NotNull @NotNull Principal principal, @Nullable @Nullable String intermediatePath) throws javax.jcr.RepositoryException
      Angegeben von:
      createGroup in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createGroup

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.Group createGroup(@NotNull @NotNull String groupID, @NotNull @NotNull Principal principal, @Nullable @Nullable String intermediatePath) throws javax.jcr.RepositoryException
      Angegeben von:
      createGroup in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • toPrincipalName

      @Nullable protected @Nullable String toPrincipalName(@Nullable @Nullable String id, @Nullable @Nullable Principal principal)
      Calculates the principal name, preferring the supplied id or fallback to the Principal.getName() value
      Parameter:
      id - the user or group id
      principal - the principal
      Gibt zurück:
      the principal name
    • ensureAuthorizablePathExists

      @Deprecated(forRemoval=true, since="1.4.0") protected javax.jcr.Node ensureAuthorizablePathExists(@Nullable @Nullable String intermediatePath, @NotNull @NotNull String principalName, boolean isGroup) throws javax.jcr.RepositoryException
      Veraltet, zur Entfernung: Dieses API-Element wird in einer zukünftigen Version entfernt.
      Creates the user/group home folder if they don't exist yet
      Parameter:
      intermediatePath - the parent path
      principalName - Principal name
      isGroup - Is group
      Gibt zurück:
      Existing or created node
      Löst aus:
      javax.jcr.RepositoryException - Repository exception
    • ensureAuthorizablePathExists

      protected javax.jcr.Node ensureAuthorizablePathExists(@NotNull @NotNull String intermediatePath, @NotNull @NotNull String principalName, @NotNull @NotNull String authorizableNodeType) throws javax.jcr.RepositoryException
      Creates the user/group home folder if they don't exist yet
      Parameter:
      intermediatePath - the parent path
      principalName - Principal name
      authorizableNodeType - the node type for the user or group node
      Gibt zurück:
      Existing or created node
      Löst aus:
      javax.jcr.RepositoryException - Repository exception
    • createSystemUser

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.User createSystemUser(@NotNull @NotNull String userID, @Nullable @Nullable String intermediatePath) throws javax.jcr.RepositoryException
      Angegeben von:
      createSystemUser in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createUser

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.User createUser(@NotNull @NotNull String userID, @Nullable @Nullable String password) throws javax.jcr.RepositoryException
      Angegeben von:
      createUser in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • createUser

      @NotNull public @NotNull org.apache.jackrabbit.api.security.user.User createUser(@NotNull @NotNull String userID, @Nullable @Nullable String password, @NotNull @NotNull Principal principal, @Nullable @Nullable String intermediatePath) throws javax.jcr.RepositoryException
      Angegeben von:
      createUser in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • findAuthorizables

      @NotNull public @NotNull Iterator<org.apache.jackrabbit.api.security.user.Authorizable> findAuthorizables(@NotNull @NotNull org.apache.jackrabbit.api.security.user.Query query) throws javax.jcr.RepositoryException
      Angegeben von:
      findAuthorizables in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • findAuthorizables

      @NotNull public @NotNull Iterator<org.apache.jackrabbit.api.security.user.Authorizable> findAuthorizables(@NotNull @NotNull String relPath, @Nullable @Nullable String value) throws javax.jcr.RepositoryException
      Angegeben von:
      findAuthorizables in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • findAuthorizables

      @NotNull public @NotNull Iterator<org.apache.jackrabbit.api.security.user.Authorizable> findAuthorizables(@NotNull @NotNull String relPath, @Nullable @Nullable String value, int searchType) throws javax.jcr.RepositoryException
      Angegeben von:
      findAuthorizables in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • getAuthorizable

      @Nullable public @Nullable org.apache.jackrabbit.api.security.user.Authorizable getAuthorizable(@NotNull @NotNull String id) throws javax.jcr.RepositoryException
      Angegeben von:
      getAuthorizable in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • getAuthorizable

      @Nullable public @Nullable org.apache.jackrabbit.api.security.user.Authorizable getAuthorizable(@NotNull @NotNull Principal principal) throws javax.jcr.RepositoryException
      Angegeben von:
      getAuthorizable in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • getAuthorizable

      @Nullable public <T extends org.apache.jackrabbit.api.security.user.Authorizable> T getAuthorizable(@NotNull @NotNull String id, @NotNull @NotNull Class<T> authorizableClass) throws javax.jcr.RepositoryException
      Angegeben von:
      getAuthorizable in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException
    • getAuthorizableByPath

      @Nullable public @Nullable org.apache.jackrabbit.api.security.user.Authorizable getAuthorizableByPath(@NotNull @NotNull String path) throws javax.jcr.RepositoryException
      Angegeben von:
      getAuthorizableByPath in Schnittstelle org.apache.jackrabbit.api.security.user.UserManager
      Löst aus:
      javax.jcr.RepositoryException