Back up one character. This provides a sort of lookahead capability, so that you can test for a digit or letter before attempting to parse the next number or identifier.
()
| 91 | * the next number or identifier. |
| 92 | */ |
| 93 | public void back() { |
| 94 | if (this.usePrevious || this.index <= 0) { |
| 95 | throw new RuntimeException("Stepping back two steps is not supported"); |
| 96 | } |
| 97 | this.index -= 1; |
| 98 | this.character -= 1; |
| 99 | this.usePrevious = true; |
| 100 | this.eof = false; |
| 101 | } |
| 102 | |
| 103 | |
| 104 | /** |