当前页面:
在线文档首页 >
JBoss Seam 1.1.0 bate1 API 英文版文档
Authentication (JBoss Seam API Documentation) - JBoss Seam 1.1.0 bate1 API 英文版文档
org.jboss.seam.security
Class Authentication
java.lang.Object
org.jboss.seam.security.Authentication
- All Implemented Interfaces:
- Serializable, Principal
- Direct Known Subclasses:
- UsernamePasswordToken
@Name(value="org.jboss.seam.security.authentication")
@Scope(value=SESSION)
public abstract class Authentication
- extends Object
- implements Principal, Serializable
An Authentication represents either a login token or an authenticated Principal.
- Author:
- Shane Bryzak
- See Also:
- Serialized Form
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
authenticated
protected boolean authenticated
valid
protected boolean valid
Authentication
public Authentication()
instance
public static Authentication instance()
getRoles
public abstract String[] getRoles()
getCredentials
public abstract Object getCredentials()
getPrincipal
public abstract Object getPrincipal()
isAuthenticated
public final boolean isAuthenticated()
isValid
public final boolean isValid()
invalidate
public final void invalidate()
isUserInRole
public boolean isUserInRole(String role)
- Checks if the authenticated user contains the specified role.
- Parameters:
role
- String
- Returns:
- boolean Returns true if the authenticated user contains the role,
or false if otherwise.