Class AbstractIntSet

  • All Implemented Interfaces:
    IntSet

    public abstract class AbstractIntSet
    extends java.lang.Object
    implements IntSet

    Copyright: Copyright (c) 2007

    Company: Clark & Parsia, LLC.

    Author:
    Evren Sirin
    • Constructor Summary

      Constructors 
      Constructor Description
      AbstractIntSet()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addAll​(IntSet values)
      Adds all the integers from another set to this set.
      int max()
      Returns the maximum integer in this set.
      int min()
      Returns the minimum integer in this set.
      java.lang.String toString()  
      IntSet union​(IntSet values)
      Creates a new IntSet that is the union of this set and the given set.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Constructor Detail

      • AbstractIntSet

        public AbstractIntSet()
    • Method Detail

      • addAll

        public void addAll​(IntSet values)
        Description copied from interface: IntSet
        Adds all the integers from another set to this set.
        Specified by:
        addAll in interface IntSet
        Parameters:
        values - the set whose elements will be added
      • max

        public int max()
        Description copied from interface: IntSet
        Returns the maximum integer in this set.
        Specified by:
        max in interface IntSet
        Returns:
        the maximum integer in this set
      • min

        public int min()
        Description copied from interface: IntSet
        Returns the minimum integer in this set.
        Specified by:
        min in interface IntSet
        Returns:
        the minimum integer in this set
      • union

        public IntSet union​(IntSet values)
        Description copied from interface: IntSet
        Creates a new IntSet that is the union of this set and the given set. Neither of the sets are changed by this operation.
        Specified by:
        union in interface IntSet
        Parameters:
        values - the other set that will be included in the union result
        Returns:
        a new IntSet instance that is the union of two sets
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object