add new method getDistance