public class EntityStream
extends java.lang.Object
A stream of entity values.
DataService.entityStream
, DeltaStream
.
Modifier and Type | Method and Description |
---|---|
void |
abort()
Close this stream and release all associated resources, without checking first that the end of stream has been reached.
|
void |
close()
Close this stream and release all associated resources, checking first that the end of stream has been reached.
|
java.lang.String |
getDeltaLink()
Return (nullable) The delta-link (if any) that was encountered when
EntityStream.next was called repeatedly until end of stream and then EntityStream.close was called, otherwise null . |
java.lang.String |
getNextLink()
Return (nullable) The next-link (if any) that was encountered when
EntityStream.next was called repeatedly until end of stream and then EntityStream.close was called, otherwise null . |
java.lang.String |
getReadLink()
Return (nullable) The read-link (if any) that was encountered when
EntityStream.next was called repeatedly until end of stream and then EntityStream.close was called, otherwise null . |
boolean |
hasNext()
Return true If this stream has not been
EntityStream.close and has a next entity value. |
boolean |
isClosed()
Return has
EntityStream.close been called? |
EntityValue |
next()
Return the next entity value in this stream.
|
public void abort()
Close this stream and release all associated resources, without checking first that the end of stream has been reached.
public void close()
Close this stream and release all associated resources, checking first that the end of stream has been reached.
Can safely be called even if the stream was previously closed.
If a delta link was encountered before the stream was closed, it will be available via the EntityStream.deltaLink
property only after the stream is closed.
If a next link was encountered before the stream was closed, it will be available via the EntityStream.nextLink
property only after the stream is closed.
public java.lang.String getDeltaLink()
Return (nullable) The delta-link (if any) that was encountered when EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.
EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.public java.lang.String getNextLink()
Return (nullable) The next-link (if any) that was encountered when EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.
EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.public java.lang.String getReadLink()
Return (nullable) The read-link (if any) that was encountered when EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.
EntityStream.next
was called repeatedly until end of stream and then EntityStream.close
was called, otherwise null
.public boolean hasNext()
Return true If this stream has not been EntityStream.close
and has a next entity value. Otherwise return false
.
EntityStream.close
and has a next entity value. Otherwise return false
.public boolean isClosed()
Return has EntityStream.close
been called?
EntityStream.close
been called?public EntityValue next()
Return the next entity value in this stream.
Only call this if a previous call to EntityStream.hasNext
returned true
.