MCPcopy Create free account
hub / github.com/cogentcore/core / CanOpen

Method CanOpen

core/tree.go:1114–1116  ·  view source on GitHub ↗

CanOpen returns true if the node is able to open. By default it checks HasChildren(), but could check other properties to perform lazy building of the tree.

()

Source from the content-addressed store, hash-verified

1112// By default it checks HasChildren(), but could check other properties
1113// to perform lazy building of the tree.
1114func (tr *Tree) CanOpen() bool {
1115 return tr.HasChildren()
1116}
1117
1118// Open opens the given node and updates the tree accordingly
1119// (if it is not already opened). It calls OnOpen in the [Treer]

Callers

nothing calls this directly

Calls 1

HasChildrenMethod · 0.45

Tested by

no test coverage detected