Package com.franz.agraph.repository
Class AGBooleanQuery
java.lang.Object
org.eclipse.rdf4j.query.impl.AbstractOperation
org.eclipse.rdf4j.query.impl.AbstractQuery
com.franz.agraph.repository.AGQuery
com.franz.agraph.repository.AGBooleanQuery
- All Implemented Interfaces:
BooleanQuery,Operation,Query
Implements the Sesame BooleanQuery interface for AllegroGraph.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.eclipse.rdf4j.query.Query
Query.QueryType -
Field Summary
Fields inherited from class com.franz.agraph.repository.AGQuery
RDFS_PLUS_PLUS, RESTRICTION, SPARQL_COVERAGE_PLANNER, SPARQL_IDENTITY_PLANNER -
Constructor Summary
ConstructorsConstructorDescriptionAGBooleanQuery(AGRepositoryConnection con, QueryLanguage ql, String queryString, String baseURI) Creates an AGBooleanQuery instance for a given connection. -
Method Summary
Modifier and TypeMethodDescriptionvoiddownload(File file, BooleanQueryResultFormat format) Evaluates the query and saves the results to a file.voiddownload(String file, BooleanQueryResultFormat format) Evaluates the query and saves the results to a file.booleanevaluate()Evaluates the query and returns a boolean result.stream(BooleanQueryResultFormat format) Evaluates the query and returns the result as an input stream.Methods inherited from class com.franz.agraph.repository.AGQuery
analyze, download, download, download, download, getBaseURI, getBindingsArray, getEngine, getEntailmentRegime, getFranzOptionPrefixString, getLanguage, getLimit, getName, getOffset, getPlanner, getQueryString, hashCode, isCheckVariables, isLoggingEnabled, isPrepared, setCheckVariables, setEngine, setEntailmentRegime, setIncludeInferred, setLimit, setLoggingEnabled, setOffset, setPlanner, setPrepared, setSaveName, stream, stream, toStringMethods inherited from class org.eclipse.rdf4j.query.impl.AbstractQuery
getMaxQueryTime, setMaxQueryTimeMethods inherited from class org.eclipse.rdf4j.query.impl.AbstractOperation
clearBindings, getBindings, getDataset, getIncludeInferred, getMaxExecutionTime, removeBinding, setBinding, setDataset, setMaxExecutionTimeMethods inherited from interface org.eclipse.rdf4j.query.Operation
clearBindings, getBindings, getDataset, getIncludeInferred, getMaxExecutionTime, removeBinding, setBinding, setDataset, setIncludeInferred, setMaxExecutionTimeMethods inherited from interface org.eclipse.rdf4j.query.Query
explain, getMaxQueryTime, setMaxQueryTime
-
Constructor Details
-
AGBooleanQuery
public AGBooleanQuery(AGRepositoryConnection con, QueryLanguage ql, String queryString, String baseURI) Creates an AGBooleanQuery instance for a given connection.- Parameters:
con- the connectionql- the query languagequeryString- the querybaseURI- the base URI for the query
-
-
Method Details
-
evaluate
Evaluates the query and returns a boolean result.- Specified by:
evaluatein interfaceBooleanQuery- Throws:
QueryEvaluationException
-
download
Evaluates the query and saves the results to a file.- Parameters:
file- Output path.format- Output format.- Throws:
QueryEvaluationException- if there is an error while evaluating query
-
download
Evaluates the query and saves the results to a file.- Parameters:
file- Output path.format- Output format.- Throws:
QueryEvaluationException- if there is an error while evaluating query
-
stream
Evaluates the query and returns the result as an input stream.Note that it is important to close the returned stream, to avoid resource leaks.
- Parameters:
format- Output format.- Returns:
- An input stream containing response data. The caller MUST close this stream to release connection resources.
- Throws:
QueryEvaluationException- if there is an error while evaluating query
-