public class NoopResourceService extends Object implements ResourceService
Constructor and Description |
---|
NoopResourceService() |
Modifier and Type | Method and Description |
---|---|
CompletionStage<Void> |
add(IRI identifier,
Dataset dataset) |
CompletionStage<Void> |
delete(Metadata metadata)
Delete a resource from the server.
|
String |
generateIdentifier()
An identifier generator.
|
CompletionStage<Resource> |
get(IRI identifier)
Get a resource by the given identifier.
|
CompletionStage<Void> |
replace(Metadata metadata,
Dataset dataset)
Replace a resource in the server.
|
Set<IRI> |
supportedInteractionModels()
Return a collection of interaction models supported by this Resource Service.
|
CompletionStage<Void> |
touch(IRI identifier)
Update the modification date of the provided resource.
|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
create, skolemize, toExternal, toInternal, unskolemize
public CompletionStage<Resource> get(IRI identifier)
RetrievalService
get
in interface RetrievalService<Resource>
identifier
- the resource identifierpublic CompletionStage<Void> replace(Metadata metadata, Dataset dataset)
ResourceService
replace
in interface ResourceService
metadata
- metadata for the resourcedataset
- the dataset to be persistedCompletionStage
will complete exceptionally and can be handled with
CompletionStage.handle(java.util.function.BiFunction<? super T, java.lang.Throwable, ? extends U>)
, CompletionStage.exceptionally(java.util.function.Function<java.lang.Throwable, ? extends T>)
or similar methods.public CompletionStage<Void> delete(Metadata metadata)
ResourceService
delete
in interface ResourceService
metadata
- metadata for the resourceCompletionStage
will complete exceptionally and can be handled with
CompletionStage.handle(java.util.function.BiFunction<? super T, java.lang.Throwable, ? extends U>)
, CompletionStage.exceptionally(java.util.function.Function<java.lang.Throwable, ? extends T>)
or similar methods.public CompletionStage<Void> add(IRI identifier, Dataset dataset)
add
in interface ResourceService
identifier
- the identifier under which to persist a datasetdataset
- a dataset to persistCompletionStage
will complete exceptionally and can be handled with
CompletionStage.handle(java.util.function.BiFunction<? super T, java.lang.Throwable, ? extends U>)
, CompletionStage.exceptionally(java.util.function.Function<java.lang.Throwable, ? extends T>)
or similar methods.public CompletionStage<Void> touch(IRI identifier)
ResourceService
touch
in interface ResourceService
identifier
- the identifier of the resourcepublic Set<IRI> supportedInteractionModels()
ResourceService
supportedInteractionModels
in interface ResourceService
public String generateIdentifier()
ResourceService
generateIdentifier
in interface ResourceService