stella
Interface TargetDefinition

All Known Subinterfaces:
Appointable, Handable, HistoryAware
All Known Implementing Classes:
AbstractTarget, GrbTarget, ParsedTarget

public interface TargetDefinition

An interface describing an astronomical target in a way that it is handable by a scheduler and a sequencer. This interface is only the very basic definition of a whole sequence of target definitions, specifying the target into deeper and deeper detail.

A target definition initially comprises only a unique target name, a target type and some parameters which may be distinguished by an identifier object. This identifier is needed if a target provides different definitions for the same named property. E.g. if a target consists of different stars, all with have a property ra. Specifying the right identifier blocks ambiguities.

For some astronomical observation it may be necessary that one target consists of a couple of daughter targets (e.g. a radial velocity standard target may actually consist of a handful of radial velocity standard stars), or requires another target immediately after this target. This process is called target-chaining. The following rules apply:

Note that chaining targets that are not Handable will not work.


Method Summary
 List getDaughters()
          Returns a list of daugther targets.
 String getDescription()
          Returns a description of the target.
 String getDescriptionID()
          Returns an id of the target description.
 List<? extends javax.mail.Address> getEmailAddresses()
          Returns a list of user e-mails.
 Object getImageType()
          Gets the image type.
 UserProfile.Affil getInstitution()
          Gets the institution this target belongs to.
 String getName()
          Gets the target name.
 TargetDefinition getPrecursor()
          If the target is called in a target-chain, this method returns a pointer to that target that was currently handled when this target was selected.
 TargetDefinition getSuccessor()
          If this target needs another target executed right after it, this method should return this target.
 URL getTargetResource()
          A resource where the target can be located.
 Object getTargetSpecific(Object id)
          Gets a description of a specified field in the target description.
 List<String> getTeam()
          Gets the names of the cois or null if no Co-Is are assigned.
 String getTitle()
          Gets the target title.
 Object getType()
          Gets the target type.
 String getUser()
          Gets the target user.
 void setPrecursor(TargetDefinition parent)
          Sets the precursor target of the current target.
 

Method Detail

getName

String getName()
Gets the target name. Used to uniquely identify the target.


getTargetResource

URL getTargetResource()
A resource where the target can be located.


getTitle

String getTitle()
Gets the target title.


getDescription

String getDescription()
Returns a description of the target. This is an abstract of the observing program purpose.


getDescriptionID

String getDescriptionID()
Returns an id of the target description. This might be a proposal name.


getUser

String getUser()
Gets the target user. Used for assigning observation time shares if getInstitution() is not meaningful.


getTeam

List<String> getTeam()
Gets the names of the cois or null if no Co-Is are assigned.


getEmailAddresses

List<? extends javax.mail.Address> getEmailAddresses()
Returns a list of user e-mails. All entries in the list should follow the java-mail API Address definition.


getInstitution

UserProfile.Affil getInstitution()
Gets the institution this target belongs to. Used for assigning observation time shares.


getType

Object getType()
Gets the target type. Normally, the return type will be a string. A sequencer must be able to derive a List of sequencer steps out of this target type.


getImageType

Object getImageType()
Gets the image type. Normally, the return type will be a string. This method is used for FITS header entries.


getTargetSpecific

Object getTargetSpecific(Object id)
Gets a description of a specified field in the target description. This description id-tag must be unique and must allow the underlying target definition to return an object out of the definition. This can be used if a target definition is augmented by some additional data like an instrument section that defines an exposure of the target. The id is needed if more than one setup is possible. E.g. if two instrument sections are present, they will have the same keys. Distinguishing is possibly with identifier object.
Note that this comes in handy with an XML-ID-attribute definition.

Parameters:
id - An identifier, most likely a string.
Returns:
A sub-class of object, commands must know how to use it.

getPrecursor

TargetDefinition getPrecursor()
If the target is called in a target-chain, this method returns a pointer to that target that was currently handled when this target was selected. Precursor may be daugther targets as well as top-level targets.


setPrecursor

void setPrecursor(TargetDefinition parent)
Sets the precursor target of the current target. Used in target-chaining. Called whenever a this target is newly selected in the chain, with the target as an argument that was currently executing.


getDaughters

List getDaughters()
Returns a list of daugther targets. This list should have no multiple entries. If this target does not have any daugther targets, this method should return null.


getSuccessor

TargetDefinition getSuccessor()
If this target needs another target executed right after it, this method should return this target.