Implementation of a interval tree