Package quadbase.util

Class PolyLine

java.lang.Object
quadbase.util.PolyLine

public class PolyLine extends Object
This class contains methods for modifying the properties of a chart poly-line. A poly-line is a set of connected line segments.
See Also:
  • Constructor Details

    • PolyLine

      public PolyLine()
    • PolyLine

      public PolyLine(PolyLine p)
      Copy Constructor.
      Parameters:
      p - The input PolyLine object.
  • Method Details

    • getColor

      public final Color getColor()
      Returns the color of the poly-line.
      Returns:
      The Color object.
    • setColor

      public final void setColor(Color c)
      Sets the color of the poly-line.
      Parameters:
      c - The Color object.
    • isFillArea

      public final boolean isFillArea()
      Returns whether the poly-line is filled.
      Returns:
      The state.
    • setFillArea

      public final void setFillArea(boolean state)
      Sets whether the poly-line is filled.
      Parameters:
      state - The new state.
    • getThickness

      public final int getThickness()
      Returns the thickness of the poly-line.
      Returns:
      The thickness.
    • setThickness

      public final void setThickness(int t)
      Sets the thickness of the poly-line.
      Parameters:
      t - The thickness.
    • getLineStyle

      public final int getLineStyle()
      Returns the line style of the poly-line.
      Returns:
      The line style.
    • setLineStyle

      public final void setLineStyle(int s)
      Sets the line style of the poly-line.
      Parameters:
      s - The line style.
    • isArrowAtStartPointVisible

      public final boolean isArrowAtStartPointVisible()
      Returns whether the arrow at start point of poly-line is visible.
      Returns:
      The state.
    • setArrowAtStartPointVisible

      public final void setArrowAtStartPointVisible(boolean state)
      Sets whether the arrow at start point of poly-line is visible.
      Parameters:
      state - The new state.
    • isArrowAtEndPointVisible

      public final boolean isArrowAtEndPointVisible()
      Returns whether the arrow at end point of poly-line is visible.
      Returns:
      The state.
    • setArrowAtEndPointVisible

      public final void setArrowAtEndPointVisible(boolean state)
      Sets whether the arrow at end point of poly-line is visible.
      Parameters:
      state - The new state.
    • elements

      public final Enumeration elements()
      Returns the list of all coordinates that define the poly-line. Each object in the list is of type quadbase.util.Point_3D / Point_2D.
      Returns:
      The Enumeration object containing the coordinates of the poly-line.
      See Also:
    • set

      public final void set(Enumeration e, Color c)
      Defines the coordinates for the poly-line.
      Parameters:
      e - The list of Point_3D objects that define the poly-line. / The list of Point_2D objects which relative to the canvas (0.0 to 1.0, Lower-left corner is 0.0).
      c - The color of the poly-line.
      See Also:
    • set

      public final void set(Enumeration e, Color color, int thickness, int style, boolean fillArea, boolean startArrow, boolean endArrow)
      Defines the coordinates for the poly-line.
      Parameters:
      e - The list of Point_3D objects that define the poly-line. / The list of Point_2D objects which relative to the canvas (0.0 to 1.0, Lower-left corner is 0.0).
      color - The color of the poly-line.
      thickness - The thickness of the poly-line.
      style - The line style of the poly-line.
      fillArea - The state of fill area.
      startArrow - The state of start arrow.
      endArrow - The state of end arrow.
      See Also:
    • getPoints

      public final Vector getPoints()
      Returns a Vector containing all the Point_3D / Point_2D objects that define the poly-line.
      Returns:
      The coordinates of the poly-line in a Vector.
    • write

      public final void write(DataOutput out) throws IOException
      Created for internal use only
      Throws:
      IOException
    • read

      public static PolyLine read(DataInput in, int version) throws IOException
      Created for internal use only
      Throws:
      IOException