Class AxisEntity

  • All Implemented Interfaces:
    java.io.Serializable, java.lang.Cloneable, PublicCloneable

    public class AxisEntity
    extends ChartEntity
    A class that captures information about an Axis belonging to a chart.
    See Also:
    Serialized Form
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private Axis axis
      The axis for the entity.
      private static long serialVersionUID
      For serialization.
    • Constructor Summary

      Constructors 
      Constructor Description
      AxisEntity​(java.awt.Shape area, Axis axis)
      Creates a new axis entity.
      AxisEntity​(java.awt.Shape area, Axis axis, java.lang.String toolTipText)
      Creates a new axis entity.
      AxisEntity​(java.awt.Shape area, Axis axis, java.lang.String toolTipText, java.lang.String urlText)
      Creates a new axis entity.
    • Field Detail

      • serialVersionUID

        private static final long serialVersionUID
        For serialization.
        See Also:
        Constant Field Values
      • axis

        private final Axis axis
        The axis for the entity.
    • Constructor Detail

      • AxisEntity

        public AxisEntity​(java.awt.Shape area,
                          Axis axis)
        Creates a new axis entity.
        Parameters:
        area - the area (null not permitted).
        axis - the axis (null not permitted).
      • AxisEntity

        public AxisEntity​(java.awt.Shape area,
                          Axis axis,
                          java.lang.String toolTipText)
        Creates a new axis entity.
        Parameters:
        area - the area (null not permitted).
        axis - the axis (null not permitted).
        toolTipText - the tool tip text (null permitted).
      • AxisEntity

        public AxisEntity​(java.awt.Shape area,
                          Axis axis,
                          java.lang.String toolTipText,
                          java.lang.String urlText)
        Creates a new axis entity.
        Parameters:
        area - the area (null not permitted).
        axis - the axis (null not permitted).
        toolTipText - the tool tip text (null permitted).
        urlText - the URL text for HTML image maps (null permitted).
    • Method Detail

      • getAxis

        public Axis getAxis()
        Returns the axis that occupies the entity area.
        Returns:
        The axis (never null).
      • toString

        public java.lang.String toString()
        Returns a string representation of the chart entity, useful for debugging.
        Overrides:
        toString in class ChartEntity
        Returns:
        A string.
      • equals

        public boolean equals​(java.lang.Object obj)
        Tests the entity for equality with an arbitrary object.
        Overrides:
        equals in class ChartEntity
        Parameters:
        obj - the object to test against (null permitted).
        Returns:
        A boolean.
      • canEqual

        public boolean canEqual​(java.lang.Object other)
        Ensures symmetry between super/subclass implementations of equals. For more detail, see http://jqno.nl/equalsverifier/manual/inheritance.
        Overrides:
        canEqual in class ChartEntity
        Parameters:
        other - Object
        Returns:
        true ONLY if the parameter is THIS class type
      • hashCode

        public int hashCode()
        Returns a hash code for this instance.
        Overrides:
        hashCode in class ChartEntity
        Returns:
        A hash code.
      • clone

        public java.lang.Object clone()
                               throws java.lang.CloneNotSupportedException
        Returns a clone of the entity.
        Specified by:
        clone in interface PublicCloneable
        Overrides:
        clone in class ChartEntity
        Returns:
        A clone.
        Throws:
        java.lang.CloneNotSupportedException - if there is a problem cloning the entity.
      • writeObject

        private void writeObject​(java.io.ObjectOutputStream stream)
                          throws java.io.IOException
        Provides serialization support.
        Parameters:
        stream - the output stream.
        Throws:
        java.io.IOException - if there is an I/O error.
      • readObject

        private void readObject​(java.io.ObjectInputStream stream)
                         throws java.io.IOException,
                                java.lang.ClassNotFoundException
        Provides serialization support.
        Parameters:
        stream - the input stream.
        Throws:
        java.io.IOException - if there is an I/O error.
        java.lang.ClassNotFoundException - if there is a classpath problem.