Class AutoAnnotateXYPlot.TransparentCrosshairState

  • Direct Known Subclasses:
    AutoAnnotateXYPlot.MultiCrosshairState
    Enclosing class:
    AutoAnnotateXYPlot

    public class AutoAnnotateXYPlot.TransparentCrosshairState
    extends org.jfree.chart.plot.CrosshairState
    This is an example of object oriented programming gone bad!! CrosshairState has no accessors for its private data variables which I need, hence this ridiculous copy-paste job, overriding everything.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.awt.geom.Point2D anchor
      The anchor point in Java2D space - if null, don't update crosshair.
      protected double anchorX
      The x-value (in data space) for the anchor point.
      protected double anchorY
      The y-value (in data space) for the anchor point.
      protected double crosshairX
      The x-value for the crosshair point.
      protected double crosshairY
      The y-value for the crosshair point.
      protected double distance
      The smallest distance so far between the anchor point and a data point.
    • Method Summary

      All Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      double getCrosshairX()  
      double getCrosshairY()  
      double getDistance()  
      void setAnchor​(java.awt.geom.Point2D anchor)  
      void setCrosshairDistance​(double distance)  
      void setCrosshairX​(double x)  
      void setCrosshairY​(double y)  
      java.lang.String toString()  
      void updateCrosshairPoint​(double x, double y, double transX, double transY, org.jfree.chart.plot.PlotOrientation orientation)
      Deprecated.
      void updateCrosshairPoint​(double x, double y, int domainAxisIndex, int rangeAxisIndex, double transX, double transY, org.jfree.chart.plot.PlotOrientation orientation)  
      void updateCrosshairX​(double candidateX)
      Deprecated.
      void updateCrosshairX​(double candidateX, int axis)  
      void updateCrosshairY​(double candidateY)
      Deprecated.
      void updateCrosshairY​(double candidateY, int axis)  
      • Methods inherited from class org.jfree.chart.plot.CrosshairState

        getAnchor, getAnchorX, getAnchorY, getCrosshairDistance, getDatasetIndex, getDomainAxisIndex, getRangeAxisIndex, setAnchorX, setAnchorY, setDatasetIndex
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • anchorX

        protected double anchorX
        The x-value (in data space) for the anchor point.
      • anchorY

        protected double anchorY
        The y-value (in data space) for the anchor point.
      • anchor

        protected java.awt.geom.Point2D anchor
        The anchor point in Java2D space - if null, don't update crosshair.
      • crosshairX

        protected double crosshairX
        The x-value for the crosshair point.
      • crosshairY

        protected double crosshairY
        The y-value for the crosshair point.
      • distance

        protected double distance
        The smallest distance so far between the anchor point and a data point.
    • Constructor Detail

      • TransparentCrosshairState

        public TransparentCrosshairState()
    • Method Detail

      • setCrosshairDistance

        public void setCrosshairDistance​(double distance)
        Overrides:
        setCrosshairDistance in class org.jfree.chart.plot.CrosshairState
      • updateCrosshairPoint

        @Deprecated
        public void updateCrosshairPoint​(double x,
                                         double y,
                                         double transX,
                                         double transY,
                                         org.jfree.chart.plot.PlotOrientation orientation)
        Deprecated.
        Overrides:
        updateCrosshairPoint in class org.jfree.chart.plot.CrosshairState
      • updateCrosshairPoint

        public void updateCrosshairPoint​(double x,
                                         double y,
                                         int domainAxisIndex,
                                         int rangeAxisIndex,
                                         double transX,
                                         double transY,
                                         org.jfree.chart.plot.PlotOrientation orientation)
        Overrides:
        updateCrosshairPoint in class org.jfree.chart.plot.CrosshairState
        Parameters:
        x - the x value of the item being rendered in data space
        y - the y value of the item being rendered in data space
        transX - The domain value, in j2d space.
        transY - The range value in j2d space.
      • updateCrosshairX

        @Deprecated
        public void updateCrosshairX​(double candidateX)
        Deprecated.
        Overrides:
        updateCrosshairX in class org.jfree.chart.plot.CrosshairState
      • updateCrosshairX

        public void updateCrosshairX​(double candidateX,
                                     int axis)
        Overrides:
        updateCrosshairX in class org.jfree.chart.plot.CrosshairState
      • updateCrosshairY

        @Deprecated
        public void updateCrosshairY​(double candidateY)
        Deprecated.
        Overrides:
        updateCrosshairY in class org.jfree.chart.plot.CrosshairState
      • updateCrosshairY

        public void updateCrosshairY​(double candidateY,
                                     int axis)
        Overrides:
        updateCrosshairY in class org.jfree.chart.plot.CrosshairState
      • setAnchor

        public void setAnchor​(java.awt.geom.Point2D anchor)
        Overrides:
        setAnchor in class org.jfree.chart.plot.CrosshairState
      • getCrosshairX

        public double getCrosshairX()
        Overrides:
        getCrosshairX in class org.jfree.chart.plot.CrosshairState
      • setCrosshairX

        public void setCrosshairX​(double x)
        Overrides:
        setCrosshairX in class org.jfree.chart.plot.CrosshairState
      • getCrosshairY

        public double getCrosshairY()
        Overrides:
        getCrosshairY in class org.jfree.chart.plot.CrosshairState
      • setCrosshairY

        public void setCrosshairY​(double y)
        Overrides:
        setCrosshairY in class org.jfree.chart.plot.CrosshairState
      • getDistance

        public double getDistance()
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object