@ThreadSafe public final class SynchronizedBooleanBag extends AbstractSynchronizedBooleanCollection implements com.gs.collections.api.bag.primitive.MutableBooleanBag
MutableBooleanBag. It is imperative that the user manually synchronize on the collection when iterating over it using the
BooleanIterator, as per Collections.synchronizedCollection(Collection).
This file was automatically generated from template file synchronizedPrimitiveBag.stg.
MutableBooleanBag.asSynchronized(),
MutableBag.asSynchronized(),
Serialized Form| Modifier and Type | Method and Description |
|---|---|
void |
addOccurrences(boolean item,
int occurrences) |
com.gs.collections.api.LazyBooleanIterable |
asLazy() |
com.gs.collections.api.bag.primitive.MutableBooleanBag |
asSynchronized() |
com.gs.collections.api.bag.primitive.MutableBooleanBag |
asUnmodifiable() |
<V> com.gs.collections.api.bag.MutableBag<V> |
collect(com.gs.collections.api.block.function.primitive.BooleanToObjectFunction<? extends V> function) |
boolean |
equals(java.lang.Object otherBag)
Follows the same general contract as
Bag.equals(Object). |
void |
forEachWithOccurrences(com.gs.collections.api.block.procedure.primitive.BooleanIntProcedure procedure)
For each distinct item, with the number of occurrences, execute the specified procedure.
|
int |
hashCode()
Follows the same general contract as
Bag.hashCode(). |
<T> T |
injectInto(T injectedValue,
com.gs.collections.api.block.function.primitive.ObjectBooleanToObjectFunction<? super T,? extends T> function) |
int |
occurrencesOf(boolean item)
The occurrences of a distinct item in the bag.
|
com.gs.collections.api.bag.primitive.MutableBooleanBag |
reject(com.gs.collections.api.block.predicate.primitive.BooleanPredicate predicate) |
boolean |
removeOccurrences(boolean item,
int occurrences) |
com.gs.collections.api.bag.primitive.MutableBooleanBag |
select(com.gs.collections.api.block.predicate.primitive.BooleanPredicate predicate) |
int |
sizeDistinct()
The size of the Bag when counting only distinct elements.
|
com.gs.collections.api.bag.primitive.ImmutableBooleanBag |
toImmutable()
Returns an immutable copy of this bag.
|
SynchronizedBooleanBag |
with(boolean element) |
SynchronizedBooleanBag |
withAll(com.gs.collections.api.BooleanIterable elements) |
SynchronizedBooleanBag |
without(boolean element) |
SynchronizedBooleanBag |
withoutAll(com.gs.collections.api.BooleanIterable elements) |
add, addAll, addAll, allSatisfy, anySatisfy, appendString, appendString, appendString, booleanIterator, clear, contains, containsAll, containsAll, count, detectIfNone, forEach, getBooleanCollection, getLock, isEmpty, makeString, makeString, makeString, noneSatisfy, notEmpty, remove, removeAll, removeAll, retainAll, retainAll, size, toArray, toBag, toList, toSet, toStringclone, finalize, getClass, notify, notifyAll, wait, wait, waitadd, addAll, addAll, clear, remove, removeAll, removeAll, retainAll, retainAllpublic SynchronizedBooleanBag with(boolean element)
with in interface com.gs.collections.api.bag.primitive.MutableBooleanBagwith in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionwith in class AbstractSynchronizedBooleanCollectionpublic SynchronizedBooleanBag without(boolean element)
without in interface com.gs.collections.api.bag.primitive.MutableBooleanBagwithout in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionwithout in class AbstractSynchronizedBooleanCollectionpublic SynchronizedBooleanBag withAll(com.gs.collections.api.BooleanIterable elements)
withAll in interface com.gs.collections.api.bag.primitive.MutableBooleanBagwithAll in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionwithAll in class AbstractSynchronizedBooleanCollectionpublic SynchronizedBooleanBag withoutAll(com.gs.collections.api.BooleanIterable elements)
withoutAll in interface com.gs.collections.api.bag.primitive.MutableBooleanBagwithoutAll in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionwithoutAll in class AbstractSynchronizedBooleanCollectionpublic void addOccurrences(boolean item,
int occurrences)
addOccurrences in interface com.gs.collections.api.bag.primitive.MutableBooleanBagpublic boolean removeOccurrences(boolean item,
int occurrences)
removeOccurrences in interface com.gs.collections.api.bag.primitive.MutableBooleanBagpublic int sizeDistinct()
com.gs.collections.api.bag.primitive.BooleanBagsizeDistinct in interface com.gs.collections.api.bag.primitive.BooleanBagpublic int occurrencesOf(boolean item)
com.gs.collections.api.bag.primitive.BooleanBagoccurrencesOf in interface com.gs.collections.api.bag.primitive.BooleanBagpublic void forEachWithOccurrences(com.gs.collections.api.block.procedure.primitive.BooleanIntProcedure procedure)
com.gs.collections.api.bag.primitive.BooleanBagforEachWithOccurrences in interface com.gs.collections.api.bag.primitive.BooleanBagpublic com.gs.collections.api.bag.primitive.MutableBooleanBag select(com.gs.collections.api.block.predicate.primitive.BooleanPredicate predicate)
select in interface com.gs.collections.api.bag.primitive.BooleanBagselect in interface com.gs.collections.api.bag.primitive.MutableBooleanBagselect in interface com.gs.collections.api.BooleanIterableselect in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionselect in class AbstractSynchronizedBooleanCollectionpublic com.gs.collections.api.bag.primitive.MutableBooleanBag reject(com.gs.collections.api.block.predicate.primitive.BooleanPredicate predicate)
reject in interface com.gs.collections.api.bag.primitive.BooleanBagreject in interface com.gs.collections.api.bag.primitive.MutableBooleanBagreject in interface com.gs.collections.api.BooleanIterablereject in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionreject in class AbstractSynchronizedBooleanCollectionpublic <V> com.gs.collections.api.bag.MutableBag<V> collect(com.gs.collections.api.block.function.primitive.BooleanToObjectFunction<? extends V> function)
collect in interface com.gs.collections.api.bag.primitive.BooleanBagcollect in interface com.gs.collections.api.bag.primitive.MutableBooleanBagcollect in interface com.gs.collections.api.BooleanIterablecollect in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectioncollect in class AbstractSynchronizedBooleanCollectionpublic boolean equals(java.lang.Object otherBag)
com.gs.collections.api.bag.primitive.BooleanBagBag.equals(Object).equals in interface com.gs.collections.api.bag.primitive.BooleanBagequals in class java.lang.Objectpublic int hashCode()
com.gs.collections.api.bag.primitive.BooleanBagBag.hashCode().hashCode in interface com.gs.collections.api.bag.primitive.BooleanBaghashCode in class java.lang.Objectpublic com.gs.collections.api.LazyBooleanIterable asLazy()
asLazy in interface com.gs.collections.api.BooleanIterableasLazy in class AbstractSynchronizedBooleanCollectionpublic com.gs.collections.api.bag.primitive.MutableBooleanBag asUnmodifiable()
asUnmodifiable in interface com.gs.collections.api.bag.primitive.MutableBooleanBagasUnmodifiable in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionasUnmodifiable in class AbstractSynchronizedBooleanCollectionpublic com.gs.collections.api.bag.primitive.MutableBooleanBag asSynchronized()
asSynchronized in interface com.gs.collections.api.bag.primitive.MutableBooleanBagasSynchronized in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectionasSynchronized in class AbstractSynchronizedBooleanCollectionpublic com.gs.collections.api.bag.primitive.ImmutableBooleanBag toImmutable()
com.gs.collections.api.bag.primitive.MutableBooleanBagtoImmutable in interface com.gs.collections.api.bag.primitive.BooleanBagtoImmutable in interface com.gs.collections.api.bag.primitive.MutableBooleanBagtoImmutable in interface com.gs.collections.api.collection.primitive.MutableBooleanCollectiontoImmutable in class AbstractSynchronizedBooleanCollectionpublic <T> T injectInto(T injectedValue,
com.gs.collections.api.block.function.primitive.ObjectBooleanToObjectFunction<? super T,? extends T> function)
injectInto in interface com.gs.collections.api.BooleanIterableinjectInto in class AbstractSynchronizedBooleanCollection