public interface TXMLObjectIterator
Alternating calls to next and previous will return the same TXMLObject instance repeatedly. If you call moveBy with a positive argument n, it has the same effect on the position of the iterator as calling next n times. If you call moveBy with a negative argument n, it has the same effect on the iterator as calling previous n times. Calling moveBy with a zero argument has no effect.
Modifier and Type | Method and Description |
---|---|
boolean |
canMoveBy(int offset)
Indicates if this iterator can be moved by the given offset.
|
void |
close()
Closes this iterator.
|
int |
getCount()
Gets the query count as an int.
|
boolean |
hasCount()
Indicates if the response of Tamino contained the query count.
|
boolean |
hasNext()
Returns true if this iterator has more TXMLObject instances when traversing the
list in the forward direction.
|
boolean |
hasPrevious()
Returns true if this list iterator has more TXMLObject instances when traversing the
list in the reverse direction.
|
void |
moveBy(int offset)
Moves the iterator by the given offset.
|
TXMLObject |
next()
Returns the next element in the list of TXMLObject instances.
|
TXMLObject |
previous()
Returns the previous TXMLObject instance in the list.
|
void |
reset()
Resets the iterator to its initial state.
|
boolean hasNext()
TXMLObject next() throws TNoSuchXMLObjectException, TIteratorException
TNoSuchXMLObjectException
- the if iteration has no next TXMLObject instance.TIteratorException
- signals an error while attempting to access Tamino.boolean hasPrevious()
TXMLObject previous() throws TNoSuchXMLObjectException, TIteratorException
TNoSuchXMLObjectException
- if the iteration has no previous TXMLObject instance.TIteratorException
- signals an error while attempting to access Tamino.boolean hasCount()
int getCount()
boolean canMoveBy(int offset) throws TIteratorException
offset
- the positive or negative amount to move the iteratorTIteratorException
- signals an error while attempting to access Tamino.void moveBy(int offset) throws TNoSuchXMLObjectException, TIteratorException
offset
- the positive or negative amount to move the iteratorTNoSuchXMLObjectException
- if the new position is out of bounds.TIteratorException
- signals an error while attempting to access Tamino.void reset() throws TIteratorException
TIteratorException
- signals an error while attempting to access Tamino.void close() throws TIteratorException
TIteratorExceptionsignals
- an error while attempting to access Tamino.TIteratorException
Copyright (c) 2017 Software AG. All Rights Reserved.