org.codehaus.janino.util.resource
Class ResourceFinder.FileResource
java.lang.Object
org.codehaus.janino.util.resource.ResourceFinder.FileResource
- All Implemented Interfaces:
- ResourceFinder.Resource
- Enclosing class:
- ResourceFinder
- public static class ResourceFinder.FileResource
- extends Object
- implements ResourceFinder.Resource
Representation of a resource that is a File
.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ResourceFinder.FileResource
public ResourceFinder.FileResource(File file)
getFileName
public String getFileName()
- Description copied from interface:
ResourceFinder.Resource
- Returns a decorative "file name" that can be used for reporting
errors and the like. It does not necessarily map to a file in the
local file system!
- Specified by:
getFileName
in interface ResourceFinder.Resource
open
public InputStream open()
throws IOException
- Description copied from interface:
ResourceFinder.Resource
- Opens the resource. The caller is responsible for closing the
InputStream
.
- Specified by:
open
in interface ResourceFinder.Resource
- Throws:
IOException
getFile
public File getFile()