JClass DesktopViews 6.3.0 API
Documentation

com.klg.jclass.chart3d
Class ContourCell

java.lang.Object
  |
  +--com.klg.jclass.chart3d.ContourCell
All Implemented Interfaces:
Comparator, Serializable

public class ContourCell
extends Object
implements Comparator, Serializable

Data structure internal to JClass Chart 3D. Stores contour information on a per cell basis.

See Also:
Serialized Form

Field Summary
protected  ArrayList[] corners
          A contour intersection list for each corner of the cell.
protected  boolean hole
          Does this cell correspond to a hole?
protected  com.klg.jclass.chart3d.Intersection newIntersection
          A place to temporarily store new Intersections.
protected  int nIntersections
          The number of contour intersections for this cell.
protected  ArrayList side
          A contour intersection list for the side of the cell (either vertical or horizontal, it can't be both).
static int SIDE
           
 
Method Summary
protected  void addIntersection(com.klg.jclass.chart3d.Intersection intersection, int place)
          Adds an intersection to one of the four corner lists or the side list.
 int compare(Object o1, Object o2)
          Generic segment sorting routine, for all four corners, and sides (left-to-right or top-to-bottom).
 ArrayList getIntersectionList(int place)
           
protected  com.klg.jclass.chart3d.Intersection getNewIntersection()
          Gets the newest intersection (possibly still under construction).
 int getNIntersections()
          Retrieves the number of contour intersections for this cell.
protected  boolean isHole()
          Does this cell correspond to a hole?
protected  void setHole(boolean hole)
          Sets whether this cell corresponds to a hole or not.
protected  void setNewIntersection(com.klg.jclass.chart3d.Intersection newIntersection)
          Sets the newest intersection.
protected  void sortIntersectionLists()
          Sorts the contour intersection lists of each of the four corners and the side list.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface java.util.Comparator
equals
 

Field Detail

SIDE

public static final int SIDE
See Also:
Constant Field Values

hole

protected boolean hole
Does this cell correspond to a hole?


nIntersections

protected int nIntersections
The number of contour intersections for this cell.


corners

protected ArrayList[] corners
A contour intersection list for each corner of the cell.


side

protected ArrayList side
A contour intersection list for the side of the cell (either vertical or horizontal, it can't be both).


newIntersection

protected com.klg.jclass.chart3d.Intersection newIntersection
A place to temporarily store new Intersections.

Method Detail

setHole

protected void setHole(boolean hole)
Sets whether this cell corresponds to a hole or not.

Parameters:
hole -

isHole

protected boolean isHole()
Does this cell correspond to a hole?


addIntersection

protected void addIntersection(com.klg.jclass.chart3d.Intersection intersection,
                               int place)
Adds an intersection to one of the four corner lists or the side list.

Parameters:
intersection -
place -

getNIntersections

public int getNIntersections()
Retrieves the number of contour intersections for this cell.


getNewIntersection

protected com.klg.jclass.chart3d.Intersection getNewIntersection()
Gets the newest intersection (possibly still under construction).


setNewIntersection

protected void setNewIntersection(com.klg.jclass.chart3d.Intersection newIntersection)
Sets the newest intersection.

Parameters:
newIntersection -

getIntersectionList

public ArrayList getIntersectionList(int place)
Parameters:
place -

sortIntersectionLists

protected void sortIntersectionLists()
Sorts the contour intersection lists of each of the four corners and the side list.


compare

public int compare(Object o1,
                   Object o2)
Generic segment sorting routine, for all four corners, and sides (left-to-right or top-to-bottom). Each of these has a list of intersections that need to be sorted. We know that all edges have the same side1 and side2, so the sorting is easy.

Specified by:
compare in interface Comparator
Parameters:
o1 -
o2 -

Copyright © 2004 Quest Software Inc..
All rights reserved.