public interface RepositoryItem
Modifier and Type | Interface and Description |
---|---|
static class |
RepositoryItem.State |
Modifier and Type | Method and Description |
---|---|
java.io.InputStream |
createInputStreamToRead()
Creates an InputStream to read for the contents of the item.
|
java.io.OutputStream |
createOutputStreamToWrite()
Creates an OutputStream to write the binary content of the file.
|
RepositoryHttpPlayer |
createRepositoryHttpPlayer()
Returns the
RepositoryHttpPlayer to download the contents of the item using http
protocol. |
RepositoryHttpPlayer |
createRepositoryHttpPlayer(java.lang.String sessionIdInUrl)
Returns the
RepositoryHttpPlayer to download the contents of the item using http
protocol. |
RepositoryHttpRecorder |
createRepositoryHttpRecorder()
Returns the
RepositoryHttpRecorder to upload the contents of the item using http
protocol. |
RepositoryHttpRecorder |
createRepositoryHttpRecorder(java.lang.String sessionIdInUrl)
Returns the
RepositoryHttpRecorder to upload the contents of the item using http
protocol. |
RepositoryItemAttributes |
getAttributes()
Returns the attributes associated with this
RepositoryItem . |
java.lang.String |
getId() |
java.util.Map<java.lang.String,java.lang.String> |
getMetadata() |
RepositoryItem.State |
getState()
Returns the state of the RepositoryItem.
|
void |
putMetadataEntry(java.lang.String key,
java.lang.String value) |
void |
setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata) |
java.lang.String getId()
java.util.Map<java.lang.String,java.lang.String> getMetadata()
void setMetadata(java.util.Map<java.lang.String,java.lang.String> metadata)
void putMetadataEntry(java.lang.String key, java.lang.String value)
RepositoryItem.State getState()
java.io.InputStream createInputStreamToRead()
STORED
state.java.io.OutputStream createOutputStreamToWrite()
RepositoryItem.State.STORING
. When the OutputStream.close()
method is invoked,
the item's state is changed to STORED
. This method can be
called only once because only one OutputStream
can be created.RepositoryHttpPlayer createRepositoryHttpPlayer()
RepositoryHttpPlayer
to download the contents of the item using http
protocol. This operation is only valid when the item is in STORED
state.RepositoryHttpPlayer createRepositoryHttpPlayer(java.lang.String sessionIdInUrl)
RepositoryHttpPlayer
to download the contents of the item using http
protocol. This operation is only valid when the item is in STORED
state. The parameter sessionIdInURL
allows to specify the sessionId of this player used to construct the URL. The
complete URL of the player can be obtained using the RepositoryHttpEndpoint.getURL()
in
the returned object.sessionIdInUrl
- The sessionId of this player used to construct the URL.RepositoryHttpRecorder createRepositoryHttpRecorder()
RepositoryHttpRecorder
to upload the contents of the item using http
protocol. This operation is only valid when the item is in NEW state. When the element is used
using the provided URL, the state of the item is changed to STORING
.RepositoryHttpRecorder createRepositoryHttpRecorder(java.lang.String sessionIdInUrl)
RepositoryHttpRecorder
to upload the contents of the item using http
protocol. This operation is only valid when the item is in NEW state. When the element is used
using the provided URL, the state of the item is changed to STORING
. The parameter sessionIdInURL
allows to specify the sessionId of this recorder
used to construct the URL. The complete URL of the recorder can be obtained using the
RepositoryHttpEndpoint.getURL()
in the returned object.sessionIdInUrl
- The sessionId of this player used to construct the URL.RepositoryItemAttributes getAttributes()
RepositoryItem
. This attributes are used
mainly when serving this item by means of http endpoint.