SELECT ?zone WHER { ?zone rdf:type sitac:TaskZone . ?zone sitac:isTasked "true" . }To parse this request, we can do:
SPARQLParser parser = new SPARQLParser("sitac"); SparqlRequest request = parser.parseQuery(<the request String>);The following code will throw a MalformedQueryException.
SELECT ?zone WHER { ?zone rdf:type sitac:TaskZone . ?zone sitac:isTasked "true" . }To parse this request, we can do:
SparqlHelperConfig.getInstance().setErrorsHandlingType(ErrorsHandlingType.EMPTY_QUERY); SPARQLParser parser = new SPARQLParser("sitac"); SparqlRequest request = parser.parseQuery(<the request String>); boolean isValid = request.isWellformed(); // will return falseIf you perform:
String parsedQuery = request.toString();You will have the following content:
SELECT * WHERE { ?o rdf:type owl:Thing . } LIMIT 0
Copyright 2025 Dassault Aviation. All Rights Reserved. Documentation and source under the LGPL v3 licence
Project Web Hosted by
Copyright 1999-2010 -
Geeknet, Inc., All Rights Reserved
About
-
Legal
-
Help