|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.metamatrix.platform.security.api.UserEntitlementInfo
public class UserEntitlementInfo
Information about a particular entitled Resource (Group or table, Element or column), this class specifies a collection of Principals (users or user groups) - Grantees that have been granted certain Allowed Actions (one or more of {CREATE, READ, UPDATE, DELETE}) on the given Resource by one or more Grantors (granting authority).
There may be multiple Grantees that have multiple Allowed Actions they are entitled
to perform on this Group or Element by multiple Grantors. This means we have an independantly
varying triplet. We take a user-centered approach so this object contains a Set
of
GranteeEntitlementEntry
s
Constructor Summary | |
---|---|
UserEntitlementInfo(AuthorizationRealm realm,
java.lang.String groupName,
java.lang.String eleName)
ctor |
Method Summary | |
---|---|
void |
addTriplet(GranteeEntitlementEntry newEntry)
Add a GranteeEntitlementEntry object. |
void |
addTriplet(MetaMatrixPrincipalName grantee,
java.lang.String grantor,
int allowedActions)
Add a Grantee -> Grantor -> Allowed Actions triplet. |
boolean |
contains(java.lang.String grantee)
Is the given grantee entitled to perform any action on the Resource represented by this object? |
java.lang.String |
getElementName()
Get the element (column) of this entitlement. |
java.util.Collection |
getGrantees()
Get the collection of Grantee names possessing this entitlement. |
java.lang.String |
getGroupName()
Get the group (table) of this entitlement. |
java.lang.String |
getVDBName()
Get the name of the VDB this entitlement falls under. |
java.lang.String |
getVDBVersion()
Get the version of the VDB this entitlement falls under. |
boolean |
isGroupEntitlement()
Does this represent a group or an element entitlement? |
java.util.Iterator |
iterator()
Get an iterator over the Grantees possessing this entitlement. |
int |
size()
Get the number of Grantees in this entitlement. |
java.lang.String |
toString()
Pretty print this Object to a String. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public UserEntitlementInfo(AuthorizationRealm realm, java.lang.String groupName, java.lang.String eleName)
Method Detail |
---|
public boolean isGroupEntitlement()
true
if this object pertains to a group entitlement,
false
if it's an element entitlement.public java.lang.String getVDBName()
public java.lang.String getVDBVersion()
public java.lang.String getGroupName()
public java.lang.String getElementName()
Note: Will be null
if this is a group entitlement.
public int size()
public boolean contains(java.lang.String grantee)
grantee
- The user (or user group) name of inquery.
true
if the grantee can perform one or
more actions on this Resource, false
if he can
perform none.public java.util.Collection getGrantees()
Elements of the collection are of type GranteeEntitlementEntry
and are sorted.
public java.util.Iterator iterator()
Elements of the iterator are of type GranteeEntitlementEntry
.
public void addTriplet(MetaMatrixPrincipalName grantee, java.lang.String grantor, int allowedActions)
grantee
- A Grantee.grantor
- A Grantor.allowedActions
- The Allowed Actions on the resource granted
by the Grantor to the Grantee.public void addTriplet(GranteeEntitlementEntry newEntry)
GranteeEntitlementEntry
object.
newEntry
- A new entry.public java.lang.String toString()
String[]
of one or more of {CREATE, READ, UPDATE, DELETE})
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |