Interface ResourceStore
- All Known Implementing Classes:
ResourceStoreImpl
public interface ResourceStore
-
Method Summary
Modifier and TypeMethodDescriptionallocateEntity(String uri, org.apache.jena.rdf.model.Resource description) allocateEntity(Path relPath, org.apache.jena.rdf.model.Resource description) booleanTest whether the path lies within the store - does not check for existencegetEntityForPath(Path absEntityPath) Bridge between paths and entitiesdefault org.apache.jena.rdf.model.Resourceorg.apache.jena.rdf.model.ResourceReturn the metadata associated with a given pathgetResource(String uri) listEntities(Path basePath) putWithMove(String uri, RdfEntityInfo metadata, Path file) Archive the file in the repository and then delete the source TODO This method can be considered mostly as simple convenience function: We may want some more sophisticated API that places a file or stream into the repository once it becomes ready and triggers an action when the archiving has completed - something along the lines of: flowableSourceOfByteSourceOrFile .flatMap(repo.archivingThatProducesASingleWithInfo(byteSourceOrFile)) .subscribe(info -> info.inputFile().delete())static StringreadHash(RdfHttpEntityFile entity, String hashName) voidupdateInfo(Path path, Consumer<? super org.apache.jena.rdf.model.Resource> info)
-
Method Details
-
readHash
-
putWithMove
Archive the file in the repository and then delete the source TODO This method can be considered mostly as simple convenience function: We may want some more sophisticated API that places a file or stream into the repository once it becomes ready and triggers an action when the archiving has completed - something along the lines of: flowableSourceOfByteSourceOrFile .flatMap(repo.archivingThatProducesASingleWithInfo(byteSourceOrFile)) .subscribe(info -> info.inputFile().delete())- Parameters:
uri-metadata-file-- Returns:
- Throws:
IOException
-
getEntityForPath
Bridge between paths and entities- Parameters:
absEntityPath- Absolute path to an entity.- Returns:
-
getResource
-
allocateEntity
-
getAbsolutePath
Path getAbsolutePath() -
listEntities
-
contains
Test whether the path lies within the store - does not check for existence- Parameters:
path-- Returns:
-
getInfo
Return the metadata associated with a given path- Parameters:
path-layer- A label to retrieve the metadata from a single source- Returns:
-
updateInfo
-
getInfo
-
allocateEntity
-