fr.cnes.genopus.events
Class GPTriggeredEventDetectorAbstract

java.lang.Object
  extended by fr.cnes.genius.main.GComponent
      extended by fr.cnes.genius.lowLevel.GContainer
          extended by fr.cnes.genopus.events.GPEventDetectorAbstract
              extended by fr.cnes.genopus.events.GPTriggeredEventDetectorAbstract
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<CustomEventDetector>
Direct Known Subclasses:
GPAOLDetector, GPApsideDetector, GPEclipseDetector, GPLocalTimeDetector, GPNodeDetector, GPVisibilityFromStationDetector

public abstract class GPTriggeredEventDetectorAbstract
extends GPEventDetectorAbstract

Abstract class defining the default methods to be implemented by any class defining an CustomEventDetector widget that can be triggered after a given number of ocurrences.

Author:
ffsm

Nested Class Summary
 
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
 
Fields inherited from class fr.cnes.genopus.events.GPEventDetectorAbstract
ACTION, DETECTOR_ERROR
 
Fields inherited from class fr.cnes.genius.main.GComponent
NAME_ATTRIBUTE
 
Constructor Summary
GPTriggeredEventDetectorAbstract(String widgetId, String label)
          Constructor.
 
Method Summary
 void after(fr.cnes.genius.main.GEvent e)
          
 void display()
          
 void generic()
          
 fr.cnes.genius.highLevel.GEntryInt getGEntryIntTriggerCount()
          Getter for the GEntryInt defining the count at wich the event must be triggered.
 fr.cnes.genius.main.GComponent getSubComponent(int position)
          
 boolean isModified()
          
protected  void setAbstractClassDefaultValue(CustomEventDetector customDetector)
          Set default values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.
protected  void setAbstractClassSavedValue(CustomEventDetector customDetector)
          Set saved values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.
protected  void setAbstractClassValue(CustomEventDetector customDetector)
          Set default values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.
 void setConstraint(int labelGap, int subWidgetGap)
          Setter for the constraints of the Event Detector widget.
 void setDisplayIsModifiedIndicatorAll(fr.cnes.genius.main.GComponent.DisplayIndicatorStatus displayIndicatorStatus)
          Controls the display of the isModified indicator of all sub-widgets.
 void setEnabled(boolean b)
          
 void setWidgetId(String widgetId)
          
 void updateCondensedStatus(fr.cnes.genius.main.GCondensedStatus condensedStatus)
          
 
Methods inherited from class fr.cnes.genopus.events.GPEventDetectorAbstract
attachCopyPasteMenu, blockAction, clear, getGCheckBoxExpertConfig, getGComboBoxAction, getGEntryRealMaxCheck, getGEntryRealThreshold, getGLabel, getPatriusObject, getSelectedAction, getXMLTag, isEnabled, isNativeEventDetector, read, setDefaultConstraint, setDefaultEventDetector, setDisplayAction, setDisplayExpertConfig, setEventDetector, setSavedEventDetector, updateIsModifiedIndicator, updateStatus, 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
 
Methods inherited from interface fr.cnes.genius.main.GListener
before
 

Constructor Detail

GPTriggeredEventDetectorAbstract

public GPTriggeredEventDetectorAbstract(String widgetId,
                                        String label)
Constructor.

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

setWidgetId

public void setWidgetId(String widgetId)

Overrides:
setWidgetId in class GPEventDetectorAbstract

getGEntryIntTriggerCount

public fr.cnes.genius.highLevel.GEntryInt getGEntryIntTriggerCount()
Getter for the GEntryInt defining the count at wich the event must be triggered.

Returns:
the GEntryInt defining the count at wich the event must be triggered.

setConstraint

public void setConstraint(int labelGap,
                          int subWidgetGap)
Setter for the constraints of the Event Detector widget.

Overrides:
setConstraint in class GPEventDetectorAbstract
Parameters:
labelGap - left gap from panel border to display the label of the event.
subWidgetGap - left gap from panel border to display the sub-widgets of the event.

setDisplayIsModifiedIndicatorAll

public void setDisplayIsModifiedIndicatorAll(fr.cnes.genius.main.GComponent.DisplayIndicatorStatus displayIndicatorStatus)
Controls the display of the isModified indicator of all sub-widgets.

Overrides:
setDisplayIsModifiedIndicatorAll in class GPEventDetectorAbstract
Parameters:
displayIndicatorStatus - if Always the modifiedStatusIndicator is always shown, if Never the modifiedStatusIndicator is always shown, if Automatic the modifiedStatusIndicator is shown as needed.

setEnabled

public void setEnabled(boolean b)

Overrides:
setEnabled in class GPEventDetectorAbstract

isModified

public boolean isModified()

Overrides:
isModified in class GPEventDetectorAbstract

generic

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

Overrides:
generic in class GPEventDetectorAbstract
Throws:
fr.cnes.genius.exception.GException

display

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

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

after

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

Specified by:
after in interface fr.cnes.genius.main.GListener
Overrides:
after in class GPEventDetectorAbstract
Throws:
GPEventException

setAbstractClassValue

protected void setAbstractClassValue(CustomEventDetector customDetector)
Set default values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.

Overrides:
setAbstractClassValue in class GPEventDetectorAbstract
Parameters:
customDetector - the custom detector where to extract the values to be set as default ones in the sub-widgets

setAbstractClassDefaultValue

protected void setAbstractClassDefaultValue(CustomEventDetector customDetector)
Set default values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.

Overrides:
setAbstractClassDefaultValue in class GPEventDetectorAbstract
Parameters:
customDetector - the custom detector where to extract the values to be set as default ones in the sub-widgets

setAbstractClassSavedValue

protected void setAbstractClassSavedValue(CustomEventDetector customDetector)
Set saved values for the abstract class sub-widgets from a given custom detector:
- the entry int for the triggerer.

Overrides:
setAbstractClassSavedValue in class GPEventDetectorAbstract
Parameters:
customDetector - the custom detector where to extract the values to be set as saved ones in the sub-widgets

getSubComponent

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

Overrides:
getSubComponent in class GPEventDetectorAbstract
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
Overrides:
updateCondensedStatus in class GPEventDetectorAbstract


Copyright © 2017. All rights reserved.