DLESE Tools
v1.6.0

org.dlese.dpc.vocab
Interface MetadataVocab

All Superinterfaces:
ContentHandler
All Known Implementing Classes:
MetadataVocabOPML, MetadataVocabTermsGroups

public interface MetadataVocab
extends ContentHandler

Interface for classes that manage audience-based metadata controlled vocabulary UI displays and encoded ID translation to/from metadata field/value names/xpaths. Current implementations:

Author:
Ryan Deardorff

Method Summary
 void addError(String err)
          Adds a feature to the Error attribute of the MetadataVocab object
 void addMessage(String msg)
          Adds a feature to the Message attribute of the MetadataVocab object
 void doneLoading()
          Invoked when XML parsing completes
 VocabNode findVocabNode(String system, String fieldName, String valueName)
          Deprecated. As of MetadataUI v1.0, replaced by getVocabNode()
 ArrayList getCacheValuesInOrder(String system, String group, Map cache)
          Given a cache (Map) of vocab values, this method returns a list of those values in the order that they are defined in their groups file.
 String getCurrentVersion(String metaFormat)
          Get the most recently loaded metadata format version number
 ArrayList getErrors()
          Get the list of any errors that have occured
 String getFieldSystemId(String field)
          Deprecated. As of MetadataUI v1.0, replaced by getTranslatedField()
 boolean getFieldValueIdPairExists(String fieldId, String valueId)
          Does a vocabulary definition exist for the given encoded field/value Ids?
 String getFieldValueSystemId(String field, String value)
          Deprecated. As of MetadataUI v1.0, replaced by getTranslatedValue()
 ArrayList getMessages()
          Return stored messages
 String getMetaFormatOfField(String field)
          Gets the metadata format associated with the given field identifier (either encoded ID or PATH)
 String getMetaNameOfId(String system, String fieldId, String valueId)
          Deprecated. As of MetadataUI v1.0, replaced by getTranslatedValue()
 String getOPML(String metaFormat, String audience, String language, String field)
          Gets the OPML for a given format/audience/language, using the current or most recently loaded version without the XML declaration tag
 String getOPML(String metaFormat, String audience, String language, String field, boolean includeXmlDeclaration)
          Gets the OPML for a given format/audience/language, using the current or most recently loaded version
 String getOPML(String metaFormat, String metaVersion, String audience, String language, String field)
          Gets the OPML for a given format/version/audience/language without the XML declaration tag
 String getOPML(String metaFormat, String metaVersion, String audience, String language, String field, boolean includeXmlDeclaration)
          Gets the OPML for a given format/version/audience/language
 String getResponseOPML(PageContext context)
          Gets the re-ordered/grouped/labeled tree of metadata values from the cache created by setResponseGroup()
 String getTopLevelAbbrevLabelOf(String system, String metadataField, String systemFieldId, String systemValueId)
          Gets the topLevelAbbrevLabelOf attribute of the MetadataVocab object
 String getTranslatedField(String metaFormat, String field)
          Gets the translated FIELD NAME/ID of the given FIELD NAME/ID
 String getTranslatedField(String metaFormat, String metaVersion, String field)
          Gets the translated FIELD NAME/ID of the given FIELD NAME/ID
 String getTranslatedFieldPath(String metaFormat, String field)
          Gets the translated FIELD XPATH of the given FIELD NAME/ID
 String getTranslatedFieldPath(String metaFormat, String metaVersion, String field)
          Gets the translated FIELD XPATH of the given FIELD NAME/ID
 String getTranslatedValue(String metaFormat, String field, String value)
          Gets the translated VALUE NAME/ID of the given FIELD+VALUE NAMEs/IDs
 String getTranslatedValue(String metaFormat, String metaVersion, String field, String value)
          Gets the translated VALUE NAME/ID of the given FIELD+VALUE NAMEs/IDs
 String getUiFieldLabel(String audience, String language, String field, boolean abbrev)
          Gets the uiFieldLabel attribute of the MetadataVocab object
 String getUiFieldLabel(String metaFormat, String audience, String language, String field, boolean abbrev)
          Gets the UI label associated with the given FIELD NAME/ID, using the current or most recently loaded metadata format version number
 String getUiFieldLabel(String metaFormat, String metaVersion, String audience, String language, String field)
          Gets the non-abbreviated UI label associated with the given FIELD NAME/ID
 String getUiFieldLabel(String metaFormat, String metaVersion, String audience, String language, String field, boolean abbrev)
          Gets the UI label associated with the given FIELD NAME/ID
 String getUiLabelOf(String system, String metadataField, String metadataValue)
          Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()
 String getUiLabelOf(String system, String metadataField, String metadataValue, boolean abbreviated)
          Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()
 String getUiLabelOfFieldId(String fieldId)
          Deprecated. As of MetadataUI v1.0, replaced by getUiFieldLabel()
 String getUiLabelOfSystemIds(String system, String systemFieldId, String systemValueId)
          Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()
 String getUiLabelOfSystemIds(String system, String systemFieldId, String systemValueId, boolean abbreviated)
          Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()
 String getUiValueDisplay(String metaFormat, String audience, String language, String field, String value)
          Gets the "display" attribute value for the given field/value vocab using the CURRENT metadata framework version
 String getUiValueDisplay(String metaFormat, String metaVersion, String audience, String language, String field, String value)
          Gets the "display" attribute value for the given field/value vocab
 String getUiValueLabel(String audience, String language, String field, String value, boolean abbrev)
          Gets the uiValueLabel attribute of the MetadataVocab object
 String getUiValueLabel(String metaFormat, String audience, String language, String field, String value, boolean abbrev)
          Gets the UI label associated with the given FIELD+VALUE NAMES/IDS, using the current or most recently loaded metadata format version number
 String getUiValueLabel(String metaFormat, String metaVersion, String audience, String language, String field, String value)
          Gets the non-abbreviated UI label associated with the given FIELD+VALUE NAMES/IDS
 String getUiValueLabel(String metaFormat, String metaVersion, String audience, String language, String field, String value, boolean abbrev)
          Gets the UI label associated with the given FIELD+VALUE NAMES/IDS
 String getVocabCheckbox(String groupTop, String value, String label, MetadataVocabInputState inputState)
          Returns a SINGLE HTML CHECKBOX input of the specified part of the vocabulary.
 String getVocabCheckboxes(String system, String group, int size, String tdWidth, boolean skipTopRow, MetadataVocabInputState inputState)
          Returns an HTML TABLE of CHECKBOX inputs of the specified part of the vocabulary.
 ArrayList getVocabFieldIds()
          Gets the vocabFieldIds attribute of the MetadataVocab object
 String getVocabHiddenInputs(String system, String group, MetadataVocabInputState inputState)
          Generates HTML HIDDEN inputs of the specified part of the vocabulary.
 VocabNode getVocabNode(String metaFormat, String audience, String language, String fieldName, String valueName)
          Gets a VocabNode for the given field/value pair
 ArrayList getVocabNodes(String system, String group)
          Gets the vocabNodes attribute of the MetadataVocab object
 ArrayList getVocabNodes(String metaFormat, String audience, String language, String field)
          Gets the vocabNodes attribute of the MetadataVocab object
 ArrayList getVocabNodes(String metaFormat, String audience, String language, String field, String group)
          Gets the vocabNodes attribute of the MetadataVocab object
 String getVocabSelectList(String system, String group, int size, MetadataVocabInputState inputState)
          Returns an HTML SELECT list of the specified part of the vocabulary.
 Set getVocabSystemInterfaces()
          Gets the set of interfaces defined in this instance of the vocabs
 String getVocabTreeMenu(String system, String language, String group, PageContext page)
          Generates an absolutely-positioned JavaScript Tree Menu (collapsable flyout hierarchy) of the specified part of the vocabulary
 void reportError(String err)
          Log an error
 void reportMessage(String msg)
          Log a message
 void setResponseGroup(PageContext context, String metaFormat, String audience, String language, String field)
          Initiate the re-ordering/grouping/labeling of a flat list of metadata values in a search response (Services or otherwise) by indicating an audience grouping (OPML tree) sans version
 void setResponseGroup(PageContext context, String metaFormat, String metaVersion, String audience, String language, String field)
          Initiate the re-ordering/grouping/labeling of a flat list of metadata values in a search response (Services or otherwise) by indicating an audience grouping (OPML tree)
 void setResponseList(ArrayList values, PageContext context)
          Adds an ArrayList of metadata values to the re-ordering/grouping/labeling cache
 void setResponseList(String[] values, PageContext context)
          Adds an ArrayList of metadata values to the re-ordering/grouping/labeling cache
 void setResponseValue(String value, PageContext context)
          Adds a single metadata value to the re-ordering/grouping/labeling cache
 
