Examples of WSDL2UDDI


Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

   
        @Test
        public void Nulltest1()
        {
            try {
                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, null, new Properties());
            } catch (ConfigurationException ex) {
                Logger.getLogger(WSDL2UDDITest.class.getName()).log(Level.SEVERE, null, ex);
            }
        }
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

        }
        @Test(expected = IllegalArgumentException.class)
        public void Nulltest2()
        {
            try {
                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), null);
            } catch (ConfigurationException ex) {
               
            }
           
        }
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

    Definition wsdlDefinition = rw.readWSDL("wsdl/HelloWorld.wsdl");
    String wsdlURL = wsdlDefinition.getDocumentBaseURI();
   
    Properties properties = new Properties();
    properties.put("keyDomain", "juddi.apache.org");
    WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
    Set<TModel> tModels = new HashSet<TModel>();
      @SuppressWarnings("unchecked")
    Map<QName,PortType> portTypes = (Map<QName,PortType>) wsdlDefinition.getAllPortTypes();
      Set<TModel> portTypeTModels = wsdl2UDDI.createWSDLPortTypeTModels(wsdlURL, portTypes);
      tModels.addAll(portTypeTModels);
     
    for (TModel tModel : tModels) {
      System.out.println("UDDI PortType TModel " + tModel.getName().getValue());
                        if (serialize)
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

    Definition wsdlDefinition = rw.readWSDL("wsdl/HelloWorld.wsdl");
    String wsdlURL = wsdlDefinition.getDocumentBaseURI();
   
    Properties properties = new Properties();
    properties.put("keyDomain", "juddi.apache.org");
    WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
    Set<TModel> tModels = new HashSet<TModel>();
      @SuppressWarnings("unchecked")
    Map<QName,Binding> bindings= (Map<QName,Binding>) wsdlDefinition.getAllBindings();
      Set<TModel> bindingTModels = wsdl2UDDI.createWSDLBindingTModels(wsdlURL, bindings);
      tModels.addAll(bindingTModels);
     
    for (TModel tModel : tModels) {
      System.out.println("UDDI Binding TModel " + tModel.getName().getValue());
                        if (serialize)
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

        }

        @Test
        public void test_3_2_1_UDDI_portType_tModel() throws WSDLException, IOException, JAXBException, ConfigurationException {

                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
                Set<TModel> tModels = new HashSet<TModel>();
                @SuppressWarnings("unchecked")
                Map<QName, PortType> portTypes = (Map<QName, PortType>) wsdlDefinition.getAllPortTypes();
                Set<TModel> portTypeTModels = wsdl2UDDI.createWSDLPortTypeTModels(wsdlURL, portTypes);
                tModels.addAll(portTypeTModels);

                Assert.assertEquals(1, tModels.size());

                TModel tModel = tModels.iterator().next();
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

        }

        @Test
        public void test_3_2_2_UDDI_binding_tModel() throws WSDLException, JAXBException, IOException, ConfigurationException {

                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
                @SuppressWarnings("unchecked")
                Map<QName, Binding> bindings = (Map<QName, Binding>) wsdlDefinition.getAllBindings();
                Set<TModel> tModels = wsdl2UDDI.createWSDLBindingTModels(wsdlURL, bindings);

                //Now check
                Assert.assertEquals(1, tModels.size());

                TModel tModel = tModels.iterator().next();
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

                }
        }

        @Test
        public void test_3_2_3_UDDI_businessService_and_bindingTemplate() throws JAXBException, IOException, ConfigurationException {
                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);

                BusinessServices businessServices = wsdl2UDDI.createBusinessServices(wsdlDefinition);
                PrintUDDI<BusinessService> servicePrinter = new PrintUDDI<BusinessService>();

                Assert.assertEquals(1, businessServices.getBusinessService().size());

                BusinessService businessService = businessServices.getBusinessService().get(0);
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

        }

        @Test
        public void test_3_2_3_UDDI_businessService_and_bindingTemplateLongDescriptions() throws JAXBException, IOException, ConfigurationException {
                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);

                BusinessServices businessServices = wsdl2UDDI.createBusinessServices(wsdlDefinitionLongDescriptions);
                PrintUDDI<BusinessService> servicePrinter = new PrintUDDI<BusinessService>();

                Assert.assertEquals(1, businessServices.getBusinessService().size());

                BusinessService businessService = businessServices.getBusinessService().get(0);
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

      Definition wsdlDefinition = new ReadWSDL().readWSDL("wsdl/sample.wsdl");
      //set required properties
      properties.put("keyDomain", "uddi.joepublisher.com");
      properties.put(org.apache.juddi.v3.client.config.Property.BUSINESS_KEY, "uddi:uddi.joepublisher.com:businessone");
      properties.put("nodeName", "api.example.org_80");
      WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(clerk, urlLocalizer, properties);
      //register all services in the wsdl
      wsdl2UDDI.registerBusinessServices(wsdlDefinition);
      //done
     
      String portTypeName = "StockQuotePortType";
      String namespace    = "http://example.com/stockquote/";
      FindTModel findTModelForPortType = WSDL2UDDI.createFindPortTypeTModelForPortType(portTypeName, namespace);
      System.out.println(new PrintUDDI<FindTModel>().print(findTModelForPortType));
     
      wsdl2UDDI.unRegisterBusinessServices(wsdlDefinition);
    } finally {
      tckBusiness.deleteJoePublisherBusiness(authInfoJoe);
      tckTModel.deleteJoePublisherTmodel(authInfoJoe);
    }
  }
View Full Code Here

Examples of org.apache.juddi.v3.client.mapping.wsdl.WSDL2UDDI

                properties.put("keyDomain", domain);
                properties.put("businessName", domain);
                properties.put("serverName", domain);
                properties.put("serverPort", port);
                wsdlURL = wsdlDefinition.getDocumentBaseURI();
                WSDL2UDDI wsdl2UDDI = new WSDL2UDDI(null, new URLLocalizerDefaultImpl(), properties);
                BusinessServices businessServices = wsdl2UDDI.createBusinessServices(wsdlDefinition);
                @SuppressWarnings("unchecked")
                Map<QName, PortType> portTypes = (Map<QName, PortType>) wsdlDefinition.getAllPortTypes();
                Set<TModel> portTypeTModels = wsdl2UDDI.createWSDLPortTypeTModels(wsdlURL, portTypes);
                Map allBindings = wsdlDefinition.getAllBindings();
                Set<TModel> createWSDLBindingTModels = wsdl2UDDI.createWSDLBindingTModels(wsdlURL, allBindings);
        //When parsing a WSDL, there's really two things going on
                //1) convert a bunch of stuff (the portTypes) to tModels
                //2) convert the service definition to a BusinessService

                //Since the service depends on the tModel, we have to save the tModels first
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.