]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
docstrings for the hated fold_equivalents argument/function
authorMike Bayer <mike_mp@zzzcomputing.com>
Sat, 3 Jan 2009 22:40:58 +0000 (22:40 +0000)
committerMike Bayer <mike_mp@zzzcomputing.com>
Sat, 3 Jan 2009 22:40:58 +0000 (22:40 +0000)
lib/sqlalchemy/sql/expression.py
lib/sqlalchemy/sql/util.py

index 7eeff0660d1fdd3fad9c6193ba0a63ea73323ecb..2360efe05a16e53d1d70a3b0d877aab11fac49b9 100644 (file)
@@ -2522,23 +2522,22 @@ class Join(FromClause):
         return sql_util.join_condition(primary, secondary)
 
     def select(self, whereclause=None, fold_equivalents=False, **kwargs):
-        """Create a ``Select`` from this ``Join``.
+        """Create a :class:`Select` from this :class:`Join`.
 
-        whereclause
-          the WHERE criterion that will be sent to the ``select()``
-          function
+        :param whereclause: the WHERE criterion that will be sent to 
+          the :func:`select()` function
 
-        fold_equivalents
-          based on the join criterion of this ``Join``, do not include
+        :param fold_equivalents: based on the join criterion of this 
+          :class:`Join`, do not include
           repeat column names in the column list of the resulting
           select, for columns that are calculated to be "equivalent"
-          based on the join criterion of this ``Join``. This will
+          based on the join criterion of this :class:`Join`. This will
           recursively apply to any joins directly nested by this one
-          as well.
+          as well.  This flag is specific to a particular use case
+          by the ORM and will be deprecated in 0.6.
 
-        \**kwargs
-          all other kwargs are sent to the underlying ``select()`` function.
-          See the ``select()`` module level function for details.
+        :param \**kwargs: all other kwargs are sent to the 
+          underlying :func:`select()` function.
 
         """
         if fold_equivalents:
index a808c508d082fb7a30dfa862ad8b8e99234bc3ba..b8ceabb7414ddebfaa66ce2d33e09791e4952bc6 100644 (file)
@@ -346,7 +346,10 @@ def criterion_as_pairs(expression, consider_as_foreign_keys=None, consider_as_re
     return pairs
 
 def folded_equivalents(join, equivs=None):
-    """Returns the column list of the given Join with all equivalently-named,
+    """Return a list of uniquely named columns.
+    
+    The column list of the given Join will be narrowed 
+    down to a list of all equivalently-named,
     equated columns folded into one column, where 'equated' means they are
     equated to each other in the ON clause of this join.