Package uk.ac.starlink.util

# Interface Sequence

public interface Sequence
Utility sub-interface of Splittable suitable for use with splittable data that can be iterated over.

The main purpose of this interface is to act as standard documentation for a `next` method where it is provided.

Since:
  13 Sep 2019
Author:
  Mark Taylor

## Method Summary

Modifier and Type
Method
Description
`boolean`
`next()`
Move to the next item in the sequence.

## Method Details

### next

boolean next() throws Exception
Move to the next item in the sequence. Must be called before accessing each item, including the first one. Returns false when there are no items left.

This method is declared to throw an untyped exception. Subinterfaces are encouraged to override this method restricting the exception type or throwing no exception.

Returns:
  true iff the current sequence element has data
Throws:
  `Exception` - if there is some failure