From 0e058d4b6cf487297960007bea141e19825b7eff Mon Sep 17 00:00:00 2001 From: Mike Bayer Date: Tue, 13 Mar 2007 02:37:44 +0000 Subject: [PATCH] some formatting --- lib/sqlalchemy/orm/strategies.py | 2 +- lib/sqlalchemy/sql.py | 28 +++++++++++++++++++++++----- 2 files changed, 24 insertions(+), 6 deletions(-) diff --git a/lib/sqlalchemy/orm/strategies.py b/lib/sqlalchemy/orm/strategies.py index a295ed862d..e6496a401a 100644 --- a/lib/sqlalchemy/orm/strategies.py +++ b/lib/sqlalchemy/orm/strategies.py @@ -11,7 +11,7 @@ from sqlalchemy.orm import mapper, query from sqlalchemy.orm.interfaces import * from sqlalchemy.orm import session as sessionlib from sqlalchemy.orm import util as mapperutil -import sets, random +import random class ColumnLoader(LoaderStrategy): diff --git a/lib/sqlalchemy/sql.py b/lib/sqlalchemy/sql.py index 190ec29d40..8312406973 100644 --- a/lib/sqlalchemy/sql.py +++ b/lib/sqlalchemy/sql.py @@ -988,11 +988,21 @@ class ColumnElement(Selectable, _CompareMixin): """ primary_key = property(lambda self:getattr(self, '_primary_key', False), - doc="Primary key flag. Indicates if this Column represents part or whole of a primary key.") + doc=\ + """Primary key flag. Indicates if this Column represents part or + whole of a primary key. + """) foreign_keys = property(lambda self:getattr(self, '_foreign_keys', []), - doc="Foreign key accessor. Points to a list of ForeignKey objects which represents a Foreign Key placed on this column's ultimate ancestor.") + doc=\ + """Foreign key accessor. Points to a list of ForeignKey objects + which represents a Foreign Key placed on this column's ultimate + ancestor. + """) columns = property(lambda self:[self], - doc="Columns accessor which just returns self, to provide compatibility with Selectable objects.") + doc=\ + """Columns accessor which just returns self, to provide compatibility + with Selectable objects. + """) def _one_fkey(self): if len(self._foreign_keys): @@ -1013,7 +1023,12 @@ class ColumnElement(Selectable, _CompareMixin): s.add(self) self.__orig_set = s orig_set = property(_get_orig_set, _set_orig_set, - doc="A Set containing TableClause-bound, non-proxied ColumnElements for which this ColumnElement is a proxy. In all cases except for a column proxied from a Union (i.e. CompoundSelect), this set will be just one element.") + doc=\ + """A Set containing TableClause-bound, non-proxied ColumnElements + for which this ColumnElement is a proxy. In all cases except + for a column proxied from a Union (i.e. CompoundSelect), this + set will be just one element. + """) def shares_lineage(self, othercolumn): """Return True if the given ``ColumnElement`` has a common ancestor to this ``ColumnElement``.""" @@ -1195,7 +1210,10 @@ class FromClause(Selectable): c = property(lambda s:s._get_exported_attribute('_columns')) primary_key = property(lambda s:s._get_exported_attribute('_primary_key')) foreign_keys = property(lambda s:s._get_exported_attribute('_foreign_keys')) - original_columns = property(lambda s:s._get_exported_attribute('_orig_cols'), doc="A dictionary mapping an original Table-bound column to a proxied column in this FromClause.") + original_columns = property(lambda s:s._get_exported_attribute('_orig_cols'), doc=\ + """A dictionary mapping an original Table-bound + column to a proxied column in this FromClause. + """) oid_column = property(_get_oid_column) def _export_columns(self): -- 2.47.2