Methods inherited from interface org.xml.sax.ContentHandler
characters, endDocument, endElement, endPrefixMapping, ignorableWhitespace, processingInstruction, setDocumentLocator, skippedEntity, startDocument, startElement, startPrefixMapping
 

Method Detail

getErrors

ArrayList getErrors()
Get the list of any errors that have occured

Returns:
The errors value

addMessage

void addMessage(String msg)
Adds a feature to the Message attribute of the MetadataVocab object

Parameters:
msg - The feature to be added to the Message attribute

addError

void addError(String err)
Adds a feature to the Error attribute of the MetadataVocab object

Parameters:
err - The feature to be added to the Error attribute

setResponseGroup

void setResponseGroup(PageContext context,
                      String metaFormat,
                      String metaVersion,
                      String audience,
                      String language,
                      String field)
Initiate the re-ordering/grouping/labeling of a flat list of metadata values in a search response (Services or otherwise) by indicating an audience grouping (OPML tree)

Parameters:
context - JSP page context
metaVersion - metadata version (i.e. "0.6.50")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
See Also:
setResponseValue(String,PageContext), setResponseList(String[],PageContext), setResponseList(ArrayList,PageContext), getResponseOPML(PageContext)

setResponseGroup

void setResponseGroup(PageContext context,
                      String metaFormat,
                      String audience,
                      String language,
                      String field)
