Inherits SMWDescription.
Public Member Functions | |
| __construct ($descriptions=array()) | |
| getDescriptions () | |
| addDescription (SMWDescription $description) | |
| getQueryString ($asvalue=false) | |
| Return a string expressing this query. | |
| isSingleton () | |
| Return true if the description is required to encompass at most a single result, independently of the knowledge base. | |
| getSize () | |
| Compute the size of the decription. | |
| getDepth () | |
| Compute the depth of the decription. | |
| getQueryFeatures () | |
| Report on query features used in description. | |
| prune (&$maxsize, &$maxdepth, &$log) | |
| Recursively restrict query to a maximal size and depth as given. | |
Protected Attributes | |
| $m_descriptions | |
Corresponds to conjunction in OWL and SPARQL. Not available in RDFS.
Definition at line 453 of file SMW_Description.php.
| SMWConjunction::__construct | ( | $ | descriptions = array() |
) |
Definition at line 457 of file SMW_Description.php.
| SMWConjunction::getDescriptions | ( | ) |
Definition at line 461 of file SMW_Description.php.
Referenced by addDescription(), SMWSparqlStoreQueryEngine::buildConjunctionCondition(), and prune().
| SMWConjunction::addDescription | ( | SMWDescription $ | description | ) |
TODO: This may not be a good solution, since it does modify $description and since it does not react to future changes
Definition at line 465 of file SMW_Description.php.
References getDescriptions(), SMWDescription::getPrintRequests(), and SMWDescription::setPrintRequests().
| SMWConjunction::getQueryString | ( | $ | asvalue = false |
) |
Return a string expressing this query.
Some descriptions have different syntax in property value positions. The parameter $asvalue specifies whether the serialisation should take that into account.
Example: The SMWValueDescription [[Paris]] returns the single result "Paris" but can also be used as value in [[has location::Paris]] which is preferred over the canonical [[has location::<q>[[Paris]]</q>]].
| boolean | $asvalue |
Reimplemented from SMWDescription.
Definition at line 482 of file SMW_Description.php.
Referenced by prune().
| SMWConjunction::isSingleton | ( | ) |
Return true if the description is required to encompass at most a single result, independently of the knowledge base.
Reimplemented from SMWDescription.
Definition at line 496 of file SMW_Description.php.
| SMWConjunction::getSize | ( | ) |
Compute the size of the decription.
Default is 1.
Reimplemented from SMWDescription.
Definition at line 505 of file SMW_Description.php.
| SMWConjunction::getDepth | ( | ) |
Compute the depth of the decription.
Default is 0.
Reimplemented from SMWDescription.
Definition at line 515 of file SMW_Description.php.
| SMWConjunction::getQueryFeatures | ( | ) |
Report on query features used in description.
Return values are (sums of) query feature constants such as SMW_PROPERTY_QUERY.
Reimplemented from SMWDescription.
Definition at line 525 of file SMW_Description.php.
| SMWConjunction::prune | ( | &$ | maxsize, | |
| &$ | maxdepth, | |||
| &$ | log | |||
| ) |
Recursively restrict query to a maximal size and depth as given.
Returns a possibly changed description that should be used as a replacement. Reduce values of parameters to account for the returned descriptions size. Default implementation for non-nested descriptions of size 1. The parameter $log contains a list of all pruned conditions, updated when some description was reduced.
Reimplemented from SMWDescription.
Definition at line 535 of file SMW_Description.php.
References getDescriptions(), SMWDescription::getPrintRequests(), and getQueryString().
SMWConjunction::$m_descriptions [protected] |
Definition at line 455 of file SMW_Description.php.
1.5.6