GeneralPath class represents a geometric path
constructed from straight lines, and quadratic and cubic
(Bézier) curves. It can contain multiple subpaths.
GeneralPath is a legacy final class which exactly
implements the behavior of its superclass Path2D..
Together with Path2D., the Path2D classes
provide full implementations of a general geometric path that
support all of the functionality of the Shape and
PathIterator interfaces with the ability to explicitly
select different levels of internal coordinate precision.
Use Path2D.Float (or this legacy GeneralPath
subclass) when dealing with data that can be represented
and used with floating point precision. Use Path2D.Double
for data that requires the accuracy or range of double precision.
| Modifier and Type | Field and Description |
|---|---|
| private static final long | serialVersionUID
Use serialVersionUID from JDK 1.6 for interoperability.
|
| Access | Constructor and Description |
|---|---|
| public | GeneralPath()
Constructs a new empty single precision |
| public | GeneralPath(int
the winding rule rule)Constructs a new |
| public | GeneralPath(int
the winding rule rule, int the estimate for the number of path segments
in the path initialCapacity)Constructs a new |
| public | GeneralPath(Shape
the specified s)Shape objectConstructs a new |
| pack-priv |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID Hides java. Use serialVersionUID from JDK 1.6 for interoperability. | |
| GeneralPath | back to summary |
|---|---|
| public GeneralPath() Constructs a new empty single precision
| |
| GeneralPath | back to summary |
|---|---|
| public GeneralPath(int rule) Constructs a new
| |
| GeneralPath | back to summary |
|---|---|
| public GeneralPath(int rule, int initialCapacity) Constructs a new
| |
| GeneralPath | back to summary |
|---|---|
| public GeneralPath(Shape s) Constructs a new
| |
| GeneralPath | back to summary |
|---|---|
| pack-priv GeneralPath(int windingRule, byte[] pointTypes, int numTypes, float[] pointCoords, int numCoords) | |