MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / _init_items

Method _init_items

lib/sqlalchemy/sql/schema.py:233–245  ·  view source on GitHub ↗

Initialize the list of child items for this SchemaItem.

(self, *args: SchemaItem, **kw: Any)

Source from the content-addressed store, hash-verified

231 create_drop_stringify_dialect = "default"
232
233 def _init_items(self, *args: SchemaItem, **kw: Any) -> None:
234 """Initialize the list of child items for this SchemaItem."""
235 for item in args:
236 if item is not None:
237 try:
238 spwd = item._set_parent_with_dispatch
239 except AttributeError as err:
240 raise exc.ArgumentError(
241 "'SchemaItem' object, such as a 'Column' or a "
242 f"'Constraint' expected, got {item!r}"
243 ) from err
244 else:
245 spwd(self, **kw)
246
247 def __repr__(self) -> str:
248 return util.generic_repr(self, omit_kwarg=["info"])

Callers 5

__init__Method · 0.80
_init_existingMethod · 0.80
__init__Method · 0.80
add_seqFunction · 0.80

Calls

no outgoing calls