BigList<java.lang.Byte>
, ByteBigList
, ByteCollection
, ByteIterable
, ByteStack
, Size64
, Stack<java.lang.Byte>
, java.io.Serializable
, java.lang.Comparable<BigList<? extends java.lang.Byte>>
, java.lang.Iterable<java.lang.Byte>
, java.util.Collection<java.lang.Byte>
public static class AbstractByteBigList.ByteSubList extends AbstractByteBigList implements java.io.Serializable
AbstractByteBigList.ByteSubList
Constructor | Description |
---|---|
ByteSubList(ByteBigList l,
long from,
long to) |
Modifier and Type | Method | Description |
---|---|---|
boolean |
add(byte k) |
Ensures that this collection contains the specified element (optional
operation).
|
void |
add(long index,
byte k) |
Inserts the specified element at the specified position in this type-specific
big list (optional operation).
|
boolean |
addAll(long index,
ByteBigList l) |
Inserts all of the elements in the specified type-specific big list into this
type-specific big list at the specified position (optional operation).
|
boolean |
addAll(long index,
ByteCollection c) |
Inserts all of the elements in the specified type-specific collection into
this type-specific big list at the specified position (optional operation).
|
boolean |
addAll(long index,
java.util.Collection<? extends java.lang.Byte> c) |
Adds all of the elements in the specified collection to this list (optional
operation).
|
void |
addElements(long index,
byte[][] a,
long offset,
long length) |
Add (hopefully quickly) elements to this type-specific big list.
|
byte |
getByte(long index) |
Returns the element at the specified position.
|
void |
getElements(long from,
byte[][] a,
long offset,
long length) |
Copies (hopefully quickly) elements of this type-specific big list into the
given big array.
|
ByteBigListIterator |
listIterator(long index) |
Returns a type-specific list iterator on this type-specific big list starting
at a given index.
|
boolean |
rem(byte k) |
Removes a single instance of the specified element from this collection, if
it is present (optional operation).
|
byte |
removeByte(long index) |
Removes the element at the specified position.
|
void |
removeElements(long from,
long to) |
Removes (hopefully quickly) elements of this type-specific big list.
|
byte |
set(long index,
byte k) |
Replaces the element at the specified position in this big list with the
specified element (optional operation).
|
long |
size64() |
Returns the size of this data structure as a long.
|
ByteBigList |
subList(long from,
long to) |
Returns a type-specific view of the portion of this type-specific big list
from the index
from , inclusive, to the index to , exclusive. |
add, addAll, addAll, addAll, addElements, clear, compareTo, contains, equals, get, hashCode, indexOf, indexOf, iterator, lastIndexOf, lastIndexOf, listIterator, peek, peekByte, pop, popByte, push, push, remove, set, size, size, top, topByte, toString
add, contains, containsAll, remove, removeAll, retainAll, toArray, toByteArray, toByteArray
containsAll, isEmpty, removeAll, retainAll, toArray, toArray
add, contains, containsAll, remove, removeAll, removeIf, removeIf, retainAll, toArray, toByteArray, toByteArray
forEach, forEach
public ByteSubList(ByteBigList l, long from, long to)
public boolean add(byte k)
AbstractByteBigList
This implementation always throws an UnsupportedOperationException
.
This implementation delegates to the type-specific version of
BigList.add(long, Object)
.
add
in interface ByteCollection
add
in class AbstractByteBigList
Collection.add(Object)
public void add(long index, byte k)
AbstractByteBigList
This implementation always throws an UnsupportedOperationException
.
add
in interface ByteBigList
add
in class AbstractByteBigList
BigList.add(long,Object)
public boolean addAll(long index, java.util.Collection<? extends java.lang.Byte> c)
AbstractByteBigList
addAll
in interface BigList<java.lang.Byte>
addAll
in class AbstractByteBigList
index
- index at which to insert the first element from the specified collection.c
- collection containing elements to be added to this big list.true
if this big list changed as a result of the callList.addAll(int, Collection)
public byte getByte(long index)
ByteBigList
getByte
in interface ByteBigList
BigList.get(long)
public byte removeByte(long index)
AbstractByteBigList
This implementation always throws an UnsupportedOperationException
.
removeByte
in interface ByteBigList
removeByte
in class AbstractByteBigList
BigList.remove(long)
public byte set(long index, byte k)
AbstractByteBigList
This implementation always throws an UnsupportedOperationException
.
set
in interface ByteBigList
set
in class AbstractByteBigList
BigList.set(long,Object)
public long size64()
Size64
public void getElements(long from, byte[][] a, long offset, long length)
AbstractByteBigList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
getElements
in interface ByteBigList
getElements
in class AbstractByteBigList
from
- the start index (inclusive).a
- the destination big array.offset
- the offset into the destination big array where to store the first
element copied.length
- the number of elements to be copied.public void removeElements(long from, long to)
AbstractByteBigList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
removeElements
in interface ByteBigList
removeElements
in class AbstractByteBigList
from
- the start index (inclusive).to
- the end index (exclusive).public void addElements(long index, byte[][] a, long offset, long length)
AbstractByteBigList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
addElements
in interface ByteBigList
addElements
in class AbstractByteBigList
index
- the index at which to add elements.a
- the big array containing the elements.offset
- the offset of the first element to add.length
- the number of elements to add.public ByteBigListIterator listIterator(long index)
AbstractByteBigList
Note that this specification strengthens the one given in
BigList.listIterator(long)
.
This implementation is based on the random-access methods.
listIterator
in interface BigList<java.lang.Byte>
listIterator
in interface ByteBigList
listIterator
in class AbstractByteBigList
index
- index of first element to be returned from the big-list iterator.BigList.listIterator(long)
public ByteBigList subList(long from, long to)
ByteBigList
from
, inclusive, to the index to
, exclusive.
Note that this specification strengthens the one given in
BigList.subList(long,long)
.
subList
in interface BigList<java.lang.Byte>
subList
in interface ByteBigList
subList
in class AbstractByteBigList
from
- the starting element (inclusive).to
- the ending element (exclusive).BigList.subList(long,long)
public boolean rem(byte k)
AbstractByteBigList
This implementation delegates to indexOf()
.
rem
in interface ByteCollection
rem
in class AbstractByteBigList
Collection.remove(Object)
public boolean addAll(long index, ByteCollection c)
AbstractByteBigList
This implementation delegates to the type-specific version of
AbstractByteBigList.addAll(long, Collection)
.
addAll
in interface ByteBigList
addAll
in class AbstractByteBigList
List.addAll(int,java.util.Collection)
public boolean addAll(long index, ByteBigList l)
AbstractByteBigList
This implementation delegates to the type-specific version of
AbstractByteBigList.addAll(long, Collection)
.
addAll
in interface ByteBigList
addAll
in class AbstractByteBigList
List.addAll(int,java.util.Collection)