|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectuk.org.ogsadai.client.toolkit.data.BinaryDataStreamDataValueIterator
public class BinaryDataStreamDataValueIterator
A data value iterator that reads data values from a binary data stream.
| Constructor Summary | |
|---|---|
BinaryDataStreamDataValueIterator(java.io.InputStream inputStream)
Constructor. |
|
| Method Summary | |
|---|---|
boolean |
hasNext()
Returns true if the iteration has more data. |
DataValue |
next()
Returns the next element in the iteration. |
boolean |
nextAsBoolean()
Gets the next data value as a boolean. |
byte[] |
nextAsByteArray()
Gets the next data value as a byte array. |
char[] |
nextAsCharArray()
Gets the next data value as a char array. |
java.util.Date |
nextAsDate()
Gets the next data value as a Date. |
double |
nextAsDouble()
Gets the next data value as a double. |
float |
nextAsFloat()
Gets the next data value as a float. |
int |
nextAsInt()
Gets the next data value as a int. |
long |
nextAsLong()
Gets the next data value as a long. |
java.lang.String |
nextAsString()
Gets the next data value as a String. |
DataValue |
readDataValue()
Reads a data value from the input stream. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BinaryDataStreamDataValueIterator(java.io.InputStream inputStream)
inputStream - input stream with binary data| Method Detail |
|---|
public boolean hasNext()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratortrue if the iteration has more data.
hasNext in interface DataValueIteratortrue if the iteration has more data,
false otherwise.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if there is an unexpected data value on the data stream.
DataSourceUsageException - if there is an error reading from a data source.
public DataValue readDataValue()
throws java.io.IOException,
DataStreamException
null if there are no more blocks.
java.io.IOException - if an error occurred reading the request data stream
DataStreamException - if the data stream ends in an error
public DataValue next()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIterator
next in interface DataValueIteratorDataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if there is an unexpected data value on the data stream.
DataSourceUsageException - if there is an error reading from a data source.
public boolean nextAsBoolean()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorboolean.
nextAsBoolean in interface DataValueIteratorboolean.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a boolean.
DataSourceUsageException - if there is an error reading from a data source.
public byte[] nextAsByteArray()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorbyte array.
nextAsByteArray in interface DataValueIteratorbyte array.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not an array of bytes.
DataSourceUsageException - if there is an error reading from a data source.
public char[] nextAsCharArray()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorchar array.
nextAsCharArray in interface DataValueIteratorchar array.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not an array of characters.
DataSourceUsageException - if there is an error reading from a data source.
public java.lang.String nextAsString()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorString.
nextAsString in interface DataValueIteratorString.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a string.
DataSourceUsageException - if there is an error reading from a data source.
public java.util.Date nextAsDate()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorDate.
nextAsDate in interface DataValueIteratorDate.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a date.
DataSourceUsageException - if there is an error reading from a data source.
public double nextAsDouble()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratordouble.
nextAsDouble in interface DataValueIteratordouble.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a double.
DataSourceUsageException - if there is an error reading from a data source.
public float nextAsFloat()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorfloat.
nextAsFloat in interface DataValueIteratorfloat.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a float.
DataSourceUsageException - if there is an error reading from a data source.
public int nextAsInt()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorint.
nextAsInt in interface DataValueIteratorint.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a integer.
DataSourceUsageException - if there is an error reading from a data source.
public long nextAsLong()
throws DataStreamErrorException,
UnexpectedDataValueException,
DataSourceUsageException
DataValueIteratorlong.
nextAsLong in interface DataValueIteratorlong.
DataStreamErrorException - if there is an error on the data stream.
UnexpectedDataValueException - if the next data value is not a long.
DataSourceUsageException - if there is an error reading from a data source.
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||