Initiate the re-ordering/grouping/labeling of a flat list of metadata values in a search response (Services or otherwise) by indicating an audience grouping (OPML tree) sans version

Parameters:
context - JSP page context
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
See Also:
setResponseValue(String,PageContext), setResponseList(String[],PageContext), setResponseList(ArrayList,PageContext), getResponseOPML(PageContext)

setResponseValue

void setResponseValue(String value,
                      PageContext context)
Adds a single metadata value to the re-ordering/grouping/labeling cache

Parameters:
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
context - JSP page context
See Also:
setResponseGroup(PageContext,String,String,String,String,String), setResponseList(String[],PageContext), setResponseList(ArrayList,PageContext), getResponseOPML(PageContext)

setResponseList

void setResponseList(ArrayList values,
                     PageContext context)
Adds an ArrayList of metadata values to the re-ordering/grouping/labeling cache

Parameters:
context - JSP page context
values - List of metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
See Also:
setResponseGroup(PageContext,String,String,String,String,String), setResponseValue(String,PageContext), setResponseList(String[],PageContext), getResponseOPML(PageContext)

setResponseList

void setResponseList(String[] values,
                     PageContext context)
Adds an ArrayList of metadata values to the re-ordering/grouping/labeling cache

Parameters:
context - JSP page context
values - List of metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
See Also:
setResponseGroup(PageContext,String,String,String,String,String), setResponseValue(String,PageContext), setResponseList(ArrayList,PageContext), getResponseOPML(PageContext)

getResponseOPML

String getResponseOPML(PageContext context)
Gets the re-ordered/grouped/labeled tree of metadata values from the cache created by setResponseGroup()

Parameters:
context - JSP page context
Returns:
OPML for the group specified with setResponseGroup() and trimmed to the subset indicated by values passed into setResponse()
See Also:
setResponseValue(String,PageContext), setResponseList(String[],PageContext), setResponseList(ArrayList,PageContext), setResponseGroup(PageContext,String,String,String,String,String)

getVocabSystemInterfaces

Set getVocabSystemInterfaces()
Gets the set of interfaces defined in this instance of the vocabs

