1 | try {↵ | | 1 | try {↵
|
2 | // substitute special characters like: <,>,&,\t,\n↵ | | |
|
3 | body = HtmlParser.substituteSpecialCharacters(decodedBody);↵ | | |
|
|
4 | // parse for urls / email adr. and substite with HTML-code↵ | | |
|
5 | body = HtmlParser.substituteURL(body);↵ | | |
|
6 | body = HtmlParser.substituteEmailAddress(body);↵ | | |
|
|
7 | // mark quotings with special font↵ | | |
|
8 | body = DocumentParser.markQuotings(body);↵ | | |
|
9 | } catch (Exception e) {↵ | | |
|
10 | LOG.severe("Error parsing body: " + e.getMessage());↵ | | |
|
11 | body = "<em>Error parsing body!!!</em>";↵ | | |
|
12 | ↵ | | 2 | charset = Charset.forName(charsetName);↵
|
| | | 3 | } catch (UnsupportedCharsetException e) {↵
|
| | | 4 | charsetName = System.getProperty("file.encoding");↵
|
| | | 5 | charset = Charset.forName(charsetName);↵
|
| | | 6 | } catch (IllegalCharsetNameException e) {↵
|
| | | 7 | charsetName = System.getProperty("file.encoding");↵
|
| | | 8 | charset = Charset.forName(charsetName);↵
|
13 | } | | 9 | }
|