]> git.ipfire.org Git - thirdparty/sqlalchemy/sqlalchemy.git/commitdiff
Convert most "See also" phrases into .. seealso::
authorMike Bayer <mike_mp@zzzcomputing.com>
Tue, 15 Jan 2019 21:12:39 +0000 (16:12 -0500)
committerMike Bayer <mike_mp@zzzcomputing.com>
Tue, 15 Jan 2019 21:13:12 +0000 (16:13 -0500)
Change-Id: Ie32598b895c1c5f5bce7c8e1573abbcfe9d434a8
(cherry picked from commit e81d3815abb36c52b0019dee6e4f67990e3d1c7d)

12 files changed:
doc/build/orm/mapping_columns.rst
doc/build/orm/session_basics.rst
lib/sqlalchemy/engine/base.py
lib/sqlalchemy/events.py
lib/sqlalchemy/orm/descriptor_props.py
lib/sqlalchemy/orm/interfaces.py
lib/sqlalchemy/orm/properties.py
lib/sqlalchemy/orm/relationships.py
lib/sqlalchemy/pool.py
lib/sqlalchemy/sql/operators.py
lib/sqlalchemy/sql/sqltypes.py
lib/sqlalchemy/sql/type_api.py

index 4b31b92102c91089d0835fe58447362c4368b85c..e07692388532f4b5620d47f6d5ff01956fafce18 100644 (file)
@@ -207,16 +207,18 @@ should be included or excluded::
 
 .. note::
 
-   insert and update defaults configured on individual
-   :class:`.Column` objects, i.e. those described at :ref:`metadata_defaults`
-   including those configured by the ``default``, ``update``,
-   ``server_default`` and ``server_onupdate`` arguments, will continue to
-   function normally even if those :class:`.Column` objects are not mapped.
-   This is because in the case of ``default`` and ``update``, the
-   :class:`.Column` object is still present on the underlying
-   :class:`.Table`, thus allowing the default functions to take place when
-   the ORM emits an INSERT or UPDATE, and in the case of ``server_default``
-   and ``server_onupdate``, the relational database itself maintains these
-   functions.
+    insert and update defaults configured on individual :class:`.Column`
+    objects, i.e. those described at :ref:`metadata_defaults` including those
+    configured by the :paramref:`.Column.default`,
+    :paramref:`.Column.onupdate`, :paramref:`.Column.server_default` and
+    :paramref:`.Column.server_onupdate` parameters, will continue to function
+    normally even if those :class:`.Column` objects are not mapped. This is
+    because in the case of :paramref:`.Column.default` and
+    :paramref:`.Column.onupdate`, the :class:`.Column` object is still present
+    on the underlying :class:`.Table`, thus allowing the default functions to
+    take place when the ORM emits an INSERT or UPDATE, and in the case of
+    :paramref:`.Column.server_default` and :paramref:`.Column.server_onupdate`,
+    the relational database itself emits these defaults as a server side
+    behavior.
 
 
index 6f3500abbbde2b881336c2e9cac00e623d5fc43c..4547e124361901ebb530980274b724bf48a915b3 100644 (file)
@@ -664,7 +664,9 @@ it will be deleted on flush::
     some_user.preference = None
     session.flush()  # will delete the Preference object
 
-See also :ref:`unitofwork_cascades` for detail on cascades.
+.. seealso::
+
+    :ref:`unitofwork_cascades` for detail on cascades.
 
 
 Deleting based on Filter Criterion
index 2b7c3f86e489b2701e9344e82184d385c9863e6f..91accd9ec8d351fd97226e43377949b141d50bb4 100644 (file)
@@ -609,14 +609,14 @@ class Connection(Connectable):
         :class:`.Transaction` objects will roll back the
         transaction.
 
-        See also:
+        .. seealso::
 
-        :meth:`.Connection.begin_nested` - use a SAVEPOINT
+            :meth:`.Connection.begin_nested` - use a SAVEPOINT
 
-        :meth:`.Connection.begin_twophase` - use a two phase /XID transaction
+            :meth:`.Connection.begin_twophase` - use a two phase /XID transaction
 
-        :meth:`.Engine.begin` - context manager available from
-        :class:`.Engine`.
+            :meth:`.Engine.begin` - context manager available from
+            :class:`.Engine`
 
         """
         if self.__branch_from:
@@ -639,8 +639,12 @@ class Connection(Connectable):
         still controls the overall ``commit`` or ``rollback`` of the
         transaction of a whole.
 
-        See also :meth:`.Connection.begin`,
-        :meth:`.Connection.begin_twophase`.
+        .. seealso::
+
+            :meth:`.Connection.begin`
+
+            :meth:`.Connection.begin_twophase`
+
         """
         if self.__branch_from:
             return self.__branch_from.begin_nested()
