ImmutableShortCollection
, PrimitiveIterable
, ShortBag
, ShortIterable
public interface ImmutableShortBag extends ImmutableShortCollection, ShortBag
Modifier and Type | Method | Description |
---|---|---|
ImmutableList<ShortIntPair> |
bottomOccurrences(int count) |
Returns the
count least frequently occurring items. |
<V> ImmutableBag<V> |
collect(ShortToObjectFunction<? extends V> function) |
Returns a new collection with the results of applying the specified function on each element of the source
collection.
|
ImmutableShortBag |
newWith(short element) |
|
ImmutableShortBag |
newWithAll(ShortIterable elements) |
|
ImmutableShortBag |
newWithout(short element) |
|
ImmutableShortBag |
newWithoutAll(ShortIterable elements) |
|
ImmutableShortBag |
reject(ShortPredicate predicate) |
Returns a new ShortIterable with all of the elements in the ShortIterable that
return false for the specified predicate.
|
ImmutableShortBag |
select(ShortPredicate predicate) |
Returns a new ShortIterable with all of the elements in the ShortIterable that
return true for the specified predicate.
|
ImmutableShortBag |
selectByOccurrences(IntPredicate predicate) |
Returns all elements of the bag that have a number of occurrences that satisfy the predicate.
|
default ImmutableShortBag |
selectDuplicates() |
Returns all elements of the bag that have more than one occurrence.
|
ImmutableShortSet |
selectUnique() |
Returns all elements of the bag that have exactly one occurrence.
|
default ImmutableShortBag |
tap(ShortProcedure procedure) |
|
ImmutableList<ShortIntPair> |
topOccurrences(int count) |
Returns the
count most frequently occurring items. |
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
equals, forEachWithOccurrences, hashCode, occurrencesOf, sizeDistinct, toImmutable, toStringOfItemToCount
allSatisfy, anySatisfy, asLazy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, count, detectIfNone, each, flatCollect, forEach, injectInto, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, shortIterator, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedList
ImmutableShortBag select(ShortPredicate predicate)
ShortIterable
select
in interface ImmutableShortCollection
select
in interface ShortBag
select
in interface ShortIterable
ImmutableShortBag reject(ShortPredicate predicate)
ShortIterable
reject
in interface ImmutableShortCollection
reject
in interface ShortBag
reject
in interface ShortIterable
default ImmutableShortBag tap(ShortProcedure procedure)
tap
in interface ImmutableShortCollection
tap
in interface ShortBag
tap
in interface ShortIterable
ImmutableShortBag selectByOccurrences(IntPredicate predicate)
selectByOccurrences
in interface ShortBag
default ImmutableShortBag selectDuplicates()
selectDuplicates
in interface ShortBag
ImmutableShortSet selectUnique()
selectUnique
in interface ShortBag
ImmutableList<ShortIntPair> topOccurrences(int count)
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.topOccurrences
in interface ShortBag
ImmutableList<ShortIntPair> bottomOccurrences(int count)
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.bottomOccurrences
in interface ShortBag
<V> ImmutableBag<V> collect(ShortToObjectFunction<? extends V> function)
ShortIterable
collect
in interface ImmutableShortCollection
collect
in interface ShortBag
collect
in interface ShortIterable
ImmutableShortBag newWith(short element)
newWith
in interface ImmutableShortCollection
ImmutableShortBag newWithout(short element)
newWithout
in interface ImmutableShortCollection
ImmutableShortBag newWithAll(ShortIterable elements)
newWithAll
in interface ImmutableShortCollection
ImmutableShortBag newWithoutAll(ShortIterable elements)
newWithoutAll
in interface ImmutableShortCollection
Copyright © 2004–2019. All rights reserved.