diff options
| author | Jörn Hees <joernhees@users.noreply.github.com> | 2016-12-05 11:37:43 +0100 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-12-05 11:37:43 +0100 |
| commit | 2a869caa4a34197bc45e8c79302d559b026ef7b9 (patch) | |
| tree | 273886f78db38dba629b2b7a08940fb4406c93f0 | |
| parent | 38445f5622209ae83a392bc0182776d01a538fde (diff) | |
| parent | 87f71daa0a3685b982b350394cde366af41de939 (diff) | |
| download | rdflib-2a869caa4a34197bc45e8c79302d559b026ef7b9.tar.gz | |
Merge pull request #673 from SeguinBe/master
Adding the option of using POST for queries in SPARQLStore
| -rw-r--r-- | rdflib/plugins/stores/sparqlstore.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/rdflib/plugins/stores/sparqlstore.py b/rdflib/plugins/stores/sparqlstore.py index 5a703246..25cfb61d 100644 --- a/rdflib/plugins/stores/sparqlstore.py +++ b/rdflib/plugins/stores/sparqlstore.py @@ -239,6 +239,7 @@ class SPARQLStore(NSSPARQLWrapper, Store): sparql11=True, context_aware=True, node_to_sparql=_node_to_sparql, node_from_result=_node_from_result, + default_query_method=GET, **sparqlwrapper_kwargs): """ """ @@ -259,6 +260,7 @@ class SPARQLStore(NSSPARQLWrapper, Store): self.context_aware = context_aware self.graph_aware = context_aware self._timeout = None + self.query_method = default_query_method # Database Management Methods def create(self, configuration): @@ -322,6 +324,7 @@ class SPARQLStore(NSSPARQLWrapper, Store): " ".join(self.node_to_sparql(initBindings[x]) for x in v)) self.resetQuery() + self.setMethod(self.query_method) if self._is_contextual(queryGraph): self.addParameter("default-graph-uri", queryGraph) self.timeout = self._timeout |
