Clover coverage report - PMD - 3.9 Coverage timestamp: Tue Dec 19 2006 09:38:44 EST FRAMES NO FRAMES |
file stats: | LOC: | 84 |  | Methods: | 6
| NCLOC: | 36 |  | Classes: | 1
Source file | Conditionals | Statements | Methods | TOTAL
StartAndEndTagMismatchException.java | - | 0% | 0% | 0% |

1 |  | /*
2 |  | * Created on 11-jan-2006
3 |  | *
4 |  | * TODO To change the template for this generated file go to
5 |  | * Window - Preferences - Java - Code Style - Code Templates
6 |  | */
7 |  | package net.sourceforge.pmd.jsp.ast;
8 |  |
9 |  | /**
10 |  | * @author Pieter_Van_Raemdonck
11 |  | * <p/>
12 |  | * TODO To change the template for this generated type comment go to
13 |  | * Window - Preferences - Java - Code Style - Code Templates
14 |  | */
15 |  | public class StartAndEndTagMismatchException extends SyntaxErrorException {
16 |  |
17 |  | public static final String START_END_TAG_MISMATCH_RULE_NAME
18 |  | = "Start and End Tags of an XML Element must match.";
19 |  |
20 |  | private int startLine, endLine, startColumn, endColumn;
21 |  | private String startTagName, endTagName;
22 |  |
23 |  | /**
24 |  | * Public constructor.
25 |  | *
26 |  | * @param startLine
27 |  | * @param startColumn
28 |  | * @param startTagName
29 |  | * @param endLine
30 |  | * @param endColumn
31 |  | * @param endTagName
32 |  | */
33 | 0 | public StartAndEndTagMismatchException(int startLine, int startColumn, String startTagName,
34 |  | int endLine, int endColumn, String endTagName) {
35 | 0 | super(endLine, START_END_TAG_MISMATCH_RULE_NAME);
36 | 0 | this.startLine = startLine;
37 | 0 | this.startColumn = startColumn;
38 | 0 | this.startTagName = startTagName;
39 |  |
40 | 0 | this.endLine = endLine;
41 | 0 | this.endColumn = endColumn;
42 | 0 | this.endTagName = endTagName;
43 |  | }
44 |  |
45 |  |
46 |  | /**
47 |  | * @return Returns the endColumn.
48 |  | */
49 | 0 | public int getEndColumn() {
50 | 0 | return endColumn;
51 |  | }
52 |  |
53 |  | /**
54 |  | * @return Returns the endLine.
55 |  | */
56 | 0 | public int getEndLine() {
57 | 0 | return endLine;
58 |  | }
59 |  |
60 |  | /**
61 |  | * @return Returns the startColumn.
62 |  | */
63 | 0 | public int getStartColumn() {
64 | 0 | return startColumn;
65 |  | }
66 |  |
67 |  | /**
68 |  | * @return Returns the startLine.
69 |  | */
70 | 0 | public int getStartLine() {
71 | 0 | return startLine;
72 |  | }
73 |  |
74 |  | /* (non-Javadoc)
75 |  | * @see java.lang.Throwable#getMessage()
76 |  | */
77 | 0 | public String getMessage() {
78 | 0 | return "The start-tag of element \"" + startTagName + "\" (line "
79 |  | + startLine + ", column " + startColumn
80 |  | + ") does not correspond to the end-tag found: \""
81 |  | + endTagName + "\" (line " + endLine
82 |  | + ", column " + endColumn + ").";
83 |  | }
84 |  | }