fr.cnes.genopus.frames
Class GPFrame

java.lang.Object
  extended by fr.cnes.genius.main.GComponent
      extended by fr.cnes.genius.lowLevel.GContainer
          extended by fr.cnes.genopus.frames.GPFrame
All Implemented Interfaces:
fr.cnes.genius.main.GClear, fr.cnes.genius.main.GCondensedStatusInterface, fr.cnes.genius.main.GDisplay, fr.cnes.genius.main.GListener, fr.cnes.genius.main.GReadWrite, GPPatrius<org.orekit.frames.Frame>

public class GPFrame
extends fr.cnes.genius.lowLevel.GContainer
implements fr.cnes.genius.main.GReadWrite, fr.cnes.genius.main.GListener, fr.cnes.genius.main.GDisplay, fr.cnes.genius.main.GClear, GPPatrius<org.orekit.frames.Frame>, fr.cnes.genius.main.GCondensedStatusInterface

Widget representing an OREKIT Frame.

Author:
aadt
Default Constraint(s):
IndexClassItemConstraint
0GComboBoxWithLabelcomboBoxRefFrame0, 0, 0 => "newline , gapleft 0 , split 2"
0, 0, 1 => (null)
0, 1 => "split 4"
1GCheckBoxWithIndicatorcheckBoxEOP1, 0, 0 => (null)
1, 0, 1 => (null)
1, 1 => (null)
2GPAbsoluteDateabsoluteDateH0"newline"
(see table below)
3GEntryRealentryRealN3, 0, 0 => "newline , gapleft 20 , split 2"
3, 0, 1 => (null)
3, 1 => "split 2"
3, 2 => (null)
4GEntryRealentryRealLon4, 0, 0 => "newline , gapleft 20 , split 2"
4, 0, 1 => (null)
4, 1 => "split 2"
4, 2 => (null)

Default Constraint(s) for absoluteDateH0:
IndexClassItemConstraint
2, 0GLabelWithIndicatorlabel2, 0, 0 => "newline , gapleft 20 , split 2"
2, 0, 1 => (null)
2, 1GPDateFielddateField"spanx 2 , split 5"
2, 2GPopupListWithLabelpopupListTimeScales2, 2, 0, 0 => "split 4"
2, 2, 0, 1 => (null)
2, 2, 1 => (null)
2, 3GButtonbuttonRelativeDate(null)


Nested Class Summary
static class GPFrame.GPRefFrame
          Enumerate of Reference frames available in the widget.
 
Nested classes/interfaces inherited from class fr.cnes.genius.main.GComponent
fr.cnes.genius.main.GComponent.CopyPasteOperation, fr.cnes.genius.main.GComponent.DisplayIndicatorStatus, fr.cnes.genius.main.GComponent.ItemType, fr.cnes.genius.main.GComponent.Operation
 
Field Summary
static String H0_MINUS_N_NAME
          Name for any H0-n frame internally used in GENOPUS.
 
Fields inherited from class fr.cnes.genius.main.GComponent
NAME_ATTRIBUTE
 
Constructor Summary
GPFrame(String label)
          Constructor without frame and without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).
GPFrame(String label, org.orekit.frames.Frame frame)
          Constructor without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).
GPFrame(String label, org.orekit.frames.Frame frame, GPFrame.GPRefFrame... framesToShow)
          Constructor.
GPFrame(String label, GPFrame.GPRefFrame... framesToShow)
          Constructor without frame.
GPFrame(String widgetId, String label)
          Constructor without frame and without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).
GPFrame(String widgetId, String label, org.orekit.time.AbsoluteDate h0, double n, double lon, GPFrame.GPRefFrame... framesToShow)
          Specific constructor to initialize the widget with an H0-n reference frame.
GPFrame(String widgetId, String label, org.orekit.frames.Frame frame)
          Constructor without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).
GPFrame(String widgetId, String label, org.orekit.frames.Frame frame, GPFrame.GPRefFrame... framesToShow)
          Constructor.