@@ -663,8 +667,11 @@ class Connection(Connectable):
         :param xid: the two phase transaction id.  If not supplied, a
           random id will be generated.
 
-        See also :meth:`.Connection.begin`,
-        :meth:`.Connection.begin_twophase`.
+        .. seealso::
+
+            :meth:`.Connection.begin`
+
+            :meth:`.Connection.begin_twophase`
 
         """
 
@@ -1553,7 +1560,7 @@ class Connection(Connectable):
                with engine.begin() as conn:
                    conn.execute("some statement", {'x':5, 'y':10})
 
-        See also:
+        .. seealso::
 
             :meth:`.Engine.begin` - engine-level transactional
             context
@@ -1643,8 +1650,13 @@ class Transaction(object):
 
     The Transaction object is **not** threadsafe.
 
-    See also:  :meth:`.Connection.begin`, :meth:`.Connection.begin_twophase`,
-    :meth:`.Connection.begin_nested`.
+    .. seealso::
+
+        :meth:`.Connection.begin`
+
+        :meth:`.Connection.begin_twophase`
+
+        :meth:`.Connection.begin_nested`
 
     .. index::
       single: thread safety; Transaction
@@ -1797,11 +1809,11 @@ class Engine(Connectable, log.Identified):
     An :class:`.Engine` object is instantiated publicly using the
     :func:`~sqlalchemy.create_engine` function.
 
-    See also:
+    .. seealso::
 
-    :doc:`/core/engines`
+        :doc:`/core/engines`
 
-    :ref:`connections_toplevel`
+        :ref:`connections_toplevel`
 
     """
 
@@ -2082,7 +2094,7 @@ class Engine(Connectable, log.Identified):
                with engine.begin() as conn:
                    conn.execute("some statement", {'x':5, 'y':10})
 
-        See also:
+        .. seealso::
 
             :meth:`.Engine.begin` - engine-level transactional
             context
index c1b6f3740b491499cf53104dfa38a6b08584e0d6..5eb84a1564cad729b638dd4294cb0f7a85ac5f38 100644 (file)
@@ -80,8 +80,7 @@ class DDLEvents(event.Events):
     The above :class:`.DDL` object will also be associated with the
     :class:`.Table` object represented by ``new_table``.
 
-
-    See also:
+    .. seealso::
 
         :ref:`event_toplevel`
 
@@ -669,9 +668,9 @@ class ConnectionEvents(event.Events):
         :param multiparams: Multiple parameter sets, a list of dictionaries.
         :param params: Single parameter set, a single dictionary.
 
-        See also:
+        .. seealso::
 
-        :meth:`.before_cursor_execute`
+            :meth:`.before_cursor_execute`
 
         """
 
@@ -722,11 +721,11 @@ class ConnectionEvents(event.Events):
         :param executemany: boolean, if ``True``, this is an ``executemany()``
          call, if ``False``, this is an ``execute()`` call.
 
-        See also:
+        .. seealso::
 
-        :meth:`.before_execute`
+            :meth:`.before_execute`
 
-        :meth:`.after_cursor_execute`
+            :meth:`.after_cursor_execute`
 
         """
 
index f9d955f85efb1b088dc0ee48cdb9de8600e474cd..edb61b427340c9e306c874b9718b6b8108e784da 100644 (file)
@@ -393,15 +393,15 @@ class CompositeProperty(DescriptorProperty):
         See the example in :ref:`composite_operations` for an overview
         of usage , as well as the documentation for :class:`.PropComparator`.
 
-        See also:
+        .. seealso::
 
-        :class:`.PropComparator`
+            :class:`.PropComparator`
 
-        :class:`.ColumnOperators`
+            :class:`.ColumnOperators`
 
-        :ref:`types_operators`
+            :ref:`types_operators`
 
-        :attr:`.TypeEngine.comparator_factory`
+            :attr:`.TypeEngine.comparator_factory`
 
         """
 
index aac14669c12beecb4577bef922603e6bb44fec41..a93c0d16053840f446c779721b58a0fc08b1b2cf 100644 (file)
@@ -338,19 +338,19 @@ class PropComparator(operators.ColumnOperators):
     :attr:`.TypeEngine.comparator_factory` attribute.  See
     :ref:`types_operators` for more detail.
 
-    See also:
+    .. seealso::
 
-    :class:`.ColumnProperty.Comparator`
+        :class:`.ColumnProperty.Comparator`
 
-    :class:`.RelationshipProperty.Comparator`
+        :class:`.RelationshipProperty.Comparator`
 
-    :class:`.CompositeProperty.Comparator`
+        :class:`.CompositeProperty.Comparator`
 
-    :class:`.ColumnOperators`
+        :class:`.ColumnOperators`
 
-    :ref:`types_operators`
+        :ref:`types_operators`
 
-    :attr:`.TypeEngine.comparator_factory`
+        :attr:`.TypeEngine.comparator_factory`
 
     """
 
