Package noaa.coastwatch.gui.nav
Class XMLPointWriter
java.lang.Object
noaa.coastwatch.gui.nav.NavigationPointWriter
noaa.coastwatch.gui.nav.XMLPointWriter
The
XMLPointWriter
class writes navigation point data
to an XML format file. Each navigation point is written as an XML
<point>
element with attributes and subelements
specifying the data.- Since:
- 3.2.2
- Author:
- Peter Hollemans
-
Field Summary
Fields inherited from class noaa.coastwatch.gui.nav.NavigationPointWriter
gridCache, reader, variableList
-
Constructor Summary
ConstructorDescriptionXMLPointWriter
(EarthDataReader reader, List<String> variableList, List<NavigationPoint> pointList) Creates an XML point writer. -
Method Summary
Modifier and TypeMethodDescriptionstatic void
Tests this class.protected void
writeFooter
(PrintStream stream) Writes the file footer to the stream.protected void
writeHeader
(PrintStream stream) Writes the file header to the stream.protected void
writePoint
(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
-
XMLPointWriter
public XMLPointWriter(EarthDataReader reader, List<String> variableList, List<NavigationPoint> pointList) throws IOException Creates an XML 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:NavigationPointWriter
Writes the file header to the stream.- Specified by:
writeHeader
in classNavigationPointWriter
- Parameters:
stream
- the print stream to write to.
-
main
Tests this class.- Parameters:
argv
- the array of command line parameters.- Throws:
Exception
-