GPFrame(String widgetId, String label, GPFrame.GPRefFrame... framesToShow)
          Constructor without frame.
 
Method Summary
 void after(fr.cnes.genius.main.GEvent e)
          
 void attachCopyPasteMenu(String label, fr.cnes.genius.main.GComponent.CopyPasteOperation... operationList)
          
 void before(fr.cnes.genius.main.GEvent e)
          
 void clear()
          
 void display()
          
 void generic()
          
 GPFrame.GPRefFrame[] getAvailableFrames()
          Getter for the list of frames available in the widget.
 fr.cnes.genius.highLevel.GCheckBoxWithIndicator getGCheckBox()
          Getter for the CheckBox widget to select whether to apply or not the EOP correction.
 fr.cnes.genius.highLevel.GComboBoxWithLabel getGComboBox()
          Getter for the ComboBox widget to select the reference frame.
 fr.cnes.genius.highLevel.GEntryReal getGEntryRealLon()
          Getter for the GEntryReal to select the longitude for the H0-n frame.
 fr.cnes.genius.highLevel.GEntryReal getGEntryRealN()
          Getter for the GEntryReal to select the n for the H0-n frame.
 GPAbsoluteDate getGPAbsoluteDateH0()
          Getter for the GPAbsoluteDate to select the H0 for the H0-n frame.
 org.orekit.frames.Frame getPatriusObject()
          Frame getter.
 fr.cnes.genius.main.GComponent getSubComponent(int position)
          
 boolean isEnabled()
          
 boolean isH0MinusN()
          Method to check if current frame is H0-n.
 boolean isModified()
          
 Boolean isPseudoInertial()
          Checks if the GPFrame is an inertial frame.
 void read()
          
 void setAvailableFrames(GPFrame.GPRefFrame... framesToShow)
          Setter for the list of frames available in the widget.
 void setConstraint(int labelGap)
          Setter for the constraints of the widget.
 void setDefaultFrame(org.orekit.time.AbsoluteDate defaultH0, Double defaultN, Double defaultLon)
          Frame setter for the default frame being a H0-n reference frame..
 void setDefaultFrame(org.orekit.frames.Frame defaultFrame)
          Setter for the default frame.
 void setEnabled(boolean b)
          
 void setFrame(org.orekit.time.AbsoluteDate h0, Double n, Double lon)
          Frame setter.
 void setFrame(org.orekit.frames.Frame frame)
          Frame setter.
 void setSavedFrame(org.orekit.time.AbsoluteDate savedH0, Double savedN, Double savedLon)
          Frame setter for the saved frame being a H0-n reference frame.
 void setSavedFrame(org.orekit.frames.Frame savedFrame)
          Setter for the saved frame.
 void setWidgetId(String widgetId)
          
 void updateCondensedStatus(fr.cnes.genius.main.GCondensedStatus condensedStatus)
          
 void updateIsModifiedIndicator()
          
 void write()
          
 
Methods inherited from class fr.cnes.genius.lowLevel.GContainer
put
 
Methods inherited from class fr.cnes.genius.main.GComponent
activateConstraintsByType, attachCopyPasteMenu, beginOfElement, beginOfElement, beginOfElement, beginOfElement, composeWidgetId, doDisplay, endOfElement, getCommentInConfigFile, getComponent, getConstraint, getCurrentOperation, getDisplayIndicatorStatus, getDisplayIsModifiedIndicator, getElement, getGPanel, getGParent, getGUnitInConfigFile, getInnerDescendantConstraint, getName, getNameInConfigFile, getOperationSaveValue, getSimpleWidgetId, getStatus, getStringConstraint, getWidgetId, handleCopyPasteEvent, handleProcessEventException, isCopyPasteEvent, launchInvalidPositionException, parseSimpleConstraint, processGEvent, setBusyCursor, setCommentInConfigFile, setConstraint, setCopyPasteMenuEnabled, setCurrentOperation, setDataForConstraintsByType, setDisplayIsModifiedIndicator, setElement, setGPanel, setGParent, setGUnitInConfigFile, setInnerDescendantConstraint, setNameAndCommentInConfigFile, setNameInConfigFile, setStatus, setStringConstraint, setToolTipText, setWidth, writeCollection, writeCollection, writeCollection, writeCollection, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItem
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

