1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
package Torello.HTML;

import Torello.Java.ExceptionCheckError;

/**
 * Thrown during a {@link Replaceable} HTML-{@code Vector} update operation when two consecutive
 * {@link Replaceable} instances appear to point to overlapping indices within the {@code Vector}.
 * 
 * <EMBED CLASS='external-html' DATA-FILE-ID=REX_METHOD_LOC_NOTE>
 */
public class ReplaceablesOverlappingException extends ReplaceableException
{
    /** <EMBED CLASS='external-html' DATA-FILE-ID=SVUIDEX> */
    public static final long serialVersionUID = 1;

    /**
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF>
     * 
     * A reference to the <B STYLE='color: red'>first</B> {@link Replaceable} which caused this
     * exception to throw
     */
    public final Replaceable r1;

    /**
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF>
     * 
     * A reference to the <B STYLE='color: red'>second</B> {@link Replaceable} which caused this
     * exception to throw
     */
    public final Replaceable r2;

    /**
     * Constructs a {@code ReplaceablesOverlappingException} with no detail message.
     * 
     * @param r1 A reference to the <B STYLE='color: red'>first</B> {@link Replaceable} which caused
     * this exception to throw 
     * 
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF_PARAM>
     * 
     * @param r2 A reference to the <B STYLE='color: red'>second</B> {@link Replaceable} which caused
     * this exception to throw 
     * 
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF_PARAM>
     */
    public ReplaceablesOverlappingException(Replaceable r1, Replaceable r2)
    {
        super();

        if (r1 == null) throw new ExceptionCheckError
            ("Parameter 'r1' was passed a null reference");

        if (r2 == null) throw new ExceptionCheckError
            ("Parameter 'r2' was passed a null reference");

        this.r1 = r1;
        this.r2 = r2;
    }

    /**
     * Constructs a {@code ReplaceablesOverlappingException} with the specified detail message.
     * 
     * @param message the detail message.
     * 
     * @param r1 A reference to the <B STYLE='color: red'>first</B> {@link Replaceable} which caused
     * this exception to throw 
     * 
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF_PARAM>
     * 
     * @param r2 A reference to the <B STYLE='color: red'>second</B> {@link Replaceable} which caused
     * this exception to throw 
     * 
     * <EMBED CLASS='external-html' DATA-FILE-ID=EXPF_PARAM>
     */
    public ReplaceablesOverlappingException(String message, Replaceable r1, Replaceable r2)
    {
        super(message);

        if (r1 == null) throw new ExceptionCheckError
            ("Parameter 'r1' was passed a null reference");

        if (r2 == null) throw new ExceptionCheckError
            ("Parameter 'r2' was passed a null reference");

        this.r1 = r1;
        this.r2 = r2;
    }
}