public class MutablePath extends AbstractShape
This shape has the notion of several distinct paths where each path begins with a separator moveoTo() instruction. There are some methods that treat this object as one long string of segments, and some methods that recognize that you can access each path separately.
Several methods here match the signatures of GeneralPath methods for convenience. Internally field and methods are made private/final because of the thorough verification that happens as you manipulate this object: subclasses shouldn't let you position anything other than a SEG_MOVETO after a SEG_CLOSE, for example.
| Constructor and Description |
|---|
MutablePath()
|
MutablePath(Shape
|
| Modifier and Type | Method and Description |
|---|---|
void |
append(Shape
|
void |
append(Shape
|
void |
close()
|
void |
close(int pathIndex)
|
void |
curveTo(double cx0, double cy0, double cx1, double cy1, double x, double y)
|
void |
curveTo(int pathIndex, double cx0, double cy0, double cx1, double cy1, double x, double y)
|
void |
delete(int pathIndex, int segmentIndex)
|
int |
getPathCount()
|
PathIterator |
getPathIterator(AffineTransform
|
int |
getSegment(int index, double[] coords)
|
int |
getSegment(int index, float[] coords)
|
int |
getSegment(int pathIndex, int segmentIndex, double[] coords)
|
int |
getSegment(int pathIndex, int segmentIndex, float[] coords)
|
int |
getSegmentCount()
|
int |
getSegmentCount(int pathIndex)
|
int |
getSegmentType(int index)
|
int |
getSegmentType(int pathIndex, int segmentIndex)
|
int |
getWindingRule()
|
boolean |
isEmpty()
|
void |
lineTo(double x, double y)
|
void |
lineTo(int pathIndex, double x, double y)
|
int |
moveTo(double x, double y)
|
protected com |
peek(int pathIndex)
|
void |
quadTo(double cx, double cy, double x, double y)
|
void |
quadTo(int pathIndex, double cx, double cy, double x, double y)
|
protected void |
releaseIterators()
|
void |
reset()
|
boolean |
setSegment(int index, int type, double[] coords)
Redefine a segment.
|
boolean |
setSegment(int index, int type, float[] coords)
Redefine a segment.
|
boolean |
setSegment(int pathIndex, int segmentIndex, int type, double[] coords)
|
void |
setWindingRule(int newRule)
|
void |
transform(AffineTransform
|
contains, contains, contains, contains, contains, contains, contains, contains, countCrossings, getBounds, getBounds, getBounds, getBounds2D, getBounds2D, getPathIterator, identifyCrossings, intersects, intersects, intersectspublic MutablePath(Shapes)
public MutablePath()
public void setWindingRule(int newRule)
protected com.bric .geom .MutablePathSegment peek(int pathIndex)
public void close()
public void close(int pathIndex)
public int moveTo(double x,
double y)
x -
y -
public void lineTo(double x,
double y)public void lineTo(int pathIndex,
double x,
double y)public void quadTo(double cx,
double cy,
double x,
double y)public void quadTo(int pathIndex,
double cx,
double cy,
double x,
double y)public void curveTo(double cx0,
double cy0,
double cx1,
double cy1,
double x,
double y)public void curveTo(int pathIndex,
double cx0,
double cy0,
double cx1,
double cy1,
double x,
double y)public void delete(int pathIndex,
int segmentIndex)public void append(Shapes)
public void append(Shapes, AffineTransform transform)
protected void releaseIterators()
public int getPathCount()
public int getSegmentCount(int pathIndex)
public int getSegmentCount()
public int getSegment(int pathIndex,
int segmentIndex,
double[] coords)public int getSegment(int pathIndex,
int segmentIndex,
float[] coords)public int getSegment(int index,
double[] coords)public int getSegmentType(int pathIndex,
int segmentIndex)public int getSegmentType(int index)
public int getSegment(int index,
float[] coords)public boolean setSegment(int pathIndex,
int segmentIndex,
int type,
double[] coords)public boolean setSegment(int index,
int type,
double[] coords)
index -
type -
coords -
public boolean setSegment(int index,
int type,
float[] coords)
index -
type -
coords -
public boolean isEmpty()
public void transform(AffineTransformtransform)
public void reset()
public int getWindingRule()
public PathIteratorgetPathIterator(AffineTransform at)