Class ReportDateFieldRangePaintlet

  • All Implemented Interfaces:
    Destroyable, GlobalInfoSupporter, LoggingLevelHandler, LoggingSupporter, OptionHandler, ShallowCopySupporter<Paintlet>, SizeOfHandler, TechnicalInformationHandler, Paintlet, Serializable

    public class ReportDateFieldRangePaintlet
    extends AbstractPaintlet
    implements TechnicalInformationHandler
    Paintlet for painting a background region based on the date stored in a report.
    For more details on the date format, see:
    Javadoc. java.text.SimpleDateFormat.

    Valid options are:

    -D <int> (property: debugLevel)
        The greater the number the more additional info the scheme may output to 
        the console (0 = off).
        default: 0
        minimum: 0
     
    -stroke-thickness <float> (property: strokeThickness)
        The thickness of the stroke.
        default: 1.0
        minimum: 0.01
     
    -start <adams.data.report.Field> (property: start)
        The date field in the report to use as start of the region.
        default: 
     
    -end <adams.data.report.Field> (property: end)
        The date field in the report to use as end of the region.
        default: 
     
    -format <java.lang.String> (property: format)
        The date format to use for parsing the value stored in the report.
        default: yyyy-MM-dd HH:mm:ss
     
    -color <java.awt.Color> (property: color)
        The color to use for the background region.
        default: #c0c0c0
     
    Version:
    $Revision$
    Author:
    fracpete (fracpete at waikato dot ac dot nz)
    See Also:
    Serialized Form
    • Field Detail

      • m_Start

        protected Field m_Start
        the date field in the report (start).
      • m_End

        protected Field m_End
        the date field in the report (end).
      • m_Format

        protected String m_Format
        the date format.
      • m_Color

        protected Color m_Color
        the color to paint the point with.
      • m_DateFormat

        protected transient DateFormat m_DateFormat
        the date formatter.
    • Constructor Detail

      • ReportDateFieldRangePaintlet

        public ReportDateFieldRangePaintlet()
    • Method Detail

      • getTechnicalInformation

        public TechnicalInformation getTechnicalInformation()
        Returns an instance of a TechnicalInformation object, containing detailed information about the technical background of this class, e.g., paper reference or book this class is based on.
        Specified by:
        getTechnicalInformation in interface TechnicalInformationHandler
        Returns:
        the technical information about this class
      • setStart

        public void setStart​(Field value)
        Sets the date field in the report to use for the start of the region.
        Parameters:
        value - the date field
      • getStart

        public Field getStart()
        Returns the currently set date field in use for the start of the region.
        Returns:
        the date field
      • startTipText

        public String startTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setEnd

        public void setEnd​(Field value)
        Sets the date field in the report to use for the end of the region.
        Parameters:
        value - the date field
      • getEnd

        public Field getEnd()
        Returns the currently set date field in use for the end of the region.
        Returns:
        the date field
      • endTipText

        public String endTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setFormat

        public void setFormat​(String value)
        Sets the date format.
        Parameters:
        value - the date format
      • getFormat

        public String getFormat()
        Returns the currently set date format.
        Returns:
        the date format
      • formatTipText

        public String formatTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • setColor

        public void setColor​(Color value)
        Sets the color to paint the background with.
        Parameters:
        value - the color
      • getColor

        public Color getColor()
        Returns the currently set color to paint the background with.
        Returns:
        the color
      • colorTipText

        public String colorTipText()
        Returns the tip text for this property.
        Returns:
        tip text for this property suitable for displaying in the GUI or for listing the options.
      • getDateFormat

        protected DateFormat getDateFormat()
        Returns the formatter/parser.
        Returns:
        the formatter/parser