Package slash.navigation.gopal.binding3

Examples of slash.navigation.gopal.binding3.ObjectFactory


      String authToken = (String) session.getAttribute("token-" + clerk.getName());
      subscriptionService.saveSubscription(authToken, subscriptionHolder);
      subscription = subscriptionHolder.value.get(0);
      String expiresAfter = null;
      if (subscription.getExpiresAfter()!=null) expiresAfter = subscription.getExpiresAfter().toString();
      String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(subscription.getSubscriptionFilter()), "org.uddi.sub_v3");
      Subscription savedModelSubscription = new Subscription(
          (subscription.getBindingKey()==null)?"":subscription.getBindingKey(),
          subscription.isBrief(),
          expiresAfter,
          subscription.getMaxEntities(),
View Full Code Here


    } else {
      modelSubscription.setBrief(new Boolean(false));
    }
     
    try {
      String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(apiSubscription.getSubscriptionFilter()), "org.uddi.sub_v3");
      logger.debug("marshalled subscription filter:  " + rawFilter);
      modelSubscription.setSubscriptionFilter(rawFilter);

    } catch (JAXBException e) {
      logger.error("JAXBException while marshalling subscription filter", e);
View Full Code Here

    } else {
      modelSubscription.setBrief(new Boolean(false));
    }
     
   
    String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(apiSubscription.getSubscriptionFilter()), "org.uddi.sub_v3");
    logger.debug("marshalled subscription filter:  " + rawFilter);
    modelSubscription.setSubscriptionFilter(rawFilter);
   
  }
View Full Code Here

    } else {
      modelSubscription.setBrief(new Boolean(false));
    }
     
    try {
      String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(apiSubscription.getSubscriptionFilter()), "org.uddi.sub_v3");
      logger.debug("marshalled subscription filter:  " + rawFilter);
      modelSubscription.setSubscriptionFilter(rawFilter);

    } catch (JAXBException e) {
      logger.error("JAXBException while marshalling subscription filter", e);
View Full Code Here

                } else {
                        modelSubscription.setBrief(Boolean.FALSE);
                }


                String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(apiSubscription.getSubscriptionFilter()), "org.uddi.sub_v3");
                logger.debug("marshalled subscription filter:  " + rawFilter);
                modelSubscription.setSubscriptionFilter(rawFilter);

        }
View Full Code Here

    } else {
      modelSubscription.setBrief(new Boolean(false));
    }
     
   
    String rawFilter = JAXBMarshaller.marshallToString(new ObjectFactory().createSubscriptionFilter(apiSubscription.getSubscriptionFilter()), "org.uddi.sub_v3");
    logger.debug("marshalled subscription filter:  " + rawFilter);
    modelSubscription.setSubscriptionFilter(rawFilter);
   
  }
View Full Code Here

    }

    private Tour.Options createOptions(GoPalRoute route) {
        Tour.Options options = route.getOptions(Tour.Options.class);
        if (options == null) {
            options = new ObjectFactory().createTourOptions();
            options.setType((short) preferences.getInt(VERSION_PREFIX + "type", 3)); // Fahrzeugtyp: 0=PKW 1=Fussgaenger 2=Fahrrad 3=Motorrad
            options.setMode((short) preferences.getInt(VERSION_PREFIX + "mode", 2)); // Art der Route: 0=kurz 1=schnell 2=Oekonomisch
            options.setFerries((short) preferences.getInt(VERSION_PREFIX + "ferries", 1)); // Faehren: 0=meiden 1=verwenden
            options.setMotorWays((short) preferences.getInt(VERSION_PREFIX + "motorWays", 0)); // Autobahn: 0=meiden 1=verwenden
            options.setTollRoad((short) preferences.getInt(VERSION_PREFIX + "tollRoad", 1)); // Mautstrassen: 0=meiden 1=verwenden
View Full Code Here

        }
        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());
View Full Code Here

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

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

        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;
    }
View Full Code Here

TOP

Related Classes of slash.navigation.gopal.binding3.ObjectFactory

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.