Package org.jf.dexlib2.dexbacked.util
Class VariableSizeListIterator<T>
- java.lang.Object
-
- org.jf.dexlib2.dexbacked.util.VariableSizeListIterator<T>
-
- All Implemented Interfaces:
java.util.Iterator<T>
,java.util.ListIterator<T>
public abstract class VariableSizeListIterator<T> extends java.lang.Object implements java.util.ListIterator<T>
-
-
Field Summary
Fields Modifier and Type Field Description protected int
size
-
Constructor Summary
Constructors Modifier Constructor Description protected
VariableSizeListIterator(DexBuffer buffer, int offset, int size)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description void
add(T t)
int
getReaderOffset()
boolean
hasNext()
boolean
hasPrevious()
T
next()
int
nextIndex()
T
previous()
int
previousIndex()
protected abstract T
readNextItem(DexReader<? extends DexBuffer> reader, int index)
Reads the next item from reader.void
remove()
void
set(T t)
-
-
-
Constructor Detail
-
VariableSizeListIterator
protected VariableSizeListIterator(@Nonnull DexBuffer buffer, int offset, int size)
-
-
Method Detail
-
readNextItem
protected abstract T readNextItem(@Nonnull DexReader<? extends DexBuffer> reader, int index)
Reads the next item from reader.- Parameters:
reader
- TheDexReader
to read the next item fromindex
- The index of the item being read. This is guaranteed to be less thansize
- Returns:
- The item that was read
-
getReaderOffset
public int getReaderOffset()
-
hasNext
public boolean hasNext()
-
next
public T next()
-
hasPrevious
public boolean hasPrevious()
- Specified by:
hasPrevious
in interfacejava.util.ListIterator<T>
-
nextIndex
public int nextIndex()
- Specified by:
nextIndex
in interfacejava.util.ListIterator<T>
-
previousIndex
public int previousIndex()
- Specified by:
previousIndex
in interfacejava.util.ListIterator<T>
-
remove
public void remove()
-
-