index c06b43918d7922de074ca39741988b1aac818bda..d0305509e26138e6fbbf40e54c1f98aee610f6d0 100644 (file)
@@ -260,15 +260,15 @@ class ColumnProperty(StrategizedProperty):
         See the documentation for :class:`.PropComparator` for a brief
         overview.
 
-        See also:
+        .. seealso::
 
-        :class:`.PropComparator`
+            :class:`.PropComparator`
 
-        :class:`.ColumnOperators`
+            :class:`.ColumnOperators`
 
-        :ref:`types_operators`
+            :ref:`types_operators`
 
-        :attr:`.TypeEngine.comparator_factory`
+            :attr:`.TypeEngine.comparator_factory`
 
         """
 
index 046e7d4ee99da4887bf6711719b1a5aad6c11522..ff8b679e48927721101e4490e5f2c8bc88a3f14c 100644 (file)
@@ -94,9 +94,9 @@ class RelationshipProperty(StrategizedProperty):
 
     Public constructor is the :func:`.orm.relationship` function.
 
-    See also:
+    .. seealso::
 
-    :ref:`relationship_config_toplevel`
+        :ref:`relationship_config_toplevel`
 
     """
 
@@ -894,17 +894,17 @@ class RelationshipProperty(StrategizedProperty):
         See the documentation for :class:`.PropComparator` for a brief
         overview of ORM level operator definition.
 
-        See also:
+        .. seealso::
 
-        :class:`.PropComparator`
+            :class:`.PropComparator`
 
-        :class:`.ColumnProperty.Comparator`
+            :class:`.ColumnProperty.Comparator`
 
-        :class:`.ColumnOperators`
+            :class:`.ColumnOperators`
 
-        :ref:`types_operators`
+            :ref:`types_operators`
 
-        :attr:`.TypeEngine.comparator_factory`
+            :attr:`.TypeEngine.comparator_factory`
 
         """
 
index f8d46b21f1fb7cc8b061d6da6bd98791be3af132..df714f0162e8e52245ab81470d2dfd8a53443fc3 100644 (file)
@@ -405,7 +405,9 @@ class Pool(log.Identified):
         remaining open, as it only affects connections that are
         idle in the pool.
 
-        See also the :meth:`Pool.recreate` method.
+        .. seealso::
+
+            :meth:`Pool.recreate`
 
         """
 
index f202cf35322bc3512486311b8ba9cb84f9d91bc7..f36fb6d340f13ebf88c108412035dd0cf14458fa 100644 (file)
@@ -320,15 +320,15 @@ class ColumnOperators(Operators):
     so that the ``==`` operation above is replaced by a clause
     construct.
 
-    See also:
+    .. seealso::
 
-    :ref:`types_operators`
+        :ref:`types_operators`
 
-    :attr:`.TypeEngine.comparator_factory`
+        :attr:`.TypeEngine.comparator_factory`
 
-    :class:`.ColumnOperators`
+        :class:`.ColumnOperators`
 
-    :class:`.PropComparator`
+        :class:`.PropComparator`
 
     """
 
index 4428bb8f9cf86955a56565ee77f2aa0703147555..eb9d2c2f4315d893387fa5aba1d927df3672b11a 100644 (file)
@@ -376,7 +376,7 @@ class Unicode(String):
     unicode.  The recipe at :ref:`coerce_to_unicode` illustrates
     how this is done.
 
-    See also:
+    .. seealso::
 
         :class:`.UnicodeText` - unlengthed textual counterpart
         to :class:`.Unicode`.
index baa41e6f1b679f16e0ec4b2da0a20d92b8128ed3..4a4d20f3641954352f1a7ebd20637e9893b5feca 100644 (file)
@@ -295,9 +295,9 @@ class TypeEngine(Visitable):
         The method is evaluated at statement compile time, as opposed
         to statement construction time.
 
-        See also:
+        .. seealso::
 
-        :ref:`types_sql_value_processing`
+            :ref:`types_sql_value_processing`
 
         """
 
@@ -336,9 +336,9 @@ class TypeEngine(Visitable):
         may be used in an executemany() call against an arbitrary number
         of bound parameter sets.
 
-        See also:
+        .. seealso::
 
-        :ref:`types_sql_value_processing`
+            :ref:`types_sql_value_processing`
 
         """
         return None