Class FilterOptimizer
- All Implemented Interfaces:
QueryOptimizer
Filters as far down in the model tree as possible.
To make the first optimization succeed more often it splits filters which contains And conditions.
SELECT * WHERE {
?s ?p ?o .
?s ?p ?o2 .
FILTER(?o > '2'^^xsd:int invalid input: '&'invalid input: '&' ?o2 invalid input: '<' '4'^^xsd:int)
}
May be more efficient when decomposed into
SELECT * WHERE {
?s ?p ?o .
FILTER(?o > '2'^^xsd:int)
?s ?p ?o2 .
FILTER(?o2 invalid input: '<' '4'^^xsd:int)
}
Then it optimizes a query model by merging adjacent Filters. e.g.
SELECT * WHERE {
?s ?p ?o .
FILTER(?o > 2) .
FILTER(?o invalid input: '<' 4) .
}
may be merged into
SELECT * WHERE {
?s ?p ?o .
FILTER(?o > 2 invalid input: '&'invalid input: '&' ?o invalid input: '<' 4) . }
This optimization allows for sharing evaluation costs in the future and removes an iterator. This is done as a second step to not break the first optimization. In the case that the splitting was done but did not help it is now undone.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classDeprecated, for removal: This API element is subject to removal in a future version.protected static classDeprecated, for removal: This API element is subject to removal in a future version.protected static classDeprecated, for removal: This API element is subject to removal in a future version.protected static classDeprecated, for removal: This API element is subject to removal in a future version. -
Constructor Summary
ConstructorsConstructorDescriptionDeprecated, for removal: This API element is subject to removal in a future version. -
Method Summary
Methods inherited from class FilterOptimizer
optimizeMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface QueryOptimizer
optimize
-
Constructor Details
-
FilterOptimizer
public FilterOptimizer()Deprecated, for removal: This API element is subject to removal in a future version.
-
FilterOptimizerinstead.