MCPcopy
hub / github.com/ent/ent / ToEdgeOwner

Method ToEdgeOwner

dialect/sql/sqlgraph/graph.go:154–156  ·  view source on GitHub ↗

ToEdgeOwner returns true if the step is to an edge owner. i.e., to the table that holds the foreign-key.

()

Source from the content-addressed store, hash-verified

152// ToEdgeOwner returns true if the step is to an edge owner.
153// i.e., to the table that holds the foreign-key.
154func (s *Step) ToEdgeOwner() bool {
155 return s.Edge.Rel == O2M || (s.Edge.Rel == O2O && !s.Edge.Inverse)
156}
157
158// ThroughEdgeTable returns true if the step is through a join-table.
159func (s *Step) ThroughEdgeTable() bool {

Callers 6

NeighborsFunction · 0.80
SetNeighborsFunction · 0.80
HasNeighborsFunction · 0.80
HasNeighborsWithFunction · 0.80
OrderByNeighborsCountFunction · 0.80
OrderByNeighborTermsFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected