Package ucar.unidata.gis.shapefile
Class DbaseData
java.lang.Object
ucar.unidata.gis.shapefile.DbaseData
Class DbaseData
- Author:
- Russ Rew
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
Data is an array of booleans (boolean[]).static final int
Character type data (String[]).static final int
Data is an array of doubles (double[]). -
Method Summary
Modifier and TypeMethodDescriptionasList()
_more_boolean
getBoolean
(int i) Method to retrieve a boolean for this fieldboolean[]
Method to retrieve a booleans array for this fieldgetData
(int i) Method to retrieve data for this fielddouble
getDouble
(int i) Method to retrieve a double for this fielddouble[]
Method to retrieve the double array for this fieldint
getString
(int i) Method to retrieve a String for this fieldString[]
Method to retrieve an array of Strings for this fieldint
getType()
Method to return the type of data for the field
-
Field Details
-
TYPE_CHAR
public static final int TYPE_CHARCharacter type data (String[]).- See Also:
-
TYPE_NUMERIC
public static final int TYPE_NUMERICData is an array of doubles (double[]).- See Also:
-
TYPE_BOOLEAN
public static final int TYPE_BOOLEANData is an array of booleans (boolean[]).- See Also:
-
-
Method Details
-
getType
public int getType()Method to return the type of data for the field- Returns:
- One of TYPE_CHAR, TYPE_BOOLEAN, or TYPE_NUMERIC
-
getDoubles
public double[] getDoubles()Method to retrieve the double array for this field- Returns:
- An array of doubles with the data
-
getDouble
public double getDouble(int i) Method to retrieve a double for this field- Parameters:
i
- index of desired double, assumes 0 invalid input: '<' i invalid input: '<' getNumRec()- Returns:
- A double with the data
-
getBooleans
public boolean[] getBooleans()Method to retrieve a booleans array for this field- Returns:
- An array of boolean values
-
getBoolean
public boolean getBoolean(int i) Method to retrieve a boolean for this field- Parameters:
i
- index of desired boolean, assumes 0 invalid input: '<' i invalid input: '<' getNumRec()- Returns:
- A boolean with the data
-
getStrings
Method to retrieve an array of Strings for this field- Returns:
- An array of Strings
-
getString
Method to retrieve a String for this field- Parameters:
i
- index of desired String, assumes 0 invalid input: '<' i invalid input: '<' getNumRec()- Returns:
- A String with the data
-
asList
_more_- Returns:
- _more_
-
getData
Method to retrieve data for this field- Parameters:
i
- index of desired String, assumes 0 invalid input: '<' i invalid input: '<' getNumRec()- Returns:
- either a Double, Boolean, or String with the data
-
getNumRec
public int getNumRec()- Returns:
- The number of records in the field.
-