Class AbstractRectangleBasedAnnotator
- java.lang.Object
-
- adams.core.logging.LoggingObject
-
- adams.core.logging.CustomLoggingLevelObject
-
- adams.core.option.AbstractOptionHandler
-
- adams.gui.visualization.object.annotator.AbstractAnnotator
-
- adams.gui.visualization.object.annotator.AbstractReportBasedAnnotator
-
- adams.gui.visualization.object.annotator.AbstractRectangleBasedAnnotator
-
- All Implemented Interfaces:
CleanUpHandler,Destroyable,GlobalInfoSupporter,LoggingLevelHandler,LoggingSupporter,OptionHandler,SizeOfHandler,ObjectPrefixHandler,Serializable
- Direct Known Subclasses:
BoundingBoxAnnotator,PolygonAnnotator,PolygonPointAnnotator
public abstract class AbstractRectangleBasedAnnotator extends AbstractReportBasedAnnotator
Annotators that use a rectangle based approach.- Author:
- FracPete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected List<SelectionRectangle>m_Locationsthe current rectangles.protected intm_NumDigitsthe number of digits to use for left-padding the index.-
Fields inherited from class adams.gui.visualization.object.annotator.AbstractReportBasedAnnotator
m_Prefix
-
Fields inherited from class adams.gui.visualization.object.annotator.AbstractAnnotator
m_Owner, m_Selecting
-
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 AbstractRectangleBasedAnnotator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidannotationsChanged()Hook method for when annotations change.voiddefineOptions()Adds options to the internal list of options.protected intgetDefaultNumDigits()Returns the default number of digits to use.protected StringgetDefaultPrefix()Returns the default prefix to use for the objects.protected List<SelectionRectangle>getLocations(Report report)Returns all currently stored locations.intgetNumDigits()Returns the number of digits to use for the left-padded index.StringnumDigitsTipText()Returns the tip text for this property.protected voidreset()Resets the scheme.voidsetNumDigits(int value)Sets the number of digits to use for the left-padded index.-
Methods inherited from class adams.gui.visualization.object.annotator.AbstractReportBasedAnnotator
findLastIndex, getPrefix, prefixTipText, removeIndex, setPrefix, valuesForIndex
-
Methods inherited from class adams.gui.visualization.object.annotator.AbstractAnnotator
applyStroke, cleanUp, doInstall, doPaintSelection, doUninstall, getCurrentLabel, getOwner, getStrokeWidth, hasCurrentLabel, initialize, install, labelChanged, paintSelection, setOwner, uninstall
-
Methods inherited from class adams.core.option.AbstractOptionHandler
cleanUpOptions, destroy, finishInit, getDefaultLoggingLevel, getOptionManager, globalInfo, loggingLevelTipText, newOptionManager, 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.logging.LoggingLevelHandler
getLoggingLevel
-
-
-
-
Field Detail
-
m_NumDigits
protected int m_NumDigits
the number of digits to use for left-padding the index.
-
m_Locations
protected List<SelectionRectangle> m_Locations
the current rectangles.
-
-
Method Detail
-
defineOptions
public void defineOptions()
Adds options to the internal list of options.- Specified by:
defineOptionsin interfaceOptionHandler- Overrides:
defineOptionsin classAbstractReportBasedAnnotator
-
reset
protected void reset()
Resets the scheme.- Overrides:
resetin classAbstractOptionHandler
-
getDefaultPrefix
protected String getDefaultPrefix()
Returns the default prefix to use for the objects.- Specified by:
getDefaultPrefixin classAbstractReportBasedAnnotator- Returns:
- the default
-
getDefaultNumDigits
protected int getDefaultNumDigits()
Returns the default number of digits to use.- Returns:
- the default
-
setNumDigits
public void setNumDigits(int value)
Sets the number of digits to use for the left-padded index.- Parameters:
value- the number of digits
-
getNumDigits
public int getNumDigits()
Returns the number of digits to use for the left-padded index.- Returns:
- the number of digits
-
numDigitsTipText
public String numDigitsTipText()
Returns the tip text for this property.- Returns:
- tip text for this property suitable for displaying in the GUI or for listing the options.
-
annotationsChanged
public void annotationsChanged()
Hook method for when annotations change.- Overrides:
annotationsChangedin classAbstractAnnotator
-
getLocations
protected List<SelectionRectangle> getLocations(Report report)
Returns all currently stored locations.- Parameters:
report- the report to get the locations from- Returns:
- the locations
-
-