public class SuggestedObservation
extends java.util.HashMap
implements java.lang.Cloneable
Modifier and Type | Class and Description |
---|---|
static class |
SuggestedObservation.PriorityComparator
A comparator for priority values that sorts them in a preferred order, via
their numerical prefix.
|
Modifier and Type | Field and Description |
---|---|
static java.lang.String[] |
ALLOWED_BINNING
Maximum allowed binning.
|
static java.lang.String |
APPROVAL_STATUS |
static java.lang.String[] |
APPROVAL_STATUSES
Approval states.
|
static java.lang.String |
CENTER_LATITUDE |
static java.lang.String |
CENTER_LONGITUDE |
static java.lang.String[] |
COLOR_PRIORITIES
Color priorities.
|
static java.lang.String |
CRISM_COORDINATION |
static java.lang.String |
DEFAULT_PRIORITY
Default value for Priority.
|
static java.lang.String |
DEFAULT_PRIORITY_BACKFILL
Default value for Priority for backfills.
|
static java.lang.String |
DEFAULT_THEME
Default theme name.
|
static java.lang.String |
DESCRIPTION |
static java.lang.String |
EXACT_AREA_REQUESTED |
static java.lang.String[] |
HIGHRES_PRIORITIES
Overall priorities.
|
static java.lang.String |
ID
Class identification name with source code version and date.
|
static java.lang.String |
KEY_ID |
static java.lang.String |
LAST_UPDATE |
static java.lang.String |
MAX_BINNING |
static java.lang.String |
MAX_EMISSION_ANGLE |
static java.lang.String |
MAX_INCIDENCE_ANGLE |
static java.lang.String |
MAX_LATITUDE |
static java.lang.String |
MAX_LONGITUDE |
static java.lang.String |
MAX_LSUBS |
static java.lang.String |
MAX_PHASE_ANGLE |
static java.lang.String |
MIN_EMISSION_ANGLE |
static java.lang.String |
MIN_INCIDENCE_ANGLE |
static java.lang.String |
MIN_LATITUDE |
static java.lang.String |
MIN_LONGITUDE |
static java.lang.String |
MIN_LSUBS |
static java.lang.String |
MIN_PHASE_ANGLE |
static java.lang.String |
NEED_COLOR |
static java.lang.String |
NEED_STEREO |
static java.lang.String |
NONE
Target name for no target.
|
static java.lang.String |
NULL_VALUE
The value in a JComboBox that indicates a null should be
used in the database record.
|
static java.lang.String |
NUMBER_OF_OBSERVATIONS |
static java.lang.String[] |
OVERALL_PRIORITIES
Overall priorities.
|
static java.lang.String[] |
PRIORITIES_HICAT
Suggestion priorities as represented in HiCat.
|
static java.lang.String[] |
PRIORITIES_TEXT
Suggestion priorities plain text.
|
static java.lang.String |
PRIORITY |
static java.lang.String |
PRIORITY_COLOR |
static java.lang.String |
PRIORITY_HIGHRES |
static java.lang.String |
PRIORITY_OVERALL |
static java.lang.String |
PRIORITY_STEREO |
static java.lang.String |
ROI_VERTICES |
static java.lang.String |
SCIENCE_RATIONALE |
static java.lang.String |
SCIENCE_THEME |
static java.lang.String |
SCIENCE_THEME_ACTION_COMMAND
The action command associated with the science theme combo box.
|
static java.lang.String |
SECONDARY_THEME |
static java.lang.String |
SECONDARY_THEME_ACTION_COMMAND
The action command associated with the science theme combo box.
|
static java.lang.String |
SPECIAL_NOTES |
static java.lang.String[] |
STEREO_PRIORITIES
Stereo priorities.
|
static java.lang.String |
STL_COMMENTS_END
The end of the STL comment component of the
SPECIAL_NOTES . |
static java.lang.String |
STL_COMMENTS_START
The start of the STL comment component of the
SPECIAL_NOTES . |
static java.lang.String |
STL_CRISM_COORDINATION |
static java.lang.String |
STL_DESCRIPTION |
static java.lang.String |
STL_HIGH_STABILITY_NADIR |
static java.lang.String |
STL_MAX_BINNING |
static java.lang.String |
STL_MAX_EMISSION_ANGLE |
static java.lang.String |
STL_MAX_INCIDENCE_ANGLE |
static java.lang.String |
STL_MAX_LSUBS |
static java.lang.String |
STL_MAX_PHASE_ANGLE |
static java.lang.String |
STL_MIN_EMISSION_ANGLE |
static java.lang.String |
STL_MIN_INCIDENCE_ANGLE |
static java.lang.String |
STL_MIN_LSUBS |
static java.lang.String |
STL_MIN_PHASE_ANGLE |
static java.lang.String |
STL_MUST_HAVE |
static java.lang.String |
STL_NONINTERACTIVE |
static java.lang.String |
STL_NUMBER_OF_OBSERVATIONS |
static java.lang.String |
STL_OFF_NADIR_IO |
static java.lang.String |
STL_STEREO |
static java.lang.String |
SUGGESTER |
static java.lang.String |
SUGGESTION_DATE |
static java.lang.String |
TARGET_NAME |
static java.lang.String[] |
TARGET_NAMES
Target names.
|
static java.lang.String |
UNPRIORITIZED
The value in the PRIORITY list that indicates a suggestion has not been
prioritized.
|
static java.lang.String |
VERSION |
Constructor and Description |
---|
SuggestedObservation()
Create a new SuggestedObservation model and view with the fields
initialized to default values.
|
Modifier and Type | Method and Description |
---|---|
java.lang.Double |
centerLatitude()
Gets the center planetocentric latitude of the suggestion.
|
java.lang.Double |
centerLongitude()
Gets the center east-leading longitude of the suggestion.
|
void |
clear()
Clears and reinitializes the suggested observation UI elements.
|
java.lang.Object |
clone()
Returns a clone of this suggestion.
|
void |
enableAllEditableFields(boolean enabled) |
void |
enableEditorFields(boolean enabled)
Enables or disables those fields that an editor of a suggestion is allowed
to change.
|
void |
enableOwnerFields(boolean enabled)
Enables or disables those fields that the owner of a suggestion is allowed
to change.
|
void |
enableOwnerHitsFields(boolean enabled)
Enables or disables those fields that the owner of a suggestion or the
targeting specialists are allowed to change.
|
void |
enableStlFields(boolean enabled)
Enables or disables those fields that an STL of a suggestion is allowed to
change.
|
boolean |
equals(java.lang.Object object)
Indicates whether some other object is equal to this suggestion.
|
java.util.Vector |
getFields()
Gets all non-empty field names.
|
java.lang.Object |
getValue(java.lang.String key)
Gets the value given a field name.
|
java.util.Vector |
getValues()
Gets all non-empty values.
|
java.lang.Integer |
id()
Gets the suggestion ID.
|
static boolean |
isNumericField(java.lang.String field_name)
Determines whether a given field name is a field defined as a numeric field
in the Suggest_Observations table.
|
static boolean |
isYesNoField(java.lang.String field_name)
Determines whether a given field name is a field defined as a "yes/no"
field in the Suggested_Observations table.
|
java.lang.Double |
maximumLatitude() |
java.lang.Double |
maximumLongitude() |
java.lang.Double |
minimumLatitude() |
java.lang.Double |
minimumLongitude() |
static java.util.Vector<java.lang.String> |
numericFields()
Gets the collection of numeric field names.
|
PIRL.PVL.Parameter |
parameter()
Gets the suggestion record as a PVL parameter.
|
java.lang.String |
roiVertices() |
java.lang.String |
scienceTheme()
Gets the value of the science theme field.
|
java.lang.String |
secondaryTheme()
Gets the value of the secondary science theme field.
|
void |
setValue(java.lang.String key,
java.lang.Object val)
Set the value for a particular field (given by the key, which is the
field name).
|
static void |
skipFields(java.lang.String... field_names)
Sets the collection of fields to be skipped during the
equals(java.lang.Object)
comparison. |
java.lang.String |
suggester()
Gets the value of the suggester field.
|
java.lang.String |
targetName() |
void |
targetName(java.lang.String targetName) |
compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values
public static final java.lang.String ID
public static final java.lang.String KEY_ID
public static final java.lang.String VERSION
public static final java.lang.String SUGGESTER
public static final java.lang.String SCIENCE_THEME
public static final java.lang.String SECONDARY_THEME
public static final java.lang.String DESCRIPTION
public static final java.lang.String STL_DESCRIPTION
public static final java.lang.String SCIENCE_RATIONALE
public static final java.lang.String SPECIAL_NOTES
public static final java.lang.String TARGET_NAME
public static final java.lang.String NUMBER_OF_OBSERVATIONS
public static final java.lang.String APPROVAL_STATUS
public static final java.lang.String SUGGESTION_DATE
public static final java.lang.String MAX_LATITUDE
public static final java.lang.String CENTER_LATITUDE
public static final java.lang.String MIN_LATITUDE
public static final java.lang.String MAX_LONGITUDE
public static final java.lang.String CENTER_LONGITUDE
public static final java.lang.String MIN_LONGITUDE
public static final java.lang.String ROI_VERTICES
public static final java.lang.String EXACT_AREA_REQUESTED
public static final java.lang.String NEED_STEREO
public static final java.lang.String PRIORITY_STEREO
public static final java.lang.String NEED_COLOR
public static final java.lang.String PRIORITY_COLOR
public static final java.lang.String PRIORITY_HIGHRES
public static final java.lang.String PRIORITY_OVERALL
public static final java.lang.String PRIORITY
public static final java.lang.String MAX_BINNING
public static final java.lang.String STL_MAX_BINNING
public static final java.lang.String MAX_EMISSION_ANGLE
public static final java.lang.String MIN_EMISSION_ANGLE
public static final java.lang.String STL_MAX_EMISSION_ANGLE
public static final java.lang.String STL_MIN_EMISSION_ANGLE
public static final java.lang.String MAX_INCIDENCE_ANGLE
public static final java.lang.String MIN_INCIDENCE_ANGLE
public static final java.lang.String STL_MAX_INCIDENCE_ANGLE
public static final java.lang.String STL_MIN_INCIDENCE_ANGLE
public static final java.lang.String MAX_LSUBS
public static final java.lang.String MIN_LSUBS
public static final java.lang.String STL_MAX_LSUBS
public static final java.lang.String STL_MIN_LSUBS
public static final java.lang.String MAX_PHASE_ANGLE
public static final java.lang.String MIN_PHASE_ANGLE
public static final java.lang.String STL_MAX_PHASE_ANGLE
public static final java.lang.String STL_MIN_PHASE_ANGLE
public static final java.lang.String CRISM_COORDINATION
public static final java.lang.String STL_CRISM_COORDINATION
public static final java.lang.String STL_HIGH_STABILITY_NADIR
public static final java.lang.String STL_MUST_HAVE
public static final java.lang.String STL_NONINTERACTIVE
public static final java.lang.String STL_NUMBER_OF_OBSERVATIONS
public static final java.lang.String STL_OFF_NADIR_IO
public static final java.lang.String STL_STEREO
public static final java.lang.String LAST_UPDATE
public static final java.lang.String[] STEREO_PRIORITIES
public static final java.lang.String[] COLOR_PRIORITIES
public static final java.lang.String[] OVERALL_PRIORITIES
public static final java.lang.String[] HIGHRES_PRIORITIES
public static final java.lang.String[] ALLOWED_BINNING
public static final java.lang.String UNPRIORITIZED
public static final java.lang.String[] PRIORITIES_HICAT
UNPRIORITIZED
to stand in for Null.
Note: The index of this array is not the numeric value of the priority; it's the priority value + 1.
public static final java.lang.String[] PRIORITIES_TEXT
PRIORITIES_HICAT
array. As with the HiCat array, this array includes an
additional value of UNPRIORITIZED
to stand in for Null.
Note: The index of this array is not the numeric value of the priority; it's the priority value + 1.
public static final java.lang.String DEFAULT_PRIORITY
public static final java.lang.String DEFAULT_PRIORITY_BACKFILL
public static final java.lang.String NONE
public static final java.lang.String[] TARGET_NAMES
public static final java.lang.String[] APPROVAL_STATUSES
public static final java.lang.String DEFAULT_THEME
public static final java.lang.String NULL_VALUE
public static final java.lang.String SCIENCE_THEME_ACTION_COMMAND
ActionEvent
.public static final java.lang.String SECONDARY_THEME_ACTION_COMMAND
ActionEvent
.public static final java.lang.String STL_COMMENTS_START
SPECIAL_NOTES
.public static final java.lang.String STL_COMMENTS_END
SPECIAL_NOTES
.public SuggestedObservation()
public void clear()
clear
in interface java.util.Map
clear
in class java.util.HashMap
public java.util.Vector getFields()
public java.util.Vector getValues()
public java.lang.Object getValue(java.lang.String key)
If a field name isn't valid, an empty string is returned.
key
- the field name in question.public void setValue(java.lang.String key, java.lang.Object val) throws java.text.ParseException
key
- Field nameval
- Value to Setjava.text.ParseException
- Invalid valuepublic java.lang.String suggester()
getFields()
method (or related methods).public java.lang.String scienceTheme()
getFields()
method (or related methods).public java.lang.String secondaryTheme()
getFields()
method (or related
methods).public java.lang.Integer id()
public java.lang.Double centerLatitude()
public java.lang.Double centerLongitude()
public java.lang.Double minimumLatitude()
public java.lang.Double maximumLatitude()
public java.lang.Double minimumLongitude()
public java.lang.Double maximumLongitude()
public java.lang.String roiVertices()
public java.lang.String targetName()
public void targetName(java.lang.String targetName)
public void enableOwnerFields(boolean enabled)
enabled
- if true, the owner fields are enabled; otherwise
they're disabled.public void enableOwnerHitsFields(boolean enabled)
enabled
- if true, the owner-HiTS fields are enabled;
otherwise they're disabled.public void enableStlFields(boolean enabled)
enabled
- if true, the STL fields are enabled; otherwise
they're disabled.public void enableEditorFields(boolean enabled)
enabled
- if true, the editor fields are enabled; otherwise
they're disabled.public void enableAllEditableFields(boolean enabled)
public java.lang.Object clone()
clone
in class java.util.HashMap
public boolean equals(java.lang.Object object)
If any of these is false, this method returns false.
Fields that are in the skipFields(java.lang.String...)
set are skipped in the
comparison.
Note that this class does not override the AbstractMap.hashCode()
method as of
this release, so it is in violation of the AbstractMap.hashCode()
contract that
states that equal objects must have equal hash codes.
equals
in interface java.util.Map
equals
in class java.util.AbstractMap
object
- the reference object with which to compare.public static void skipFields(java.lang.String... field_names)
equals(java.lang.Object)
comparison. No effort is made to ensure that the field names are valid
suggestion field names; if a name is not valid, it simply is not checked
during the comparison.
The collection of field names to skip is cleared with each invocation of this method; if no input fields names are supplied, then the collection is empty and no fields will be skipped during the comparison.
field_names
- the names of the fields to skip.public PIRL.PVL.Parameter parameter()
public static boolean isYesNoField(java.lang.String field_name)
JCheckBox
GUI elements are "yes/no" fields, and some are
defined as TINYINT fields, and it is necessary to distinguish
between the two.field_name
- the name of the field in question; it will be coerced
to uppercase for comparison.public static boolean isNumericField(java.lang.String field_name)
public static java.util.Vector<java.lang.String> numericFields()
Copyright \ (C) Arizona Board of Regents on behalf of the \ Planetary Image Research Laboratory, Lunar and \ Planetary Laboratory at the University of Arizona