org.codehaus.janino.util.resource
Class ResourceFinder
java.lang.Object
org.codehaus.janino.util.resource.ResourceFinder
- Direct Known Subclasses:
- FileResourceFinder, MultiResourceFinder, ZipFileResourceFinder
- public abstract class ResourceFinder
- extends Object
Finds a resource by name.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ResourceFinder
public ResourceFinder()
findResourceAsStream
public final InputStream findResourceAsStream(String resourceName)
throws IOException
- Find a resource by name and open it for reading
- Parameters:
resourceName
- Slash-separated name that identifies the resource
- Returns:
null
if the resource could not be found
- Throws:
IOException
findResource
public abstract ResourceFinder.Resource findResource(String resourceName)
- Find a resource by name and return it as a
ResourceFinder.Resource
object.
- Parameters:
resourceName
- Slash-separated name that identifies the resource
- Returns:
null
if the resource could not be found