Class RdfPubClientDefault

java.lang.Object
org.linkedopenactors.rdfpub.client.RdfPubClientAbstract
org.linkedopenactors.rdfpub.client.RdfPubClientDefault
All Implemented Interfaces:
RdfPubClient, RdfPubClientAnonymous

public class RdfPubClientDefault extends RdfPubClientAbstract implements RdfPubClient
Default implementation of RdfPubClient.
Author:
SofwareEngineering Hauschel
  • Constructor Details

    • RdfPubClientDefault

      public RdfPubClientDefault(org.eclipse.rdf4j.model.IRI rdfPubServerActorIri, org.springframework.web.reactive.function.client.WebClient webClient, org.eclipse.rdf4j.model.IRI clientApplicationActor)
      Parameters:
      rdfPubServerActorIri - The iri/url of the server actor. Used to get the public sparql endpoint
      webClient - The webclient to use for http communication.
      clientApplicationActor - The iri/url of the user. TODO determinate this by webfinger ?!
  • Method Details

    • postActivity

      public org.eclipse.rdf4j.model.IRI postActivity(org.eclipse.rdf4j.model.Model activity, String authToken)
      Description copied from interface: RdfPubClient
      Posts a new activity to the usres outbox.
      Specified by:
      postActivity in interface RdfPubClient
      Parameters:
      activity - the model of the new activity to post.
      Returns:
      the id of the newly created activity.
    • getRdfPubProfile

      public org.eclipse.rdf4j.model.Model getRdfPubProfile()
      Specified by:
      getRdfPubProfile in interface RdfPubClient
    • getProfile

      public Optional<org.eclipse.rdf4j.model.Model> getProfile()
      Specified by:
      getProfile in interface RdfPubClient
    • getProfile

      public Optional<org.eclipse.rdf4j.model.Model> getProfile(String authToken)
      Specified by:
      getProfile in interface RdfPubClient
    • read

      public Optional<org.eclipse.rdf4j.model.Model> read(org.eclipse.rdf4j.model.IRI idOfTheResourceToRead, String authToken)
      Specified by:
      read in interface RdfPubClient
    • getActorId

      public org.eclipse.rdf4j.model.IRI getActorId()
      Specified by:
      getActorId in interface RdfPubClient
    • graphQueryOutbox

      public org.eclipse.rdf4j.model.Model graphQueryOutbox(String query, String authToken)
      Specified by:
      graphQueryOutbox in interface RdfPubClient
    • tupleQueryOutbox

      public List<org.eclipse.rdf4j.query.BindingSet> tupleQueryOutbox(String query, String authToken)
      Specified by:
      tupleQueryOutbox in interface RdfPubClient
    • getStatementsOutbox

      public org.eclipse.rdf4j.model.Model getStatementsOutbox(String authToken, org.eclipse.rdf4j.model.Resource subj, org.eclipse.rdf4j.model.IRI pred, org.eclipse.rdf4j.model.Value obj, org.eclipse.rdf4j.model.Resource... contexts)
      Specified by:
      getStatementsOutbox in interface RdfPubClient