MCPcopy Create free account
hub / github.com/ipython/ipython / visit_ClassDef

Method visit_ClassDef

docs/sphinxext/apigen.py:64–71  ·  view source on GitHub ↗
(self, node)

Source from the content-addressed store, hash-verified

62 self.functions.append(node.name)
63
64 def visit_ClassDef(self, node):
65 if not (node.name.startswith('_') or self.has_undoc_decorator(node)) \
66 and node.name not in self.classes_seen:
67 cls = Obj(name=node.name)
68 cls.has_init = any(isinstance(n, ast.FunctionDef) and \
69 n.name=='__init__' for n in node.body)
70 self.classes.append(cls)
71 self.classes_seen.add(node.name)
72
73 def scan(self, mod):
74 self.visit(mod)

Callers

nothing calls this directly

Calls 3

has_undoc_decoratorMethod · 0.95
ObjClass · 0.70
addMethod · 0.45

Tested by

no test coverage detected