#include <coherence/util/aggregator/QueryRecorder.hpp>
Inherits Object, PortableObject, and InvocableMap::ParallelAwareAggregator.
For example, the following code will return a QueryPlan, containing the estimated query cost and corresponding execution steps.
QueryRecorder::Handle hAgent = QueryRecorder::create(QueryRecorder::explain); QueryRecord::View vRecord = cast<QueryRecord::View>(hCache->aggregate(filter, agent));
Public Types | ||||
enum | RecordType { explain, trace } | |||
RecordType enum specifies whether the QueryRecorder should be used to produce a QueryRecord object that contains an estimated or an actual cost of the query execution. More... | ||||
typedef spec::Handle | Handle | |||
QueryRecorder Handle definition. | ||||
typedef spec::View | View | |||
QueryRecorder View definition. | ||||
typedef spec::Holder | Holder | |||
QueryRecorder Holder definition. | ||||
Public Member Functions | ||||
virtual QueryRecorder::RecordType | getType () const | |||
Get the record type for this query recorder. | ||||
virtual Object::Holder | aggregate (Set::View vSetEntries) | |||
Process a set of InvocableMap::Entry objects in order to produce an aggregated result.
| ||||
virtual InvocableMap::EntryAggregator::Handle | getParallelAggregator () | |||
Get an aggregator that can take the place of this aggregator in situations in which the InvocableMap can aggregate in parallel.
| ||||
virtual Object::Holder | aggregateResults (Collection::View vCollResults) | |||
Aggregate the results of the parallel aggregations.
| ||||
virtual void | readExternal (PofReader::Handle hIn) | |||
virtual void | writeExternal (PofWriter::Handle hOut) const | |||
Protected Member Functions | ||||
QueryRecorder () | ||||
Default constructor (necessary for the PortableObject interface). | ||||
QueryRecorder (QueryRecorder::RecordType type) | ||||
Construct a QueryRecorder. | ||||
Protected Attributes | ||||
enum RecordType | m_type | |||
This aggregator record type. |
enum RecordType |
RecordType enum specifies whether the QueryRecorder should be used to produce a QueryRecord object that contains an estimated or an actual cost of the query execution.
explain | Produce a QueryRecord object that contains an estimated cost of the query execution. |
trace | Produce a QueryRecord object that contains the actual cost of the query execution. |
QueryRecorder | ( | QueryRecorder::RecordType | type | ) | [protected] |
virtual QueryRecorder::RecordType getType | ( | ) | const [virtual] |
Get the record type for this query recorder.