MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / before_parent_attach

Method before_parent_attach

lib/sqlalchemy/sql/events.py:308–323  ·  view source on GitHub ↗

Called before a :class:`.SchemaItem` is associated with a parent :class:`.SchemaItem`. :param target: the target object :param parent: the parent to which the target is being attached. :func:`.event.listen` also accepts the ``propagate=True`` modifier for th

(
        self, target: SchemaEventTarget, parent: SchemaItem
    )

Source from the content-addressed store, hash-verified

306 """
307
308 def before_parent_attach(
309 self, target: SchemaEventTarget, parent: SchemaItem
310 ) -> None:
311 """Called before a :class:`.SchemaItem` is associated with
312 a parent :class:`.SchemaItem`.
313
314 :param target: the target object
315 :param parent: the parent to which the target is being attached.
316
317 :func:`.event.listen` also accepts the ``propagate=True``
318 modifier for this event; when True, the listener function will
319 be established for any copies made of the target object,
320 i.e. those copies that are generated when
321 :meth:`_schema.Table.to_metadata` is used.
322
323 """
324
325 def after_parent_attach(
326 self, target: SchemaEventTarget, parent: SchemaItem

Callers 2

_newMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected