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 of RevObject
subclasses.
Nested Class Summary |
protected static class |
RevObjectList.Block
One level of contents, either an intermediate level or a leaf level. |
Method Summary |
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 |
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 other RevObjectList.Block
instances which use a shift that
is BLOCK_SHIFT
smaller.
size
protected int size
- Current number of elements in the list.
RevObjectList
public RevObjectList()
- Create an empty object list.
add
public void add(int index,
E element)
- Specified by:
add
in interface List<E extends RevObject>
- Overrides:
add
in class AbstractList<E extends RevObject>
set
public E set(int index,
E element)
- Specified by:
set
in interface List<E extends RevObject>
- Overrides:
set
in class AbstractList<E extends RevObject>
get
public E get(int index)
- Specified by:
get
in interface List<E extends RevObject>
- Specified by:
get
in class AbstractList<E extends RevObject>
size
public int size()
- Specified by:
size
in interface Collection<E extends RevObject>
- Specified by:
size
in interface List<E extends RevObject>
- Specified by:
size
in class AbstractCollection<E extends RevObject>
clear
public void clear()
- Specified by:
clear
in interface Collection<E extends RevObject>
- Specified by:
clear
in interface List<E extends RevObject>
- Overrides:
clear
in class AbstractList<E extends RevObject>
Copyright © 2013. All Rights Reserved.