public class CFPointObWriter
extends java.lang.Object
Constructor and Description |
---|
CFPointObWriter(java.io.DataOutputStream stream,
java.util.List<Attribute> globalAtts,
java.lang.String altUnits,
java.util.List<PointObVar> dataVars,
int numrec)
Deprecated.
Constructor
|
Modifier and Type | Method and Description |
---|---|
void |
addPoint(double lat,
double lon,
double alt,
java.util.Date time,
double[] vals,
java.lang.String[] svals)
Deprecated.
Add one data point to the file
|
void |
finish()
Deprecated.
Call this when all done, output is flushed
|
static void |
main(java.lang.String[] args)
Deprecated.
|
static void |
main2(java.lang.String[] args)
Deprecated.
|
static boolean |
rewritePointFeatureDataset(java.lang.String fileIn,
java.lang.String fileOut,
boolean inMemory)
Deprecated.
Open a ucar.nc2.ft.PointFeatureCollection, write out in CF point format.
|
static boolean |
rewritePointObsDataset(java.lang.String fileIn,
java.lang.String fileOut,
boolean inMemory)
Deprecated.
Open a ucar.nc2.dt.PointObsDataset, write out in CF point format.
|
static int |
writePointFeatureCollection(FeatureDatasetPoint pfDataset,
java.lang.String fileOut)
Deprecated.
Write a ucar.nc2.ft.PointFeatureCollection in CF point format.
|
static void |
writePointObsDataset(PointObsDataset pobsDataset,
java.lang.String fileOut)
Deprecated.
write data from a ucar.nc2.dt.PointObsDataset into CF point format.
|
public CFPointObWriter(java.io.DataOutputStream stream, java.util.List<Attribute> globalAtts, java.lang.String altUnits, java.util.List<PointObVar> dataVars, int numrec) throws java.io.IOException
stream
- write to this streamglobalAtts
- optional list of global attributes (may be null)altUnits
- optional altitude units (set to null if no altitude variable)dataVars
- the set of data variables: first the double values, then the String valuesjava.io.IOException
- if write errorpublic void addPoint(double lat, double lon, double alt, java.util.Date time, double[] vals, java.lang.String[] svals) throws java.io.IOException
lat
- latitude value in units of degrees_northlon
- longitude value in units of degrees_eastalt
- altitude value in units of altUnits (may be NaN)time
- time value as a datevals
- list of data values, matching dataVars in the constructorsvals
- list of String values, matching dataVars in the constructorjava.io.IOException
- if write errorpublic void finish() throws java.io.IOException
java.io.IOException
- if write errorpublic static boolean rewritePointObsDataset(java.lang.String fileIn, java.lang.String fileOut, boolean inMemory) throws java.io.IOException
fileIn
- open through TypedDatasetFactory.open(FeatureType.POINT, ..)fileOut
- write to this netcdf-3 fileinMemory
- if true, read file into memory for efficiencyjava.io.IOException
- on read/write errorpublic static void writePointObsDataset(PointObsDataset pobsDataset, java.lang.String fileOut) throws java.io.IOException
pobsDataset
- rewrite data from herefileOut
- write to tehis netcdf-3 filejava.io.IOException
- on read/write errorpublic static boolean rewritePointFeatureDataset(java.lang.String fileIn, java.lang.String fileOut, boolean inMemory) throws java.io.IOException
fileIn
- open through TypedDatasetFactory.open(FeatureType.POINT, ..)fileOut
- write to this netcdf-3 fileinMemory
- if true, read file into memory for efficiencyjava.io.IOException
- on read/write errorpublic static int writePointFeatureCollection(FeatureDatasetPoint pfDataset, java.lang.String fileOut) throws java.io.IOException
pfDataset
- find the first PointFeatureCollection, and write all data from itfileOut
- write to this netcdf-3 filejava.io.IOException
- on read/write error, or if no PointFeatureCollection in pfDatasetpublic static void main2(java.lang.String[] args) throws java.io.IOException
java.io.IOException
public static void main(java.lang.String[] args) throws java.io.IOException
java.io.IOException