Modeling Object-Relational Bridge for python
来自开放百科 - 灰狐
Modeling: Object-Relational Bridge for python
- A comprehensive model description language to specify how the object model is to map to a relational model, either pure python (PyModels) or XML.
- Functional tools to help you designing your model (in the form of either a Zope poduct, or a collection of standalone utility scripts), that can also validate your models against the most common errors made when designing a model.
- Generation of database schemas (including: primary keys, foreign keys, referential constraints),
- Generation of python code templates ready to be used1
- Support for transparent mapping of (class) inheritance in relational databases.
- A simple and powerful object-oriented query langage.
- Once you get one or more objects, using that query langage, you do not need to explicitly fetch the objects in relations to the ones you already fetched. Rather, you simply use normal python getters to traverse relationships, and the related objects are automatically fetched, when needed and when appropriate. It helps you keep the memory footprint of your applications reasonable, while keeping you away from the SQL world.
- Automatic checking for referential-integrity constraints, plus the framework provides a unified place where to put your own validation logic (objects' invariants, ...) so that they are integrated in the checked constraints.
- Automatically encloses all modifications made to a graph/set of objects in a transactional scheme, so that the changes are all saved, or none are saved.
- Support for nested graphs/sets of objects.
- Works with python 2.1, 2.2, 2.3 and 2.4