r"""Called before CREATE statements are emitted. :param target: the :class:`.SchemaObject`, such as a :class:`_schema.MetaData` or :class:`_schema.Table` but also including all create/drop objects such as :class:`.Index`, :class:`.Sequence`, etc., object
(
self, target: SchemaEventTarget, connection: Connection, **kw: Any
)
| 177 | _dispatch_target = SchemaEventTarget |
| 178 | |
| 179 | def before_create( |
| 180 | self, target: SchemaEventTarget, connection: Connection, **kw: Any |
| 181 | ) -> None: |
| 182 | r"""Called before CREATE statements are emitted. |
| 183 | |
| 184 | :param target: the :class:`.SchemaObject`, such as a |
| 185 | :class:`_schema.MetaData` or :class:`_schema.Table` |
| 186 | but also including all create/drop objects such as |
| 187 | :class:`.Index`, :class:`.Sequence`, etc., |
| 188 | object which is the target of the event. |
| 189 | |
| 190 | .. versionadded:: 2.0 Support for all :class:`.SchemaItem` objects |
| 191 | was added. |
| 192 | |
| 193 | :param connection: the :class:`_engine.Connection` where the |
| 194 | CREATE statement or statements will be emitted. |
| 195 | :param \**kw: additional keyword arguments relevant |
| 196 | to the event. The contents of this dictionary |
| 197 | may vary across releases, and include the |
| 198 | list of tables being generated for a metadata-level |
| 199 | event, the checkfirst flag, and other |
| 200 | elements used by internal events. |
| 201 | |
| 202 | :func:`.event.listen` accepts the ``propagate=True`` |
| 203 | modifier for this event; when True, the listener function will |
| 204 | be established for any copies made of the target object, |
| 205 | i.e. those copies that are generated when |
| 206 | :meth:`_schema.Table.to_metadata` is used. |
| 207 | |
| 208 | :func:`.event.listen` accepts the ``insert=True`` |
| 209 | modifier for this event; when True, the listener function will |
| 210 | be prepended to the internal list of events upon discovery, and execute |
| 211 | before registered listener functions that do not pass this argument. |
| 212 | |
| 213 | """ |
| 214 | |
| 215 | def after_create( |
| 216 | self, target: SchemaEventTarget, connection: Connection, **kw: Any |
no outgoing calls