internal package Foswiki::Query::QueryAlgorithms
On this page:
internal package Foswiki::Query::QueryAlgorithms
Interface to query algorithms (documentation only, this class does nothing).
Implementations of this interface are found in Foswiki/Store/QueryAlgorithms.
The contract with query algorithms is specified by this interface description,
plus the 'query' unit tests in Fn_SEARCH.
StaticMethod query( $query, $web, $inputTopicSet, $session, $options ) → $infoCache
-
$query- A Foswiki::Query::Node object -
$web- name of the web being searched -
$inputTopicSet- iterator over names of topics in that web to search -
$session- reference to the store object -
$options- hash of requested options
getField method in this module to evaluate leaf data in the
store.
To monitor the evaluation process, use the MONITOR_EVAL setting in
Foswiki::Query::Node
StaticMethod getField($class, $node, $data, $field ) → $result
-
$classis this package -
$nodeis the query node -
$datais the indexed object -
$fieldis the scalar being used to index the object
getField is used by the query evaluation code in Foswiki::Query::Node to get
information about a leaf node, or 'field'. A field can be a name, or a literal,
and the information it refers to can be a scalar, a reference to a hash, or
a reference to an array. The exact interpretation of fields is
context-dependant, according to reasonably complex rules best documented by
the Fn_SEARCH unit test and QuerySearch.
StaticMethod getRefTopic($class, $relativeTo, $web, $topic) → $topic
-
$classis this package -
$relativeTois a pointer into the data structure of this module where the ref is relative to; for example, in the expression "other/'Web.Topic'" then$relativeToisother. -
$webthe web;Webin the above example -
$topicthe topic;Topicin the above example
Foswiki::Query::OP_ref operator by abstracting the
loading of a topic referred to using the '/' operator. For more information
on the '/' operator, see QuerySearch.
History: r1 - 19 Apr 2011 - 03:38:03 - ProjectContributor