Package slash.navigation.gopal.binding5

Examples of slash.navigation.gopal.binding5.TravelSpeeds$Vehicle$PedestrianArea


        }
        return (short)49;
    }

    private Tour.Start createStart(GoPalPosition position) {
        ObjectFactory objectFactory = new ObjectFactory();
        Tour.Start start = objectFactory.createTourStart();
        Tour.Start.Coordinates coordinates = objectFactory.createTourStartCoordinates();
        if (position.getX() != null)
            coordinates.setMercatorx(position.getX());
        if (position.getY() != null)
            coordinates.setMercatory(position.getY());
        if (position.getLongitude() != null)
            coordinates.setLongitude(formatPosition(position.getLongitude()));
        if (position.getLatitude() != null)
            coordinates.setLatitude(formatPosition(position.getLatitude()));
        start.setCoordinates(coordinates);

        Tour.Start.City city = objectFactory.createTourStartCity();
        city.setName(position.getCity());
        city.setSuburb(position.getSuburb());
        start.setCity(city);
        Tour.Start.Country country = objectFactory.createTourStartCountry();
        country.setCode(formatCountry(position));
        start.setCountry(country);
        Tour.Start.State state = objectFactory.createTourStartState();
        if (position.getState() != null)
            state.setName(position.getState());
        start.setState(state);
        Tour.Start.HouseNumber houseNumber = objectFactory.createTourStartHouseNumber();
        if (position.getHouseNumber() != null) {
            houseNumber.setValue(position.getHouseNumber());
            houseNumber.setType("middle_of_street");
        }
        start.setHouseNumber(houseNumber);
        Tour.Start.Street street = objectFactory.createTourStartStreet();
        street.setName(position.getStreet());
        if (position.getHouseNumber() != null)
            street.setHouseNumberAvailable("no");
        start.setStreet(street);
        Tour.Start.SideStreet sideStreet = objectFactory.createTourStartSideStreet();
        sideStreet.setName(position.getSideStreet());
        start.setSideStreet(sideStreet);
        Tour.Start.Zip zip = objectFactory.createTourStartZip();
        zip.setCode(position.getZipCode());
        start.setZip(zip);
        return start;
    }
View Full Code Here


        start.setZip(zip);
        return start;
    }

    private Tour.Destination createDestination(GoPalPosition position) {
        ObjectFactory objectFactory = new ObjectFactory();
        Tour.Destination destination = objectFactory.createTourDestination();
        Tour.Destination.Coordinates coordinates = objectFactory.createTourDestinationCoordinates();
        if (position.getX() != null)
            coordinates.setMercatorx(position.getX());
        if (position.getY() != null)
            coordinates.setMercatory(position.getY());
        if (position.getLongitude() != null)
            coordinates.setLongitude(formatPosition(position.getLongitude()));
        if (position.getLatitude() != null)
            coordinates.setLatitude(formatPosition(position.getLatitude()));
        destination.setCoordinates(coordinates);

        Tour.Destination.City city = objectFactory.createTourDestinationCity();
        city.setName(position.getCity());
        city.setSuburb(position.getSuburb());
        destination.setCity(city);
        Tour.Destination.Country country = objectFactory.createTourDestinationCountry();
        country.setCode(formatCountry(position));
        destination.setCountry(country);
        Tour.Destination.State state = objectFactory.createTourDestinationState();
        if (position.getState() != null)
            state.setName(position.getState());
        destination.setState(state);
        Tour.Destination.HouseNumber houseNumber = objectFactory.createTourDestinationHouseNumber();
        if (position.getHouseNumber() != null) {
            houseNumber.setValue(position.getHouseNumber());
            houseNumber.setType("middle_of_street");
        }
        destination.setHouseNumber(houseNumber);
        Tour.Destination.Street street = objectFactory.createTourDestinationStreet();
        street.setName(position.getStreet());
        if (position.getHouseNumber() != null)
            street.setHouseNumberAvailable("no");
        destination.setStreet(street);
        Tour.Destination.SideStreet sideStreet = objectFactory.createTourDestinationSideStreet();
        sideStreet.setName(position.getSideStreet());
        destination.setSideStreet(sideStreet);
        Tour.Destination.Zip zip = objectFactory.createTourDestinationZip();
        zip.setCode(position.getZipCode());
        destination.setZip(zip);
        return destination;
    }
View Full Code Here

        destination.setZip(zip);
        return destination;
    }

    private Tour createGoPal(GoPalRoute route, int startIndex, int endIndex) {
        ObjectFactory objectFactory = new ObjectFactory();
        Tour tour = objectFactory.createTour();
        tour.setRouteOptions(createRouteOptions(route));

        for (int i = startIndex; i < endIndex; i++) {
            GoPalPosition position = route.getPosition(i);
View Full Code Here

        }
        return new GoPalRoute(this, null, tour.getRouteOptions(), positions);
    }

    public void read(InputStream source, CompactCalendar startDate, ParserContext<GoPalRoute> context) throws Exception {
        Tour tour = unmarshal5(source);
        context.appendRoute(process(tour));
    }
View Full Code Here

        return destination;
    }

    private Tour createGoPal(GoPalRoute route, int startIndex, int endIndex) {
        ObjectFactory objectFactory = new ObjectFactory();
        Tour tour = objectFactory.createTour();
        tour.setRouteOptions(createRouteOptions(route));

        for (int i = startIndex; i < endIndex; i++) {
            GoPalPosition position = route.getPosition(i);

            if (i == startIndex) {
                tour.setStart(createStart(position));
            } else {
                tour.getDestination().add(createDestination(position));
            }
        }
        return tour;
    }
View Full Code Here

        }
        return new GoPalRoute(this, null, tour.getRouteOptions(), positions);
    }

    public void read(InputStream source, CompactCalendar startDate, ParserContext<GoPalRoute> context) throws Exception {
        Tour tour = unmarshal5(source);
        GoPalRoute process = process(tour);
        if (process != null)
            context.appendRoute(process);
    }
View Full Code Here

        return destination;
    }

    private Tour createGoPal(GoPalRoute route, int startIndex, int endIndex) {
        ObjectFactory objectFactory = new ObjectFactory();
        Tour tour = objectFactory.createTour();
        tour.setRouteOptions(createRouteOptions(route));

        for (int i = startIndex; i < endIndex; i++) {
            GoPalPosition position = route.getPosition(i);

            if (i == startIndex) {
                tour.setStart(createStart(position));
            } else {
                tour.getDestination().add(createDestination(position));
            }
        }
        return tour;
    }
View Full Code Here

TOP

Related Classes of slash.navigation.gopal.binding5.TravelSpeeds$Vehicle$PedestrianArea

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.