public class StructReaderStream
extends java.lang.Object
| Constructor and Description |
|---|
StructReaderStream(java.io.InputStream is,
int elmsiz,
int noelm)
Create instance of StructReaderStream.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Close underlying InputStream.
|
boolean |
more()
More records available.
|
<T> T |
read(java.lang.Class<T> t)
Read.
|
<T> T |
read(java.lang.Class<T> t,
LengthProvider2 lenpvd)
Read.
|
public StructReaderStream(java.io.InputStream is,
int elmsiz,
int noelm)
is - input streamelmsiz - fixed size structs: size struct, variable size structs: maximum size structnoelm - number of structs in bufferpublic <T> T read(java.lang.Class<T> t)
throws RecordException,
java.io.IOException
T - struct typet - class of what to readRecordException - if impossible to convert between types in class and structjava.io.IOException - if problem reading from input streampublic <T> T read(java.lang.Class<T> t,
LengthProvider2 lenpvd)
throws RecordException,
java.io.IOException
T - struct typet - class of what to readlenpvd - supplies length for fields where it is not given (null indicates that it is to be ignored)RecordException - if impossible to convert between types in class and structjava.io.IOException - if problem reading from input streampublic boolean more()
throws java.io.IOException
java.io.IOException - if problem reading from input streampublic void close()
throws java.io.IOException
java.io.IOException - if problem closing input stream