Skip to content

Commit ded6987

Browse files
committed
function name
1 parent 997f2ce commit ded6987

File tree

1 file changed

+4
-4
lines changed
  • src/compas/datastructures/tree

1 file changed

+4
-4
lines changed

src/compas/datastructures/tree/tree.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -281,7 +281,7 @@ def __init__(self, name=None, **kwargs):
281281
self._root = None
282282

283283
def __str__(self):
284-
return "<Tree with {} nodes>\n{}".format(len(list(self.nodes)), self.hierarchy(max_depth=3))
284+
return "<Tree with {} nodes>\n{}".format(len(list(self.nodes)), self.get_hierarchy_string(max_depth=3))
285285

286286
@property
287287
def root(self):
@@ -437,9 +437,9 @@ def get_nodes_by_name(self, name):
437437
nodes.append(node)
438438
return nodes
439439

440-
def hierarchy(self, max_depth=None):
440+
def get_hierarchy_string(self, max_depth=None):
441441
"""
442-
Return string for the spatial hierarchy of the tree.
442+
Return string representation for the spatial hierarchy of the tree.
443443
444444
Parameters
445445
----------
@@ -450,7 +450,7 @@ def hierarchy(self, max_depth=None):
450450
Returns
451451
-------
452452
str
453-
The spatial hierarchy of the tree.
453+
String representing the spatial hierarchy of the tree.
454454
455455
"""
456456

0 commit comments

Comments
 (0)