public interface ElementDescriptor extends java.lang.Comparable<ElementDescriptor>
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
BLOCK_REPLICATION_KEY
Available from getConfiguration as a String and getStatistics as a Short.
|
static java.lang.String |
BLOCK_SIZE_KEY
Available from getConfiguration as a String and getStatistics as a Long.
|
static java.lang.String |
LENGTH_KEY
Available from getStatistics as a Long.
|
static java.lang.String |
MODIFICATION_TIME_KEY
Available from getStatistics as a Long.
|
| Modifier and Type | Method and Description |
|---|---|
void |
copy(ElementDescriptor dstName,
boolean removeSrc) |
void |
copy(ElementDescriptor dstName,
java.util.Properties dstConfiguration,
boolean removeSrc)
Copy entity from an existing one, possibly residing in a
different Data Storage.
|
java.io.OutputStream |
create() |
java.io.OutputStream |
create(java.util.Properties configuration)
Opens a stream onto which an entity can be written to.
|
void |
delete()
Remove entity from the Data Storage.
|
boolean |
exists()
Checks whether the entity exists or not
|
java.util.Properties |
getConfiguration()
Retrieve configuration information for entity
|
DataStorage |
getDataStorage() |
java.util.Map<java.lang.String,java.lang.Object> |
getStatistics()
List entity statistics
|
java.io.InputStream |
open() |
java.io.InputStream |
open(java.util.Properties configuration)
Open for read a given entity
|
void |
rename(ElementDescriptor newName)
Changes the name of an entity in the Data Storage
|
SeekableInputStream |
sopen() |
SeekableInputStream |
sopen(java.util.Properties configuration)
Open an element in the Data Storage with support for random access
(seek operations).
|
boolean |
systemElement()
Defines whether the element is visible to users or
contains system's metadata
|
void |
updateConfiguration(java.util.Properties newConfig)
Update configuration information for this entity
|
static final java.lang.String BLOCK_SIZE_KEY
static final java.lang.String BLOCK_REPLICATION_KEY
static final java.lang.String LENGTH_KEY
static final java.lang.String MODIFICATION_TIME_KEY
DataStorage getDataStorage()
java.io.OutputStream create(java.util.Properties configuration)
throws java.io.IOException
configuration - information at the object levelDataStorageExceptionjava.io.IOExceptionjava.io.OutputStream create()
throws java.io.IOException
java.io.IOExceptionvoid copy(ElementDescriptor dstName, java.util.Properties dstConfiguration, boolean removeSrc) throws java.io.IOException
dstName - name of entity to createdstConfiguration - configuration for the new entityremoveSrc - if src entity needs to be removed after copying itDataStorageException - for instance, configuration
information for new entity is not compatible with
configuration information at the Data
Storage level, user does not have privileges to read from
source entity or write to destination storage...java.io.IOExceptionvoid copy(ElementDescriptor dstName, boolean removeSrc) throws java.io.IOException
java.io.IOExceptionjava.io.InputStream open(java.util.Properties configuration)
throws java.io.IOException
configuration - DataStorageExecption - e.g. entity does not exist...java.io.IOExceptionjava.io.InputStream open()
throws java.io.IOException
java.io.IOExceptionSeekableInputStream sopen(java.util.Properties configuration) throws java.io.IOException
configuration - DataStorageExceptionjava.io.IOExceptionSeekableInputStream sopen() throws java.io.IOException
java.io.IOExceptionboolean exists()
throws java.io.IOException
java.io.IOExceptionvoid rename(ElementDescriptor newName) throws java.io.IOException
newName - new name of entityDataStorageExceptionjava.io.IOExceptionvoid delete()
throws java.io.IOException
DataStorageExceptionjava.io.IOExceptionjava.util.Properties getConfiguration()
throws java.io.IOException
java.io.IOExceptionvoid updateConfiguration(java.util.Properties newConfig)
throws java.io.IOException
newConfig - configurationDataStorageExceptionjava.io.IOExceptionboolean systemElement()
java.util.Map<java.lang.String,java.lang.Object> getStatistics()
throws java.io.IOException
java.io.IOExceptionCopyright © 2007-2012 The Apache Software Foundation