ARoad0.gBaseInterface
Interface Privilege
- All Superinterfaces:
- ACSObject, BaseObject, BoundBean, java.lang.Cloneable, java.lang.Comparable, DetailledName, FinalizedObject, FinalizedObjectForUser, ImmutablePrivilege
- All Known Subinterfaces:
- PrivilegeForLinks, PrivilegeForType
- All Known Implementing Classes:
- PrivilegeAbst, PrivilegeForLinksImpl, PrivilegeForTypeImpl
public interface Privilege
- extends ImmutablePrivilege
This interface is used for modeling the Privilege, which, like ACL or AGO rights,
is a type of granted or denied access right delivered to an access source
for accessing to a target.
A privilege instance is controlled by an ACS, and delivers immutable rights
applicable to couples (source or sources set or source containers set,
target or targets set), which may be external (do not belong to the privilege ACS)
in some cases. The rights of a privilege are immutable
after its creation, while the AclEntry has immutable source and target,
but with editable rights after the creation.
The two types of privileges are typed privileges and linked privileges.
See the Copyright.
- See Also:
PrivilegeAbst
,
PrivilegeForLinksImpl
,
PrivilegeForTypeImpl
Method Summary |
void |
setComment(java.lang.String _s)
Set any comment related to this privilege. |
void |
setSecondType(java.lang.String _st)
If the new value is allowed by the ACS, set the second type of this privilege. |
void |
setSeeWhy(java.lang.String _longPrivilege)
|
Methods inherited from interface ARoad0.gBaseInterface.ImmutablePrivilege |
getAcsFromName, getComment, getEmptyInstance, getEorACS, getKeyReferencesFromName, getL_Rights, getMainType, getName, getPositiveRight, getPropertyChangeListeners, getSecondType, getSeeWhy, isEmpty, isExternalPrivilege |
Methods inherited from interface java.lang.Comparable |
compareTo |
setSeeWhy
void setSeeWhy(java.lang.String _longPrivilege)
- Parameters:
_longPrivilege
- is the description which is displayed to the user.
May be null.
setComment
void setComment(java.lang.String _s)
- Set any comment related to this privilege.
- Parameters:
_s
- comment which is associated to the resource.
setSecondType
void setSecondType(java.lang.String _st)
throws UpDateError
- If the new value is allowed by the ACS, set the second type of this privilege.
This method is used to switch from an type
which forbids the updates of a protected property, and to return to this protecting type.
Then, it is possible to switch for instance from 'read' to
' read', but not to ' write'.
From the default value '', any first update may be done.
'<12345678901234567890>' is a program-reserved value. Even if not
allowed by the ACS, '<12345678901234567890>' is the only new value
for which a current type containing '' may be changed.
From '<12345678901234567890>', any new value may be set from the allowed ones,
and this starting value is the only one which allows to set a value containing
''. Calls ACS.getM_TypesAndGUIPolicy() to have the allowed values
for the key 'PrivilegeForType.SecondType' if the instance is a PrivilegeForType,
or 'PrivilegeForLinks.SecondType' if the instance is a PrivilegeForLinks.
- Parameters:
_st
- second type of the privilege. It is not the main type.
- Throws:
UpDateError
- if the type is null, starts with ,
or not known by the ACS, or not associated to the previous type.