Package com.microstrategy.utils.xml
Class FileFinderEntityResolver
- java.lang.Object
 - 
- com.microstrategy.utils.xml.FileFinderEntityResolver
 
 
- 
- All Implemented Interfaces:
 org.xml.sax.EntityResolver
- Direct Known Subclasses:
 FileLoaderEntityResolver
public class FileFinderEntityResolver extends java.lang.Object implements org.xml.sax.EntityResolverThis EntityResolver tries to create the InputStream using theFileFinder, which basically looks for files in the class-path.- Since:
 - MicroStrategy Web 9.0.0
 
 
- 
- 
Constructor Summary
Constructors Constructor Description FileFinderEntityResolver() 
- 
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.lang.StringgetFileName(java.lang.String publicId, java.lang.String systemId)Resolves the file name from the systemId.protected java.io.InputStreamgetInputStream(java.lang.String fileName)Returns the InputStream for the given fileName.org.xml.sax.InputSourceresolveEntity(java.lang.String publicId, java.lang.String systemId) 
 - 
 
- 
- 
Method Detail
- 
resolveEntity
public org.xml.sax.InputSource resolveEntity(java.lang.String publicId, java.lang.String systemId) throws org.xml.sax.SAXException, java.io.IOException- Specified by:
 resolveEntityin interfaceorg.xml.sax.EntityResolver- Throws:
 org.xml.sax.SAXExceptionjava.io.IOException
 
- 
getFileName
protected java.lang.String getFileName(java.lang.String publicId, java.lang.String systemId)Resolves the file name from the systemId. This implementation just returns the file starting from the last slash (/). For example, ifsystemIdis:
it returns:"/path/name.dtd"
name.dtd 
- 
getInputStream
protected java.io.InputStream getInputStream(java.lang.String fileName) throws java.io.FileNotFoundException, java.io.IOExceptionReturns the InputStream for the given fileName.- Throws:
 java.io.FileNotFoundExceptionjava.io.IOException- See Also:
 FileFinder.getResourceAsStream(java.lang.String)
 
 - 
 
 -