Returns:
The vocabSystemInterfaces value

getFieldValueIdPairExists

boolean getFieldValueIdPairExists(String fieldId,
                                  String valueId)
Does a vocabulary definition exist for the given encoded field/value Ids?

Parameters:
fieldId - Encoded vocabulary field Id
valueId - Encoded vocabulary value Id
Returns:
The fieldValueIdPairExists value

getVocabNodes

ArrayList getVocabNodes(String system,
                        String group)
Gets the vocabNodes attribute of the MetadataVocab object

Parameters:
system -
group -
Returns:
The vocabNodes value

getVocabSelectList

String getVocabSelectList(String system,
                          String group,
                          int size,
                          MetadataVocabInputState inputState)
Returns an HTML SELECT list of the specified part of the vocabulary.

Parameters:
group - colon-seperated specifier of the part of the vocab hierarchy which is to be displayed
size - size (height) of the SELECT list
system -
inputState -
Returns:
The vocabSelectList value

getVocabCheckboxes

String getVocabCheckboxes(String system,
                          String group,
                          int size,
                          String tdWidth,
                          boolean skipTopRow,
                          MetadataVocabInputState inputState)
Returns an HTML TABLE of CHECKBOX inputs of the specified part of the vocabulary.

Parameters:
group - colon-seperated specifier of the part of the vocab hierarchy which is to be displayed
size - how many inputs to display before starting a new column in the table
tdWidth - value inserted into the width param of the TD tag
skipTopRow - Should the top row of checkboxes (next to All | Clear) be skipped?
system -
inputState -
Returns:
the HTML code

getVocabCheckbox

String getVocabCheckbox(String groupTop,
                        String value,
                        String label,
                        MetadataVocabInputState inputState)
Returns a SINGLE HTML CHECKBOX input of the specified part of the vocabulary.

Parameters:
groupTop - Top-level vocab group
value - vocab value
label - UI label
inputState -
Returns:
the HTML code

getVocabTreeMenu

String getVocabTreeMenu(String system,
                        String language,
                        String group,
                        PageContext page)
Generates an absolutely-positioned JavaScript Tree Menu (collapsable flyout hierarchy) of the specified part of the vocabulary

Parameters:
group - colon-seperated specifier of the part of the vocab hierarchy which is to be displayed
system -
page -
language -
Returns:
the Javascript code defining the menu

getVocabHiddenInputs

String getVocabHiddenInputs(String system,
                            String group,
                            MetadataVocabInputState inputState)
Generates HTML HIDDEN inputs of the specified part of the vocabulary.

Parameters:
group - colon-seperated specifier of the part of the vocab hierarchy which is to be displayed
system -
inputState -
Returns:
the HTML code

getCacheValuesInOrder

ArrayList getCacheValuesInOrder(String system,
                                String group,
                                Map cache)
Given a cache (Map) of vocab values, this method returns a list of those values in the order that they are defined in their groups file.

Parameters:
cache -
system -
group -
Returns:
The orderedCacheValues value

getVocabFieldIds

ArrayList getVocabFieldIds()
Gets the vocabFieldIds attribute of the MetadataVocab object

Returns:
The vocabFieldIds value

doneLoading

void doneLoading()
Invoked when XML parsing completes


findVocabNode

VocabNode findVocabNode(String system,
                        String fieldName,
                        String valueName)
Deprecated. As of MetadataUI v1.0, replaced by getVocabNode()

Description of the Method

Parameters:
system -
fieldName -
valueName -
Returns:

getVocabNode

VocabNode getVocabNode(String metaFormat,
                       String audience,
                       String language,
                       String fieldName,
                       String valueName)
Gets a VocabNode for the given field/value pair

Parameters:
metaFormat - metadata format (i.e. "adn")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
fieldName - vocab field
valueName - vocab value
Returns:
VocabNode for the vocab

getVocabNodes

ArrayList getVocabNodes(String metaFormat,
                        String audience,
                        String language,
                        String field)
Gets the vocabNodes attribute of the MetadataVocab object

Parameters:
metaFormat -
audience -
language -
field -
Returns:
The vocabNodes value

getVocabNodes

