public final class ChoiceAuthorityManager extends Object
ChoiceAuthority| Modifier and Type | Method and Description |
|---|---|
Choices |
getBestMatch(String fieldKey,
String query,
int collection,
String locale)
Wrapper that calls getBestMatch method of the plugin corresponding to
the metadata field defined by single field key.
|
String |
getLabel(String fieldKey,
String authKey,
String locale)
Wrapper that calls getLabel method of the plugin corresponding to
the metadata field defined by single field key.
|
String |
getLabel(String schema,
String element,
String qualifier,
String authKey,
String locale)
Wrapper that calls getLabel method of the plugin corresponding to
the metadata field defined by schema,element,qualifier.
|
static ChoiceAuthorityManager |
getManager()
Factory method
|
Choices |
getMatches(String fieldKey,
String query,
int collection,
int start,
int limit,
String locale)
Wrapper calls getMatches method of the plugin corresponding to
the metadata field defined by single field key.
|
Choices |
getMatches(String schema,
String element,
String qualifier,
String query,
int collection,
int start,
int limit,
String locale)
Wrapper that calls getMatches method of the plugin corresponding to
the metadata field defined by schema,element,qualifier.
|
String |
getPresentation(String fieldKey)
Get the presentation keyword (should be "lookup", "select" or "suggest", but this
is an informal convention so it can be easily extended) for this field.
|
List<String> |
getVariants(String schema,
String element,
String qualifier,
String authorityKey,
String language)
Wrapper to call plugin's getVariants().
|
boolean |
isChoicesConfigured(String fieldKey)
Predicate, is there a Choices configuration of any kind for the
given metadata field?
|
boolean |
isClosed(String fieldKey)
Get the configured "closed" value for this field.
|
static String |
makeFieldKey(String dotty)
Construct a single key from the "dot" notation e.g.
|
static String |
makeFieldKey(String schema,
String element,
String qualifier)
Construct a single key from the tuple of schema/element/qualifier
that describes a metadata field.
|
public static ChoiceAuthorityManager getManager()
public Choices getMatches(String schema, String element, String qualifier, String query, int collection, int start, int limit, String locale)
schema - schema of metadata fieldelement - element of metadata fieldqualifier - qualifier of metadata fieldquery - user's value to matchcollection - database ID of Collection for context (owner of Item)start - choice at which to start, 0 is first.limit - maximum number of choices to return, 0 for no limit.locale - explicit localization key if available, or nullChoiceAuthority.getMatches(String, String, int, int, int, String)public Choices getMatches(String fieldKey, String query, int collection, int start, int limit, String locale)
fieldKey - single string identifying metadata fieldquery - user's value to matchcollection - database ID of Collection for context (owner of Item)start - choice at which to start, 0 is first.limit - maximum number of choices to return, 0 for no limit.locale - explicit localization key if available, or nullChoiceAuthority.getMatches(String, String, int, int, int, String)public Choices getBestMatch(String fieldKey, String query, int collection, String locale)
fieldKey - single string identifying metadata fieldquery - user's value to matchcollection - database ID of Collection for context (owner of Item)locale - explicit localization key if available, or nullChoiceAuthority.getBestMatch(String, String, int, String)public String getLabel(String schema, String element, String qualifier, String authKey, String locale)
public String getLabel(String fieldKey, String authKey, String locale)
public boolean isChoicesConfigured(String fieldKey)
public String getPresentation(String fieldKey)
public boolean isClosed(String fieldKey)
public static String makeFieldKey(String schema, String element, String qualifier)
public static String makeFieldKey(String dotty)
Copyright © 2013 DuraSpace. All Rights Reserved.