public class EmbeddedRepository extends AbstractRepository implements Repository, SupportsSearchExcluding
| Constructor and Description |
|---|
EmbeddedRepository(android.content.Context context,
java.lang.String authority)
Creates an EmbeddedRepository pointing to a specific content provider specified by its authority.
|
| Modifier and Type | Method and Description |
|---|---|
android.os.Bundle |
call(java.lang.String method,
java.lang.String arg,
android.os.Bundle extras) |
void |
close()
Close the repository and release all resources.
|
DigitalObject |
createDigitalObject(java.lang.String handle)
Creates a new digital object with the given identifier in this repository.
|
void |
deleteDigitalObject(java.lang.String handle)
Deletes a digital object from the repository.
|
DigitalObject |
getDigitalObject(java.lang.String handle)
Returns the digital object with the given identifier from this repository.
|
static Repository |
getEmbeddedRepository(android.content.Context context)
Creates a repository used to access the embedded repository on the Android device.
|
CloseableIterator<java.lang.String> |
listHandles()
Provides a CloseableIterator view of the identifiers for digital objects accessible through this repository.
|
CloseableIterator<DigitalObject> |
listObjects()
Provides a CloseableIterator view of the digital objects accessible through this repository.
|
CloseableIterator<DigitalObject> |
search(Query query)
Provides a CloseableIterator view of the digital objects accessible through this repository under search bounds defined in the Query object with default parameters.
|
CloseableIterator<DigitalObject> |
searchExcluding(Query query,
java.util.Collection<java.lang.String> handles) |
CloseableIterator<java.lang.String> |
searchHandles(Query query)
Provides a CloseableIterator view of the digital objects handles accessible through this repository under search bounds defined in the Query object with default parameters.
|
CloseableIterator<java.lang.String> |
searchHandlesExcluding(Query query,
java.util.Collection<java.lang.String> handles) |
void |
setContext(android.content.Context context) |
boolean |
verifyDigitalObject(java.lang.String handle)
Verifies whether a digital object with the given identifier can be accessed via this repository.
|
getHandle, getOrCreateDigitalObject, search, search, searchHandles, searchHandles, searchMappingequals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetHandle, getOrCreateDigitalObject, search, search, searchHandles, searchHandles, searchMappingpublic EmbeddedRepository(android.content.Context context,
java.lang.String authority)
throws RepositoryException
getEmbeddedRepository(Context) to use the default provider.authority - RepositoryExceptionpublic static Repository getEmbeddedRepository(android.content.Context context) throws RepositoryException
context - the context of the Android application environment in which the repository will be accessedRepositoryExceptionpublic void setContext(android.content.Context context)
throws RepositoryException
RepositoryExceptionpublic boolean verifyDigitalObject(java.lang.String handle)
throws RepositoryException
RepositoryverifyDigitalObject in interface RepositoryverifyDigitalObject in class AbstractRepositoryhandle - an identifier for a digital objectRepositoryExceptionpublic DigitalObject createDigitalObject(java.lang.String handle) throws CreationException, RepositoryException
Repositorynull requests that the repository assign a new unique identifier;
this method will throw UnsupportedOperationException if the given repository does not support that functionality.createDigitalObject in interface Repositoryhandle - the identifier for the new digital object, or null to request that the repository assign a new unique identifier.CreationException - if an object with the given identifier already exists within the repositoryRepositoryExceptionpublic DigitalObject getDigitalObject(java.lang.String handle) throws RepositoryException
RepositorygetDigitalObject in interface Repositoryhandle - the identifier for the digital objectRepositoryExceptionpublic void deleteDigitalObject(java.lang.String handle)
throws RepositoryException
RepositorydeleteDigitalObject in interface RepositorydeleteDigitalObject in class AbstractRepositoryhandle - the identifier for the digital objectRepositoryExceptionpublic CloseableIterator<java.lang.String> listHandles() throws RepositoryException
RepositorylistHandles in interface RepositorylistHandles in class AbstractRepositoryRepositoryExceptionpublic CloseableIterator<DigitalObject> listObjects() throws RepositoryException
RepositorylistObjects in interface RepositorylistObjects in class AbstractRepositoryRepositoryExceptionpublic CloseableIterator<DigitalObject> searchExcluding(Query query, java.util.Collection<java.lang.String> handles) throws RepositoryException
searchExcluding in interface SupportsSearchExcludingRepositoryExceptionpublic CloseableIterator<DigitalObject> search(Query query) throws RepositoryException
Repositorysearch in interface Repositorysearch in class AbstractRepositoryquery - the query to performQueryResults.RepositoryExceptionpublic CloseableIterator<java.lang.String> searchHandles(Query query) throws RepositoryException
RepositorysearchHandles in interface RepositorysearchHandles in class AbstractRepositoryquery - the query to performQueryResults.RepositoryExceptionpublic CloseableIterator<java.lang.String> searchHandlesExcluding(Query query, java.util.Collection<java.lang.String> handles) throws RepositoryException
searchHandlesExcluding in interface SupportsSearchExcludingRepositoryExceptionpublic void close()
Repositoryclose in interface Repositorypublic android.os.Bundle call(java.lang.String method,
java.lang.String arg,
android.os.Bundle extras)
throws RepositoryException
RepositoryException