public interface MutableByteBag extends MutableByteCollection, ByteBag
Modifier and Type | Method and Description |
---|---|
void |
addOccurrences(byte item,
int occurrences) |
MutableByteBag |
asSynchronized() |
MutableByteBag |
asUnmodifiable() |
MutableList<ByteIntPair> |
bottomOccurrences(int count)
Returns the
count least frequently occurring items. |
<V> MutableBag<V> |
collect(ByteToObjectFunction<? extends V> function) |
MutableByteBag |
reject(BytePredicate predicate) |
boolean |
removeOccurrences(byte item,
int occurrences) |
MutableByteBag |
select(BytePredicate predicate) |
MutableByteBag |
selectByOccurrences(IntPredicate predicate)
Returns all elements of the bag that have a number of occurrences that satisfy the predicate.
|
ImmutableByteBag |
toImmutable()
Returns an immutable copy of this bag.
|
MutableList<ByteIntPair> |
topOccurrences(int count)
Returns the
count most frequently occurring items. |
MutableByteBag |
with(byte element) |
MutableByteBag |
withAll(ByteIterable elements) |
MutableByteBag |
without(byte element) |
MutableByteBag |
withoutAll(ByteIterable elements) |
add, addAll, addAll, byteIterator, clear, remove, removeAll, removeAll, retainAll, retainAll
equals, forEachWithOccurrences, hashCode, occurrencesOf, sizeDistinct
allSatisfy, anySatisfy, asLazy, average, contains, containsAll, containsAll, count, detectIfNone, each, forEach, injectInto, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedList
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
void addOccurrences(byte item, int occurrences)
boolean removeOccurrences(byte item, int occurrences)
MutableByteBag selectByOccurrences(IntPredicate predicate)
selectByOccurrences
in interface ByteBag
MutableList<ByteIntPair> 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 ByteBag
MutableList<ByteIntPair> 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 ByteBag
MutableByteBag select(BytePredicate predicate)
select
in interface ByteBag
select
in interface ByteIterable
select
in interface MutableByteCollection
MutableByteBag reject(BytePredicate predicate)
reject
in interface ByteBag
reject
in interface ByteIterable
reject
in interface MutableByteCollection
<V> MutableBag<V> collect(ByteToObjectFunction<? extends V> function)
collect
in interface ByteBag
collect
in interface ByteIterable
collect
in interface MutableByteCollection
MutableByteBag with(byte element)
with
in interface MutableByteCollection
MutableByteBag without(byte element)
without
in interface MutableByteCollection
MutableByteBag withAll(ByteIterable elements)
withAll
in interface MutableByteCollection
MutableByteBag withoutAll(ByteIterable elements)
withoutAll
in interface MutableByteCollection
MutableByteBag asUnmodifiable()
asUnmodifiable
in interface MutableByteCollection
MutableByteBag asSynchronized()
asSynchronized
in interface MutableByteCollection
ImmutableByteBag toImmutable()
toImmutable
in interface ByteBag
toImmutable
in interface MutableByteCollection
Copyright © 2004–2016. All rights reserved.