Class AbstractPixelSelectorOverlay
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.flow.transformer.pixelselector.AbstractPixelSelectorOverlay
-
- All Implemented Interfaces:
CleanUpHandler
,Destroyable
,GlobalInfoSupporter
,LoggingLevelHandler
,LoggingSupporter
,OptionHandler
,ShallowCopySupporter<AbstractPixelSelectorOverlay>
,SizeOfHandler
,ImageOverlay
,Serializable
- Direct Known Subclasses:
AbstractColorProviderPixelSelectorOverlay
,AbstractSingleColorPixelSelectorOverlay
public abstract class AbstractPixelSelectorOverlay extends AbstractOptionHandler implements ImageOverlay, ShallowCopySupporter<AbstractPixelSelectorOverlay>
Ancestor for overlays in the pixel selector GUI, making use of the data stored in the report.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected AbstractImageContainer
m_Image
the underlying image.-
Fields inherited from class adams.core.option.AbstractOptionHandler
m_OptionManager
-
Fields inherited from class adams.core.logging.LoggingObject
m_Logger, m_LoggingIsEnabled, m_LoggingLevel
-
-
Constructor Summary
Constructors Constructor Description AbstractPixelSelectorOverlay()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
cleanUp()
Cleans up data structures, frees up memory.protected abstract void
doPaintOverlay(ImagePanel.PaintPanel panel, Graphics g)
Paints the actual overlay over the image.protected abstract String
getGlobalInfo()
Returns a string describing the object.AbstractImageContainer
getImage()
Returns the underlying image.abstract Class[]
getSuggestedActions()
Returns some actions that generate data for this overlay.String
globalInfo()
Returns a string describing the object.void
overlayAdded(ImagePanel.PaintPanel panel)
Gets called when the image overlay got added to a paintable panel.void
overlayRemoved(ImagePanel.PaintPanel panel)
Gets called when the image overlay got removed from a paintable panel.void
paintOverlay(ImagePanel.PaintPanel panel, Graphics g)
Paints the overlay over the image.void
setImage(AbstractImageContainer value)
Sets the underlying image.AbstractPixelSelectorOverlay
shallowCopy()
Returns a shallow copy of itself.AbstractPixelSelectorOverlay
shallowCopy(boolean expand)
Returns a shallow copy of itself.-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, defineOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, initialize, loggingLevelTipText, newOptionManager, reset, setLoggingLevel, toCommandLine, toString
-
Methods inherited from class adams.core.logging.LoggingObject
configureLogger, getLogger, getLoggingLevel, initializeLogging, isLoggingEnabled, sizeOf
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface adams.core.Destroyable
destroy
-
Methods inherited from interface adams.gui.visualization.image.ImageOverlay
imageChanged
-
Methods inherited from interface adams.core.logging.LoggingLevelHandler
getLoggingLevel
-
Methods inherited from interface adams.core.option.OptionHandler
cleanUpOptions, defineOptions, getOptionManager, toCommandLine
-
-
-
-
Field Detail
-
m_Image
protected AbstractImageContainer m_Image
the underlying image.
-
-
Method Detail
-
globalInfo
public String globalInfo()
Returns a string describing the object.- Specified by:
globalInfo
in interfaceGlobalInfoSupporter
- Specified by:
globalInfo
in classAbstractOptionHandler
- Returns:
- a description suitable for displaying in the gui
-
getGlobalInfo
protected abstract String getGlobalInfo()
Returns a string describing the object.- Returns:
- a description suitable for displaying in the gui
-
getSuggestedActions
public abstract Class[] getSuggestedActions()
Returns some actions that generate data for this overlay.- Returns:
- the actions
-
setImage
public void setImage(AbstractImageContainer value)
Sets the underlying image.- Parameters:
value
- the image
-
getImage
public AbstractImageContainer getImage()
Returns the underlying image.- Returns:
- the image
-
doPaintOverlay
protected abstract void doPaintOverlay(ImagePanel.PaintPanel panel, Graphics g)
Paints the actual overlay over the image.- Parameters:
panel
- the panel this overlay is forg
- the graphics context
-
paintOverlay
public void paintOverlay(ImagePanel.PaintPanel panel, Graphics g)
Paints the overlay over the image.- Specified by:
paintOverlay
in interfaceImageOverlay
- Parameters:
panel
- the panel this overlay is forg
- the graphics context
-
overlayAdded
public void overlayAdded(ImagePanel.PaintPanel panel)
Gets called when the image overlay got added to a paintable panel.
Default implementation does nothing.- Specified by:
overlayAdded
in interfaceImageOverlay
- Parameters:
panel
- the panel it got added to
-
overlayRemoved
public void overlayRemoved(ImagePanel.PaintPanel panel)
Gets called when the image overlay got removed from a paintable panel.
Default implementation does nothing.- Specified by:
overlayRemoved
in interfaceImageOverlay
- Parameters:
panel
- the panel it got removed from
-
shallowCopy
public AbstractPixelSelectorOverlay shallowCopy()
Returns a shallow copy of itself.- Specified by:
shallowCopy
in interfaceShallowCopySupporter<AbstractPixelSelectorOverlay>
- Returns:
- the shallow copy
-
shallowCopy
public AbstractPixelSelectorOverlay shallowCopy(boolean expand)
Returns a shallow copy of itself.- Specified by:
shallowCopy
in interfaceShallowCopySupporter<AbstractPixelSelectorOverlay>
- Parameters:
expand
- whether to expand variables to their current values- Returns:
- the shallow copy
-
cleanUp
public void cleanUp()
Cleans up data structures, frees up memory.- Specified by:
cleanUp
in interfaceCleanUpHandler
-
-