ArrayList getVocabNodes(String metaFormat,
                        String audience,
                        String language,
                        String field,
                        String group)
Gets the vocabNodes attribute of the MetadataVocab object

Parameters:
metaFormat -
audience -
language -
field -
group -
Returns:
The vocabNodes value

getCurrentVersion

String getCurrentVersion(String metaFormat)
Get the most recently loaded metadata format version number

Parameters:
metaFormat - metadata format (i.e. "adn")
Returns:
The current (most recently loaded) version for the given format

getTranslatedField

String getTranslatedField(String metaFormat,
                          String metaVersion,
                          String field)
                          throws Exception
Gets the translated FIELD NAME/ID of the given FIELD NAME/ID

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
Returns:
The FIELD NAME/ID as translated from input FIELD NAME/ID, i.e. "gradeRange"
Throws:
Exception

getTranslatedField

String getTranslatedField(String metaFormat,
                          String field)
                          throws Exception
Gets the translated FIELD NAME/ID of the given FIELD NAME/ID

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
Returns:
The FIELD NAME/ID as translated from input FIELD NAME/ID, i.e. "gradeRange"
Throws:
Exception

getTranslatedFieldPath

String getTranslatedFieldPath(String metaFormat,
                              String metaVersion,
                              String field)
                              throws Exception
Gets the translated FIELD XPATH of the given FIELD NAME/ID

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
Returns:
The FIELD XPATH as translated from input FIELD NAME/ID
Throws:
Exception

getTranslatedFieldPath

String getTranslatedFieldPath(String metaFormat,
                              String field)
                              throws Exception
Gets the translated FIELD XPATH of the given FIELD NAME/ID

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
Returns:
The FIELD XPATH as translated from input FIELD NAME/ID
Throws:
Exception

getTranslatedValue

String getTranslatedValue(String metaFormat,
                          String metaVersion,
                          String field,
                          String value)
                          throws Exception
Gets the translated VALUE NAME/ID of the given FIELD+VALUE NAMEs/IDs

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
Returns:
The VALUE NAME/ID as translated from input FIELD+VALUE NAMEs/IDs
Throws:
Exception

getTranslatedValue

String getTranslatedValue(String metaFormat,
                          String field,
                          String value)
                          throws Exception
Gets the translated VALUE NAME/ID of the given FIELD+VALUE NAMEs/IDs

Parameters:
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
metaFormat - metadata format (i.e. "adn")
Returns:
The VALUE NAME/ID as translated from input FIELD+VALUE NAMEs/IDs
Throws:
Exception

getUiValueLabel

String getUiValueLabel(String metaFormat,
                       String metaVersion,
                       String audience,
                       String language,
                       String field,
                       String value,
                       boolean abbrev)
Gets the UI label associated with the given FIELD+VALUE NAMES/IDS

Parameters:
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
abbrev - get the abbreviated version of the label?
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
Returns:
The user interface label associated with the given format/version/audience/language value

getUiValueLabel

String getUiValueLabel(String metaFormat,
                       String metaVersion,
                       String audience,
                       String language,
                       String field,
                       String value)
Gets the non-abbreviated UI label associated with the given FIELD+VALUE NAMES/IDS

Parameters:
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
Returns:
The user interface label associated with the given format/version/audience/language value

getUiValueLabel

String getUiValueLabel(String metaFormat,
                       String audience,
                       String language,
                       String field,
                       String value,
                       boolean abbrev)
Gets the UI label associated with the given FIELD+VALUE NAMES/IDS, using the current or most recently loaded metadata format version number

Parameters:
metaFormat - metadata format (i.e. "adn")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
abbrev - get the abbreviated version of the label?
Returns:
The user interface label associated with the given format/version/audience/language value

getUiValueLabel

String getUiValueLabel(String audience,
                       String language,
                       String field,
                       String value,
                       boolean abbrev)
Gets the uiValueLabel attribute of the MetadataVocab object

Parameters:
audience -
language -
field -
value -
abbrev -
Returns:
The uiValueLabel value

getUiFieldLabel

String getUiFieldLabel(String metaFormat,
                       String metaVersion,
                       String audience,
                       String language,
                       String field,
                       boolean abbrev)
Gets the UI label associated with the given FIELD NAME/ID

Parameters:
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
abbrev - get the abbreviated version of the label?
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
Returns:
The user interface label associated with the given format/version/audience/language value

getUiFieldLabel

String getUiFieldLabel(String metaFormat,
                       String metaVersion,
                       String audience,
                       String language,
                       String field)
Gets the non-abbreviated UI label associated with the given FIELD NAME/ID

Parameters:
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
Returns:
The user interface label associated with the given format/version/audience/language value

getUiFieldLabel

String getUiFieldLabel(String metaFormat,
                       String audience,
                       String language,
                       String field,
                       boolean abbrev)
Gets the UI label associated with the given FIELD NAME/ID, using the current or most recently loaded metadata format version number

Parameters:
metaFormat - metadata format (i.e. "adn")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
abbrev - get the abbreviated version of the label?
Returns:
The user interface label associated with the given format/version/audience/language value

getUiFieldLabel

String getUiFieldLabel(String audience,
                       String language,
                       String field,
                       boolean abbrev)
Gets the uiFieldLabel attribute of the MetadataVocab object

Parameters:
audience -
language -
field -
abbrev -
Returns:
The uiFieldLabel value

getUiValueDisplay

String getUiValueDisplay(String metaFormat,
                         String metaVersion,
                         String audience,
                         String language,
                         String field,
                         String value)
Gets the "display" attribute value for the given field/value vocab

Parameters:
metaFormat - metadata format (i.e. "adn")
metaVersion - metadata version (i.e. "0.6.50")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
Returns:
The uiValueDisplay value

getUiValueDisplay

String getUiValueDisplay(String metaFormat,
                         String audience,
                         String language,
                         String field,
                         String value)
Gets the "display" attribute value for the given field/value vocab using the CURRENT metadata framework version

Parameters:
metaFormat - metadata format (i.e. "adn")
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
value - metadata VALUE encoded ID (i.e. "04") or metadata NAME (i.e. "DLESE:Intermediate elementary")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
Returns:
The uiValueDisplay value

getOPML

String getOPML(String metaFormat,
               String metaVersion,
               String audience,
               String language,
               String field,
               boolean includeXmlDeclaration)
Gets the OPML for a given format/version/audience/language

Parameters:
metaVersion - metadata version (i.e. "0.6.50")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
includeXmlDeclaration - should the <?xml...?> declaration tag be included with the output?
Returns:
OPML for the given format/audience

getOPML

String getOPML(String metaFormat,
               String audience,
               String language,
               String field,
               boolean includeXmlDeclaration)
Gets the OPML for a given format/audience/language, using the current or most recently loaded version

Parameters:
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
includeXmlDeclaration - should the <?xml...?> declaration tag be included with the output?
Returns:
OPML for the given format/audience

getOPML

String getOPML(String metaFormat,
               String metaVersion,
               String audience,
               String language,
               String field)
Gets the OPML for a given format/version/audience/language without the XML declaration tag

Parameters:
metaVersion - metadata version (i.e. "0.6.50")
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
Returns:
OPML for the given format/audience

getOPML

String getOPML(String metaFormat,
               String audience,
               String language,
               String field)
Gets the OPML for a given format/audience/language, using the current or most recently loaded version without the XML declaration tag

Parameters:
audience - UI audience, i.e. "community" or "cataloger"
language - UI language, i.e. "en-us"
field - metadata FIELD encoded ID (i.e. "gr") or metadata NAME (i.e. "gradeRange")
metaFormat - metadata format (i.e. "adn")
Returns:
OPML for the given format/audience

getMetaNameOfId

String getMetaNameOfId(String system,
                       String fieldId,
                       String valueId)
Deprecated. As of MetadataUI v1.0, replaced by getTranslatedValue()

Gets the metadata value or field name of the given encoded field and value Ids. Pass "" (empty string) for valueId to have it return the metadata field name (instead of value).

