Interface UserEmailResolver

All Known Implementing Classes:
DefaultUserEmailResolver

public interface UserEmailResolver
Base interface for user email resolver. It allows to resolve email for provided user.

DefaultUserEmailResolver is used by default. To support some custom logic create Spring bean that implements this interface.

There can be multiple resolvers - they will be applied according to their bean Order until email is found. DefaultUserEmailResolver is always the last one.

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    resolveEmail(org.springframework.security.core.userdetails.UserDetails user)
    Resolves email for provided user.
  • Method Details

    • resolveEmail

      @Nullable String resolveEmail(org.springframework.security.core.userdetails.UserDetails user)
      Resolves email for provided user.
      Parameters:
      user - user
      Returns:
      email value or null if no email found