Interface MetadataAuthorityService
- All Known Implementing Classes:
MetadataAuthorityServiceImpl
public interface MetadataAuthorityService
Broker for metadata authority settings configured for each metadata field.
Configuration keys, per metadata field (e.g. "dc.contributor.author")
# is field authority controlled (i.e. store authority, confidence values)?
authority.controlled.<FIELD> = true
# is field required to have an authority value, or may it be empty?
# default is false.
authority.required.<FIELD> = true | false
# default value of minimum confidence level for ALL fields - must be
# symbolic confidence level, see org.dspace.content.authority.Choices
authority.minconfidence = uncertain
# minimum confidence level for this field
authority.minconfidence.SCHEMA.ELEMENT.QUALIFIER = SYMBOL
e.g.
authority.minconfidence.dc.contributor.author = accepted
NOTE: There is *expected* to be a "choices" (see ChoiceAuthorityManager)
configuration for each authority-controlled field.- Author:
- Larry Stone
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidThis method has been created to have a way of clearing the cache kept inside the serviceReturn the list of metadata field with authority control.intgetMinConfidence(MetadataField metadataField) Give the minimal level of confidence required to consider valid an authority value for the given metadata.booleanisAuthorityControlled(String fieldKey) Predicate - is field authority-controlled?booleanisAuthorityControlled(MetadataField metadataField) Predicate - is field authority-controlled?booleanisAuthorityRequired(String fieldKey) Predicate - is authority value required for field?booleanisAuthorityRequired(MetadataField metadataField) Predicate - is authority value required for field?makeFieldKey(String schema, String element, String qualifier) Construct a single key from the tuple of schema/element/qualifier that describes a metadata field.makeFieldKey(MetadataField metadataField) Construct a single key from the tuple of schema/element/qualifier that describes a metadata field.
-
Method Details
-
isAuthorityControlled
Predicate - is field authority-controlled?- Parameters:
metadataField- metadata field- Returns:
- true/false
-
isAuthorityControlled
Predicate - is field authority-controlled?- Parameters:
fieldKey- field key- Returns:
- true/false
-
isAuthorityRequired
Predicate - is authority value required for field?- Parameters:
metadataField- metadata field- Returns:
- true/false
-
isAuthorityRequired
Predicate - is authority value required for field?- Parameters:
fieldKey- field key- Returns:
- true/false
-
makeFieldKey
Construct a single key from the tuple of schema/element/qualifier that describes a metadata field. Punt to the function we use for submission UI input forms, for now.- Parameters:
metadataField- metadata field- Returns:
- field key
-
makeFieldKey
Construct a single key from the tuple of schema/element/qualifier that describes a metadata field. Punt to the function we use for submission UI input forms, for now.- Parameters:
schema- schemaelement- elementqualifier- qualifier- Returns:
- field key
-
getMinConfidence
Give the minimal level of confidence required to consider valid an authority value for the given metadata.- Parameters:
metadataField- metadata field- Returns:
- the minimal valid level of confidence for the given metadata
-
getAuthorityMetadata
Return the list of metadata field with authority control. The strings are in the formschema.element[.qualifier]- Returns:
- the list of metadata field with authority control
-
clearCache
void clearCache()This method has been created to have a way of clearing the cache kept inside the service
-