public final class CoordinateArraySequenceFactory extends java.lang.Object implements CoordinateSequenceFactory, java.io.Serializable
CoordinateSequences represented as an array of Coordinates.| Modifier and Type | Field and Description |
|---|---|
private static CoordinateArraySequenceFactory |
instanceObject |
private static long |
serialVersionUID |
| Modifier | Constructor and Description |
|---|---|
private |
CoordinateArraySequenceFactory() |
| Modifier and Type | Method and Description |
|---|---|
CoordinateSequence |
create(Coordinate[] coordinates)
Returns a
CoordinateArraySequence based on the given array (the array is
not copied). |
CoordinateSequence |
create(CoordinateSequence coordSeq)
Creates a
CoordinateSequence which is a copy
of the given CoordinateSequence. |
CoordinateSequence |
create(int size,
int dimension)
The created sequence dimension is clamped to be <= 3.
|
static CoordinateArraySequenceFactory |
instance()
Returns the singleton instance of
CoordinateArraySequenceFactory |
private java.lang.Object |
readResolve() |
private static final long serialVersionUID
private static final CoordinateArraySequenceFactory instanceObject
private java.lang.Object readResolve()
public static CoordinateArraySequenceFactory instance()
CoordinateArraySequenceFactorypublic CoordinateSequence create(Coordinate[] coordinates)
CoordinateArraySequence based on the given array (the array is
not copied).create in interface CoordinateSequenceFactorycoordinates - the coordinates, which may not be null nor contain null
elementspublic CoordinateSequence create(CoordinateSequence coordSeq)
CoordinateSequenceFactoryCoordinateSequence which is a copy
of the given CoordinateSequence.
This method must handle null arguments by creating an empty sequence.create in interface CoordinateSequenceFactorycoordSeq - the coordinate sequence to copyCoordinateSequenceFactory.create(org.locationtech.jts.geom.CoordinateSequence)public CoordinateSequence create(int size, int dimension)
create in interface CoordinateSequenceFactorysize - the number of coordinates in the sequencedimension - the dimension of the coordinates in the sequence (if user-specifiable,
otherwise ignored)CoordinateSequenceFactory.create(int, int)