private boolean findDestinationAndTrack(Car car,RouteLocation rl,RouteLocation rld) throws BuildFailedException {
  int index;
  for (index=0; index < _routeList.size(); index++) {
    if (rld == _routeList.get(index)) {
      break;
    }
  }
  if (_routeList.size() == 1) {
    return findDestinationAndTrack(car,rl,index,index + 1);
  }
  return findDestinationAndTrack(car,rl,index - 1,index + 1);
}

private boolean findDestinationAndTrack ( Car car , RouteLocation rl , RouteLocation rld ) throws BuildFailedException { int index ; for ( index = 0 ; index < _routeList . size ( ) ; index ++ ) { if ( rld == _routeList . get ( index ) ) { break ; } } if ( _routeList . size ( ) == 1 ) { return findDestinationAndTrack ( car , rl , index , index + 1 ) ; } return findDestinationAndTrack ( car , rl , index - 1 , index + 1 ) ; }
find a destination for the car at a specified location .
