1 | Object resolveEntity(String publicId, String systemId)↵ | | 1 | Object resolveEntity(String publicId, String systemId)↵
|
2 | {↵ | | 2 | {↵
|
3 | if("killring.dtd".equals(systemId))↵ | | 3 | if("recent.dtd".equals(systemId))↵
|
4 | {↵ | | 4 | {↵
|
5 | // this will result in a slight speed up, since we↵ | | 5 | // this will result in a slight speed up, since we↵
|
6 | // don't need to read the DTD anyway, as AElfred is↵ | | 6 | // don't need to read the DTD anyway, as AElfred is↵
|
7 | // non-validating↵ | | 7 | // non-validating↵
|
8 | return new StringReader("<!-- -->");↵ | | 8 | return new StringReader("<!-- -->");↵
|
|
| | | 9 | /* try↵
|
| | | 10 | {↵
|
| | | 11 | return new BufferedReader(new InputStreamReader(↵
|
| | | 12 | getClass().getResourceAsStream("recent.dtd")));↵
|
| | | 13 | }↵
|
| | | 14 | catch(Exception e)↵
|
| | | 15 | {↵
|
| | | 16 | Log.log(Log.ERROR,this,"Error while opening"↵
|
| | | 17 | + " recent.dtd:");↵
|
| | | 18 | Log.log(Log.ERROR,this,e);↵
|
| | | 19 | } */↵
|
9 | }↵ | | 20 | }↵
|
|
10 | return null;↵ | | 21 | return null;↵
|
11 | }↵ | | 22 | }↵
|
|
12 | public void doctypeDecl(String name, String publicId,↵ | | 23 | public void doctypeDecl(String name, String publicId,↵
|
13 | String systemId) throws Exception↵ | | 24 | String systemId) throws Exception↵
|
14 | {↵ | | 25 | {↵
|
15 | if("KILLRING".equals(name))↵ | | 26 | if("RECENT".equals(name))↵
|
16 | return;↵ | | 27 | return;↵
|
|
17 | Log.log(Log.ERROR,this,"killring.xml: DOCTYPE must be KILLRING");↵ | | 28 | Log.log(Log.ERROR,this,"recent.xml: DOCTYPE must be RECENT");↵
|
18 | } | | 29 | }
|