Interface User
-
- All Known Subinterfaces:
User
@ProviderType public interface UserRepresentation of a user. The user object can be used by plugins toauthorize(String)the user.
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringUSER_ATTRIBUTEThe name of the request attribute providing an object of this class
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description booleanauthorize(java.lang.String role)Checks whether the user has the given role permission.java.lang.ObjectgetUserObject()Return the user object.
-
-
-
Method Detail
-
getUserObject
java.lang.Object getUserObject()
Return the user object. This method might returnnullif no web console security provider is configured and access to the console is allowed without authentication.- Returns:
- The user object or
null
-
authorize
boolean authorize(java.lang.String role)
Checks whether the user has the given role permission.- Parameters:
role- The requested role- Returns:
trueif the user is given permission for the given role.
-
-