public class ZipReadContentLocation extends Object implements ContentLocation
| Constructor and Description |
|---|
ZipReadContentLocation(ZipReadRepository repository,
ZipReadContentLocation parent,
String entryName) |
ZipReadContentLocation(ZipReadRepository repository,
ZipReadContentLocation parent,
ZipEntry zipEntry) |
| Modifier and Type | Method and Description |
|---|---|
ContentItem |
createItem(String name)
Creates a new data item in the current location.
|
ContentLocation |
createLocation(String name)
Creates a new content location in the current location.
|
boolean |
delete()
Attempts to delete the entity.
|
boolean |
exists(String name)
Checks, whether an content entity with the given name exists in this content location.
|
Object |
getAttribute(String domain,
String key)
Returns a attribute value for the given domain (namespace) and attribute-name.
|
Object |
getContentId()
Returns a unique identifier.
|
ContentEntity |
getEntry(String name)
Returns the content entity with the given name.
|
String |
getName()
Returns the name of the entry.
|
ContentLocation |
getParent()
Returns a reference to the parent location.
|
Repository |
getRepository()
Returns the current repository, to which tis entity belongs.
|
ContentEntity[] |
listContents()
Returns all content entities stored in this content-location.
|
boolean |
setAttribute(String domain,
String key,
Object value)
Updates the attribute value for the given attribute domain and name.
|
void |
updateDirectoryEntry(String[] name,
int index,
ZipEntry zipEntry) |
void |
updateEntry(String[] name,
int index,
ZipEntry zipEntry,
byte[] data) |
public ZipReadContentLocation(ZipReadRepository repository, ZipReadContentLocation parent, String entryName)
public ZipReadContentLocation(ZipReadRepository repository, ZipReadContentLocation parent, ZipEntry zipEntry)
public ContentEntity[] listContents() throws ContentIOException
ContentLocationlistContents in interface ContentLocationContentIOException - if an repository error occured.public ContentEntity getEntry(String name) throws ContentIOException
ContentLocationgetEntry in interface ContentLocationname - the name of the entity to be retrieved.ContentIOException - if an repository error occured.public boolean exists(String name)
ContentLocationexists in interface ContentLocationname - the name of the new entity.public ContentItem createItem(String name) throws ContentCreationException
ContentLocationcreateItem in interface ContentLocationname - the name of the new entity.ContentCreationException - if the item could not be created.public ContentLocation createLocation(String name) throws ContentCreationException
ContentLocationcreateLocation in interface ContentLocationname - the name of the new entity.ContentCreationException - if the item could not be created.public String getName()
ContentEntitygetName in interface ContentEntitypublic Object getContentId()
ContentEntitygetContentId in interface ContentEntitypublic Object getAttribute(String domain, String key)
ContentEntityLibRepositoryBoot class.getAttribute in interface ContentEntitydomain - the attribute domain.key - the name of the attribute.public boolean setAttribute(String domain, String key, Object value)
ContentEntitysetAttribute in interface ContentEntitydomain - the attribute domain.key - the attribute namevalue - the new attribute value.public ContentLocation getParent()
ContentEntitygetParent in interface ContentEntitypublic Repository getRepository()
ContentEntitygetRepository in interface ContentEntitypublic boolean delete()
ContentEntitydelete in interface ContentEntity