Interface AuthorizationFeature
-
- All Known Implementing Classes:
AdministratorOfFeature,CCLicenseFeature,CollectionAdminFeature,ComColAdminFeature,CommunityAdminFeature,CreateBitstreamFeature,CreateBundleFeature,CreateCollectionFeature,CreateCommunityFeature,DeleteFeature,DownloadFeature,EditMetadataFeature,EPersonRegistrationFeature,LoginOnBehalfOfFeature,MakeDiscoverableFeature,MakePrivateFeature,ManageAdminGroupFeature,ManageGroupsFeature,ManageMappedItemsFeature,ManageSubmitterGroupFeature,ManageTemplateItemFeature,ManageWorkflowGroupFeature,MoveFeature,PolicyFeature,ReinstateFeature,ReorderBitstreamFeature,RequestCopyFeature,ViewSearchStatisticsFeature,ViewUsageStatisticsFeature,ViewVersionsFeature,ViewWorkflowStatisticsFeature,WithdrawFeature
public interface AuthorizationFeatureA feature is the representation of a business goal used in the Authorization endpoint to declare what an user can do on a specific object.- Author:
- Andrea Bollini (andrea.bollini at 4science.it)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default StringgetDescription()Return the description of the featuredefault StringgetName()Return the name of the featureString[]getSupportedTypes()Return the supported object type according to theRestAddressableModel.getUniqueType()booleanisAuthorized(org.dspace.core.Context context, BaseObjectRest object)Check if the eperson in the provided context, or the anonymous user if not loggedin, has access to the feature for the requested object
-
-
-
Method Detail
-
isAuthorized
boolean isAuthorized(org.dspace.core.Context context, BaseObjectRest object) throws SQLExceptionCheck if the eperson in the provided context, or the anonymous user if not loggedin, has access to the feature for the requested object- Parameters:
context- the DSpace Contextobject- the object target by the feature (MUST be NOT null). Use theSiteRestobject for repository wide feature- Returns:
- true if the user associated with the context has access to the feature for the specified object
- Throws:
SQLException
-
getName
default String getName()
Return the name of the feature- Returns:
- the name of the feature
-
getDescription
default String getDescription()
Return the description of the feature- Returns:
- the description of the feature
-
getSupportedTypes
String[] getSupportedTypes()
Return the supported object type according to theRestAddressableModel.getUniqueType()- Returns:
- the supported object type, required to be not null
-
-