Package gov.usgs.earthquake.product.io
package gov.usgs.earthquake.product.io
Classes that perform input and output for Products.
The two primary interfaces are ProductSource and ProductHandler. A
ProductSource generates product events. A ProductHandler handles product
events.
The idea behind these interfaces is to process products using streams, to
minimize the memory footprint and to allow creation and processing of
products with contents that cannot fit within a virtual machine.
There are four main ProductSource/ProductHandler pairs:
- Object
- Java Object => ObjectProductSource => events
events => ObjectProductHandler => Java Object
- Directory
- product directory => DirectoryProductSource => events
events => DirectoryProductHandler => product directory - Xml
- product xml => XmlProductSource => events
events => XmlProductHandler => product xml
- Zip
- product zip => ZipProductSource => events
events => ZipProductHandler => product zip
-
ClassDescriptionClass to read and write Binary streamsGenerator of binary format for product data.Parser for binary format for product data.Compare io times of XML and Binary product formats.Deliver content in a separate thread.Store a product to a Directory.Load a product from a Directory.Filter calls to another ProductHandler.Class with main method for converting from one product format to another.Product format conversion tools to and from jsonStore a product as Json.Load a product from an InputStream containing Json.Convert ProductSource events into a java Product object.Convert a java Product object into events for a ProductHandler.A Handler for Product events.A Source of Product events.Store a product to an OutputStream using XML.Load a product from an InputStream containing XML.Store a product to an OutputStream using ZIP.Load a product from an InputStream containing ZIP.