Interface HistoryFlavorCodec
- 
 public interface HistoryFlavorCodecA HistoryFlavorCodec knows how to encode and decode a certain history flavor in binary and potentially several text formats.It will be used to import and export data from the store and forward system, and the binary encoding will be used to store the the data cache. Versioning If a codec changes over time, new instances should be registered for each version. On export or new data, the latest version will be used, but on decode the correct version will be retrieved. 
- 
- 
Nested Class SummaryNested Classes Modifier and Type Interface Description static classHistoryFlavorCodec.TextFormat
 - 
Field SummaryFields Modifier and Type Field Description static HistoryFlavorCodec.TextFormatCSVstatic HistoryFlavorCodec.TextFormatJSONstatic HistoryFlavorCodec.TextFormatXML
 - 
Method SummaryAll Methods Instance Methods Abstract Methods Modifier and Type Method Description HistoricalDatadecode(byte[] bytes)HistoricalDatadecodeText(java.io.Reader r, HistoryFlavorCodec.TextFormat fmt)byte[]encode(HistoricalData data)voidencodeText(java.io.Writer w, HistoricalData data, HistoryFlavorCodec.TextFormat fmt)java.util.List<HistoryFlavorCodec.TextFormat>getSupportedTextFormats()intversion()Returns the version of this codec instance.
 
- 
- 
- 
Field Detail- 
XMLstatic final HistoryFlavorCodec.TextFormat XML 
 - 
CSVstatic final HistoryFlavorCodec.TextFormat CSV 
 - 
JSONstatic final HistoryFlavorCodec.TextFormat JSON 
 
- 
 - 
Method Detail- 
versionint version() Returns the version of this codec instance.
 - 
encodebyte[] encode(HistoricalData data) 
 - 
decodeHistoricalData decode(byte[] bytes) 
 - 
getSupportedTextFormatsjava.util.List<HistoryFlavorCodec.TextFormat> getSupportedTextFormats() 
 - 
encodeTextvoid encodeText(java.io.Writer w, HistoricalData data, HistoryFlavorCodec.TextFormat fmt) throws java.io.IOException- Throws:
- java.io.IOException
 
 - 
decodeTextHistoricalData decodeText(java.io.Reader r, HistoryFlavorCodec.TextFormat fmt) throws java.io.IOException - Throws:
- java.io.IOException
 
 
- 
 
-