[all packages]
[package net.sf.pizzacompiler.contrib]
[class hierarchy]
[index]
public class net.sf.pizzacompiler.contrib.SortedVector<A>
(source file: /home/enno/source/tmp/pizza/main/src/net/sf/pizzacompiler/contrib/SortedVector.pizza)
java.lang.Object
|
+----net.sf.pizzacompiler.util.Vector<A>
|
+----net.sf.pizzacompiler.contrib.SortedVector<A>
The pure class interface.
public class SortedVector<A>
extends Vector<A>
-
A sorted vector. All elements are inserted at the correct position.
- See also:
- net.sf.pizzacompiler.util.Vector, SortedStringVector
- SortedVector((int) -> A[], A, (A, A) -> int)
-
- SortedVector(int, (int) -> A[], A, (A, A) -> int)
-
- SortedVector(int, int, (int) -> A[], A, (A, A) -> int)
-
- insert(A)
-
- setDuplicates(boolean)
-
Sets if duplicates are allowed in this Vector.
Default is true.
- sortVector(Vector<A>)
-
TODO: This uses sorting by insertion...
SortedVector
public SortedVector(int initialCapacity,
int capacityIncrement,
(int) -> A[] allocator,
A defaultElem,
(A, A) -> int compare);
-
- Parameters:
- compare - returns < 0 if A1 0 if A1>A2
- See also:
- Vector(int, int, (int) -> A[], A, (A, A) -> int)
SortedVector
public SortedVector(int initialCapacity,
(int) -> A[] allocator,
A defaultElem,
(A, A) -> int compare);
-
- Parameters:
- compare - returns < 0 if A1 0 if A1>A2
- See also:
- Vector(int, (int) -> A[], A, (A, A) -> int)
SortedVector
public SortedVector((int) -> A[] allocator,
A defaultElem,
(A, A) -> int compare);
-
- Parameters:
- compare - returns < 0 if A1 0 if A1>A2
- See also:
- Vector((int) -> A[], A, (A, A) -> int)
setDuplicates
public void setDuplicates(boolean duplicates);
-
Sets if duplicates are allowed in this Vector.
Default is true.
insert
public synchronized void insert(A obj);
sortVector
public void sortVector(Vector<A> v);
-
TODO: This uses sorting by insertion...
[all packages]
[package net.sf.pizzacompiler.contrib]
[class hierarchy]
[index]
net.sf.pizzacompiler.contrib.SortedVector.html