public class LabelUtil extends Object
Modifier and Type | Field and Description |
---|---|
static String |
CONTEXT_AREA_INVESTIGATION_AREA_REFERENCE |
static String |
CONTEXT_AREA_OBSERVATION_SYSTEM_COMPONENT_REFERENCE |
static String |
CONTEXT_AREA_TARGET_IDENTIFICATION_REFERENCE |
static String |
LID_REFERENCE |
static String |
LIDVID_REFERENCE |
Constructor and Description |
---|
LabelUtil() |
Modifier and Type | Method and Description |
---|---|
static ArrayList<String> |
getIdentifiersCommon(DOMSource source,
URL context,
String[] tagsList,
String searchPathName)
Common function to retrieve values either from logical_identifier or lid_reference/lidvid_reference tags.
|
static String |
getIMVersion(DOMSource source,
URL context)
Get the Information Model (IM) version of the label (as a DOMSource)
|
static ArrayList<String> |
getInformationModelVersions()
Returns the list of IMs registered so far.
|
static String |
getLauncherURIName()
Get the name of the executable of validate.
|
static ArrayList<String> |
getLidVidReferences(DOMSource source,
URL context)
Get the LIDVID references in the label (as a DOMSource)
|
static String |
getLocation()
Get the location of the label currently processing.
|
static ArrayList<String> |
getLogicalIdentifiers(DOMSource source,
URL context)
Get the local identifiers the label (as a DOMSource)
|
static void |
hardResetInformationModelVersions()
Reset Information Model Versions List to zero size.
|
static void |
reduceInformationModelVersions()
Reduce Information Model Versions List to just one if it contains more than one elements
|
static void |
registerIMVersion(String informationModelVersion)
Register the Information Model (IM) version.
|
static void |
reportIfMoreThanOneVersion(String validationRule)
Report a WARNING if the number of unique IM versions are more than one.
|
static void |
reset()
Reset all list(s) and variables back to their default states.
|
static void |
setLauncherURIName(String launcherURIName)
Set the name of the executable of validate.
|
static void |
setLocation(String location)
Set the location of the label currently processing.
|
static void |
setReport(Report report)
Set the report to log status of labels or WARNING messages.
|
public static String LIDVID_REFERENCE
public static String LID_REFERENCE
public static String CONTEXT_AREA_TARGET_IDENTIFICATION_REFERENCE
public static String CONTEXT_AREA_OBSERVATION_SYSTEM_COMPONENT_REFERENCE
public static String CONTEXT_AREA_INVESTIGATION_AREA_REFERENCE
public static void reduceInformationModelVersions()
None
- public static void hardResetInformationModelVersions()
None
- public static void reset()
None
- public static void setLauncherURIName(String launcherURIName)
launcherURIName
- The name of the executable of validate.public static String getLauncherURIName()
None
- public static void setReport(Report report)
report
- The Report object.public static void registerIMVersion(String informationModelVersion)
informationModelVersion
- The version of the IM to register, e.g. 1.12.0.0, 1.10.0.0public static ArrayList<String> getInformationModelVersions()
public static void setLocation(String location)
location
- informationModelVersion The version of the IM to register, e.g. 1.12.0.0, 1.10.0.0public static String getLocation()
public static String getIMVersion(DOMSource source, URL context)
source
- The content of context as a DOMSource.
# @param context The location of the label being parsed frompublic static ArrayList<String> getIdentifiersCommon(DOMSource source, URL context, String[] tagsList, String searchPathName)
source
- context
- tagsList
- searchPathName
- public static ArrayList<String> getLidVidReferences(DOMSource source, URL context)
source
- The content of context as a DOMSource.
# @param context The location of the label being parsed from.public static ArrayList<String> getLogicalIdentifiers(DOMSource source, URL context)
source
- The content of context as a DOMSource.
# @param context The location of the label being parsed from.public static void reportIfMoreThanOneVersion(String validationRule)
validationRule
- The rule of the validation, e.g. pds4.label, pds4.bundle. This value can be null since a rule is is not required within validate module.Copyright © 2021 Jet Propulsion Laboratory, California Institute of Technology. All rights reserved.