@@ -0,0 +1,1337 @@
+package verifier;%0A%0Aimport java.util.AbstractList;%0Aimport java.util.Map;%0Aimport java.util.Set;%0A%0A/*%0A  Interface for an object that can verify if an element can be added to a%0A    sequence.%0A*/%0Apublic interface SequenceVerifier%3CT%3E %7B%0A  public T upperBound(int index);%0A  public T lowerBound(int index);%0A%0A  // Default verification%0A  public boolean verifyElement(AbstractList%3CT%3E sequence, T element);%0A  // Verification with an extra %3Ccode%3ESet%3C/code%3E of data. May not be necessary but can be used to achieve a speed-up in some cases.%0A  public boolean verifyElement(AbstractList%3CT%3E sequence, Set%3CT%3E set, T elements);%0A  // Verification with an extra %3Ccode%3EMap%3C/code%3E of data. May not be necessary but can be used to achieve a speed-up in some cases.%0A  public boolean verifyElement(AbstractList%3CT%3E sequence, Map%3CT, T%3E map, T element);%0A%0A  /*%0A    Default verification with an indicator.%0A%0A    The indicator should be used to pass information about the next term in the%0A      sequence to the caller.%0A  */%0A  public T indicatorVerify(AbstractList%3CT%3E sequence, T element);%0A  // IndicatorVerification with an extra %3Ccode%3ESet%3C/code%3E of data.%0A  public T indicatorVerify(AbstractList%3CT%3E sequence, Set%3CT%3E set, T element);%0A  // Verification with an extra %3Ccode%3EMap%3C/code%3E of data.%0A  public T indicatorVerify(AbstractList%3CT%3E sequence, Map%3CT, T%3E map, T element);%0A%7D%0A

Create SequenceVerifier.java