langdev.orm — Object-relational mapping powered by SQLAlchemy

This module provides object-relational mapping facilities powered by SQLAlchemy.

In order to define persist model class, just subclass Base:

from sqlalchemy import *
import langdev.orm

class Thing(langdev.orm.Base):
    '''A something object-relationally mapped.'''

    id = Column(Integer, primary_key=True)
    value = Column(UnicodeText, nullable=False)
    __tablename__ = 'things'
class langdev.orm.Session(**local_kwargs)

SQLAlchemy session class.

See also

SQLAlchemy — Using the Session

class langdev.orm.Base(**kwargs)

SQLAlchemy declarative base class.

See also

SQLAlchemy — Declarative


Make a repr() string for the given self object.

Parameters:self – an object to make a repr() string
Returns:a repr() string
Return type:str

Project Versions

Previous topic

langdev — LangDev

Next topic

langdev.user — LangDev users

This Page