Class UnmodifiableShortBag
- java.lang.Object
-
- org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableShortCollection
-
- org.eclipse.collections.impl.bag.mutable.primitive.UnmodifiableShortBag
-
- All Implemented Interfaces:
Serializable
,MutableShortBag
,ShortBag
,MutableShortCollection
,PrimitiveIterable
,ShortIterable
public class UnmodifiableShortBag extends AbstractUnmodifiableShortCollection implements MutableShortBag
This file was automatically generated from template file unmodifiablePrimitiveBag.stg.- Since:
- 3.1.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description UnmodifiableShortBag(MutableShortBag bag)
-
Method Summary
-
Methods inherited from class org.eclipse.collections.impl.collection.mutable.primitive.AbstractUnmodifiableShortCollection
add, addAll, addAll, allSatisfy, anySatisfy, appendString, appendString, appendString, asLazy, average, chunk, clear, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, injectInto, isEmpty, makeString, makeString, makeString, max, maxIfEmpty, median, min, minIfEmpty, noneSatisfy, notEmpty, reduce, reduceIfEmpty, remove, removeAll, removeAll, removeIf, retainAll, retainAll, shortIterator, size, sum, toArray, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toString
-
Methods inherited from interface org.eclipse.collections.api.bag.primitive.MutableShortBag
selectDuplicates, tap
-
Methods inherited from interface org.eclipse.collections.api.collection.primitive.MutableShortCollection
add, addAll, addAll, clear, remove, removeAll, removeAll, removeIf, retainAll, retainAll, shortIterator
-
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size, toString
-
Methods inherited from interface org.eclipse.collections.api.bag.primitive.ShortBag
toStringOfItemToCount
-
Methods inherited from interface org.eclipse.collections.api.ShortIterable
allSatisfy, anySatisfy, asLazy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, flatCollect, forEach, injectInto, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toSortedList, toSortedListBy, toSortedListBy
-
-
-
-
Constructor Detail
-
UnmodifiableShortBag
public UnmodifiableShortBag(MutableShortBag bag)
-
-
Method Detail
-
with
public UnmodifiableShortBag with(short element)
- Specified by:
with
in interfaceMutableShortBag
- Specified by:
with
in interfaceMutableShortCollection
- Overrides:
with
in classAbstractUnmodifiableShortCollection
-
without
public UnmodifiableShortBag without(short element)
- Specified by:
without
in interfaceMutableShortBag
- Specified by:
without
in interfaceMutableShortCollection
- Overrides:
without
in classAbstractUnmodifiableShortCollection
-
withAll
public UnmodifiableShortBag withAll(ShortIterable elements)
- Specified by:
withAll
in interfaceMutableShortBag
- Specified by:
withAll
in interfaceMutableShortCollection
- Overrides:
withAll
in classAbstractUnmodifiableShortCollection
-
withoutAll
public UnmodifiableShortBag withoutAll(ShortIterable elements)
- Specified by:
withoutAll
in interfaceMutableShortBag
- Specified by:
withoutAll
in interfaceMutableShortCollection
- Overrides:
withoutAll
in classAbstractUnmodifiableShortCollection
-
addOccurrences
public void addOccurrences(short item, int occurrences)
- Specified by:
addOccurrences
in interfaceMutableShortBag
-
removeOccurrences
public boolean removeOccurrences(short item, int occurrences)
- Specified by:
removeOccurrences
in interfaceMutableShortBag
-
sizeDistinct
public int sizeDistinct()
- Specified by:
sizeDistinct
in interfaceShortBag
-
occurrencesOf
public int occurrencesOf(short item)
- Specified by:
occurrencesOf
in interfaceShortBag
-
forEachWithOccurrences
public void forEachWithOccurrences(ShortIntProcedure procedure)
- Specified by:
forEachWithOccurrences
in interfaceShortBag
-
selectByOccurrences
public MutableShortBag selectByOccurrences(IntPredicate predicate)
- Specified by:
selectByOccurrences
in interfaceMutableShortBag
- Specified by:
selectByOccurrences
in interfaceShortBag
-
selectUnique
public MutableShortSet selectUnique()
- Specified by:
selectUnique
in interfaceMutableShortBag
- Specified by:
selectUnique
in interfaceShortBag
-
topOccurrences
public MutableList<ShortIntPair> topOccurrences(int count)
- Specified by:
topOccurrences
in interfaceMutableShortBag
- Specified by:
topOccurrences
in interfaceShortBag
-
bottomOccurrences
public MutableList<ShortIntPair> bottomOccurrences(int count)
- Specified by:
bottomOccurrences
in interfaceMutableShortBag
- Specified by:
bottomOccurrences
in interfaceShortBag
-
select
public MutableShortBag select(ShortPredicate predicate)
- Specified by:
select
in interfaceMutableShortBag
- Specified by:
select
in interfaceMutableShortCollection
- Specified by:
select
in interfaceShortBag
- Specified by:
select
in interfaceShortIterable
- Overrides:
select
in classAbstractUnmodifiableShortCollection
-
reject
public MutableShortBag reject(ShortPredicate predicate)
- Specified by:
reject
in interfaceMutableShortBag
- Specified by:
reject
in interfaceMutableShortCollection
- Specified by:
reject
in interfaceShortBag
- Specified by:
reject
in interfaceShortIterable
- Overrides:
reject
in classAbstractUnmodifiableShortCollection
-
collect
public <V> MutableBag<V> collect(ShortToObjectFunction<? extends V> function)
- Specified by:
collect
in interfaceMutableShortBag
- Specified by:
collect
in interfaceMutableShortCollection
- Specified by:
collect
in interfaceShortBag
- Specified by:
collect
in interfaceShortIterable
- Overrides:
collect
in classAbstractUnmodifiableShortCollection
-
equals
public boolean equals(Object otherBag)
-
hashCode
public int hashCode()
-
asUnmodifiable
public MutableShortBag asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableShortBag
- Specified by:
asUnmodifiable
in interfaceMutableShortCollection
- Overrides:
asUnmodifiable
in classAbstractUnmodifiableShortCollection
-
asSynchronized
public MutableShortBag asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableShortBag
- Specified by:
asSynchronized
in interfaceMutableShortCollection
- Overrides:
asSynchronized
in classAbstractUnmodifiableShortCollection
-
toImmutable
public ImmutableShortBag toImmutable()
- Specified by:
toImmutable
in interfaceMutableShortBag
- Specified by:
toImmutable
in interfaceMutableShortCollection
- Specified by:
toImmutable
in interfaceShortBag
- Overrides:
toImmutable
in classAbstractUnmodifiableShortCollection
-
newEmpty
public MutableShortBag newEmpty()
- Specified by:
newEmpty
in interfaceMutableShortBag
- Specified by:
newEmpty
in interfaceMutableShortCollection
- Since:
- 9.2.
-
-