/*
 * jlib - The Free Java Library
 * 
 * http://www.jlib.org
 * 
 * Copyright (c) 2006-2008 Igor Akkerman
 * 
 * jlib is distributed under the
 * 
 * COMMON PUBLIC LICENSE VERSION 1.0
 * 
 * http://www.opensource.org/licenses/cpl1.0.php
 */

package org.jlib.container.sequence;

/**
 * Iterator over a {@link InsertSequence}.
 * 
 * @param <Element>
 *        type of elements held in the {@link Sequence}
 * 
 * @author Igor Akkerman
 */
public interface InsertSequenceIterator<Element>
extends SequenceIterator<Element> {

    /**
     * <p>
     * Inserts the specified Element into the sequence at the current position
     * of this Iterator.
     * </p>
     * <p>
     * The Element is inserted immediately before the next Element that would
     * have been returned by {@link #next()} and immediately after the previous
     * Element that would have been returned by {@link #previous()}.
     * </p>
     * <p>
     * A subsequent call to {@link #next()} would be unaffected, and a
     * subsequent call to {@link #previous()} would return the new element.
     * </p>
     * 
     * @param element
     *        Element to insert
     * 
     * @throws IllegalStateException
     *         if {@link #next()} or {@link #previous()} have not been called
     *         initially or after the last call to {@link #insert(Object)}
     */
    public void insert(Element element)
    throws IllegalStateException;

    /**
     * Returns the traversed {@link InsertSequence}
     * 
     * @return traversed {@link InsertSequence}
     */
    @Override
    public InsertSequence<Element> getSequence();
}

@@ -274,16 +274,17 @@
 uence;%0A%0A
+%0A
 /**%0A * I
@@ -1421,196 +1421,7 @@
 ion;
-%0A%0A    /**%0A     * Returns the traversed %7B@link InsertSequence%7D%0A     * %0A     * @return traversed %7B@link InsertSequence%7D%0A     */%0A    @Override%0A    public InsertSequence%3CElement%3E getSequence();
 %0A%7D%0A

Revert "InsertSequenceIterator: getSequence method added"