| Constructor and Description |
|---|
ResponseStreamIteratorWithHistory(Iterator serverStreamIterator) |
| Modifier and Type | Method and Description |
|---|---|
List<GenerateContentResponse> |
getHistory()
Retrieves all the chunks in a stream of responses.
|
boolean |
hasNext() |
boolean |
isConsumed()
Whether the whole stream has been consumed.
|
GenerateContentResponse |
next() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitforEachRemaining, removepublic ResponseStreamIteratorWithHistory(Iterator serverStreamIterator)
public boolean hasNext()
hasNext in interface Iterator<GenerateContentResponse>public GenerateContentResponse next()
next in interface Iterator<GenerateContentResponse>public List<GenerateContentResponse> getHistory()
public boolean isConsumed()
Here "consumed" means we have reached the end of the stream.
Copyright © 2024 Google LLC. All rights reserved.