Package it.unimi.dsi.fastutil.booleans
Class AbstractBooleanSet
java.lang.Object
java.util.AbstractCollection<Boolean>
it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
it.unimi.dsi.fastutil.booleans.AbstractBooleanSet
- All Implemented Interfaces:
it.unimi.dsi.fastutil.booleans.BooleanCollection,it.unimi.dsi.fastutil.booleans.BooleanIterable,BooleanSet,Cloneable,Iterable<Boolean>,Collection<Boolean>,Set<Boolean>
- Direct Known Subclasses:
BooleanArraySet,BooleanOpenHashSet,BooleanSets.Singleton
public abstract class AbstractBooleanSet
extends it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
implements Cloneable, BooleanSet
An abstract class providing basic methods for sets implementing a type-specific interface.
Note that the type-specific Set interface adds a type-specific remove()
method, as it is no longer harmful for subclasses. Thus, concrete subclasses of this class
must implement remove() (the rem() implementation of this
class just delegates to remove()).
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleaninthashCode()Returns a hash code for this set.abstract it.unimi.dsi.fastutil.booleans.BooleanIteratoriterator()Returns a type-specific iterator on the elements of this set.booleanrem(boolean k) Deprecated.booleanremove(boolean k) Removes an element from this set.Methods inherited from class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
add, add, addAll, addAll, contains, contains, containsAll, containsAll, remove, removeAll, removeAll, retainAll, retainAll, toArray, toBooleanArray, toBooleanArray, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface it.unimi.dsi.fastutil.booleans.BooleanCollection
add, addAll, contains, containsAll, removeAll, removeIf, removeIf, retainAll, toArray, toBooleanArray, toBooleanArrayMethods inherited from interface it.unimi.dsi.fastutil.booleans.BooleanIterable
forEach, forEachMethods inherited from interface it.unimi.dsi.fastutil.booleans.BooleanSet
add, contains, remove, spliteratorMethods inherited from interface java.util.Collection
parallelStream, stream, toArray
-
Constructor Details
-
AbstractBooleanSet
protected AbstractBooleanSet()
-
-
Method Details
-
iterator
public abstract it.unimi.dsi.fastutil.booleans.BooleanIterator iterator()Description copied from interface:BooleanSetReturns a type-specific iterator on the elements of this set.- Specified by:
iteratorin interfaceit.unimi.dsi.fastutil.booleans.BooleanCollection- Specified by:
iteratorin interfaceit.unimi.dsi.fastutil.booleans.BooleanIterable- Specified by:
iteratorin interfaceBooleanSet- Specified by:
iteratorin interfaceCollection<Boolean>- Specified by:
iteratorin interfaceIterable<Boolean>- Specified by:
iteratorin interfaceSet<Boolean>- Specified by:
iteratorin classit.unimi.dsi.fastutil.booleans.AbstractBooleanCollection- Returns:
- a type-specific iterator on the elements of this set.
-
equals
-
hashCode
public int hashCode()Returns a hash code for this set. The hash code of a set is computed by summing the hash codes of its elements. -
remove
public boolean remove(boolean k) Removes an element from this set. Delegates to the type-specificrem()method implemented by type-specific abstractCollectionsuperclass.- Specified by:
removein interfaceBooleanSet- See Also:
-
rem
Deprecated.Please useremove()instead.Removes an element from this set.This method is inherited from the type-specific collection this type-specific set is based on, but it should not used as this interface reinstates
remove()as removal method. Delegates to the type-specificremove()method specified in the type-specificSetinterface.- Specified by:
remin interfaceit.unimi.dsi.fastutil.booleans.BooleanCollection- Specified by:
remin interfaceBooleanSet- Overrides:
remin classit.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
-
remove()instead.