public class Channel_ID extends CCD_ID
Observation_ID
,
CCD_ID
,
Instrument
Modifier and Type | Field and Description |
---|---|
static int |
DEFAULT_CHANNEL_NUMBER |
static java.lang.String |
ID
Class identification name with source code version and date.
|
DEFAULT_CPMM_NUMBER
AEROBRAKING, APPROACH, ATLO, CALIBRATION, CPMM_AND_CHANNEL_PATTERN, CRUISE, DEFAULT_INORBIT_PHASE, DEFAULT_MISSION_PHASE, DEFAULT_OBSERVATION_ID, DEFAULT_ORBIT_NUMBER, DEFAULT_PREORBIT_PHASE, DEFAULT_TARGET, DEFAULT_TIME, DEFAULT_TIME_TEXT_FORMAT, DELIMITER_PATTERN, EPOCH, EXTENDED_SCIENCE_PHASE, EXTENSION_DELIMITER, EXTENSION_PATTERN, GAP_INDICATOR_PATTERN, INORBIT_MISSION_PHASE_GROUP, INORBIT_ORBIT_NUMBER_GROUP, INORBIT_PREFIX_GROUP, INORBIT_SUFFIX_GROUP, INORBIT_TARGET_GROUP, INSTRUMENT_ID_PATTERN, INTEGRATION_AND_TESTING, INVALID_OBSERVATION_ID, JPL_TIME_TEXT_FORMAT, KENNEDY_SPACE_CENTER, LAST_PREORBIT_PHASE, LAUNCH, MISSION_PHASE_ABBREVIATION, MISSION_PHASE_BIT_COUNT, MISSION_PHASE_MASK, MISSION_PHASE_MAX, MISSION_PHASE_MAX_ORBIT, MISSION_PHASE_MAX_TIME, MISSION_PHASE_NAME, MISSION_PHASE_PATTERN, MISSION_PHASE_START, OBSERVATION_ID_PATTERN, OPTIONAL_DELIMITER_PATTERN, ORBIT_NUMBER_BIT_COUNT, ORBIT_NUMBER_MASK, ORBIT_NUMBER_MAX, ORBIT_NUMBER_MIN, ORBIT_NUMBER_PATTERN, ORBIT_NUMBER_START, PDS_TIME_TEXT_FORMAT, PREFIX_PATTERN, PREORBIT_MISSION_PHASE_GROUP, PREORBIT_PREFIX_GROUP, PREORBIT_SUFFIX_GROUP, PREORBIT_TIME_GROUP, PRIMARY_SCIENCE_PHASE, RELAY, REQUIRED_DELIMITER_PATTERN, RESERVED_1, RESERVED_10, RESERVED_11, RESERVED_12, RESERVED_13, RESERVED_14, RESERVED_15, RESERVED_16, RESERVED_17, RESERVED_18, RESERVED_19, RESERVED_2, RESERVED_3, RESERVED_4, RESERVED_5, RESERVED_6, RESERVED_7, RESERVED_8, RESERVED_9, RSDS_OPS_CPMM_AND_CHANNEL_GROUP, RSDS_OPS_EXTENSION_GROUP, RSDS_OPS_GAP_GROUP, RSDS_OPS_INSTRUMENT_ID_GROUP, RSDS_OPS_OBSERVATION_ID_GROUP, RSDS_OPS_SPACECRAFT_ID_GROUP, RSDS_OPS_VERSION_GROUP, RSDS_TEST_CPMM_AND_CHANNEL_GROUP, RSDS_TEST_EXTENSION_GROUP, RSDS_TEST_GAP_GROUP, RSDS_TEST_ID_GROUP, RSDS_TEST_INSTRUMENT_ID_GROUP, RSDS_TEST_OBSERVATION_ID_GROUP, RSDS_TEST_SPACECRAFT_ID_GROUP, RSDS_TEST_VERSION_GROUP, RSDS_TIME_TEXT_FORMAT, SPACECRAFT_ID_PATTERN, SUFFIX_PATTERN, SVT, TARGET_BIT_COUNT, TARGET_MASK, TARGET_MAX, TARGET_PATTERN, TARGET_START, TEST_ID_PATTERN, TEXT_DELIMITER, TIME_BIT_COUNT, TIME_MASK, TIME_MAX, TIME_PATTERN, TIME_START, TOTAL_MISSION_PHASES, TRANSITION, VERSION_PATTERN
Constructor and Description |
---|
Channel_ID()
Creates a default
CCD_ID with the
Observation_ID.DEFAULT_OBSERVATION_ID ,
CCD_ID.DEFAULT_CPMM_NUMBER and
DEFAULT_CHANNEL_NUMBER values. |
Channel_ID(int observation_id_value,
int cpmm_value,
int channel_value)
Creates a
Channel_ID with the specified
Observation_ID, CPMM number, and channel number. |
Channel_ID(int mission_phase_value,
int time_value,
int cpmm_value,
int channel_value)
Creates a pre-orbit
Channel_ID with the specified
pre-orbit mission phase, pre-orbit time component, CPMM number, and
channel number. |
Channel_ID(int mission_phase_value,
int orbit_number_value,
int target_value,
int cpmm_value,
int channel_value)
Creates an in-orbit
Channel_ID with the specified in-orbit
mission phase, orbit number, target component, CPMM number, and
channel number. |
Channel_ID(java.lang.String id_text)
Creates a
Channel_ID from a string. |
Modifier and Type | Method and Description |
---|---|
java.lang.String |
channel_name()
Returns the text version of the channel number of this
Channel_ID object. |
Channel_ID |
channel_name(java.lang.String channel_text)
Sets the channel number for this
Channel_ID object based on a
text string. |
Channel_ID |
channel_name(java.lang.String channel_text,
boolean use_defaults)
Sets the channel number for this
Channel_ID object based on a
text string. |
int |
channel_number()
Returns the channel number for this
Channel_ID object. |
Channel_ID |
channel_number(int channel_value)
Sets the channel number for this
Channel_ID object. |
Channel_ID |
channel_number(java.lang.String channel_text)
Sets the channel number for this
Channel_ID object based on a
text string. |
Channel_ID |
channel_number(java.lang.String channel_text,
boolean use_defaults)
Sets the channel number for this
Channel_ID object based on a
text string. |
java.lang.String |
parse(java.lang.String the_text)
Sets the value of this
Channel_ID using a text
representation. |
java.lang.String |
parse(java.lang.String the_text,
boolean use_defaults)
Parses a string to obtain a value for the channel number.
|
java.lang.String |
text()
Returns the text representation of this
Channel_ID . |
Channel_ID |
text(java.lang.String id_text)
Sets the value of this
Channel_ID using a text
representation. |
Channel_ID |
text(java.lang.String id_text,
boolean use_defaults)
Sets the value of this
Channel_ID using a
text representation. |
java.lang.String |
toString()
Produces the text representation of this
Channel_ID . |
ccd_name, ccd_name, ccd_name, cpmm_number, cpmm_number, cpmm_number, cpmm_number
extract_mission_phase, extract_mission_phase, extract_orbit_number, extract_orbit_number, extract_target, extract_target, extract_time, extract_time, hex_value, hex_value, is_preorbit, mission_phase_from_orbit_number, mission_phase_from_time, mission_phase, mission_phase, mission_phase, mission_phase, orbit_number, orbit_number, orbit_number, orbit_number, target, target, target, target, time_now, time_text_format, time_text_format, time_text, time_text, time, time, time, time, time, time, value, value, value, value, zero_pad_binary, zero_pad_hex, zero_pad_number, zero_pad_number
public static final java.lang.String ID
public static final int DEFAULT_CHANNEL_NUMBER
public Channel_ID()
CCD_ID
with the
Observation_ID.DEFAULT_OBSERVATION_ID
,
CCD_ID.DEFAULT_CPMM_NUMBER
and
DEFAULT_CHANNEL_NUMBER
values.public Channel_ID(int observation_id_value, int cpmm_value, int channel_value)
Channel_ID
with the specified
Observation_ID, CPMM number, and channel number.
If cpmm_value
is not less than Instrument.CCDS
, or if
it is not equal to Instrument.CCD_UNKNOWN
, then
CCD_ID.DEFAULT_CPMM_NUMBER
will be used instead.
Likewise, if channel_value
is not less than
Instrument.CCD_CHANNELS
, or if it is not equal to
Instrument.CCD_CHANNEL_UNKNOWN
, then
DEFAULT_CHANNEL_NUMBER
will be used.observation_id_value
- The initial numeric value of the
Observation_ID.cpmm_value
- The initial value for the CPMM number.channel_value
- The initial value for the channel number.public Channel_ID(int mission_phase_value, int time_value, int cpmm_value, int channel_value)
Channel_ID
with the specified
pre-orbit mission phase, pre-orbit time component, CPMM number, and
channel number.
If mission_phase_value
is not a pre-orbit mission phase, then
Observation_ID.DEFAULT_PREORBIT_PHASE
will be used. If
time_value
is greater than Observation_ID.TIME_MAX
,
Observation_ID.DEFAULT_TIME
will be used. If
time_value
is negative, however, then the current system clock
time will be used to set the pre-orbit time component. If
cpmm_value
is not less than Instrument.CCDS
, or if
it is not equal to Instrument.CCD_UNKNOWN
, then
CCD_ID.DEFAULT_CPMM_NUMBER
will be used instead. Finally, if
channel_value
is not less than
Instrument.CCD_CHANNELS
, or if it is not equal to
Instrument.CCD_CHANNEL_UNKNOWN
, then
DEFAULT_CHANNEL_NUMBER
will be used.mission_phase_value
- The pre-orbit mission phase.time_value
- The value for the pre-orbit time component. If it
is negative, the current system clock time will be used instead.cpmm_value
- The initial value for the CPMM number.channel_value
- The initial value for the channel number.public Channel_ID(int mission_phase_value, int orbit_number_value, int target_value, int cpmm_value, int channel_value)
Channel_ID
with the specified in-orbit
mission phase, orbit number, target component, CPMM number, and
channel number.
If mission_phase_value
is not an in-orbit mission phase, then
Observation_ID.DEFAULT_INORBIT_PHASE
will be used. If
orbit_number_value
is greater than
Observation_ID.ORBIT_NUMBER_MAX
, then
Observation_ID.DEFAULT_ORBIT_NUMBER
will be used. If
target_value
is greater than
Observation_ID.TARGET_MAX
, then
Observation_ID.DEFAULT_TARGET
will be used. If
cpmm_value
is not less than Instrument.CCDS
, or if
it is not equal to Instrument.CCD_UNKNOWN
, then
CCD_ID.DEFAULT_CPMM_NUMBER
will be used instead. Finally, if
channel_value
is not less than
Instrument.CCD_CHANNELS
, or if it is not equal to
Instrument.CCD_CHANNEL_UNKNOWN
, then
DEFAULT_CHANNEL_NUMBER
will be used.mission_phase_value
- The in-orbit mission phase.orbit_number_value
- The value for the orbit number component.target_value
- The value for the target component.cpmm_value
- The initial value for the CPMM number.channel_value
- The initial value for the channel number.public Channel_ID(java.lang.String id_text)
Channel_ID
from a string.
If a valid channel number cannot be parsed from the string, then
Instrument.CCD_CHANNEL_UNKNOWN
will be used. If a valid CPMM
number cannot be parsed from the string, then
Instrument.CCD_UNKNOWN
will be used. If a valid observation ID
component cannot be parsed from the string,
Observation_ID.INVALID_OBSERVATION_ID
will be used.id_text
- A string that contains a text representation of the
Channel_ID
.text(String)
public int channel_number()
Channel_ID
object. A value
of Instrument.CCD_CHANNEL_UNKNOWN
indiciates the channel
number is not know for this Channel_ID.Channel_ID
.public Channel_ID channel_number(int channel_value) throws Out_of_Range_Exception
Channel_ID
object. If
channel_value
is greater than or equal to
Instrument.CCD_CHANNELS
, the channel number will be set to
DEFAULT_CHANNEL_NUMBER
and an Out_of_Range_Exception
will
be thrown, unless it is set to Instrument.CCD_CHANNEL_UNKNOWN
,
which indicates that channel number is not known.channel_value
- The value for the channel number for this
Channel_ID
object.Channel_ID
.Out_of_Range_Exception
- If channel_value is greater than or equal to
Instrument.CCD_CHANNELS
. The channel number will be set topublic Channel_ID channel_number(java.lang.String channel_text, boolean use_defaults) throws Invalid_Argument_Exception, Out_of_Range_Exception
Channel_ID
object based on a
text string. If a channel number cannot be derived from the string, the
channel number will be set to Instrument.CCD_CHANNEL_UNKNOWN
and an Invalid_Argument_Exception
will be thrown. If a value greater
than or equal to Instrument.CCD_CHANNELS
is derived, the
channel number will be set to DEFAULT_CHANNEL_NUMBER
and an
Out_of_Range_Exception
will be thrown. If use_defaults
is true
the DEFAULT_CHANNEL_NUMBER
will be used
instead.channel_text
- The text representation of the channel number.use_defaults
- If true
, DEFAULT_CHANNEL_NUMBER
will be used if the channel number cannot be
parsed or if the parsed value is out of range; otherwise,
an Invalid_Argument_Exception
or
Out_of_Range_Exception
will be thrown.Channel_ID
.Invalid_Argument_Exception
- If channel_text cannot be parsed for a
valid channel number. The channel number will be set to
Instrument.CCD_CHANNEL_UNKNOWN
in this case.Out_of_Range_Exception
- If channel_text indicates a value greater
than or equal to Instrument.CCD_CHANNELS
. The channel
number will be set to DEFAULT_CHANNEL_NUMBER
in this case.public Channel_ID channel_number(java.lang.String channel_text)
Channel_ID
object based on a
text string. If a channel number cannot be derived from the string or if a
value greater than or equal to Instrument.CCD_CHANNELS
is
derived, the channel number will be set to DEFAULT_CHANNEL_NUMBER
.
This method calls channel_number(String,boolean)
with
use_defaults
set to true
.channel_text
- The text representation of the Channel number.Channel_ID
.public java.lang.String channel_name()
Channel_ID
object. If the channel number is unknown,
Instrument.CCD_CHANNEL_UNKNOWN
is returned instead, as a
string.Channel_ID
or
Instrument.CCD_CHANNEL_UNKNOWN
.public Channel_ID channel_name(java.lang.String channel_text, boolean use_defaults) throws Invalid_Argument_Exception, Out_of_Range_Exception
Channel_ID
object based on a
text string. This method simply calls channel_number(String,boolean).channel_text
- The text representation of the channel number.use_defaults
- If true
, DEFAULT_CHANNEL_NUMBER
will be used if the channel number cannot be
parsed or if the parsed value is out of range; otherwise,
an Invalid_Argument_Exception
or
Out_of_Range_Exception
will be thrown.Channel_ID
.Invalid_Argument_Exception
- If channel_text cannot be parsed for a
valid channel number. The channel number will be set to
Instrument.CCD_CHANNEL_UNKNOWN
in this case.Out_of_Range_Exception
- If channel_text indicates a value greater
than or equal to Instrument.CCD_CHANNELS
. The channel number will
be set to DEFAULT_CHANNEL_NUMBER
in this case.channel_number(String)
public Channel_ID channel_name(java.lang.String channel_text)
Channel_ID
object based on a
text string. This method calls channel_name(String,boolean)
with
use_defaults
set to true
.channel_text
- The text representation of the channel number.Channel_ID
.channel_name(String,boolean)
public java.lang.String text()
Channel_ID
. The text
representation consists of the text representation of its CCD_ID followed
by the channel text that corresponds to its channel number. If the channel
number is unknown Instrument.CCD_CHANNEL_UNKNOWN
, then
Instrument.CCD_CHANNEL_UNKNOWN
replaces the channel text in the text
representation. Regardless, the name, CCD_ID and Channel_ID are separated
by an underscore ("_") delimiter.public Channel_ID text(java.lang.String id_text, boolean use_defaults) throws Invalid_Argument_Exception, Out_of_Range_Exception
Channel_ID
using a
text representation. If the id_text
cannot be parsed for a valid
channel ID, an Invalid_Argument_Exception
is thrown. If
use_defaults
is true
, appropriate default values
will be used as needed instead.text
in class CCD_ID
id_text
- The text to be parsed to obtain the value.use_defaults
- If true
, default values for the
various components of a Channel_ID
will be used
when they cannot be determined from the id_text
. If
false
, an Invalid_Argument_Exception
will be
thrown instead.Channel_ID
.Invalid_Argument_Exception
- If a Channel ID cannot be parsed
from the_text
and use_defaults
is
false
.Out_of_Range_Exception
- If a one of the parsed values is out of
range and use_defaults
is false
.parse(String)
public Channel_ID text(java.lang.String id_text)
Channel_ID
using a text
representation. If the_text
cannot be parsed for a valid
Channel ID, appropriate default values will be used as needed instead.
This method calls parse(String,boolean)
with
use_defaults
set to true
.text
in class CCD_ID
id_text
- The text to be parsed to obtain the value.CCD_ID
.parse(String,boolean)
public java.lang.String parse(java.lang.String the_text, boolean use_defaults) throws Invalid_Argument_Exception, Out_of_Range_Exception
parse
in class CCD_ID
the_text
- The text to be parsed.use_defaults
- If true
, default values for the
various components of a Channel_ID
will be used
when they cannot be determined from the the_text
. If
false
, an Invalid_Argument_Exception
will be
thrown instead.Invalid_Argument_Exception
- If a CCD ID cannot be parsed
from the_text
and use_defaults
is
false
.Out_of_Range_Exception
- If a one of the parsed values is out of
range and use_defaults
is false
.channel_number()
public java.lang.String parse(java.lang.String the_text)
Channel_ID
using a text
representation. If the_text
cannot be parsed for a valid
observation ID, appropriate default values will be used as needed instead.
This method calls parse(String,boolean)
with
use_defaults
set to true
.
This method returns the text that was not used in the interpretation of an
observation ID. Subclasses of Observation_ID
can use this
returned text to parse additional information.
parse
in class CCD_ID
the_text
- The text from which to parse an observation ID.text(String, boolean)
Copyright \ (C) Arizona Board of Regents on behalf of the \ Planetary Image Research Laboratory, Lunar and \ Planetary Laboratory at the University of Arizona