Class FedoraLdp

    • Constructor Detail

      • FedoraLdp

        public FedoraLdp()
        Default JAX-RS entry point
      • FedoraLdp

        public FedoraLdp​(String externalPath)
        Create a new FedoraNodes instance for a given path
        Parameters:
        externalPath - the external path
    • Method Detail

      • head

        @HEAD
        @Produces({"text/turtle;charset=utf-8;qs=1.0","application/ld+json;qs=0.8","text/rdf+n3;charset=utf-8","text/n3;charset=utf-8","application/rdf+xml","application/n-triples","text/plain;charset=utf-8","application/x-turtle","text/html;charset=utf-8"})
        public javax.ws.rs.core.Response head()
                                       throws UnsupportedAlgorithmException
        Retrieve the node headers
        Returns:
        response
        Throws:
        UnsupportedAlgorithmException - if unsupported digest algorithm occurred
      • options

        @OPTIONS
        public javax.ws.rs.core.Response options()
        Outputs information about the supported HTTP methods, etc.
        Returns:
        the outputs information about the supported HTTP methods, etc.
      • getResource

        @GET
        @Produces({"text/turtle;charset=utf-8;qs=1.0","application/ld+json;qs=0.8","text/rdf+n3;charset=utf-8","text/n3;charset=utf-8","application/rdf+xml","application/n-triples","text/plain;charset=utf-8","application/x-turtle","text/html;charset=utf-8"})
        public javax.ws.rs.core.Response getResource​(@HeaderParam("Range")
                                                     String rangeValue)
                                              throws IOException,
                                                     UnsupportedAlgorithmException
        Retrieve the node profile
        Parameters:
        rangeValue - the range value
        Returns:
        a binary or the triples for the specified node
        Throws:
        IOException - if IO exception occurred
        UnsupportedAlgorithmException - if unsupported digest algorithm occurred
      • deleteObject

        @DELETE
        public javax.ws.rs.core.Response deleteObject()
        Deletes an object.
        Returns:
        response
      • updateSparql

        @Consumes("application/sparql-update")
        public javax.ws.rs.core.Response updateSparql​(InputStream requestBodyStream)
                                               throws IOException
        Update an object using SPARQL-UPDATE
        Parameters:
        requestBodyStream - the request body stream
        Returns:
        201
        Throws:
        IOException - if IO exception occurred
      • createObject

        @POST
        @Consumes({"application/octet-stream;qs=1.000","*/*"})
        @Produces({"text/turtle;charset=utf-8;qs=1.0","application/ld+json;qs=0.8","text/rdf+n3;charset=utf-8","text/n3;charset=utf-8","application/rdf+xml","application/n-triples","text/plain;charset=utf-8","application/x-turtle","text/html;charset=utf-8","*/*"})
        public javax.ws.rs.core.Response createObject​(@HeaderParam("Content-Disposition")
                                                      org.glassfish.jersey.media.multipart.ContentDisposition contentDisposition,
                                                      @HeaderParam("Content-Type")
                                                      javax.ws.rs.core.MediaType requestContentType,
                                                      @HeaderParam("Slug")
                                                      String slug,
                                                      InputStream requestBodyStream,
                                                      @HeaderParam("Link")
                                                      List<String> rawLinks,
                                                      @HeaderParam("Digest")
                                                      String digest)
                                               throws InvalidChecksumException,
                                                      MalformedRdfException,
                                                      UnsupportedAlgorithmException
        Creates a new object. This originally used application/octet-stream;qs=1001 as a workaround for JERSEY-2636, to ensure requests without a Content-Type get routed here. This qs value does not parse with newer versions of Jersey, as qs values must be between 0 and 1. We use qs=1.000 to mark where this historical anomaly had been.
        Parameters:
        contentDisposition - the content Disposition value
        requestContentType - the request content type
        slug - the slug value
        requestBodyStream - the request body stream
        rawLinks - the link values
        digest - the digest header
        Returns:
        201
        Throws:
        InvalidChecksumException - if invalid checksum exception occurred
        MalformedRdfException - if malformed rdf exception occurred
        UnsupportedAlgorithmException - if an unsupported algorithm exception occurs