public class TestingAuthenticationToken extends AbstractAuthenticationToken
Authentication implementation that is designed for use whilst unit testing.The
corresponding authentication provider is TestingAuthenticationProvider.
| Constructor and Description |
|---|
TestingAuthenticationToken(Object principal,
Object credentials,
GrantedAuthority[] authorities) |
| Modifier and Type | Method and Description |
|---|---|
Object |
getCredentials()
The credentials that prove the principal is correct.
|
Object |
getPrincipal()
The identity of the principal being authenticated.
|
equals, getAuthorities, getDetails, getName, hashCode, isAuthenticated, setAuthenticated, setDetails, toStringpublic TestingAuthenticationToken(Object principal, Object credentials, GrantedAuthority[] authorities)
public Object getCredentials()
AuthenticationAuthenticationManager. Callers are expected to populate the credentials.Principalpublic Object getPrincipal()
AuthenticationPrincipal being authenticatedCopyright © 2016. All rights reserved.