Interface IntegerSequence

    • Method Detail

      • length

        int length()
      • initialize

        void initialize​(int maxIndex)
        Specifies the maximum index of the array. If the maximum index is not known then a value < 0 is passed in and an exception should be thrown if this information is required NOTE: This is length - 1
        Parameters:
        maxIndex - Largest possible value in the sequence. or < 0 if unknown
      • next

        int next()
      • hasNext

        boolean hasNext()
      • requiresMaxIndex

        boolean requiresMaxIndex()