Top Description Methods
org.eclipse.collections.api.bag.primitive

public Interface ImmutableLongBag

extends ImmutableLongCollection, LongBag
Imports
org.eclipse.collections.api.LongIterable, org.eclipse.collections.api.bag.ImmutableBag, org.eclipse.collections.api.block.function.primitive.LongToObjectFunction, org.eclipse.collections.api.block.predicate.primitive.IntPredicate, .LongPredicate, org.eclipse.collections.api.block.procedure.primitive.LongProcedure, org.eclipse.collections.api.collection.primitive.ImmutableLongCollection, org.eclipse.collections.api.list.ImmutableList, org.eclipse.collections.api.tuple.primitive.LongIntPair, org.eclipse.collections.api.set.primitive.ImmutableLongSet

This file was automatically generated from template file immutablePrimitiveBag.stg.
Since
3.0.

Method Summary

Modifier and TypeMethod and Description
public ImmutableList<LongIntPair>
bottomOccurrences(int count)

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.bottomOccurrences.

Returns the count least frequently occurring items.

public <V> ImmutableBag<V>
collect(LongToObjectFunction<? extends V> function)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.collect, org.eclipse.collections.api.bag.primitive.LongBag.collect.

Returns a new collection with the results of applying the specified function on each element of the source collection.

public ImmutableLongBag
public ImmutableLongBag
public ImmutableLongBag
public ImmutableLongBag
public ImmutableLongBag
reject(LongPredicate predicate)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.reject, org.eclipse.collections.api.bag.primitive.LongBag.reject.

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

public ImmutableLongBag
select(LongPredicate predicate)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.select, org.eclipse.collections.api.bag.primitive.LongBag.select.

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

public ImmutableLongBag
selectByOccurrences(IntPredicate predicate)

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.selectByOccurrences.

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

public default ImmutableLongBag
selectDuplicates()

Overrides default org.eclipse.collections.api.bag.primitive.LongBag.selectDuplicates.

Returns all elements of the bag that have more than one occurrence.

public ImmutableLongSet
selectUnique()

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.selectUnique.

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

public default ImmutableLongBag
public ImmutableList<LongIntPair>
topOccurrences(int count)

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.topOccurrences.

Returns the count most frequently occurring items.

Inherited from org.eclipse.collections.api.bag.primitive.LongBag:
equalsforEachWithOccurrenceshashCodeoccurrencesOfsizeDistincttoImmutabletoStringOfItemToCount

Method Detail

bottomOccurrencesback to summary
public ImmutableList<LongIntPair> bottomOccurrences(int count)

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.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
Since
8.0
collectback to summary
public <V> ImmutableBag<V> collect(LongToObjectFunction<? extends V> function)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.collect, org.eclipse.collections.api.bag.primitive.LongBag.collect.

Doc from org.eclipse.collections.api.LongIterable.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
newWithback to summary
public ImmutableLongBag newWith(long element)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.newWith.

Annotations
@Override
newWithAllback to summary
public ImmutableLongBag newWithAll(LongIterable elements)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.newWithAll.

Annotations
@Override
newWithoutback to summary
public ImmutableLongBag newWithout(long element)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.newWithout.

Annotations
@Override
newWithoutAllback to summary
public ImmutableLongBag newWithoutAll(LongIterable elements)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.newWithoutAll.

Annotations
@Override
rejectback to summary
public ImmutableLongBag reject(LongPredicate predicate)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.reject, org.eclipse.collections.api.bag.primitive.LongBag.reject.

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

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

Annotations
@Override
selectback to summary
public ImmutableLongBag select(LongPredicate predicate)

Redeclares org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.select, org.eclipse.collections.api.bag.primitive.LongBag.select.

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

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

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

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.selectByOccurrences.

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

Annotations
@Override
Since
8.0
selectDuplicatesback to summary
public default ImmutableLongBag selectDuplicates()

Overrides default org.eclipse.collections.api.bag.primitive.LongBag.selectDuplicates.

Returns all elements of the bag that have more than one occurrence.

Annotations
@Override
Since
9.2
selectUniqueback to summary
public ImmutableLongSet selectUnique()

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.selectUnique.

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

Annotations
@Override
Since
9.2
tapback to summary
public default ImmutableLongBag tap(LongProcedure procedure)

Overrides default org.eclipse.collections.api.collection.primitive.ImmutableLongCollection.tap, org.eclipse.collections.api.bag.primitive.LongBag.tap.

Annotations
@Override
Since
9.0.
topOccurrencesback to summary
public ImmutableList<LongIntPair> topOccurrences(int count)

Redeclares org.eclipse.collections.api.bag.primitive.LongBag.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
Since
8.0