return options;
}
private Tour createGoPal(GoPalRoute route, int startIndex, int endIndex) {
ObjectFactory objectFactory = new ObjectFactory();
Tour tour = objectFactory.createTour();
tour.setOptions(createOptions(route));
for (int i = startIndex; i < endIndex; i++) {
GoPalPosition position = route.getPosition(i);
Tour.Dest dest = objectFactory.createTourDest();
if (position.getX() != null)
dest.setLongitude(position.getX());
if (position.getY() != null)
dest.setLatitude(position.getY());
dest.setCity(position.getCity());
if (position.getCountry() != null)
dest.setCountry(position.getCountry());
if (position.getHouseNumber() != null)
dest.setHouse(position.getHouseNumber());
dest.setStreet(position.getStreet());
dest.setZip(position.getZipCode());
if (i == startIndex)
dest.setStartPos((short) 1);
tour.getDest().add(dest);
}
return tour;
}