Package ghidra.program.database.map
Class AddressKeyAddressIterator
java.lang.Object
ghidra.program.database.map.AddressKeyAddressIterator
- All Implemented Interfaces:
AddressIterator
,Iterable<Address>
,Iterator<Address>
Converts an AddressKeyIterator or an addressKeyAddressIterator into an AddressIterator
-
Field Summary
Fields inherited from interface ghidra.program.model.address.AddressIterator
EMPTY_ITERATOR
-
Constructor Summary
ConstructorDescriptionAddressKeyAddressIterator
(DBLongIterator keyIter, boolean forward, AddressMap addrMap, ErrorHandler errHandler) Constructor. -
Method Summary
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.lang.Iterable
forEach, spliterator
Methods inherited from interface java.util.Iterator
forEachRemaining
-
Constructor Details
-
AddressKeyAddressIterator
public AddressKeyAddressIterator(DBLongIterator keyIter, boolean forward, AddressMap addrMap, ErrorHandler errHandler) Constructor.- Parameters:
keyIter
- address key iterator, may be null. All long values must decode properly with the specified addrMap.forward
- true to iterate in the direction of increasing addresses.addrMap
- address maperrHandler
- IO error handler (may be null)
-
-
Method Details
-
hasNext
public boolean hasNext()Description copied from interface:AddressIterator
Checks if there is a next address in the iteration.- Specified by:
hasNext
in interfaceAddressIterator
- Specified by:
hasNext
in interfaceIterator<Address>
- Returns:
- true if there is a next address.
- See Also:
-
next
Description copied from interface:AddressIterator
Get the next address.NOTE: This deviates from the standard
Iterator
interface by returning null instead of throwing an exception.- Specified by:
next
in interfaceAddressIterator
- Specified by:
next
in interfaceIterator<Address>
- Returns:
- the next address in the iteration.
- See Also:
-
remove
public void remove() -
iterator
- Specified by:
iterator
in interfaceAddressIterator
- Specified by:
iterator
in interfaceIterable<Address>
-