Package javax.wsdl.factory

Examples of javax.wsdl.factory.WSDLFactory.newDefinition()


    }

    public Definition createWSDLDefinition(String tns) throws WSDLException, JAXBException {
        WSDLManager wm = BusFactory.getThreadDefaultBus().getExtension(WSDLManager.class);
        WSDLFactory wsdlFactory = wm.getWSDLFactory();
        Definition wsdlDefinition = wsdlFactory.newDefinition();
        wsdlDefinition.setExtensionRegistry(wm.getExtensionRegistry());
        wsdlDefinition.setTargetNamespace(tns);
        wsdlDefinition.addNamespace("wsdl", "http://schemas.xmlsoap.org/wsdl/");
        wsdlDefinition.addNamespace(WSDLConstants.NP_SCHEMA_XSD, WSDLConstants.NS_SCHEMA_XSD);
        wsdlDefinition.addNamespace(WSDLConstants.SOAP11_PREFIX, WSDLConstants.NS_SOAP11);
View Full Code Here


    private OperationInfo buildOperationInfoForMockOperation(AxisBuilder builder) throws NoSuchMethodException, DeploymentException, WSDLException {
        Class portClass = MockPort.class;
        Method method = portClass.getDeclaredMethod("doMockOperation", new Class[]{String.class});
        WSDLFactory factory = WSDLFactory.newInstance();
        Definition definition = factory.newDefinition();
        ExtensionRegistry extensionRegistry = factory.newPopulatedExtensionRegistry();
        BindingOperation bindingOperation = buildBindingOperation(definition, extensionRegistry);

        Style defaultStyle = Style.DOCUMENT;
View Full Code Here

        return operationInfo;
    }

    private Definition buildDefinition() throws WSDLException {
        WSDLFactory factory = WSDLFactory.newInstance();
        Definition definition = factory.newDefinition();
        definition.setDocumentBaseURI("META-INF/wsdl/fake.wsdl");
        ExtensionRegistry extensionRegistry = factory.newPopulatedExtensionRegistry();
        BindingOperation bindingOperation = buildBindingOperation(definition, extensionRegistry);
        Binding binding = definition.createBinding();
        binding.setQName(new QName(NAMESPACE, "MockPortBinding"));
View Full Code Here

    public Definition generateWSDL(boolean useSOAP12) throws WSDLException {
        WSDLFactory factory = WSDLFactory.newInstance();
        ExtensionRegistry registry = factory.newPopulatedExtensionRegistry();

        Definition def = factory.newDefinition();
        if (useSOAP12) {
            def.addNamespace(SOAP_12_NAMESPACE_PREFIX, SOAP_12_NAMESPACE_URI);
        }
        else {
            def.addNamespace(SOAP_11_NAMESPACE_PREFIX, SOAP_11_NAMESPACE_URI);
View Full Code Here

            StringToStringMap parts = wsdlCache.get(mockedInterfaces[0].getName());
            printOkXmlResult(response, parts.get(parts.get("#root#")));
        } else {
            try {
                WSDLFactory wsdlFactory = WSDLFactory.newInstance();
                Definition def = wsdlFactory.newDefinition();
                for (WsdlInterface iface : mockedInterfaces) {
                    StringToStringMap parts = wsdlCache.get(iface.getName());
                    Import wsdlImport = def.createImport();
                    wsdlImport.setLocationURI(getInterfacePrefix(iface) + "&part=" + parts.get("#root#"));
                    wsdlImport.setNamespaceURI(WsdlUtils.getTargetNamespace(iface.getWsdlContext().getDefinition()));
View Full Code Here

      throws WSDLException
  {
    checkElementName(defEl, Constants.Q_ELEM_DEFINITIONS);

    WSDLFactory factory = getWSDLFactory();
    Definition def = factory.newDefinition();

    if (extReg != null)
    {
      def.setExtensionRegistry(extReg);
    }
View Full Code Here

                            : ", relative to '" + contextURI + "'."));
                  }

                  WSDLFactory factory = getWSDLFactory();

                  importedDef = factory.newDefinition();

                  if (extReg != null)
                  {
                    importedDef.setExtensionRegistry(extReg);
                  }
View Full Code Here

              //parameter only to get its documentBaseURI. If the unmarshall method
              //implementation changes (ie: its use of definition changes) we may need
              //to rethink this approach.

              WSDLFactory factory = getWSDLFactory();
              Definition dummyDef = factory.newDefinition();

              dummyDef.setDocumentBaseURI(location);

              //By this point, we know we have a SchemaDeserializer registered
              //so we can safely cast the ExtensibilityElement to a Schema.
View Full Code Here

/*      */     throws WSDLException
/*      */   {
/*  260 */     checkElementName(defEl, Constants.Q_ELEM_DEFINITIONS);
/*      */
/*  262 */     WSDLFactory factory = getWSDLFactory();
/*  263 */     Definition def = factory.newDefinition();
/*      */
/*  265 */     if (this.extReg != null)
/*      */     {
/*  267 */       def.setExtensionRegistry(this.extReg);
/*      */     }
View Full Code Here

/*  494 */                     System.out.println("Retrieving schema wsdl:imported from '" + locationURI + "'" + (contextURI == null ? "." : new StringBuilder().append(", relative to '").append(contextURI).append("'.").toString()));
/*      */                   }
/*      */
/*  501 */                   WSDLFactory factory = getWSDLFactory();
/*      */
/*  503 */                   importedDef = factory.newDefinition();
/*      */
/*  505 */                   if (this.extReg != null)
/*      */                   {
/*  507 */                     importedDef.setExtensionRegistry(this.extReg);
/*      */                   }
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.