class documentation
class Query(object):
Undocumented
Method | __init__ |
Initializes this class. |
Method |
|
Returns the list of fields for this query. |
Method |
|
Query with "old" query result format. |
Method |
|
Execute a query. |
Method |
|
Gets requested kinds of data. |
Method |
|
Returns all names referenced in the filter. |
Instance Variable | _fields |
Undocumented |
Instance Variable | _filter |
Undocumented |
Instance Variable | _filter |
Undocumented |
Instance Variable | _name |
Undocumented |
Instance Variable | _requested |
Undocumented |
Initializes this class.
The field definition is a dictionary with the field's name as a key and a tuple containing, in order, the field definition object (objects.QueryFieldDefinition
, the data kind to help calling code collect data and a retrieval function. The retrieval function is called with two parameters, in order, the data container and the item in container (see Query.Query
).
Users of this class can call RequestedData
before preparing the data container to determine what data is needed.
Parameters | |
fieldlist:dictionary | Field definitions |
selected:list of strings | List of selected fields |
qfilter | Undocumented |
namefield | Undocumented |
Returns the list of fields for this query.
Includes unknown fields.
Returns | |
List of objects.QueryFieldDefinition | Undocumented |
Execute a query.
Parameters | |
ctx | Data container passed to field retrieval functions, must support iteration using __iter__ |
sort | Whether to sort by name or keep the input data's ordering |