Parameters:
system - Vocabulary framework/version/audience/language, i.e. "adn/0.6.50/community/en-us" in v2.x (or "dds.descr.en-us" in v1.x)
fieldId - Encoded vocabulary field Id
valueId - Encoded vocabulary value Id
Returns:
The metaNameOfId value
See Also:
MetadataVocab#getTranslatedField(String,String,String,String,String), MetadataVocab#getTranslatedValue(String,String,String,String,String,String)

getFieldValueSystemId

String getFieldValueSystemId(String field,
                             String value)
                             throws Exception
Deprecated. As of MetadataUI v1.0, replaced by getTranslatedValue()

Gets the encoded value Id of the given metadata field/value pair

Parameters:
field - Metadata field name
value - Metadata value name
Returns:
The encoded value Id
Throws:
Exception

getFieldSystemId

String getFieldSystemId(String field)
                        throws Exception
Deprecated. As of MetadataUI v1.0, replaced by getTranslatedField()

Gets the encoded field Id of the given metadata field

Parameters:
field - Metadata field name
Returns:
The encoded field Id
Throws:
Exception

getUiLabelOf

String getUiLabelOf(String system,
                    String metadataField,
                    String metadataValue,
                    boolean abbreviated)
Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()

Gets the UI label of the given metadata field/value pair

Parameters:
system - Vocabulary system/interface/language trio, i.e. "adn/0.6.50/community/en-us"
metadataField - Metadata field name
metadataValue - Metadata value name
abbreviated - Return the abbreviated form of the UI label?
Returns:
The user interface label associated with the given vocabulary value

getUiLabelOf

String getUiLabelOf(String system,
                    String metadataField,
                    String metadataValue)
Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()

Gets the full (non-abbreviated) UI label of the given metadata field/value pair

Parameters:
system - Vocabulary system/interface/language trio, i.e. "adn/0.6.50/community/en-us"
metadataField - Metadata field name
metadataValue - Metadata value name
Returns:
The user interface label associated with the given vocabulary value

getUiLabelOfFieldId

String getUiLabelOfFieldId(String fieldId)
Deprecated. As of MetadataUI v1.0, replaced by getUiFieldLabel()

Gets the uiLabelOfFieldId attribute of the MetadataVocab object

Parameters:
fieldId - Description of the Parameter
Returns:
The uiLabelOfFieldId value

getUiLabelOfSystemIds

String getUiLabelOfSystemIds(String system,
                             String systemFieldId,
                             String systemValueId,
                             boolean abbreviated)
Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()

Gets the UI label of the given encoded field/value Id pair

Parameters:
system - Vocabulary system/interface/language trio, i.e. "dds.default.en-us"
systemFieldId - Encoded field Id
systemValueId - Encoded value Id
abbreviated - Return the abbreviated form of the UI label?
Returns:
The user interface label associated with the given vocabulary value

getUiLabelOfSystemIds

String getUiLabelOfSystemIds(String system,
                             String systemFieldId,
                             String systemValueId)
Deprecated. As of MetadataUI v1.0, replaced by getUiValueLabel()

Gets the full (non-abbreviated) UI label of the given encoded field/value Id pair

Parameters:
system - Vocabulary system/interface/language trio, i.e. "dds.default.en-us"
systemFieldId - Encoded field Id
systemValueId - Encoded value Id
Returns:
The user interface label associated with the given vocabulary value

getMetaFormatOfField

String getMetaFormatOfField(String field)
Gets the metadata format associated with the given field identifier (either encoded ID or PATH)

Parameters:
field -
Returns:
The metaFormatOfField value

getTopLevelAbbrevLabelOf

String getTopLevelAbbrevLabelOf(String system,
                                String metadataField,
                                String systemFieldId,
                                String systemValueId)
Gets the topLevelAbbrevLabelOf attribute of the MetadataVocab object

Parameters:
system -
metadataField -
systemFieldId -
systemValueId -
Returns:
The topLevelAbbrevLabelOf value

getMessages

ArrayList getMessages()
Return stored messages

Returns:
The messages value

reportMessage

void reportMessage(String msg)
Log a message

Parameters:
msg -

reportError

void reportError(String err)
Log an error

Parameters:
err -

DLESE Tools
v1.6.0