Adapted to run in eclipse luna.