|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.mahout.math.PersistentObject
org.apache.mahout.math.set.AbstractSet
org.apache.mahout.math.set.AbstractDoubleSet
public abstract class AbstractDoubleSet
Field Summary |
---|
Fields inherited from class org.apache.mahout.math.set.AbstractSet |
---|
defaultCapacity, defaultMaxLoadFactor, defaultMinLoadFactor, distinct, highWaterMark, lowWaterMark, maxLoadFactor, minLoadFactor |
Constructor Summary | |
---|---|
AbstractDoubleSet()
|
Method Summary | |
---|---|
abstract boolean |
add(double key)
Associates the given key with the given value. |
boolean |
contains(double key)
Returns true if the receiver contains the specified key. |
AbstractDoubleSet |
copy()
Returns a deep copy of the receiver; uses clone() and casts the result. |
boolean |
equals(java.lang.Object obj)
|
abstract boolean |
forEachKey(DoubleProcedure procedure)
Applies a procedure to each key of the receiver, if any. |
DoubleArrayList |
keys()
Returns a list filled with all keys contained in the receiver. |
void |
keys(DoubleArrayList list)
Fills all keys contained in the receiver into the specified list. |
abstract boolean |
remove(double key)
Removes the given key with its associated element from the receiver, if present. |
java.lang.String |
toString()
Returns a string representation of the receiver, containing the String representation of each key-value pair, sorted ascending by key. |
Methods inherited from class org.apache.mahout.math.set.AbstractSet |
---|
chooseGrowCapacity, chooseHighWaterMark, chooseLowWaterMark, chooseMeanCapacity, chooseShrinkCapacity, clear, ensureCapacity, equalsMindTheNull, isEmpty, nextPrime, setUp, size, trimToSize |
Methods inherited from class org.apache.mahout.math.PersistentObject |
---|
clone |
Methods inherited from class java.lang.Object |
---|
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AbstractDoubleSet()
Method Detail |
---|
public boolean contains(double key)
public AbstractDoubleSet copy()
clone()
and casts the result.
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public abstract boolean forEachKey(DoubleProcedure procedure)
procedure
- the procedure to be applied. Stops iteration if the procedure returns false, otherwise
continues.
public DoubleArrayList keys()
forEachKey(DoubleProcedure)
. This method can be used to iterate over the keys of the receiver.
public void keys(DoubleArrayList list)
forEachKey(DoubleProcedure)
.
This method can be used to iterate over the keys of the receiver.
list
- the list to be filled, can have any size.public abstract boolean add(double key)
key
- the key the value shall be associated with.
public abstract boolean remove(double key)
key
- the key to be removed from the receiver.
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |