public static class PackedCoordinateSequence.Float extends PackedCoordinateSequence
PackedCoordinateSequence.Double, PackedCoordinateSequence.Float
M, X, Y, Z
Constructor and Description |
---|
Float(Coordinate[] coordinates,
int dimension)
Builds a new packed coordinate sequence out of a coordinate array
|
Float(Coordinate[] coordinates,
int dimension,
int measures)
Constructs a packed coordinate sequence out of a coordinate array
|
Float(double[] coords,
int dimension,
int measures)
Constructs a packed coordinate sequence from an array of
double s |
Float(float[] coords,
int dimension,
int measures)
Constructs a packed coordinate sequence from an array of
float s |
Float(int size,
int dimension,
int measures)
Constructs an empty packed coordinate sequence of a given size and dimension
|
Modifier and Type | Method and Description |
---|---|
Object |
clone()
Deprecated.
|
PackedCoordinateSequence.Float |
copy()
Returns a deep copy of this collection.
|
Envelope |
expandEnvelope(Envelope env)
Expands the given
Envelope to include the coordinates in the sequence. |
Coordinate |
getCoordinateInternal(int i)
Returns a Coordinate representation of the specified coordinate, by always
building a new Coordinate object
|
double |
getOrdinate(int index,
int ordinate)
Returns the ordinate of a coordinate in this sequence.
|
float[] |
getRawCoordinates()
Gets the underlying array containing the coordinate values.
|
void |
setOrdinate(int index,
int ordinate,
double value)
Sets the ordinate of a coordinate in this sequence.
|
int |
size()
Returns the number of coordinates in this sequence.
|
getCoordinate, getCoordinate, getCoordinateCopy, getDimension, getMeasures, getX, getY, setX, setY, toCoordinateArray, toString
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
createCoordinate, getM, getZ, hasM, hasZ
public Float(float[] coords, int dimension, int measures)
float
scoords
- an array of float
values that contains the ordinate values of the sequencedimension
- the total number of ordinates that make up a Coordinate
in this sequence.measures
- the number of measure-ordinates each Coordinate
in this sequence has.public Float(double[] coords, int dimension, int measures)
double
scoords
- an array of double
values that contains the ordinate values of the sequencedimension
- the total number of ordinates that make up a Coordinate
in this sequence.measures
- the number of measure-ordinates each Coordinate
in this sequence has.public Float(Coordinate[] coordinates, int dimension)
coordinates
- an array of Coordinate
sdimension
- the total number of ordinates that make up a Coordinate
in this sequence.public Float(Coordinate[] coordinates, int dimension, int measures)
coordinates
- an array of Coordinate
sdimension
- the total number of ordinates that make up a Coordinate
in this sequence.measures
- the number of measure-ordinates each Coordinate
in this sequence has.public Float(int size, int dimension, int measures)
size
- the number of coordinates in this sequencedimension
- the total number of ordinates that make up a Coordinate
in this sequence.measures
- the number of measure-ordinates each Coordinate
in this sequence has.public Coordinate getCoordinateInternal(int i)
PackedCoordinateSequence
i
- the coordinate indexCoordinate
at the given indexPackedCoordinateSequence.getCoordinate(int)
public float[] getRawCoordinates()
public int size()
CoordinateSequence
CoordinateSequence.size()
public Object clone()
CoordinateSequence
clone
in interface CoordinateSequence
clone
in class PackedCoordinateSequence
Object.clone()
,
PackedCoordinateSequence.clone()
public PackedCoordinateSequence.Float copy()
CoordinateSequence
copy
in interface CoordinateSequence
copy
in class PackedCoordinateSequence
PackedCoordinateSequence.copy()
public double getOrdinate(int index, int ordinate)
CoordinateSequence
Ordinates indices greater than 1 have user-defined semantics
(for instance, they may contain other dimensions or measure
values as described by CoordinateSequence.getDimension()
and CoordinateSequence.getMeasures()
).
getOrdinate
in interface CoordinateSequence
getOrdinate
in class PackedCoordinateSequence
index
- the coordinate index in the sequenceordinate
- the ordinate index in the coordinate (in range [0, dimension-1])For performance reasons the ordinate index is not checked.
If it is larger than the dimension a meaningless
value may be returned.
public void setOrdinate(int index, int ordinate, double value)
PackedCoordinateSequence
setOrdinate
in interface CoordinateSequence
setOrdinate
in class PackedCoordinateSequence
index
- the coordinate indexordinate
- the ordinate index in the coordinate, 0 based, smaller than the
number of dimensionsvalue
- the new ordinate valuePackedCoordinateSequence.setOrdinate(int, int, double)
public Envelope expandEnvelope(Envelope env)
CoordinateSequence
Envelope
to include the coordinates in the sequence.
Allows implementing classes to optimize access to coordinate values.env
- the envelope to expandCoordinateSequence.expandEnvelope(Envelope)
Copyright © 2024. All rights reserved.