Interface AccessStatusService
- All Known Implementing Classes:
AccessStatusServiceImpl
Configuration properties: (with examples)
# values for the forever embargo date threshold
# This threshold date is used in the default access status helper to determine if an item is
# restricted or embargoed based on the start date of the primary (or first) file policies.
# In this case, if the policy start date is inferior to the threshold date, the status will
# be embargo, else it will be restricted.
# You might want to change this threshold based on your needs. For example: some databases
# doesn't accept a date superior to 31 december 9999.
access.status.embargo.forever.year = 10000
access.status.embargo.forever.month = 1
access.status.embargo.forever.day = 1
# implementation of access status helper plugin - replace with local implementation if applicable
# This default access status helper provides an item status based on the policies of the primary
# bitstream (or first bitstream in the original bundles if no primary file is specified).
plugin.single.org.dspace.access.status.AccessStatusHelper = org.dspace.access.status.DefaultAccessStatusHelper
-
Method Summary
Modifier and TypeMethodDescriptiongetAccessStatus(Context context, Bitstream bitstream) Calculate the access status for a bitstream while considering the forever embargo date threshold.getAccessStatus(Context context, Item item) Calculate the access status for an Item while considering the forever embargo date threshold.getAnonymousAccessStatus(Context context, Item item) Calculate the anonymous access status for an Item while considering the forever embargo date threshold.
-
Method Details
-
getAccessStatus
Calculate the access status for an Item while considering the forever embargo date threshold.- Parameters:
context- the DSpace contextitem- the item- Returns:
- the access status
- Throws:
SQLException- An exception that provides information on a database access error or other errors.
-
getAnonymousAccessStatus
Calculate the anonymous access status for an Item while considering the forever embargo date threshold.- Parameters:
context- the DSpace contextitem- the item to check for embargo information- Returns:
- the access status
- Throws:
SQLException- An exception that provides information on a database access error or other errors.
-
getAccessStatus
Calculate the access status for a bitstream while considering the forever embargo date threshold.- Parameters:
context- the DSpace contextbitstream- the bitstream- Returns:
- the access status
- Throws:
SQLException- An exception that provides information on a database access error or other errors.
-