001package Torello.HTML.NodeSearch;
002
003/**
004 * If a second modification is attempted on an HTML-Iterator, <I>before a call to a {@code next(),
005 * previous(), first(), last()} has been invoked,</I> then the HTML-Iterators will throw the
006 * <CODE>SecondModificationException</CODE>. 
007 * 
008 * This exception is used by the {@code HNLIInclusive} &amp; {@code HNLI Iterator's}.  When
009 * modifying, updating, or changing the contents of the previous {@code Iterator} match, only
010 * one modification method may be called using the {@code Iterator's} <B>set, add</B> and
011 * <B>remove</B> operations between each iteration.
012 * 
013 * @see HNLIInclusive
014 * @see HNLI
015 */
016public class SecondModificationException extends IllegalStateException
017{
018    /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUIDEX>  */
019    public static final long serialVersionUID = 1;
020
021    /** Constructs a {@code SecondModificationException} with no detail message. */
022    public SecondModificationException()
023    { super(); }
024
025    /**
026     * Constructs a {@code SecondModificationException} with the specified detail message.
027     * @param message the detail message.
028     */
029    public SecondModificationException(String message)
030    { super(message); }
031
032    /**
033     * Constructs a new exception with the specified detail message and cause.
034     * 
035     * <BR /><BR /><B CLASS=JDDescLabel>NOTE:</B>
036     * 
037     * <BR /><BR />The detail message associated with cause is not automatically incorporated into
038     * this exception's detail message.
039     * 
040     * @param message The detail message (which is saved for later retrieval by the
041     * {@code Throwable.getMessage()} method).
042     * 
043     * @param cause the cause (which is saved for later retrieval by the
044     * {@code Throwable.getCause()} method).  (A null value is permitted, and indicates that the
045     * cause is nonexistent or unknown.)
046     */
047    public SecondModificationException(String message, Throwable cause)
048    { super(message, cause); }
049
050    /**
051     * Constructs a new exception with the specified cause and a detail message of
052     * {@code (cause==null ? null : cause.toString())} (which typically contains the class and
053     * detail message of cause).
054     * 
055     * <BR /><BR />This constructor is useful for exceptions that are little more than wrappers for
056     * other throwables.
057     * 
058     * @param cause The cause (which is saved for later retrieval by the
059     * {@code Throwable.getCause()} method).  (A null value is permitted, and indicates that the
060     * cause is nonexistent or unknown.)
061     */
062    public SecondModificationException(Throwable cause)
063    { super(cause); }
064
065}