Tree structure management