set getter and setter for branch length