当前页面:
在线文档首页 >
JBoss Seam 1.1.0 API 英文版文档
Identity (JBoss Seam API Documentation) - JBoss Seam 1.1.0 API 英文版文档
org.jboss.seam.security
Class Identity
java.lang.Object
org.jboss.seam.security.Identity
- All Implemented Interfaces:
- Serializable, Principal
- Direct Known Subclasses:
- UsernamePasswordToken
@Name(value="org.jboss.seam.security.identity")
@Scope(value=SESSION)
@Install(precedence=0,
dependencies="org.jboss.seam.securityManager")
public abstract class Identity
- extends Object
- implements Principal, Serializable
- 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
Identity
public Identity()
instance
public static Identity instance()
getRoles
public abstract Role[] 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.