]> 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:14:01 +0000 (16:14 -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/base.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 d5b3916b7d26f3c46b255ecf61624ed041ed2b97..45600928fa879fc41d995a24757668ff207075cc 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 d2eb4f644fa1b1ba37482510cf197dbbc4b102bf..02eed516b23a06626d0b06df2396e8bef57d1dcb 100644 (file)
@@ -341,19 +341,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 f7e9434485c4d6aacec46c9a658e264cf0871339..328c9b1b4e84df0f64335aefb3e4d89b90b894cf 100644 (file)
@@ -268,15 +268,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 c3e98c0c9846b960bbbd241e5bd94e1359304c30..af4d9a7825bbd6911253316a567eaadb3e4fe541 100644 (file)
@@ -95,9 +95,9 @@ class RelationshipProperty(StrategizedProperty):
 
     Public constructor is the :func:`.orm.relationship` function.
 
-    See also:
+    .. seealso::
 
-    :ref:`relationship_config_toplevel`
+        :ref:`relationship_config_toplevel`
 
     """
 
@@ -904,17 +904,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 601c5f48a719066cef6f1d61c3ab2b8392638a9b..15ac495617fb7700469d0f4d5d0a87d576fc753f 100644 (file)
@@ -358,7 +358,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 5a29d2ce8fae8ccb8be22e544264f87ad1ca42e2..7277787e2b14a3dc047185a5abbfdb5f92220b62 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 2c0a03123b6df8869710da6c55a5858d021b1230..1d97bf35c54044aeeeab70e804057b07e585c156 100644 (file)
@@ -377,7 +377,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 a283b60dc1d476461d9f72ea41a51ce4703a84d6..2c01484ebfa48d1b10574bb945302c1e54398473 100644 (file)
@@ -296,9 +296,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`
 
         """
 
@@ -337,9 +337,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