Class Overview
A comparator for shapes that orders them by increasing z-index, or for
identical z-indices, orders them by increasing insertion time (i.e., newer
shapes are after older shapes).
Summary
[Expand]
Inherited Methods |
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
|
From interface
java.util.Comparator
abstract
int
|
compare(T arg0, T arg1)
|
abstract
boolean
|
equals(Object arg0)
|
|
Public Constructors
public
ZIndexComparator
()
Public Methods
Protected Methods
protected
int
compareTimestamps
(Shape shape1, Shape shape2)
Compare the insertion times of two shapes.
Parameters
shape1 |
The first shape. |
shape2 |
The second shape. |
Returns
- -1 if shape1 was added to the ShapeSet before shape2,
0 if they were added at the same time, or 1 if shape2
was added before shape1.