Rename module to make clear it is only for sqlalchemy.

This commit is contained in:
Georg Brandl 2010-08-21 22:36:35 +02:00
parent 092ebec8a7
commit 2399e4627c
3 changed files with 8 additions and 8 deletions

View File

@ -1,10 +1,10 @@
# -*- coding: utf-8 -*-
"""
sphinx.websupport.storage.db
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
sphinx.websupport.storage.sqlalchemy_db
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
SQLAlchemy table and mapper definitions used by the
:class:`sphinx.websupport.comments.SQLAlchemyStorage`.
:class:`sphinx.websupport.storage.sqlalchemystorage.SQLAlchemyStorage`.
:copyright: Copyright 2007-2010 by the Sphinx team, see AUTHORS.
:license: BSD, see LICENSE for details.
@ -14,15 +14,15 @@ from datetime import datetime
from sqlalchemy import Column, Integer, Text, String, Boolean, \
ForeignKey, DateTime
from sqlalchemy.ext.declarative import declarative_base
from sqlalchemy.orm import relation, sessionmaker, aliased
from sqlalchemy.ext.declarative import declarative_base
Base = declarative_base()
Session = sessionmaker()
db_prefix = 'sphinx_'
class Node(Base):
"""Data about a Node in a doctree."""
__tablename__ = db_prefix + 'nodes'

View File

@ -22,8 +22,8 @@ if sqlalchemy.__version__[:3] < '0.5':
from sphinx.websupport.errors import CommentNotAllowedError, \
UserNotAuthorizedError
from sphinx.websupport.storage import StorageBackend
from sphinx.websupport.storage.db import Base, Node, Comment, \
CommentVote, Session
from sphinx.websupport.storage.sqlalchemy_db import Base, Node, \
Comment, CommentVote, Session
from sphinx.websupport.storage.differ import CombinedHtmlDiff

View File

@ -25,7 +25,7 @@ from sphinx.websupport.errors import *
from sphinx.websupport.storage.differ import CombinedHtmlDiff
from sphinx.websupport.storage.sqlalchemystorage import Session, \
SQLAlchemyStorage, Comment, CommentVote
from sphinx.websupport.storage.db import Node
from sphinx.websupport.storage.sqlalchemy_db import Node
from util import *