H0_MINUS_N_NAME

public static final String H0_MINUS_N_NAME
Name for any H0-n frame internally used in GENOPUS.

See Also:
Constant Field Values
Constructor Detail

GPFrame

public GPFrame(String label)
Constructor without frame and without list of frames for the widget (all from GPFrame.GPRefFrame will be shown). The widgetId will be assigned automatically.

Parameters:
label - text to display in the label.

GPFrame

public GPFrame(String label,
               GPFrame.GPRefFrame... framesToShow)
Constructor without frame. The widgetId will be assigned automatically.

Parameters:
label - text to display in the label.
framesToShow - list of frames to show in the widget.

GPFrame

public GPFrame(String label,
               org.orekit.frames.Frame frame)
Constructor without list of frames for the widget (all from GPFrame.GPRefFrame will be shown). The widgetId will be assigned automatically.

Parameters:
label - text to display in the label.
frame - frame to show. It must be a frame available in the widget, otherwise it will throw a GRuntimeException.

GPFrame

public GPFrame(String label,
               org.orekit.frames.Frame frame,
               GPFrame.GPRefFrame... framesToShow)
Constructor. The widgetId will be assigned automatically.

Parameters:
label - text to display in the label.
frame - frame to show. It must be a frame available in the widget, otherwise it will throw a GRuntimeException.
framesToShow - list of frames to show in the widget.

GPFrame

public GPFrame(String widgetId,
               String label)
Constructor without frame and without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).

Parameters:
widgetId - widget identifier, if null an identifier will be automatically created.
label - text to display in the label.

GPFrame

public GPFrame(String widgetId,
               String label,
               GPFrame.GPRefFrame... framesToShow)
Constructor without frame.

Parameters:
widgetId - widget identifier, if null an identifier will be automatically created.
label - text to display in the label.
framesToShow - list of frames to show in the widget.

GPFrame

public GPFrame(String widgetId,
               String label,
               org.orekit.frames.Frame frame)
Constructor without list of frames for the widget (all from GPFrame.GPRefFrame will be shown).

Parameters:
widgetId - widget identifier, if null an identifier will be automatically created.
label - text to display in the label.
frame - frame to show. It must be a frame available in the widget, otherwise it will throw a GRuntimeException.

GPFrame

public GPFrame(String widgetId,
               String label,
               org.orekit.frames.Frame frame,
               GPFrame.GPRefFrame... framesToShow)
Constructor.

Parameters:
widgetId - widget identifier, if null an identifier will be automatically created.
label - text to display in the label.
frame - frame to show. It must be a frame available in the widget, otherwise it will throw a GRuntimeException.
framesToShow - list of frames to show in the widget.

GPFrame

public GPFrame(String widgetId,
               String label,
               org.orekit.time.AbsoluteDate h0,
               double n,
               double lon,
               GPFrame.GPRefFrame... framesToShow)
Specific constructor to initialize the widget with an H0-n reference frame. It is not possible to construct it just from a Frame object as the values of h0, n and lon to be shown in the widget are not obtainable from the Frame object. set to null the unneeded arguments.

Parameters:
widgetId - widget identifier, if null an identifier will be automatically created.
label - text to display in the label.
h0 - launch date for the H0-n specific frame
n - delta time for the H0-n specific frame
lon - launchpad longitude for the H0-n specific frame
framesToShow - list of frames to show in the widget.
Method Detail

setWidgetId

public void setWidgetId(String widgetId)

Overrides:
setWidgetId in class fr.cnes.genius.main.GComponent

