Generic Segment Tree with Lazy Propogation