MCPcopy Create free account
hub / github.com/PageBot/PageBot / getNode

Method getNode

Lib/pagebot/document.py:1294–1303  ·  view source on GitHub ↗
(self, path)

Source from the content-addressed store, hash-verified

1292 for child in self.children:
1293 child.show(tab+1)
1294 def getNode(self, path): # Answer the node with this path, oatherwise add it.
1295 if path is None:
1296 return None
1297 for child in self.children:
1298 if path is not None and path == child.path:
1299 return child
1300
1301 node = PageNode(path)
1302 self.children.append(node)
1303 return node
1304
1305 def addPageNode(page, node):
1306 if page.url:

Callers 1

addPageNodeMethod · 0.80

Calls 2

PageNodeClass · 0.85
appendMethod · 0.45

Tested by

no test coverage detected