Interface PrincipalFactory

All Superinterfaces:
Serializable
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface PrincipalFactory extends Serializable
Defines operations to create principals.
Since:
4.1.0
  • Field Details

  • Method Details

    • createPrincipal

      default Principal createPrincipal(String id) throws Throwable
      Create principal.
      Parameters:
      id - the id
      Returns:
      the principal
      Throws:
      Throwable - the throwable
    • createPrincipal

      Principal createPrincipal(String id, Map<String,List<Object>> attributes) throws Throwable
      Create principal along with its attributes.
      Parameters:
      id - the id
      attributes - the attributes
      Returns:
      the principal
      Throws:
      Throwable - the throwable
    • withoutAttributes

      default Principal withoutAttributes(Principal principal) throws Throwable
      Principal Without attributes.
      Parameters:
      principal - the principal
      Returns:
      the principal
      Throws:
      Throwable - the throwable