Interface MetadataAuthorityService
-
- All Known Implementing Classes:
MetadataAuthorityServiceImpl
public interface MetadataAuthorityServiceBroker for metadata authority settings configured for each metadata field. Configuration keys, per metadata field (e.g. "dc.contributer.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.Choicesauthority.minconfidence = uncertain# minimum confidence level for this fieldauthority.minconfidence.SCHEMA.ELEMENT.QUALIFIER = SYMBOLe.g.authority.minconfidence.dc.contributor.author = acceptedNOTE: There is *expected* to be a "choices" (see ChoiceAuthorityManager) configuration for each authority-controlled field.- Author:
- Larry Stone
- See Also:
ChoiceAuthorityServiceImpl,Choices
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclearCache()This method has been created to have a way of clearing the cache kept inside the serviceList<String>getAuthorityMetadata()Return 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?StringmakeFieldKey(String schema, String element, String qualifier)Construct a single key from the tuple of schema/element/qualifier that describes a metadata field.StringmakeFieldKey(MetadataField metadataField)Construct a single key from the tuple of schema/element/qualifier that describes a metadata field.
-
-
-
Method Detail
-
isAuthorityControlled
boolean isAuthorityControlled(MetadataField metadataField)
Predicate - is field authority-controlled?- Parameters:
metadataField- metadata field- Returns:
- true/false
-
isAuthorityControlled
boolean isAuthorityControlled(String fieldKey)
Predicate - is field authority-controlled?- Parameters:
fieldKey- field key- Returns:
- true/false
-
isAuthorityRequired
boolean isAuthorityRequired(MetadataField metadataField)
Predicate - is authority value required for field?- Parameters:
metadataField- metadata field- Returns:
- true/false
-
isAuthorityRequired
boolean isAuthorityRequired(String fieldKey)
Predicate - is authority value required for field?- Parameters:
fieldKey- field key- Returns:
- true/false
-
makeFieldKey
String makeFieldKey(MetadataField metadataField)
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
String makeFieldKey(String schema, String element, String qualifier)
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
int getMinConfidence(MetadataField metadataField)
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
List<String> 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
-
-