1 package net.sf.mavenhist.extractor.util;
2
3 import java.io.StringReader;
4
5 import org.xml.sax.EntityResolver;
6 import org.xml.sax.InputSource;
7
8 /**
9 * Entity resolver that prevents the XML parser to search for schema and dtd-files in the network.
10 * If this resolver is not set, it is necessairy to have a network connection to run the
11 * application.
12 */
13 public class RemoveDTDLookupResolver implements EntityResolver {
14
15 /**
16 * {@inheritDoc}
17 */
18 public InputSource resolveEntity(String publicId, String systemId) {
19
20 StringReader stringReader = new StringReader("");
21 return new InputSource(stringReader);
22 }
23 }