Package org.eclipse.jgit.revwalk
Class RevObjectList<E extends RevObject>
- java.lang.Object
-
- java.util.AbstractCollection<E>
-
- java.util.AbstractList<E>
-
- org.eclipse.jgit.revwalk.RevObjectList<E>
-
- Type Parameters:
E
- type of subclass of RevObject the list is storing.
- All Implemented Interfaces:
Iterable<E>
,Collection<E>
,List<E>
- Direct Known Subclasses:
RevCommitList
public class RevObjectList<E extends RevObject> extends AbstractList<E>
An ordered list ofRevObject
subclasses.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static class
RevObjectList.Block
One level of contents, either an intermediate level or a leaf level.
-
Field Summary
Fields Modifier and Type Field Description protected RevObjectList.Block
contents
Items stored in this list.protected int
size
Current number of elements in the list.-
Fields inherited from class java.util.AbstractList
modCount
-
-
Constructor Summary
Constructors Constructor Description RevObjectList()
Create an empty object list.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
add(int index, E element)
void
clear()
E
get(int index)
E
set(int index, E element)
int
size()
-
Methods inherited from class java.util.AbstractList
add, addAll, equals, hashCode, indexOf, iterator, lastIndexOf, listIterator, listIterator, remove, removeRange, subList
-
Methods inherited from class java.util.AbstractCollection
addAll, contains, containsAll, isEmpty, remove, removeAll, retainAll, toArray, toArray, toString
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface java.util.Collection
parallelStream, removeIf, stream, toArray
-
Methods inherited from interface java.util.List
addAll, contains, containsAll, isEmpty, remove, removeAll, replaceAll, retainAll, sort, spliterator, toArray, toArray
-
-
-
-
Field Detail
-
contents
protected RevObjectList.Block contents
Items stored in this list.If
RevObjectList.Block.shift
= 0 this block holds the list elements; otherwise it holds pointers to otherRevObjectList.Block
instances which use a shift that isBLOCK_SHIFT
smaller.
-
size
protected int size
Current number of elements in the list.
-
-