Package ghidra.program.util
Class MultiAddressRangeIterator
java.lang.Object
ghidra.program.util.MultiAddressRangeIterator
MultiAddressRangeIterator
is a class for iterating through multiple
address range iterators simultaneously. The next() method returns the next address range
as determined from all the iterators.-
Constructor Summary
ConstructorDescriptionConstructor of a multi address iterator for multiple forward address iterators.MultiAddressRangeIterator
(AddressRangeIterator[] iters, boolean forward) Constructor of a multi address range iterator. -
Method Summary
-
Constructor Details
-
MultiAddressRangeIterator
Constructor of a multi address iterator for multiple forward address iterators.- Parameters:
iters
- the address iterators.
-
MultiAddressRangeIterator
Constructor of a multi address range iterator.
Note: all iterators must iterate in the same direction (forwards or backwards).- Parameters:
iters
- the address iterators. All must iterate in the direction indicated by the "forward" parameter.forward
- true indicates that forward iterators are in the array. false indicates backward iterators are in the array.
-
-
Method Details
-
hasNext
public boolean hasNext()Determines whether or not any of the original iterators has a next address.- Returns:
- true if a next address can be obtained from any of the address iterators.
-
next
Returns the next address. The next address could be from any one of the iterators.- Returns:
- the next address.
-
forwardNext
Returns the next address for forward iterators. The next address could be from any one of the iterators.- Returns:
- the next address.
-
backwardNext
Returns the next address for backward iterators. The next address could be from any one of the iterators.- Returns:
- the next address.
-