This package provides an implementation of a query language for Python. The query language is based on Python’s generator expression. A query in this language looks like this:
>>> from xotl.ql import these, this >>> query = these(child ... for parent in this ... if parent.children & (parent.age > 32) ... for child in parent.children ... if child.age < 6)
Updates to the latest xoutil release that introduces changes in xoutil.context API.
A lots of fixes to the xotl.ql.translation.py module. The core translation algorithm is now reasonably tested.
The sub-query interpretation for functions like all_ and other like it, is now implemented and partially tested.
We have also introduced a class-level protocol for instances so that the search space for objects be reduced in the hope of making this translator usable for one-user-only, short-lived applications.
However a new protocol was introduced.
Compatible with Python 3.2 out-of-the-box, no need to use the 2to3 script.
Although PyPy is not fully supported, it passes all tests of the core language, but fails in the translation. Nevertheless the xotl.ql.translation.py is not meant to be used in production.
The word “xotl” is a Nahuatl word that means foundation, base. The xotl package comprises the foundation for building reliable systems, frameworks, and libraries. It also provides an object model that allows to build complex systems.
It is expected that xotl will use xotl.ql to: