Add getChildNodes() method to Node
This commit is contained in:
parent
34aeeffb62
commit
eef65908a1
|
@ -171,6 +171,8 @@ class Node:
|
|||
return flatten(self._getChildren())
|
||||
def asList(self):
|
||||
return tuple(asList(self.getChildren()))
|
||||
def getChildNodes(self):
|
||||
return [n for n in self.getChildnre() if isinstance(n, Node)]
|
||||
|
||||
class EmptyNode(Node):
|
||||
def __init__(self):
|
||||
|
|
|
@ -171,6 +171,8 @@ class Node:
|
|||
return flatten(self._getChildren())
|
||||
def asList(self):
|
||||
return tuple(asList(self.getChildren()))
|
||||
def getChildNodes(self):
|
||||
return [n for n in self.getChildnre() if isinstance(n, Node)]
|
||||
|
||||
class EmptyNode(Node):
|
||||
def __init__(self):
|
||||
|
|
Loading…
Reference in New Issue