public class CoordDoubleString extends java.lang.Object implements CoordTupleString
Constructor and Description |
---|
CoordDoubleString(int tuplecount,
int tuplesize,
BinaryFile input)
Construct a CoordDoubleString from a file input
|
Modifier and Type | Method and Description |
---|---|
double[] |
getasDouble(int tuple)
Get a tuple
|
double |
getasDouble(int tuple,
int val)
Get a value in a tuple
|
float[] |
getasFloat(int tuple)
Get a tuple
|
float |
getasFloat(int tuple,
int val)
Get a value in a tuple
|
java.lang.Number |
getPrimitiveType()
Accessor for the underlying primitive type
|
double |
getXasDouble(int tuple)
Get the first value of a tuple
|
float |
getXasFloat(int tuple)
Get the first value of a tuple
|
double |
getYasDouble(int tuple)
Get the second value of a tuple
|
float |
getYasFloat(int tuple)
Get the second value of a tuple
|
double |
getZasDouble(int tuple)
Get the third value of a tuple
|
float |
getZasFloat(int tuple)
Get the third value of a tuple
|
int |
maxIndex()
The maximum indexable tuple value
|
java.lang.String |
toString()
A pretty formatter for the doublestring
|
public CoordDoubleString(int tuplecount, int tuplesize, BinaryFile input) throws FormatException
tuplecount
- the number of tuples to read from the input
streamtuplesize
- the number of doubles in the tupleinput
- the input stream to read everything fromFormatException
- if we have IO errors or premature
end-of-filepublic int maxIndex()
maxIndex
in interface CoordTupleString
public java.lang.Number getPrimitiveType()
getPrimitiveType
in interface CoordTupleString
public java.lang.String toString()
toString
in class java.lang.Object
public float getXasFloat(int tuple)
tuple
- the index of the tupletuple
public double getXasDouble(int tuple)
tuple
- the index of the tupletuple
public float getYasFloat(int tuple)
tuple
- the index of the tupletuple
public double getYasDouble(int tuple)
tuple
- the index of the tupletuple
public float getZasFloat(int tuple)
tuple
- the index of the tupletuple
public double getZasDouble(int tuple)
tuple
- the index of the tupletuple
public float[] getasFloat(int tuple)
getasFloat
in interface CoordTupleString
tuple
- the index of the tupletuple
public double[] getasDouble(int tuple)
getasDouble
in interface CoordTupleString
tuple
- the index of the tupletuple
public float getasFloat(int tuple, int val)
getasFloat
in interface CoordTupleString
tuple
- the index of the tupleval
- the index of the valuetuple
public double getasDouble(int tuple, int val)
getasDouble
in interface CoordTupleString
tuple
- the index of the tupleval
- the index of the valuetuple
Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details