Top Description Fields Constructors Methods
org.eclipse.collections.impl.bag.mutable.primitive

public Class UnmodifiableDoubleBag

extends AbstractUnmodifiableDoubleCollection
implements MutableDoubleBag
Class Inheritance
All Implemented Interfaces
org.eclipse.collections.api.bag.primitive.MutableDoubleBag, org.eclipse.collections.api.bag.primitive.DoubleBag, org.eclipse.collections.api.DoubleIterable, org.eclipse.collections.api.PrimitiveIterable, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection
Imports
org.eclipse.collections.api.DoubleIterable, org.eclipse.collections.api.bag.MutableBag, org.eclipse.collections.api.bag.primitive.ImmutableDoubleBag, .MutableDoubleBag, org.eclipse.collections.api.block.function.primitive.DoubleToObjectFunction, org.eclipse.collections.api.block.predicate.primitive.IntPredicate, .DoublePredicate, org.eclipse.collections.api.block.procedure.primitive.DoubleIntProcedure, org.eclipse.collections.api.list.MutableList, org.eclipse.collections.api.tuple.primitive.DoubleIntPair, org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection, org.eclipse.collections.impl.factory.primitive.DoubleBags, org.eclipse.collections.api.set.primitive.MutableDoubleSet

This file was automatically generated from template file unmodifiablePrimitiveBag.stg.
Since
3.1.

Field Summary

Modifier and TypeField and Description
private static final long

Constructor Summary

AccessConstructor and Description
public

Method Summary

Modifier and TypeMethod and Description
public void
public MutableDoubleBag
public MutableDoubleBag
public MutableList<DoubleIntPair>
bottomOccurrences(int count)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.bottomOccurrences.

Returns the count least frequently occurring items.

public <V> MutableBag<V>
public boolean
equals(Object otherBag)

Overrides java.lang.Object.equals.

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.equals.

Follows the same general contract as Bag#equals(Object).

public void
forEachWithOccurrences(DoubleIntProcedure procedure)

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.forEachWithOccurrences.

For each distinct item, with the number of occurrences, execute the specified procedure.

private MutableDoubleBag
public int
public MutableDoubleBag
public int
occurrencesOf(double item)

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.occurrencesOf.

The occurrences of a distinct item in the bag.

public MutableDoubleBag
public boolean
public MutableDoubleBag
public MutableDoubleBag
selectByOccurrences(IntPredicate predicate)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectByOccurrences.

Returns all elements of the bag that have a number of occurrences that satisfy the predicate.

public MutableDoubleSet
selectUnique()

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectUnique.

Returns all elements of the bag that have exactly one occurrence.

public int
sizeDistinct()

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.sizeDistinct.

The size of the Bag when counting only distinct elements.

public ImmutableDoubleBag
public MutableList<DoubleIntPair>
topOccurrences(int count)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.topOccurrences.

Returns the count most frequently occurring items.

public UnmodifiableDoubleBag
public UnmodifiableDoubleBag
public UnmodifiableDoubleBag
public UnmodifiableDoubleBag
Inherited from org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection:
addaddAlladdAllallSatisfyanySatisfyappendStringappendStringappendStringasLazyaveragechunkclearcontainscontainsAllcontainsAllcontainsAnycontainsAnycontainsNonecontainsNonecountdetectIfNonedoubleIteratoreachgetDoubleCollectioninjectIntoisEmptymakeStringmakeStringmakeStringmaxmaxIfEmptymedianminminIfEmptynoneSatisfynotEmptyreducereduceIfEmptyremoveremoveAllremoveAllremoveIfretainAllretainAllsizesumtoArraytoArraytoBagtoListtoSettoSortedArraytoSortedListtoString

Field Detail

serialVersionUIDback to summary
private static final long serialVersionUID

Hides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.serialVersionUID.

Constructor Detail

UnmodifiableDoubleBagback to summary
public UnmodifiableDoubleBag(MutableDoubleBag bag)

Method Detail

addOccurrencesback to summary
public void addOccurrences(double item, int occurrences)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.addOccurrences.

Annotations
@Override
asSynchronizedback to summary
public MutableDoubleBag asSynchronized()

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.asSynchronized.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.asSynchronized, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.asSynchronized.

Annotations
@Override
asUnmodifiableback to summary
public MutableDoubleBag asUnmodifiable()

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.asUnmodifiable.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.asUnmodifiable, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.asUnmodifiable.

Annotations
@Override
bottomOccurrencesback to summary
public MutableList<DoubleIntPair> bottomOccurrences(int count)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.bottomOccurrences.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.bottomOccurrences.

Returns the count least frequently occurring items. In the event of a tie, all of the items with the number of occurrences that match the occurrences of the last item will be returned.

