Class BooleanBigLists.Singleton

java.lang.Object
java.util.AbstractCollection<Boolean>
it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
it.unimi.dsi.fastutil.booleans.AbstractBooleanBigList
it.unimi.dsi.fastutil.booleans.BooleanBigLists.Singleton
All Implemented Interfaces:
it.unimi.dsi.fastutil.BigList<Boolean>, BooleanBigList, it.unimi.dsi.fastutil.booleans.BooleanCollection, it.unimi.dsi.fastutil.booleans.BooleanIterable, it.unimi.dsi.fastutil.booleans.BooleanStack, it.unimi.dsi.fastutil.Size64, it.unimi.dsi.fastutil.Stack<Boolean>, Serializable, Cloneable, Comparable<it.unimi.dsi.fastutil.BigList<? extends Boolean>>, Iterable<Boolean>, Collection<Boolean>
Enclosing class:
BooleanBigLists

public static class BooleanBigLists.Singleton extends AbstractBooleanBigList implements Serializable, Cloneable
An immutable class representing a type-specific singleton big list.

This class may be useful to implement your own in case you subclass a type-specific big list.

See Also:
  • Constructor Details

    • Singleton

      protected Singleton(boolean element)
  • Method Details

    • getBoolean

      public boolean getBoolean(long i)
      Description copied from interface: BooleanBigList
      Returns the element at the specified position.
      Specified by:
      getBoolean in interface BooleanBigList
      See Also:
      • BigList.get(long)
    • rem

      public boolean rem(boolean k)
      Description copied from class: AbstractBooleanBigList
      Removes a single instance of the specified element from this collection, if it is present (optional operation).
      Specified by:
      rem in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      rem in class AbstractBooleanBigList
      See Also:
    • removeBoolean

      public boolean removeBoolean(long i)
      Description copied from class: AbstractBooleanBigList
      Removes the element at the specified position.
      Specified by:
      removeBoolean in interface BooleanBigList
      Overrides:
      removeBoolean in class AbstractBooleanBigList
      See Also:
      • BigList.remove(long)
    • contains

      public boolean contains(boolean k)
      Description copied from class: AbstractBooleanBigList
      Returns true if this list contains the specified element.
      Specified by:
      contains in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      contains in class AbstractBooleanBigList
      See Also:
    • indexOf

      public long indexOf(boolean k)
      Description copied from interface: BooleanBigList
      Returns the index of the first occurrence of the specified element in this type-specific big list, or -1 if this big list does not contain the element.
      Specified by:
      indexOf in interface BooleanBigList
      Overrides:
      indexOf in class AbstractBooleanBigList
      See Also:
      • BigList.indexOf(Object)
    • toBooleanArray

      public boolean[] toBooleanArray()
      Specified by:
      toBooleanArray in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      toBooleanArray in class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
    • listIterator

      public it.unimi.dsi.fastutil.booleans.BooleanBigListIterator listIterator()
      Description copied from class: AbstractBooleanBigList
      Returns a type-specific big-list iterator on this type-specific big list.
      Specified by:
      listIterator in interface it.unimi.dsi.fastutil.BigList<Boolean>
      Specified by:
      listIterator in interface BooleanBigList
      Overrides:
      listIterator in class AbstractBooleanBigList
      See Also:
      • BigList.listIterator()
    • listIterator

      public it.unimi.dsi.fastutil.booleans.BooleanBigListIterator listIterator(long i)
      Description copied from class: AbstractBooleanBigList
      Returns a type-specific list iterator on this type-specific big list starting at a given index.
      Specified by:
      listIterator in interface it.unimi.dsi.fastutil.BigList<Boolean>
      Specified by:
      listIterator in interface BooleanBigList
      Overrides:
      listIterator in class AbstractBooleanBigList
      See Also:
      • BigList.listIterator(long)
    • spliterator

      public it.unimi.dsi.fastutil.booleans.BooleanSpliterator spliterator()
      Description copied from interface: BooleanBigList
      Returns a type-specific spliterator on the elements of this big-list.

      BigList spliterators must report at least Spliterator.SIZED and Spliterator.ORDERED.

      See List.spliterator() for more documentation on the requirements of the returned spliterator (despite BigList not being a List, most of the same requirements apply.

      Specified by:
      spliterator in interface BooleanBigList
      Specified by:
      spliterator in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Specified by:
      spliterator in interface it.unimi.dsi.fastutil.booleans.BooleanIterable
      Specified by:
      spliterator in interface Collection<Boolean>
      Specified by:
      spliterator in interface Iterable<Boolean>
      Returns:
    • subList

      public BooleanBigList subList(long from, long to)
      Description copied from interface: BooleanBigList
      Returns a type-specific view of the portion of this type-specific big list from the index from, inclusive, to the index to, exclusive.
      Specified by:
      subList in interface it.unimi.dsi.fastutil.BigList<Boolean>
      Specified by:
      subList in interface BooleanBigList
      Overrides:
      subList in class AbstractBooleanBigList
      See Also:
      • BigList.subList(long,long)
    • addAll

      public boolean addAll(long i, Collection<? extends Boolean> c)
      Description copied from class: AbstractBooleanBigList
      Adds all of the elements in the specified collection to this list (optional operation).
      Specified by:
      addAll in interface it.unimi.dsi.fastutil.BigList<Boolean>
      Overrides:
      addAll in class AbstractBooleanBigList
    • addAll

      public boolean addAll(Collection<? extends Boolean> c)
      Description copied from class: AbstractBooleanBigList
      Specified by:
      addAll in interface Collection<Boolean>
      Overrides:
      addAll in class AbstractBooleanBigList
    • removeAll

      public boolean removeAll(Collection<?> c)
      Specified by:
      removeAll in interface Collection<Boolean>
      Overrides:
      removeAll in class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
    • retainAll

      public boolean retainAll(Collection<?> c)
      Specified by:
      retainAll in interface Collection<Boolean>
      Overrides:
      retainAll in class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
    • addAll

      public boolean addAll(BooleanBigList c)
      Description copied from interface: BooleanBigList
      Appends all of the elements in the specified type-specific big list to the end of this type-specific big list (optional operation).
      Specified by:
      addAll in interface BooleanBigList
      See Also:
    • addAll

      public boolean addAll(long i, BooleanBigList c)
      Description copied from interface: BooleanBigList
      Inserts all of the elements in the specified type-specific big list into this type-specific big list at the specified position (optional operation).
      Specified by:
      addAll in interface BooleanBigList
      See Also:
      • BigList.addAll(long,Collection)
    • addAll

      public boolean addAll(long i, it.unimi.dsi.fastutil.booleans.BooleanCollection c)
      Description copied from class: AbstractBooleanBigList
      Inserts all of the elements in the specified type-specific collection into this type-specific big list at the specified position (optional operation).
      Specified by:
      addAll in interface BooleanBigList
      Overrides:
      addAll in class AbstractBooleanBigList
      See Also:
    • addAll

      public boolean addAll(it.unimi.dsi.fastutil.booleans.BooleanCollection c)
      Description copied from class: AbstractBooleanBigList
      Specified by:
      addAll in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      addAll in class AbstractBooleanBigList
    • removeAll

      public boolean removeAll(it.unimi.dsi.fastutil.booleans.BooleanCollection c)
      Specified by:
      removeAll in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      removeAll in class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
    • retainAll

      public boolean retainAll(it.unimi.dsi.fastutil.booleans.BooleanCollection c)
      Specified by:
      retainAll in interface it.unimi.dsi.fastutil.booleans.BooleanCollection
      Overrides:
      retainAll in class it.unimi.dsi.fastutil.booleans.AbstractBooleanCollection
    • clear

      public void clear()
      Description copied from class: AbstractBooleanBigList
      Specified by:
      clear in interface Collection<Boolean>
      Overrides:
      clear in class AbstractBooleanBigList
    • size64

      public long size64()
      Specified by:
      size64 in interface it.unimi.dsi.fastutil.Size64
    • clone

      public Object clone()
      Overrides:
      clone in class Object