getGComboBox

public fr.cnes.genius.highLevel.GComboBoxWithLabel getGComboBox()
Getter for the ComboBox widget to select the reference frame.

Returns:
the ComboBox widget for the reference frame.

getGCheckBox

public fr.cnes.genius.highLevel.GCheckBoxWithIndicator getGCheckBox()
Getter for the CheckBox widget to select whether to apply or not the EOP correction.

Returns:
the CheckBox widget for the application of EOP corrections.

getGPAbsoluteDateH0

public GPAbsoluteDate getGPAbsoluteDateH0()
Getter for the GPAbsoluteDate to select the H0 for the H0-n frame.

Returns:
the the GPAbsoluteDate to select the H0 for the H0-n frame.

getGEntryRealN

public fr.cnes.genius.highLevel.GEntryReal getGEntryRealN()
Getter for the GEntryReal to select the n for the H0-n frame.

Returns:
the the GEntryReal to select the n for the H0-n frame.

getGEntryRealLon

public fr.cnes.genius.highLevel.GEntryReal getGEntryRealLon()
Getter for the GEntryReal to select the longitude for the H0-n frame.

Returns:
the the GEntryReal to select the longitude for the H0-n frame.

getAvailableFrames

public GPFrame.GPRefFrame[] getAvailableFrames()
Getter for the list of frames available in the widget.

Returns:
an array of GPRefFrame with the list of frames available in the widget.

setAvailableFrames

public void setAvailableFrames(GPFrame.GPRefFrame... framesToShow)
Setter for the list of frames available in the widget. The current selected frame must be one of them. If the list of frame is null, all of them will be shown.

Parameters:
framesToShow - an array of GPRefFrame with the list of frames to show in the widget. If null: all frames will be shown.

setConstraint

public void setConstraint(int labelGap)
Setter for the constraints of the widget.

Parameters:
labelGap - left gap from panel border to display the label of the orbital parameters

getPatriusObject

public org.orekit.frames.Frame getPatriusObject()
                                         throws GPFrameException
Frame getter.

Specified by:
getPatriusObject in interface GPPatrius<org.orekit.frames.Frame>
Returns:
the current frame
Throws:
GPFrameException - if EOP data is not initialized.

setFrame

public void setFrame(org.orekit.frames.Frame frame)
              throws GPFrameException
Frame setter. Use this setter only with one of the predefined frames from Patrius Predefined.

