org.acegisecurity.providers
Class TestingAuthenticationToken
java.lang.Object
org.acegisecurity.providers.AbstractAuthenticationToken
org.acegisecurity.providers.TestingAuthenticationToken
- All Implemented Interfaces:
- java.io.Serializable, java.security.Principal, Authentication
public class TestingAuthenticationToken
- extends AbstractAuthenticationToken
An Authentication implementation that is designed for use whilst unit testing.
The
corresponding authentication provider is TestingAuthenticationProvider.
- Version:
- $Id: TestingAuthenticationToken.java 1496 2006-05-23 13:38:33Z benalex $
- Author:
- Ben Alex
- See Also:
- Serialized Form
|
Method Summary |
java.lang.Object |
getCredentials()
The credentials that prove the principal is correct. |
java.lang.Object |
getPrincipal()
The identity of the principal being authenticated. |
| Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
TestingAuthenticationToken
public TestingAuthenticationToken(java.lang.Object principal,
java.lang.Object credentials,
GrantedAuthority[] authorities)
getCredentials
public java.lang.Object getCredentials()
- Description copied from interface:
Authentication
- The credentials that prove the principal is correct. This is usually a password, but could be anything
relevant to the
AuthenticationManager. Callers are expected to populate the credentials.
- Returns:
- the credentials that prove the identity of the
Principal
getPrincipal
public java.lang.Object getPrincipal()
- Description copied from interface:
Authentication
- The identity of the principal being authenticated. This is usually a username. Callers are expected to
populate the principal.
- Returns:
- the
Principal being authenticated
Copyright © 2004-2006 Acegi Technology Pty Limited. All Rights Reserved.