|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.unimi.dsi.fastutil.chars.AbstractCharCollection
it.unimi.dsi.fastutil.chars.AbstractCharList
it.unimi.dsi.fastutil.chars.AbstractCharList.CharSubList
public static class AbstractCharList.CharSubList
Nested Class Summary |
---|
Nested classes/interfaces inherited from class it.unimi.dsi.fastutil.chars.AbstractCharList |
---|
AbstractCharList.CharSubList |
Field Summary | |
---|---|
static long |
serialVersionUID
|
Constructor Summary | |
---|---|
AbstractCharList.CharSubList(CharList l,
int from,
int to)
|
Method Summary | |
---|---|
boolean |
add(char k)
|
void |
add(int index,
char k)
|
boolean |
addAll(int index,
CharCollection c)
Delegates to a more generic method. |
boolean |
addAll(int index,
CharList l)
Delegates to a more generic method. |
boolean |
addAll(int index,
java.util.Collection<? extends java.lang.Character> c)
|
void |
addElements(int index,
char[] a,
int offset,
int length)
Adds elements to this type-specific list one-by-one. |
void |
clear()
|
char |
getChar(int index)
|
void |
getElements(int from,
char[] a,
int offset,
int length)
Copies element of this type-specific list into the given array one-by-one. |
CharListIterator |
listIterator(int index)
Returns a type-specific list iterator on the list starting at a given index. |
boolean |
rem(char k)
Note that this method should be called remove() , but the clash
with the similarly named index-based method in the List interface
forces us to use a distinguished name. |
boolean |
remove(java.lang.Object o)
Delegates to rem() . |
char |
removeChar(int index)
|
void |
removeElements(int from,
int to)
Removes elements of this type-specific list one-by-one. |
char |
set(int index,
char k)
|
int |
size()
|
CharList |
subList(int from,
int to)
Returns a type-specific view of the portion of this list from the index from , inclusive, to the index to , exclusive. |
Methods inherited from class it.unimi.dsi.fastutil.chars.AbstractCharList |
---|
add, addAll, addAll, addAll, addElements, charListIterator, charListIterator, charSubList, compareTo, contains, equals, get, hashCode, indexOf, indexOf, iterator, lastIndexOf, lastIndexOf, listIterator, peek, peekChar, pop, popChar, push, push, remove, set, size, top, topChar, toString |
Methods inherited from class it.unimi.dsi.fastutil.chars.AbstractCharCollection |
---|
add, charIterator, contains, containsAll, containsAll, isEmpty, rem, removeAll, removeAll, retainAll, retainAll, toArray, toArray, toArray, toCharArray, toCharArray |
Methods inherited from class java.lang.Object |
---|
getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface java.util.List |
---|
add, contains, containsAll, isEmpty, removeAll, retainAll, toArray, toArray |
Methods inherited from interface it.unimi.dsi.fastutil.chars.CharCollection |
---|
charIterator, containsAll, removeAll, retainAll, toArray, toArray, toCharArray, toCharArray |
Methods inherited from interface it.unimi.dsi.fastutil.Stack |
---|
isEmpty |
Field Detail |
---|
public static final long serialVersionUID
Constructor Detail |
---|
public AbstractCharList.CharSubList(CharList l, int from, int to)
Method Detail |
---|
public boolean add(char k)
add
in interface CharCollection
add
in class AbstractCharList
Collection.add(Object)
public void add(int index, char k)
add
in interface CharList
add
in class AbstractCharList
List.add(int,Object)
public boolean addAll(int index, java.util.Collection<? extends java.lang.Character> c)
addAll
in interface java.util.List<java.lang.Character>
addAll
in class AbstractCharList
public char getChar(int index)
getChar
in interface CharList
List.get(int)
public char removeChar(int index)
removeChar
in interface CharList
removeChar
in class AbstractCharList
List.remove(int)
public char set(int index, char k)
set
in interface CharList
set
in class AbstractCharList
List.set(int,Object)
public void clear()
clear
in interface java.util.Collection<java.lang.Character>
clear
in interface java.util.List<java.lang.Character>
clear
in class AbstractCharCollection
public int size()
size
in interface java.util.Collection<java.lang.Character>
size
in interface java.util.List<java.lang.Character>
public void getElements(int from, char[] a, int offset, int length)
AbstractCharList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
getElements
in interface CharList
getElements
in class AbstractCharList
from
- the start index (inclusive).a
- the destination array.offset
- the offset into the destination array where to store the first element copied.length
- the number of elements to be copied.public void removeElements(int from, int to)
AbstractCharList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
removeElements
in interface CharList
removeElements
in class AbstractCharList
from
- the start index (inclusive).to
- the end index (exclusive).public void addElements(int index, char[] a, int offset, int length)
AbstractCharList
This is a trivial iterator-based implementation. It is expected that implementations will override this method with a more optimized version.
addElements
in interface CharList
addElements
in class AbstractCharList
index
- the index at which to add elements.a
- the array containing the elements.offset
- the offset of the first element to add.length
- the number of elements to add.public CharListIterator listIterator(int index)
CharList
listIterator
in interface CharList
listIterator
in interface java.util.List<java.lang.Character>
listIterator
in class AbstractCharList
CharList.listIterator(int)
public CharList subList(int from, int to)
CharList
from
, inclusive, to the index to
, exclusive.
Note that this specification strengthens the one given in List.subList(int,int)
.
subList
in interface CharList
subList
in interface java.util.List<java.lang.Character>
subList
in class AbstractCharList
List.subList(int,int)
public boolean rem(char k)
CharCollection
remove()
, but the clash
with the similarly named index-based method in the List
interface
forces us to use a distinguished name. For simplicity, the set interfaces reinstates
remove()
.
rem
in interface CharCollection
rem
in class AbstractCharList
Collection.remove(Object)
public boolean remove(java.lang.Object o)
AbstractCharList
rem()
.
remove
in interface java.util.Collection<java.lang.Character>
remove
in interface java.util.List<java.lang.Character>
remove
in class AbstractCharList
public boolean addAll(int index, CharCollection c)
AbstractCharList
addAll
in interface CharList
addAll
in class AbstractCharList
List.add(int,Object)
public boolean addAll(int index, CharList l)
AbstractCharList
addAll
in interface CharList
addAll
in class AbstractCharList
List.add(int,Object)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |