sqltriples.Query.Tuples

Package sqltriples :: Module Query :: Class Tuples |
[show private | hide private]
[frames | no frames]

## Class Tuples

    AbstractQuery --+
                    |
                Query --+
                        |
                  Results --+
                            |
                           Tuples

Known Subclasses:
  `ConjunctionOfTuples`, `DisjunctionOfTuples`, `IntersectionOfTuples`, `NegationOfTuples`

    A class representing a selection of triples.

Method Summary
| ``_get_exposed_columns`(self)` Return the extended exposed columns for the pattern.
| ``_get_results`(self, results)` Return the 'results' for the retrieved tuples.
Inherited from Results
| ``__init__`(self, store, pattern, expression, functions, ordering, order_by, limit, partial)` Initialise the results object with the given 'store', 'pattern', optional 'expression', optional 'ordering' and 'order_by' descriptions and optional 'limit' criteria.
| ``_get_joins`(self, index)` Add joins where the result needs them: ...
| ``_get_order_column`(self, index)`
| ``_get_order_direction`(self, index)`
| ``_get_order_extent`(self)`
| ``_get_query`(self, select_clause, index, new_index, constraints, constraint_values)` Build the query conditions and return a usable query which starts with the supplied 'select_clause' and which uses the given table 'index' number as qualifier.
Inherited from Query
| ``__getitem__`(self, i)`
| ``__len__`(self)`
| ``__repr__`(self)`
| ``get_query`(self, index, constraints)` Return a query clause, associated values, and an updated table index (as a 3-tuple) for this object's query defined using the given table 'index' and the supplied, optional 'constraints' text.
| ``get_subquery`(self, parent_columns, parent_index, index, match_first, match_parent, match_child)` Make a subquery for this object using the given 'parent_columns' (indicating the columns which connect with this object's exposed columns), a 'parent_index' (indicating the table index used in the parent query, within which the returned query clause shall be employed), and the current table 'index'.
| ``_apply_function`(self, fn, column)`
| ``_ensure`(self)` Ensure the the query has been executed.
| ``_execute`(self)` Execute the query, generated by this object's 'get_query' method, and return the results in a form produced by this object's '_get_results' method.
| ``_get_columns`(self, exposed_columns, index, limited_to)` Return a column selection for the 'exposed_columns' qualified by the given table 'index', optionally limited by the given 'limited_to' sequence of column definitions.
| ``_get_join_constraints`(self, parent_columns, child_columns, parent_index, child_index)`
| ``_get_table`(self, index)`

Class Variable Summary
`list` | `exposed_columns` = `[('subject', 'subject_type'), ('predic...`
Inherited from AbstractQuery
`list` | `table_columns` = `[('subject', 'subject_type', 0), ('predi...`

Method Details

### _get_exposed_columns(self)
    Return the extended exposed columns for the pattern.
Overrides: `sqltriples.Query.AbstractQuery._get_exposed_columns`

### _get_results(self, results)
    Return the 'results' for the retrieved tuples.

Class Variable Details

    ### exposed_columns Type: `list` Value:
        [('subject', 'subject_type'), ('predicate', None), ('object', 'object_\
        type')]

Generated by Epydoc 2.1 on Sat Jul 7 23:24:47 2007 | http://epydoc.sf.net