org.apache.creadur.whisker.app.load
public final class StreamableFileNameResource extends StreamableResource
Constructor and Description |
---|
StreamableFileNameResource(String fileName)
Constructs an instance that streams
the resource identified by name on demand.
|
Modifier and Type | Method and Description |
---|---|
String |
getFileName()
Gets the file name of the resource to be streamed.
|
InputStream |
open()
Opens the file as an input stream.
|
String |
toString()
Suitable for logging.
|
public StreamableFileNameResource(String fileName)
fileName
- full file name, including path,
of the resource to be streamed
on demand, not nullpublic String getFileName()
public InputStream open() throws IOException
open
in class StreamableResource
IOException
- when resource cannot be openedStreamableResource.open()
Copyright © 2011-2013 Apache Software Foundation. All Rights Reserved.