public class HapiTableReader
extends java.lang.Object
Constructor and Description |
---|
HapiTableReader(HapiParam[] params)
Constructor.
|
Modifier and Type | Method and Description |
---|---|
RowSequence |
createRowSequence(java.io.InputStream in,
java.lang.Byte byte0,
java.lang.String fmt)
Returns a row sequence given a HAPI data stream with no header.
|
RowSequence |
createRowSequenceUsingHeader(java.io.InputStream in)
Returns a row sequence given a HAPI data stream including the
prepended commented header (info JSON object) information.
|
StarTable |
createStarTable(IOSupplier<RowSequence> rseqSupplier)
Produces a StarTable based on this metadata given a source of
row sequence data.
|
public HapiTableReader(HapiParam[] params)
params
- array of parameters that will be readpublic StarTable createStarTable(IOSupplier<RowSequence> rseqSupplier)
If a null RowSequence supplier is provided, the resulting table will be data-less; its metadata methods will work, but attempts to read its data will fail.
rseqSupplier
- provides sequential data for the table, or nullpublic RowSequence createRowSequenceUsingHeader(java.io.InputStream in) throws java.io.IOException
The supplied input stream will be used as is, so any buffering should be applied before calling this method.
in
- input stream including prepended HAPI headerjava.io.IOException
public RowSequence createRowSequence(java.io.InputStream in, java.lang.Byte byte0, java.lang.String fmt) throws java.io.IOException
The supplied input stream will be used as is, so any buffering should be applied before calling this method.
in
- input stream ready for usebyte0
- byte to read at start of input sequence, or nullfmt
- data stream format, one of "csv" or "binary"java.io.IOException