Annotations
@Override
collectback to summary
public <V> MutableBag<V> collect(DoubleToObjectFunction<? extends V> function)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.collect.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.collect, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.collect.

Doc from org.eclipse.collections.api.DoubleIterable.collect.

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.

Annotations
@Override
equalsback to summary
public boolean equals(Object otherBag)

Overrides java.lang.Object.equals.

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.equals.

Doc from org.eclipse.collections.api.bag.primitive.DoubleBag.equals.

Follows the same general contract as Bag#equals(Object).

Annotations
@Override
forEachWithOccurrencesback to summary
public void forEachWithOccurrences(DoubleIntProcedure procedure)

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.forEachWithOccurrences.

Doc from org.eclipse.collections.api.bag.primitive.DoubleBag.forEachWithOccurrences.

For each distinct item, with the number of occurrences, execute the specified procedure.

Annotations
@Override
getMutableDoubleBagback to summary
private MutableDoubleBag getMutableDoubleBag()
hashCodeback to summary
public int hashCode()

Overrides java.lang.Object.hashCode.

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.hashCode.

Doc from org.eclipse.collections.api.bag.primitive.DoubleBag.hashCode.

Follows the same general contract as Bag#hashCode().

Annotations
@Override
newEmptyback to summary
public MutableDoubleBag newEmpty()

Overrides default org.eclipse.collections.api.bag.primitive.MutableDoubleBag.newEmpty, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.newEmpty.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.newEmpty.

Creates a new empty mutable version of the same Bag type.

Since
9.2.
occurrencesOfback to summary
public int occurrencesOf(double item)

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.occurrencesOf.

Doc from org.eclipse.collections.api.bag.primitive.DoubleBag.occurrencesOf.

The occurrences of a distinct item in the bag.

Annotations
@Override
rejectback to summary
public MutableDoubleBag reject(DoublePredicate predicate)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.reject.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.reject, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.reject.

Doc from org.eclipse.collections.api.DoubleIterable.reject.

Returns a new DoubleIterable with all of the elements in the DoubleIterable that return false for the specified predicate.

Annotations
@Override
removeOccurrencesback to summary
public boolean removeOccurrences(double item, int occurrences)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.removeOccurrences.

Annotations
@Override
selectback to summary
public MutableDoubleBag select(DoublePredicate predicate)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.select.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.select, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.select.

Doc from org.eclipse.collections.api.DoubleIterable.select.

Returns a new DoubleIterable with all of the elements in the DoubleIterable that return true for the specified predicate.

Annotations
@Override
selectByOccurrencesback to summary
public MutableDoubleBag selectByOccurrences(IntPredicate predicate)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectByOccurrences.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectByOccurrences.

Returns all elements of the bag that have a number of occurrences that satisfy the predicate.

Annotations
@Override
selectUniqueback to summary
public MutableDoubleSet selectUnique()

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectUnique.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.selectUnique.

Returns all elements of the bag that have exactly one occurrence.

Annotations
@Override
sizeDistinctback to summary
public int sizeDistinct()

Implements org.eclipse.collections.api.bag.primitive.DoubleBag.sizeDistinct.

Doc from org.eclipse.collections.api.bag.primitive.DoubleBag.sizeDistinct.

The size of the Bag when counting only distinct elements.

Annotations
@Override
toImmutableback to summary
public ImmutableDoubleBag toImmutable()

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.toImmutable.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.toImmutable, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.toImmutable.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.toImmutable.

Returns an immutable copy of this bag.

Annotations
@Override
topOccurrencesback to summary
public MutableList<DoubleIntPair> topOccurrences(int count)

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.topOccurrences.

Doc from org.eclipse.collections.api.bag.primitive.MutableDoubleBag.topOccurrences.

Returns the count most frequently occurring items. In the event of a tie, all of the items with the number of occurrences that match the occurrences of the last item will be returned.

Annotations
@Override
withback to summary
public UnmodifiableDoubleBag with(double element)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.with.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.with, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.with.

Annotations
@Override
withAllback to summary
public UnmodifiableDoubleBag withAll(DoubleIterable elements)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.withAll.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.withAll, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.withAll.

Annotations
@Override
withoutback to summary
public UnmodifiableDoubleBag without(double element)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.without.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.without, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.without.

Annotations
@Override
withoutAllback to summary
public UnmodifiableDoubleBag withoutAll(DoubleIterable elements)

Overrides org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableDoubleCollection.withoutAll.

Implements org.eclipse.collections.api.bag.primitive.MutableDoubleBag.withoutAll, org.eclipse.collections.api.collection.primitive.MutableDoubleCollection.withoutAll.

Annotations
@Override