Package noaa.coastwatch.gui.nav
Class CSVPointWriter
java.lang.Object
noaa.coastwatch.gui.nav.NavigationPointWriter
noaa.coastwatch.gui.nav.CSVPointWriter
The
CSVPointWriter class writes navigation point data
to an CSV format file. Each navigation point is written as one
line with commas separating the columns. The file is prefixed with a
column name header.- Since:
- 3.2.2
- Author:
- Peter Hollemans
-
Field Summary
Fields inherited from class noaa.coastwatch.gui.nav.NavigationPointWriter
gridCache, reader, variableList -
Constructor Summary
ConstructorsConstructorDescriptionCSVPointWriter(EarthDataReader reader, List<String> variableList, List<NavigationPoint> pointList) Creates an CSV point writer. -
Method Summary
Modifier and TypeMethodDescriptionstatic voidTests this class.protected voidwriteFooter(PrintStream stream) Writes the file footer to the stream.protected voidwriteHeader(PrintStream stream) Writes the file header to the stream.protected voidwritePoint(PrintStream stream, NavigationPoint point) Writes a single point to the stream.Methods inherited from class noaa.coastwatch.gui.nav.NavigationPointWriter
getNorth, getTestPoints, write
-
Constructor Details
-
CSVPointWriter
public CSVPointWriter(EarthDataReader reader, List<String> variableList, List<NavigationPoint> pointList) throws IOException Creates an CSV point writer.- Parameters:
reader- the reader to use for extra data to write with each point.variableList- the list of variables from the reader to use for writing variable data at each point.pointList- the list of navigation points to write.- Throws:
IOException- if an error occurred accessing a data variable from the list.
-
-
Method Details
-
writeHeader
Description copied from class:NavigationPointWriterWrites the file header to the stream.- Specified by:
writeHeaderin classNavigationPointWriter- Parameters:
stream- the print stream to write to.
-
main
Tests this class.- Parameters:
argv- the array of command line parameters.- Throws:
Exception
-