Parameters:
frame - the frame to set
Throws:
GPFrameException - if the given frame is not available in the widget or if the frame is H0-n (use #setFrame(GPRefFrame, boolean, AbsoluteDate, double, double) in this case).

setFrame

public void setFrame(org.orekit.time.AbsoluteDate h0,
                     Double n,
                     Double lon)
              throws GPFrameException
Frame setter.

Parameters:
h0 - launch date for the H0-n specific frame
n - delta time for the H0-n specific frame
lon - launchpad longitude for the H0-n specific frame
Throws:
GPFrameException - if the frame is H0-n and H0, n or lon are null

setDefaultFrame

public void setDefaultFrame(org.orekit.frames.Frame defaultFrame)
                     throws GPFrameException
Setter for the default frame. Setter suitable only for one of the predefined frames from Patrius Predefined.

Parameters:
defaultFrame - the frame to set as default one.
Throws:
GPFrameException - if the given frame is not available in the widget or if the frame is H0-n (use #setDefaultFrame(GPRefFrame, boolean, AbsoluteDate, double, double) in this case).

setDefaultFrame

public void setDefaultFrame(org.orekit.time.AbsoluteDate defaultH0,
                            Double defaultN,
                            Double defaultLon)
                     throws GPFrameException
Frame setter for the default frame being a H0-n reference frame..

Parameters:
defaultH0 - launch date for the H0-n specific frame by default.
defaultN - delta time for the H0-n specific frame by default.
defaultLon - launchpad longitude for the H0-n specific frame by default.
Throws:
GPFrameException - if the frame is H0-n and H0, n or lon are null, or if the given frame is not available in the widget.

setSavedFrame

public void setSavedFrame(org.orekit.frames.Frame savedFrame)
                   throws GPFrameException
Setter for the saved frame. Setter suitable only for one of the predefined frames from Patrius Predefined.

Parameters:
savedFrame - the frame to set as saved one.
Throws:
GPFrameException - if the given frame is not available in the widget or if the frame is H0-n (use #setSavedFrame(GPRefFrame, boolean, AbsoluteDate, double, double) in this case).

setSavedFrame

public void setSavedFrame(org.orekit.time.AbsoluteDate savedH0,
                          Double savedN,
                          Double savedLon)
                   throws GPFrameException
Frame setter for the saved frame being a H0-n reference frame.

Parameters:
savedH0 - saved value of launch date for the H0-n specific frame.
savedN - saved value of delta time for the H0-n specific frame.
savedLon - saved value of launchpad longitude for the H0-n specific frame.
Throws:
GPFrameException - if the frame is H0-n and H0, n or lon are null, or if the given frame is not available in the widget.

attachCopyPasteMenu

public void attachCopyPasteMenu(String label,
                                fr.cnes.genius.main.GComponent.CopyPasteOperation... operationList)

Overrides:
attachCopyPasteMenu in class fr.cnes.genius.main.GComponent

updateIsModifiedIndicator

public void updateIsModifiedIndicator()

Overrides:
updateIsModifiedIndicator in class fr.cnes.genius.main.GComponent

before

public void before(fr.cnes.genius.main.GEvent e)

Specified by:
before in interface fr.cnes.genius.main.GListener

after

public void after(fr.cnes.genius.main.GEvent e)
           throws GPFrameException

Specified by:
after in interface fr.cnes.genius.main.GListener
Throws:
GPFrameException

generic

public void generic()

Specified by:
generic in class fr.cnes.genius.lowLevel.GContainer

display

public void display()
             throws fr.cnes.genius.exception.GException

Specified by:
display in interface fr.cnes.genius.main.GDisplay
Throws:
fr.cnes.genius.exception.GException

read

public void read()
          throws fr.cnes.genius.exception.GException

Specified by:
read in interface fr.cnes.genius.main.GReadWrite
Throws:
fr.cnes.genius.exception.GException

write

public void write()
           throws fr.cnes.genius.exception.GException

Specified by:
write in interface fr.cnes.genius.main.GReadWrite
Throws:
fr.cnes.genius.exception.GException

isEnabled

public boolean isEnabled()

Overrides:
isEnabled in class fr.cnes.genius.main.GComponent

setEnabled

public void setEnabled(boolean b)

Overrides:
setEnabled in class fr.cnes.genius.main.GComponent

isModified

public boolean isModified()

Overrides:
isModified in class fr.cnes.genius.main.GComponent

clear

public void clear()
           throws fr.cnes.genius.exception.GException

Specified by:
clear in interface fr.cnes.genius.main.GClear
Throws:
fr.cnes.genius.exception.GException

isH0MinusN

public boolean isH0MinusN()
Method to check if current frame is H0-n.

Returns:
true if the frame is H0-n.

isPseudoInertial

public Boolean isPseudoInertial()
Checks if the GPFrame is an inertial frame.

Returns:
true if frame is inertial

getSubComponent

public fr.cnes.genius.main.GComponent getSubComponent(int position)
                                               throws fr.cnes.genius.exception.GComponentException

Overrides:
getSubComponent in class fr.cnes.genius.main.GComponent
Throws:
fr.cnes.genius.exception.GComponentException

updateCondensedStatus

public void updateCondensedStatus(fr.cnes.genius.main.GCondensedStatus condensedStatus)

Specified by:
updateCondensedStatus in interface fr.cnes.genius.main.GCondensedStatusInterface


Copyright © 2017. All rights reserved.