/** * Returns the length of this span according to subtree i, i.e. getFrom(i) - getTo(i). * * @param i the index of the subtree to use * @return the length of this span according to subtree i */ public int getLength(int i) { return getTo(i) - getFrom(i); }