Class CartesianVectorCoordSet
- java.lang.Object
-
- uk.ac.starlink.ttools.plot2.layer.CartesianVectorCoordSet
-
- All Implemented Interfaces:
MultiPointCoordSet
public class CartesianVectorCoordSet extends java.lang.Object implements MultiPointCoordSet
MultiPointCoordSet for vectors in Cartesian data coordinates.- Since:
- 18 Feb 2013
- Author:
- Mark Taylor
-
-
Constructor Summary
Constructors Constructor Description CartesianVectorCoordSet(java.lang.String[] axisNames)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Coord[]
getCoords()
Returns the coordinate definitions.int
getPointCount()
Returns the number of (non-central) data positions defined by this coord set.boolean
readPoints(Tuple tuple, int icol, DataGeom geom, double[] xy0, double[][] xyExtras)
Reads the non-central points from a appropriate span of columns in a supplied tuple.
-
-
-
Method Detail
-
getCoords
public Coord[] getCoords()
Description copied from interface:MultiPointCoordSet
Returns the coordinate definitions.- Specified by:
getCoords
in interfaceMultiPointCoordSet
- Returns:
- coords
-
getPointCount
public int getPointCount()
Description copied from interface:MultiPointCoordSet
Returns the number of (non-central) data positions defined by this coord set.- Specified by:
getPointCount
in interfaceMultiPointCoordSet
- Returns:
- data position count
-
readPoints
public boolean readPoints(Tuple tuple, int icol, DataGeom geom, double[] xy0, double[][] xyExtras)
Description copied from interface:MultiPointCoordSet
Reads the non-central points from a appropriate span of columns in a supplied tuple. The central data position must be supplied as input. Theicol
value gives the column corresponding to the first coord of this coordinate set in the sequence; the following few columns are assumed to correspod 1:1 to the coords in this coord set.- Specified by:
readPoints
in interfaceMultiPointCoordSet
- Parameters:
tuple
- tupleicol
- index of tuple field corresponding to the first of the coordinates in this setgeom
- converter between tuple values and data space coordinates; may not be requiredxy0
- nDataDim-element array giving central data positionxyExtras
- [nPointCount][nDataDim]-shaped array into which the non-central data positions will be written- Returns:
- true iff the conversion was successful
-
-