MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / Vertex

Class Vertex

test/typing/plain_files/orm/composite.py:43–56  ·  test/typing/plain_files/orm/composite.py::Vertex

Source from the content-addressed store, hash-verified

41
42
43class Vertex(Base):
44 __tablename__ = class="st">"vertices"
45
46 id: Mapped[int] = mapped_column(primary_key=True)
47 x1: Mapped[int]
48 y1: Mapped[int]
49 x2: Mapped[int]
50 y2: Mapped[int]
51
52 class="cm"># inferred from right hand side
53 start = composite(Point, class="st">"x1", class="st">"y1")
54
55 class="cm"># taken from left hand side
56 end: Mapped[Point] = composite(Point._generate, class="st">"x2", class="st">"y2")
57
58
59v1 = Vertex(start=Point(3, 4), end=Point(5, 6))

Callers 1

composite.pyFile · 0.70

Calls 2

mapped_columnFunction · 0.90
compositeFunction · 0.90

Tested by

no test coverage detected