Search in sources :

Example 6 with UploadDetails

use of org.apache.jena.fuseki.system.UploadDetails in project jena by apache.

the class GSP_RW method doPutPostGSP.

// ---- Triples to target graph
protected void doPutPostGSP(HttpAction action, boolean overwrite) {
    ContentType ct = ActionLib.getContentType(action);
    if (ct == null)
        ServletOps.errorBadRequest("No Content-Type:");
    UploadDetails details;
    if (action.isTransactional())
        details = triplesPutPostTxn(action, overwrite);
    else
        details = triplesPutPostNonTxn(action, overwrite);
    ServletOps.uploadResponse(action, details);
}
Also used : UploadDetails(org.apache.jena.fuseki.system.UploadDetails) ContentType(org.apache.jena.atlas.web.ContentType)

Example 7 with UploadDetails

use of org.apache.jena.fuseki.system.UploadDetails in project jena by apache.

the class GSP_RW method doPutPostQuads.

protected void doPutPostQuads(HttpAction action, boolean replaceOperation) {
    ContentType ct = ActionLib.getContentType(action);
    if (ct == null)
        ServletOps.errorBadRequest("No Content-Type:");
    if (!action.getDataService().allowUpdate())
        ServletOps.errorMethodNotAllowed(action.getMethod());
    UploadDetails details;
    if (action.isTransactional())
        details = UploadRDF.quadsPutPostTxn(action, a -> decideDataset(a), replaceOperation);
    else
        details = UploadRDF.quadsPutPostNonTxn(action, a -> decideDataset(a), replaceOperation);
    ServletOps.uploadResponse(action, details);
}
Also used : UploadDetails(org.apache.jena.fuseki.system.UploadDetails) ContentType(org.apache.jena.atlas.web.ContentType)

Aggregations

UploadDetails (org.apache.jena.fuseki.system.UploadDetails)7 RiotException (org.apache.jena.riot.RiotException)4 StreamRDF (org.apache.jena.riot.system.StreamRDF)4 OperationDeniedException (org.apache.jena.shared.OperationDeniedException)4 DatasetGraph (org.apache.jena.sparql.core.DatasetGraph)4 ContentType (org.apache.jena.atlas.web.ContentType)3 FusekiConfigException (org.apache.jena.fuseki.FusekiConfigException)2 Graph (org.apache.jena.graph.Graph)2 RiotParseException (org.apache.jena.riot.RiotParseException)2