MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / setup_mappers

Method setup_mappers

test/orm/test_joins.py:2408–2422  ·  view source on GitHub ↗
(cls)

Source from the content-addressed store, hash-verified

2406
2407 @classmethod
2408 def setup_mappers(cls):
2409 Node, nodes = cls.classes.Node, cls.tables.nodes
2410
2411 cls.mapper_registry.map_imperatively(
2412 Node,
2413 nodes,
2414 properties={
2415 "children": relationship(
2416 Node,
2417 lazy="select",
2418 join_depth=3,
2419 backref=backref("parent", remote_side=[nodes.c.id]),
2420 )
2421 },
2422 )
2423
2424 @classmethod
2425 def insert_data(cls, connection):

Callers

nothing calls this directly

Calls 3

relationshipFunction · 0.90
backrefFunction · 0.90
map_imperativelyMethod · 0.80

Tested by

no test coverage detected