Skip to content

Commit

Permalink
function name
Browse files Browse the repository at this point in the history
  • Loading branch information
Licini committed Apr 30, 2024
1 parent 997f2ce commit ded6987
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/compas/datastructures/tree/tree.py
Original file line number Diff line number Diff line change
Expand Up @@ -281,7 +281,7 @@ def __init__(self, name=None, **kwargs):
self._root = None

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

@property
def root(self):
Expand Down Expand Up @@ -437,9 +437,9 @@ def get_nodes_by_name(self, name):
nodes.append(node)
return nodes

def hierarchy(self, max_depth=None):
def get_hierarchy_string(self, max_depth=None):
"""
Return string for the spatial hierarchy of the tree.
Return string representation for the spatial hierarchy of the tree.
Parameters
----------
Expand All @@ -450,7 +450,7 @@ def hierarchy(self, max_depth=None):
Returns
-------
str
The spatial hierarchy of the tree.
String representing the spatial hierarchy of the tree.
"""

Expand Down

0 comments on commit ded6987

Please sign in to comment.