public class GPDateOffset
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
| Index | Class | Item | Constraint |
| 0 | GLabelWithIndicator | label | 0, 0 => "newline , gapleft 0 , split 2" 0, 1 => (null) |
| 1 | GPDateOffsetField | offsetField | "split 2" |
| 2 | GPopupList | popupListUnits | (null) |
| Constructor and Description |
|---|
GPDateOffset()
Empty constructor.
|
GPDateOffset(String label)
Constructor.
|
GPDateOffset(String label,
double offset)
Constructor.
|
GPDateOffset(String widgetId,
String label)
Constructor.
|
GPDateOffset(String widgetId,
String label,
double offset)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addInterval(fr.cnes.genius.interval.GInterval interval)
Adds a validity interval to the offset value.
|
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() |
GPDateOffsetField.GPOffsetFormat |
getCurrentFormat()
Getter for the offset format.
|
fr.cnes.genius.highLevel.GLabelWithIndicator |
getGlabel()
Getter for the label of the widget.
|
fr.cnes.genius.highLevel.GPopupList |
getGPopupList()
Getter for the GPopupList defining the unit of a fractional offset.
|
fr.cnes.genius.lowLevel.GTextField |
getGTextField()
Getter for the offset field.
|
double |
getOffset()
Getter for the offset value.
|
fr.cnes.genius.main.GComponent |
getSubComponent(int position) |
boolean |
isEnabled() |
boolean |
isModified() |
void |
read() |
void |
setConstraint(int labelGap)
Setter for the constraints of the widget.
|
void |
setCurrentFormat(GPDateOffsetField.GPOffsetFormat offsetFormat)
Setter for the offset format.
|
void |
setDefaultOffset(double defaultOffset)
Setter for the default offset value in seconds.
|
void |
setEnabled(boolean b) |
void |
setOffset(double offset)
Setter for the offset value in seconds.
|
void |
setSavedOffset(double savedOffset)
Setter for the reference offset value in seconds.
|
void |
setUnit(fr.cnes.genius.unit.GUnit offsetUnit)
Setter for the offset unit.
|
void |
setValue(String stringOffset)
Set offset from string.
|
void |
setWidgetId(String widgetId) |
void |
updateIsModifiedIndicator() |
void |
write() |
activateConstraintsByType, attachCopyPasteMenu, beginOfElement, beginOfElement, beginOfElement, beginOfElement, clearAllInnerDescendantConstraint, clearConstraint, clearInnerDescendantContraint, composeWidgetId, doDisplay, endOfElement, getCommentInConfigFile, getComponent, getConstraint, getCurrentOperation, getDisplayIndicatorStatus, getDisplayIsModifiedIndicator, getElement, getGClassName, getGPanel, getGParent, getGUnitInConfigFile, getInnerDescendantConstraint, getName, getNameInConfigFile, getOperationSaveValue, getPathInConfigFile, getSimpleWidgetId, getStatus, getStringConstraint, getWidgetId, handleCopyPasteEvent, handleCopyPasteEvent, handleProcessEventException, isCopyPasteEvent, isForcedStatus, launchInvalidPositionException, mouseWheelMoved, parseSimpleConstraint, processGEvent, processMouseWheelEvent, setBusyCursor, setCommentInConfigFile, setConstraint, setCopyPasteMenuEnabled, setCurrentOperation, setDataForConstraintsByType, setDefaultConstraints, setDisplayIsModifiedIndicator, setElement, setForcedStatus, setGPanel, setGParent, setGUnitInConfigFile, setInnerDescendantConstraint, setName, setNameAndCommentInConfigFile, setNameInConfigFile, setPathInConfigFile, setStatus, setStringConstraint, setToolTipText, setWidth, setWindowBusyCursor, writeCollection, writeCollection, writeCollection, writeCollection, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItem, writeConfigItempublic GPDateOffset()
public GPDateOffset(String label)
label - text to display in the label.public GPDateOffset(String label, double offset)
label - text to display in the label.offset - date offset to set. Its absolute value must be lower than Long.MAX_VALUEpublic GPDateOffset(String widgetId, String label)
widgetId - widget identifier.label - text to display in the label.public GPDateOffset(String widgetId, String label, double offset)
widgetId - widget identifier.label - text to display in the label.offset - date offset to set. Its absolute value must be lower than Long.MAX_VALUEpublic void setWidgetId(String widgetId)
setWidgetId in class fr.cnes.genius.main.GComponentpublic fr.cnes.genius.highLevel.GLabelWithIndicator getGlabel()
public fr.cnes.genius.lowLevel.GTextField getGTextField()
public fr.cnes.genius.highLevel.GPopupList getGPopupList()
public void setOffset(double offset)
throws GPDateException,
fr.cnes.genius.exception.GArithmeticException
offset - the offset in seconds to set.GPDateException - if the absolute value of the offset in days is too high ( Long.MAX_VALUE
)fr.cnes.genius.exception.GArithmeticException - if offset is NaN.public void setUnit(fr.cnes.genius.unit.GUnit offsetUnit)
throws GPDateException
offsetUnit - format in which the offset will be shown in the widget.GPDateException - if given unit is not available in the widget.public void setValue(String stringOffset) throws GPDateException
stringOffset - string offset to set.GPDateException - if offset is in bad formatpublic GPDateOffsetField.GPOffsetFormat getCurrentFormat()
public void setCurrentFormat(GPDateOffsetField.GPOffsetFormat offsetFormat)
offsetFormat - format in which the offset will be shown in the widget.public void setConstraint(int labelGap)
labelGap - left gap from panel border to display the labelpublic fr.cnes.genius.main.GComponent getSubComponent(int position)
throws fr.cnes.genius.exception.GComponentException
getSubComponent in class fr.cnes.genius.main.GComponentfr.cnes.genius.exception.GComponentExceptionpublic void addInterval(fr.cnes.genius.interval.GInterval interval)
throws fr.cnes.genius.exception.GIntervalException
interval - real interval to add.fr.cnes.genius.exception.GIntervalException - in case the interval overlaps with an existing one.public void attachCopyPasteMenu(String label, fr.cnes.genius.main.GComponent.CopyPasteOperation... operationList)
attachCopyPasteMenu in class fr.cnes.genius.main.GComponentpublic void updateIsModifiedIndicator()
updateIsModifiedIndicator in class fr.cnes.genius.main.GComponentpublic boolean isEnabled()
isEnabled in class fr.cnes.genius.main.GComponentpublic void setEnabled(boolean b)
setEnabled in class fr.cnes.genius.main.GComponentpublic boolean isModified()
isModified in class fr.cnes.genius.main.GComponentpublic void generic()
generic in class fr.cnes.genius.lowLevel.GContainerpublic void display()
throws fr.cnes.genius.exception.GException
display in interface fr.cnes.genius.main.GDisplayfr.cnes.genius.exception.GExceptionpublic void before(fr.cnes.genius.main.GEvent e)
before in interface fr.cnes.genius.main.GListenerpublic void after(fr.cnes.genius.main.GEvent e)
throws GPDateException
after in interface fr.cnes.genius.main.GListenerGPDateExceptionpublic void read()
throws fr.cnes.genius.exception.GException
read in interface fr.cnes.genius.main.GReadWritefr.cnes.genius.exception.GExceptionpublic void write()
throws fr.cnes.genius.exception.GException
write in interface fr.cnes.genius.main.GReadWritefr.cnes.genius.exception.GExceptionpublic void clear()
clear in interface fr.cnes.genius.main.GClearpublic double getOffset()
public void setDefaultOffset(double defaultOffset)
throws GPDateException,
fr.cnes.genius.exception.GArithmeticException
defaultOffset - the default offset in seconds to set.GPDateException - if the absolute value of the defaultOffset in days is too high (
Long.MAX_VALUE )fr.cnes.genius.exception.GArithmeticException - if defaultOffset is NaN.public void setSavedOffset(double savedOffset)
throws GPDateException,
fr.cnes.genius.exception.GArithmeticException
savedOffset - the reference offset in seconds to set.GPDateException - if the absolute value of the defaultOffset in days is too high (
Long.MAX_VALUE )fr.cnes.genius.exception.GArithmeticException - if defaultOffset is NaN.Copyright © 2025. All rights reserved.