Interface PrincipalElectionStrategy

All Superinterfaces:
org.springframework.core.Ordered, Serializable

public interface PrincipalElectionStrategy extends Serializable, org.springframework.core.Ordered
This is PrincipalElectionStrategy that attempts to nominate a given principal as the primary principal object amongst many authentication events.
Since:
4.2.0
  • Field Details

  • Method Details

    • nominate

      Principal nominate(Collection<Authentication> authentications, Map<String,List<Object>> principalAttributes) throws Throwable
      Elect the principal.
      Parameters:
      authentications - the authentications
      principalAttributes - the principal attributes
      Returns:
      the principal
      Throws:
      Throwable
    • nominate

      Principal nominate(List<Principal> principals, Map<String,List<Object>> attributes) throws Throwable
      Nominate principal.
      Parameters:
      principals - the principals
      attributes - the attributes
      Returns:
      the principal
      Throws:
      Throwable
    • getOrder

      default int getOrder()
      Specified by:
      getOrder in interface org.springframework.core.Ordered
    • getAttributeMerger

      AttributeMerger getAttributeMerger()
      Gets attribute merger.
      Returns:
      the attribute merger