public void index(Resource resource, IntrospectionContext context) throws InstallException { InputStream stream = null; try { Source source = resource.getSource(); stream = source.openStream(); // eagerly process the WSDL since port types need to be available during contribution processing. parse(resource, context); } catch (IOException e) { throw new InstallException(e); } finally { try { if (stream != null) { stream.close(); } } catch (IOException e) { e.printStackTrace(); } } }
InputStream stream = null; try { stream = resource.getSource().openStream(); XMLStreamReader reader = xmlFactory.createXMLStreamReader(stream); while (true) {
private void parse(Resource resource, IntrospectionContext context) throws InstallException { Source source = resource.getSource(); Definition definition = parseWsdl(source, context); QName wsdlQName = definition.getQName();