Class AbstractMutableFloatValuesMap
java.lang.Object
org.eclipse.collections.impl.primitive.AbstractFloatIterable
org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableFloatValuesMap
- All Implemented Interfaces:
FloatIterable
,FloatValuesMap
,MutableFloatValuesMap
,PrimitiveIterable
- Direct Known Subclasses:
ByteFloatHashMap
,CharFloatHashMap
,DoubleFloatHashMap
,FloatFloatHashMap
,IntFloatHashMap
,LongFloatHashMap
,ShortFloatHashMap
public abstract class AbstractMutableFloatValuesMap extends AbstractFloatIterable implements MutableFloatValuesMap
This file was automatically generated from template file abstractMutablePrimitiveValuesMap.stg.
- Since:
- 6.0.
-
Constructor Summary
Constructors Constructor Description AbstractMutableFloatValuesMap()
-
Method Summary
Modifier and Type Method Description boolean
allSatisfy(FloatPredicate predicate)
Returns true if all of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.boolean
anySatisfy(FloatPredicate predicate)
Returns true if any of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.void
appendString(Appendable appendable, String start, String separator, String end)
Prints a string representation of this collection onto the givenAppendable
.RichIterable<FloatIterable>
chunk(int size)
Partitions elements in fixed size chunks.<V> MutableBag<V>
collect(FloatToObjectFunction<? extends V> function)
Returns a new collection with the results of applying the specified function on each element of the source collection.boolean
contains(float value)
Returns true if the value is contained in the FloatIterable, and false if it is not.boolean
containsAll(FloatIterable source)
Returns true if the all of the values specified in the source FloatIterable are contained in the FloatIterable, and false if they are not.boolean
containsValue(float value)
Returns whether or not this map contains the value.int
count(FloatPredicate predicate)
Returns a count of the number of elements in the FloatIterable that return true for the specified predicate.float
detectIfNone(FloatPredicate predicate, float value)
void
each(FloatProcedure procedure)
A synonym for forEach.void
forEach(FloatProcedure procedure)
Applies the FloatProcedure to each element in the FloatIterable.void
forEachValue(FloatProcedure procedure)
Iterates through each value in this map.boolean
isEmpty()
Returns true if this iterable has zero items.float
max()
float
min()
boolean
noneSatisfy(FloatPredicate predicate)
Returns true if none of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.boolean
notEmpty()
The English equivalent of !this.isEmpty()MutableFloatBag
reject(FloatPredicate predicate)
Returns a new FloatIterable with all of the elements in the FloatIterable that return false for the specified predicate.MutableFloatBag
select(FloatPredicate predicate)
Returns a new FloatIterable with all of the elements in the FloatIterable that return true for the specified predicate.int
size()
Returns the number of items in this iterable.double
sum()
float[]
toArray()
Converts the FloatIterable to a primitive float array.float[]
toArray(float[] target)
Converts the FloatIterable to a primitive float array.Methods inherited from class org.eclipse.collections.impl.primitive.AbstractFloatIterable
asLazy, average, containsAll, maxIfEmpty, median, minIfEmpty, toBag, toList, toSet, toSortedArray, toSortedList, toString
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface org.eclipse.collections.api.FloatIterable
asLazy, average, averageIfEmpty, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, containsAll, flatCollect, injectInto, maxIfEmpty, median, medianIfEmpty, minIfEmpty, reduce, reduceIfEmpty, reject, select, summaryStatistics, toBag, toList, toSet, toSortedArray, toSortedList
Methods inherited from interface org.eclipse.collections.api.map.primitive.FloatValuesMap
tap, values
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableFloatValuesMap
clear, floatIterator
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, makeString, makeString, makeString, toString
-
Constructor Details
-
AbstractMutableFloatValuesMap
public AbstractMutableFloatValuesMap()
-
-
Method Details
-
contains
public boolean contains(float value)Description copied from interface:FloatIterable
Returns true if the value is contained in the FloatIterable, and false if it is not.- Specified by:
contains
in interfaceFloatIterable
-
containsAll
Description copied from interface:FloatIterable
Returns true if the all of the values specified in the source FloatIterable are contained in the FloatIterable, and false if they are not.- Specified by:
containsAll
in interfaceFloatIterable
- Overrides:
containsAll
in classAbstractFloatIterable
-
max
public float max()- Specified by:
max
in interfaceFloatIterable
-
min
public float min()- Specified by:
min
in interfaceFloatIterable
-
size
public int size()Description copied from interface:PrimitiveIterable
Returns the number of items in this iterable.- Specified by:
size
in interfacePrimitiveIterable
-
isEmpty
public boolean isEmpty()Description copied from interface:PrimitiveIterable
Returns true if this iterable has zero items.- Specified by:
isEmpty
in interfacePrimitiveIterable
-
notEmpty
public boolean notEmpty()Description copied from interface:PrimitiveIterable
The English equivalent of !this.isEmpty()- Specified by:
notEmpty
in interfacePrimitiveIterable
-
forEach
Description copied from interface:FloatIterable
Applies the FloatProcedure to each element in the FloatIterable.- Specified by:
forEach
in interfaceFloatIterable
-
each
Description copied from interface:FloatIterable
A synonym for forEach.- Specified by:
each
in interfaceFloatIterable
- Since:
- 7.0.
-
appendString
Description copied from interface:PrimitiveIterable
Prints a string representation of this collection onto the givenAppendable
. Prints the string returned byPrimitiveIterable.makeString(String, String, String)
.- Specified by:
appendString
in interfacePrimitiveIterable
-
toArray
public float[] toArray()Description copied from interface:FloatIterable
Converts the FloatIterable to a primitive float array.- Specified by:
toArray
in interfaceFloatIterable
-
toArray
public float[] toArray(float[] target)Description copied from interface:FloatIterable
Converts the FloatIterable to a primitive float array. If the collection fits into the provided array it is used to store its elements and is returned from the method, otherwise a new array of the appropriate size is allocated and returned. If the iterable is empty, the target array is returned unchanged.- Specified by:
toArray
in interfaceFloatIterable
-
select
Description copied from interface:FloatIterable
Returns a new FloatIterable with all of the elements in the FloatIterable that return true for the specified predicate.- Specified by:
select
in interfaceFloatIterable
- Specified by:
select
in interfaceFloatValuesMap
- Specified by:
select
in interfaceMutableFloatValuesMap
-
reject
Description copied from interface:FloatIterable
Returns a new FloatIterable with all of the elements in the FloatIterable that return false for the specified predicate.- Specified by:
reject
in interfaceFloatIterable
- Specified by:
reject
in interfaceFloatValuesMap
- Specified by:
reject
in interfaceMutableFloatValuesMap
-
collect
Description copied from interface:FloatIterable
Returns a new collection with the results of applying the specified function on each element of the source collection. This method is also commonly called transform or map.- Specified by:
collect
in interfaceFloatIterable
- Specified by:
collect
in interfaceFloatValuesMap
- Specified by:
collect
in interfaceMutableFloatValuesMap
-
detectIfNone
- Specified by:
detectIfNone
in interfaceFloatIterable
-
count
Description copied from interface:FloatIterable
Returns a count of the number of elements in the FloatIterable that return true for the specified predicate.- Specified by:
count
in interfaceFloatIterable
-
anySatisfy
Description copied from interface:FloatIterable
Returns true if any of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.- Specified by:
anySatisfy
in interfaceFloatIterable
-
allSatisfy
Description copied from interface:FloatIterable
Returns true if all of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.- Specified by:
allSatisfy
in interfaceFloatIterable
-
noneSatisfy
Description copied from interface:FloatIterable
Returns true if none of the elements in the FloatIterable return true for the specified predicate, otherwise returns false.- Specified by:
noneSatisfy
in interfaceFloatIterable
-
chunk
Description copied from interface:FloatIterable
Partitions elements in fixed size chunks.- Specified by:
chunk
in interfaceFloatIterable
- Parameters:
size
- the number of elements per chunk- Returns:
- A
RichIterable
containingFloatIterable
s of sizesize
, except the last will be truncated if the elements don't divide evenly.
-
sum
public double sum()- Specified by:
sum
in interfaceFloatIterable
-
containsValue
public boolean containsValue(float value)Description copied from interface:FloatValuesMap
Returns whether or not this map contains the value.- Specified by:
containsValue
in interfaceFloatValuesMap
- Parameters:
value
- the value to test- Returns:
- if this collection contains the value
-
forEachValue
Description copied from interface:FloatValuesMap
Iterates through each value in this map.- Specified by:
forEachValue
in interfaceFloatValuesMap
- Parameters:
procedure
- the procedure to invoke for each value in this map.
-