Mercurial Hosting > luan
comparison src/luan/modules/parsers/ParseException.java @ 1110:38a42f437fd2
queryparser now uses parsers.Parser
author | Franklin Schmidt <fschmidt@gmail.com> |
---|---|
date | Wed, 02 Aug 2017 13:45:06 -0600 |
parents | 1a68fc55a80c |
children |
comparison
equal
deleted
inserted
replaced
1109:8c999ab85e33 | 1110:38a42f437fd2 |
---|---|
4 public final class ParseException extends Exception { | 4 public final class ParseException extends Exception { |
5 public final String text; | 5 public final String text; |
6 public final int errorIndex; | 6 public final int errorIndex; |
7 public final int highIndex; | 7 public final int highIndex; |
8 | 8 |
9 ParseException(Parser parser,String msg) { | 9 public ParseException(Parser parser,String msg) { |
10 super(msg); | 10 super(msg); |
11 this.text = parser.text; | |
12 this.errorIndex = parser.currentIndex(); | |
13 this.highIndex = parser.highIndex(); | |
14 } | |
15 | |
16 public ParseException(Parser parser,Exception cause) { | |
17 this(parser,cause.getMessage(),cause); | |
18 } | |
19 | |
20 public ParseException(Parser parser,String msg,Exception cause) { | |
21 super(msg,cause); | |
11 this.text = parser.text; | 22 this.text = parser.text; |
12 this.errorIndex = parser.currentIndex(); | 23 this.errorIndex = parser.currentIndex(); |
13 this.highIndex = parser.highIndex(); | 24 this.highIndex = parser.highIndex(); |
14 } | 25 } |
15 | 26 |