public abstract class ALfnBinaryMetadataStore extends Object implements Closeable
com.luciad.fusion.tilestore.metadata.ALfnResourceMetadata
instance)
and binary data is done outside the store; implementations of this class are only responsible for storing and retrieving the binary data representation
of the metadata.Constructor and Description |
---|
ALfnBinaryMetadataStore() |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
containsId(String aId)
Returns
true if this store contains a metadata for the given id, false otherwise. |
abstract boolean |
deleteMetadata(String aId)
Deletes the metadata for the given id.
|
abstract void |
getIds(ILcdFunction aFunction)
Applies the given function to the id's for which metadatas are stored in this store.
|
abstract boolean |
getMetadata(String aId,
WritableByteChannel aChannel)
Retrieves the binary representation of the metadata for the given id.
|
abstract int |
getMetadataCount()
Returns the number of metadatas contained in this store.
|
abstract void |
putMetadata(String aId,
ReadableByteChannel aChannel)
Stores the binary representation of the metadata with the given id in this store.
|
public abstract void getIds(ILcdFunction aFunction) throws IOException, TLfnServiceException
String
instances to the applyOn
method of the given function.
The return value of the function is used as a stop criterion: the id iteration is interrupted if the
function returns false
.aFunction
- the function to apply the id's on.IOException
- if an I/O problem occurs during the iteration.TLfnServiceException
- if a service problem occurs during the iteration.public abstract boolean containsId(String aId) throws IOException, TLfnServiceException
true
if this store contains a metadata for the given id, false
otherwise.aId
- the id to testtrue
if this store contains a metadata for the given id, false
otherwise.IOException
- if an I/O problem occurs during the test.TLfnServiceException
- if a service problem occurs during the test.public abstract int getMetadataCount() throws IOException, TLfnServiceException
IOException
- if an I/O problem occurs during retrievalTLfnServiceException
- if a service problem occurs during retrievalpublic abstract boolean getMetadata(String aId, WritableByteChannel aChannel) throws IOException, TLfnServiceException
WritableByteChannel
. The channel will never be closed by this method.aId
- the id for which to retrieve the metadataaChannel
- the channel in which the metadata bytes shall be writtentrue
if the metadata existed, false
otherwiseIOException
- if an I/O problem occurs during retrievalTLfnServiceException
- if a service problem occurs during retrievalpublic abstract void putMetadata(String aId, ReadableByteChannel aChannel) throws IOException, TLfnServiceException
ReadableByteChannel
. The channel will never be closed by this method.aId
- the id for which to store the metadataaChannel
- the channel from which the metadata bytes should be readIOException
- if an I/O problem occurs during retrievalTLfnServiceException
- if a service problem occurs during retrievalpublic abstract boolean deleteMetadata(String aId) throws IOException, TLfnServiceException
aId
- the id for which to delete the metadatatrue
if the metadata existed and was successfully deleted, false
otherwiseIOException
- if an I/O problem occurs during deletionTLfnServiceException
- if a service problem occurs during deletion