MCPcopy
hub / github.com/apecloud/kubeblocks / AddConnectRoot

Method AddConnectRoot

pkg/controller/graph/dag.go:139–145  ·  view source on GitHub ↗

AddConnectRoot add 'v' to the DAG 'd' and connect root to 'v'

(v Vertex)

Source from the content-addressed store, hash-verified

137
138// AddConnectRoot add 'v' to the DAG 'd' and connect root to 'v'
139func (d *DAG) AddConnectRoot(v Vertex) bool {
140 root := d.Root()
141 if root == nil {
142 return false
143 }
144 return d.AddConnect(root, v)
145}
146
147// WalkTopoOrder walks the DAG 'd' in topology order
148func (d *DAG) WalkTopoOrder(walkFunc WalkFunc, less func(v1, v2 Vertex) bool) error {

Callers 6

MergeMethod · 0.95
TestXConnectFunction · 0.95
DoMethod · 0.80
doWriteMethod · 0.80

Calls 2

RootMethod · 0.95
AddConnectMethod · 0.95

Tested by 1

TestXConnectFunction · 0.76