/** * Get a WSDLReader. * * @return WSDLReader. * @throws WSDLException * on error. */ private WSDLReader getReader() throws WSDLException { WSDLFactory wsdlFactory = WSDLFactory.newInstance(); WSDLReader wsdlReader = wsdlFactory.newWSDLReader(); ExtensionRegistry registry = wsdlFactory.newPopulatedExtensionRegistry(); wsdlReader.setExtensionRegistry( registry ); wsdlReader.setFeature( "javax.wsdl.verbose", true ); wsdlReader.setFeature( "javax.wsdl.importDocuments", true ); return wsdlReader; }
WSDLReader wsdlReader = wsdlFactory.newWSDLReader(); WSDLWriter wsdlWriter = wsdlFactory.newWSDLWriter();
/** * Create a new instance of a WSDLReader. */ public WSDLReader newWSDLReader() { return factory.newWSDLReader(); }
public WSDLServiceConfigurator(Service service, URL url, TransportManager transportManager) throws WSDLException, IOException { this(service, WSDLFactory.newInstance().newWSDLReader().readWSDL(null, new InputSource(url.openStream())), transportManager); }
private Definition getDefinition() { try { return this.definition == null ? definition = newInstance().newWSDLReader().readWSDL(wsdl.toExternalForm()) : definition; } catch (WSDLException e) { throw new RuntimeException(e); } } }
public Definition getDefinition(File wsdlFile) throws Exception { WSDLFactory wsdlFactory = WSDLFactory.newInstance(); WSDLReader reader = wsdlFactory.newWSDLReader(); reader.setFeature("javax.wsdl.verbose", false); return reader.readWSDL(wsdlFile.toURI().toURL().toString()); } }
public Definition getDefinition(File wsdlFile) throws Exception { WSDLFactory wsdlFactory = WSDLFactory.newInstance(); WSDLReader reader = wsdlFactory.newWSDLReader(); reader.setFeature("javax.wsdl.verbose", false); return reader.readWSDL(wsdlFile.toURI().toURL().toString()); } }
public Definition getDefinition(File wsdlFile) throws Exception { WSDLFactory wsdlFactory = WSDLFactory.newInstance(); WSDLReader reader = wsdlFactory.newWSDLReader(); reader.setFeature("javax.wsdl.verbose", false); return reader.readWSDL(wsdlFile.toURI().toURL().toString()); } }
protected Definition loadDefinition() throws IOException, WSDLException { if (wsdlResource != null) { URL resource = wsdlResource.getURL(); WSDLReader reader = WSDLFactory.newInstance().newWSDLReader(); reader.setFeature(Constants.FEATURE_VERBOSE, false); return reader.readWSDL(null, resource.toString()); } return null; }
public WSDLServiceBuilder(String baseURI, InputSource source) throws WSDLException { this(WSDLFactory.newInstance().newWSDLReader().readWSDL(baseURI, source)); this.definition.setDocumentBaseURI(baseURI); this.systemId = source.getSystemId(); }
/** * Gets the Definition contained in the WSDL document (does not currently support reading * WSDL that is protected with authentication). * @return Definition describing the service(s) * @throws Exception if the definition could not be read */ protected Definition getWSDLDefinition() throws Exception { return WSDLFactory.newInstance().newWSDLReader().readWSDL(getWsdlDocumentUrl()); }
protected Definition getDefinitionFromDescription() { if (description != null) { try { WSDLReader reader = WSDLFactory.newInstance().newWSDLReader(); reader.setFeature(Constants.FEATURE_VERBOSE, false); return reader.readWSDL(null, description); } catch (WSDLException ignore) { // Ignore } } return null; }
/** * Populate the description with the provided WSDL * * @throws DeploymentException if the provided WSDL can't be read */ protected void useProvidedWsdl() throws Exception { description = DomUtil.parse(wsdl.getInputStream()); javax.wsdl.xml.WSDLReader reader = javax.wsdl.factory.WSDLFactory.newInstance().newWSDLReader(); reader.setFeature("javax.wsdl.verbose", false); definition = reader.readWSDL(new SpringWSDLLocator(wsdl)); }
public Definition cloneDefinition(WSDLFactory factory, Definition definition) throws WSDLException { Element root = definition.getDocumentationElement(); root = (Element)root.cloneNode(true); WSDLReader reader = factory.newWSDLReader(); return reader.readWSDL(definition.getDocumentBaseURI(), root); }
private static Definition loadDefinition(String name) throws Exception { WSDLFactory factory = WSDLFactory.newInstance(); WSDLReader reader = factory.newWSDLReader(); reader.setFeature("javax.wsdl.importDocuments", false); reader.setFeature("javax.wsdl.verbose", false); Definition definition = reader.readWSDL(name); return definition; }
public Definition cloneDefinition(WSDLFactory factory, Definition definition) throws WSDLException { Element root = definition.getDocumentationElement(); root = (Element)root.cloneNode(true); WSDLReader reader = factory.newWSDLReader(); return reader.readWSDL(definition.getDocumentBaseURI(), root); }
@Init public void start() throws WSDLException { WSDLFactory factory = WSDLFactory.newInstance(); reader = factory.newWSDLReader(); ExtensionRegistry extensionRegistry = factory.newPopulatedExtensionRegistry(); for (Class<? extends ExtensibilityElement> type : extensionHandlers.keySet()) { ExtensionHandler<?> extensionHandler = extensionHandlers.get(type); extensionRegistry.registerSerializer(Definition.class, extensionHandler.getQualifiedName(), extensionHandler); extensionRegistry.registerDeserializer(Definition.class, extensionHandler.getQualifiedName(), extensionHandler); } reader.setExtensionRegistry(extensionRegistry); }
protected WSDLReader createWsdlReader() throws WSDLException { WSDLFactory factory = WSDLFactory.newInstance(); ExtensionRegistry registry = factory.newPopulatedExtensionRegistry(); registerExtensions(registry); WSDLReader reader = factory.newWSDLReader(); reader.setFeature("javax.wsdl.verbose", false); reader.setExtensionRegistry(registry); return reader; }
private static void loadWsdl(String wsdlUrl, Map<String, Element> schemaMap, List<JibxSchemaResolver> resolvers) throws WSDLException { WSDLFactory factory = WSDLFactory.newInstance(); WSDLReader reader = factory.newWSDLReader(); Definition parentDef = reader.readWSDL(wsdlUrl); JibxSchemaHelper util = new JibxSchemaHelper(BusFactory.getDefaultBus(), schemaMap); util.getSchemas(parentDef, new SchemaCollection(), resolvers); }
@Test public void testWSDLLocatorWithDefaultCatalog() throws Exception { URL wsdl = getClass().getResource("/wsdl/catalog/hello_world_services.wsdl"); assertNotNull(wsdl); WSDLFactory wsdlFactory = WSDLFactory.newInstance(); WSDLReader wsdlReader = wsdlFactory.newWSDLReader(); CatalogWSDLLocator wsdlLocator = new CatalogWSDLLocator(wsdl.toString(), OASISCatalogManager.getCatalogManager(null)); wsdlReader.setFeature("javax.wsdl.verbose", false); wsdlReader.readWSDL(wsdlLocator); }