Errai 3.0.1-SNAPSHOT

org.jboss.errai.security.shared.api.identity
Interface User

All Superinterfaces:
Serializable
All Known Implementing Classes:
UserImpl

public interface User
extends Serializable

Represents a user or other actor which may have permissions to do things within the application.


Nested Class Summary
static class User.StandardUserProperties
          A set of standard property names that most other security identity systems are likely to have information about.
 
Field Summary
static User ANONYMOUS
          Represents a user who is not logged in.
 
Method Summary
 String getIdentifier()
           
 Map<String,String> getProperties()
           
 String getProperty(String name)
           
 Set<Role> getRoles()
           
 boolean hasAllRoles(String... roleNames)
           
 boolean hasAnyRoles(String... roleNames)
           
 void removeProperty(String name)
           
 void setProperty(String name, String value)
           
 

Field Detail

ANONYMOUS

static final User ANONYMOUS
Represents a user who is not logged in. This user has no properties and a single role.

Method Detail

getIdentifier

String getIdentifier()

getRoles

Set<Role> getRoles()

hasAllRoles

boolean hasAllRoles(String... roleNames)

hasAnyRoles

boolean hasAnyRoles(String... roleNames)

getProperties

Map<String,String> getProperties()

setProperty

void setProperty(String name,
                 String value)

removeProperty

void removeProperty(String name)

getProperty

String getProperty(String name)

Errai 3.0.1-SNAPSHOT

Copyright © 2013-2014 JBoss, a division of Red Hat. All Rights Reserved.