public class StreamRepository extends java.lang.Object implements Repository
| Constructor and Description |
|---|
StreamRepository(java.io.InputStream inputStream,
java.io.OutputStream outputStream)
Deprecated.
This constructor should not be used, as it hardcodes the filename for the input stream.
Use one of the other constructors instead.
|
StreamRepository(java.io.InputStream inputStream,
java.io.OutputStream outputStream,
java.lang.String contentName)
Creates a new repository that potentially allows both read and write access.
|
StreamRepository(java.io.InputStream inputStream,
java.lang.String contentName)
Creates a new read-only repository.
|
StreamRepository(java.io.OutputStream outputStream)
Creates a new write-only repository.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getContentName()
Returns the optional content name by which the data in the input-stream should be accessed.
|
WrappedInputStream |
getInputStream()
Returns the optional input stream.
|
MimeRegistry |
getMimeRegistry()
Returns the mime registry for this repository.
|
WrappedOutputStream |
getOutputStream()
Returns the optional output stream.
|
ContentLocation |
getRoot()
Returns the content root of this repository.
|
public StreamRepository(java.io.InputStream inputStream,
java.io.OutputStream outputStream,
java.lang.String contentName)
inputStream - the inputstream from which to read from.outputStream - the output stream to which to write to.contentName - the content name by which the content should be accessed.public StreamRepository(java.io.InputStream inputStream,
java.io.OutputStream outputStream)
inputStream - the input stream from where to read the data (can be null).outputStream - the output stream where data is written to (can be null).public StreamRepository(java.io.InputStream inputStream,
java.lang.String contentName)
inputStream - the input stream from where to read the data (can be null).contentName - the content name by which the content should be accessed.public StreamRepository(java.io.OutputStream outputStream)
outputStream - the output stream to which to write to.public java.lang.String getContentName()
public WrappedOutputStream getOutputStream()
public WrappedInputStream getInputStream()
public ContentLocation getRoot()
getRoot in interface Repositorypublic MimeRegistry getMimeRegistry()
getMimeRegistry in interface RepositoryMimeRegistry