Changeset 8510 in josm for trunk/src/org/openstreetmap/josm/tools/template_engine/Tokenizer.java
- Timestamp:
- 2015-06-20T23:42:21+02:00 (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/org/openstreetmap/josm/tools/template_engine/Tokenizer.java
r7937 r8510 36 36 @Override 37 37 public String toString() { 38 return type + (text != null ?" " + text:"");38 return type + (text != null ? " " + text : ""); 39 39 } 40 40 } … … 85 85 return new Token(TokenType.CONDITION_START, position); 86 86 } else 87 throw ParseError.unexpectedChar('{', (char) c, position);87 throw ParseError.unexpectedChar('{', (char) c, position); 88 88 case '!': 89 89 getChar(); … … 92 92 return new Token(TokenType.CONTEXT_SWITCH_START, position); 93 93 } else 94 throw ParseError.unexpectedChar('{', (char) c, position);94 throw ParseError.unexpectedChar('{', (char) c, position); 95 95 case '}': 96 96 getChar(); … … 103 103 return new Token(TokenType.APOSTROPHE, position); 104 104 default: 105 while (c != -1 && !specialCharaters.contains((char) c)) {105 while (c != -1 && !specialCharaters.contains((char) c)) { 106 106 if (c == '\\') { 107 107 getChar(); … … 110 110 } 111 111 } 112 text.append((char) c);112 text.append((char) c); 113 113 getChar(); 114 114 } … … 132 132 getChar(); 133 133 } 134 result.append((char) c);134 result.append((char) c); 135 135 getChar(); 136 136 } 137 137 return new Token(TokenType.TEXT, position, result.toString()); 138 138 } 139 140 139 }
Note:
See TracChangeset
for help on using the changeset viewer.