public class InputStreamProvider
extends java.lang.Object
Modifier and Type | Field | Description |
---|---|---|
static java.lang.String |
CACHE_PROPERTY |
|
static int |
GZIP_MAGIC |
The magic number found at the start of a GZIP stream.
|
Constructor | Description |
---|---|
InputStreamProvider() |
Modifier and Type | Method | Description |
---|---|---|
java.io.InputStream |
getInputStream(java.io.File f) |
Get an InputStream for the file.
|
java.io.InputStream |
getInputStream(java.lang.String pathToFile) |
Get an InputStream for given file path.
|
java.io.InputStream |
getInputStream(java.net.URL u) |
public static final int GZIP_MAGIC
public static final java.lang.String CACHE_PROPERTY
public java.io.InputStream getInputStream(java.lang.String pathToFile) throws java.io.IOException
pathToFile
- the path of the file.java.io.IOException
public java.io.InputStream getInputStream(java.net.URL u) throws java.io.IOException
java.io.IOException
public java.io.InputStream getInputStream(java.io.File f) throws java.io.IOException
f
- a Filejava.io.IOException