Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'bundles/org.eclipse.wst.ws.parser')
-rw-r--r--bundles/org.eclipse.wst.ws.parser/.classpath7
-rw-r--r--bundles/org.eclipse.wst.ws.parser/.cvsignore7
-rw-r--r--bundles/org.eclipse.wst.ws.parser/.project28
-rw-r--r--bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.jdt.core.prefs57
-rw-r--r--bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.pde.prefs12
-rw-r--r--bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF21
-rw-r--r--bundles/org.eclipse.wst.ws.parser/about.html22
-rw-r--r--bundles/org.eclipse.wst.ws.parser/build.properties6
-rw-r--r--bundles/org.eclipse.wst.ws.parser/plugin.properties16
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOContractReference.java28
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOParser.java123
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOReference.java27
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/NetUtils.java93
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/WebServicesParserExt.java32
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesConstants.java22
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesLink.java34
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesRegistryTypeAbstract.java429
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesService.java34
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIBusiness.java49
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIRegistry.java88
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIService.java51
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIServiceInterface.java51
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSDL.java38
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSIL.java39
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesRegistryType.java36
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIBusiness.java23
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIRegistry.java25
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIService.java23
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIServiceInterface.java23
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSDL.java21
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSIL.java21
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/plugin/ParserPlugin.java111
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/HTMLHeadHandler.java171
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/IllegalArgumentsException.java22
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/UDDIURIHelper.java63
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WSILMessages.java22
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationException.java46
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationHandler.java19
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServiceEntity.java148
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServicesParser.java547
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/wsil.properties22
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/PluginMessages.java18
-rw-r--r--bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/plugin.properties18
43 files changed, 0 insertions, 2693 deletions
diff --git a/bundles/org.eclipse.wst.ws.parser/.classpath b/bundles/org.eclipse.wst.ws.parser/.classpath
deleted file mode 100644
index 751c8f2e5..000000000
--- a/bundles/org.eclipse.wst.ws.parser/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="src" path="src"/>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/bundles/org.eclipse.wst.ws.parser/.cvsignore b/bundles/org.eclipse.wst.ws.parser/.cvsignore
deleted file mode 100644
index 6e021a124..000000000
--- a/bundles/org.eclipse.wst.ws.parser/.cvsignore
+++ /dev/null
@@ -1,7 +0,0 @@
-bin
-.cdtproject
-build.xml
-temp.folder
-parser.jar
-@dot
-src.zip
diff --git a/bundles/org.eclipse.wst.ws.parser/.project b/bundles/org.eclipse.wst.ws.parser/.project
deleted file mode 100644
index feb66400b..000000000
--- a/bundles/org.eclipse.wst.ws.parser/.project
+++ /dev/null
@@ -1,28 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.wst.ws.parser</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- </natures>
-</projectDescription>
diff --git a/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index de2122bdc..000000000
--- a/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,57 +0,0 @@
-#Mon Jan 30 10:38:08 EST 2006
-eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=disabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.2
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.4
-org.eclipse.jdt.core.compiler.debug.lineNumber=generate
-org.eclipse.jdt.core.compiler.debug.localVariable=generate
-org.eclipse.jdt.core.compiler.debug.sourceFile=generate
-org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning
-org.eclipse.jdt.core.compiler.problem.assertIdentifier=warning
-org.eclipse.jdt.core.compiler.problem.autoboxing=ignore
-org.eclipse.jdt.core.compiler.problem.deprecation=ignore
-org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
-org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
-org.eclipse.jdt.core.compiler.problem.discouragedReference=ignore
-org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore
-org.eclipse.jdt.core.compiler.problem.enumIdentifier=warning
-org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
-org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning
-org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
-org.eclipse.jdt.core.compiler.problem.forbiddenReference=error
-org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
-org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
-org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
-org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
-org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
-org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
-org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
-org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
-org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning
-org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
-org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
-org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
-org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning
-org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore
-org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=ignore
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.unusedImport=warning
-org.eclipse.jdt.core.compiler.problem.unusedLocal=warning
-org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled
-org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled
-org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.3
diff --git a/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.pde.prefs b/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 25b0b69eb..000000000
--- a/bundles/org.eclipse.wst.ws.parser/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,12 +0,0 @@
-#Mon Jan 30 10:39:59 EST 2006
-compilers.p.deprecated=1
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=1
-compilers.p.unknown-attribute=0
-compilers.p.unknown-class=0
-compilers.p.unknown-element=1
-compilers.p.unknown-resource=0
-compilers.p.unresolved-ex-points=0
-compilers.p.unresolved-import=0
-compilers.use-project=true
-eclipse.preferences.version=1
diff --git a/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF
deleted file mode 100644
index 8b3fd2a38..000000000
--- a/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,21 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: %PLUGIN_NAME
-Bundle-SymbolicName: org.eclipse.wst.ws.parser
-Bundle-Version: 1.0.100.qualifier
-Bundle-Activator: org.eclipse.wst.ws.internal.parser.plugin.ParserPlugin
-Bundle-Vendor: %PLUGIN_PROVIDER
-Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.ws.internal.parser.disco;x-internal:=true,
- org.eclipse.wst.ws.internal.parser.discovery;x-internal:=true,
- org.eclipse.wst.ws.internal.parser.favorites;x-internal:=true,
- org.eclipse.wst.ws.internal.parser.plugin;x-internal:=true,
- org.eclipse.wst.ws.internal.parser.wsil;x-internal:=true,
- org.eclipse.wst.ws.parser
-Require-Bundle: org.eclipse.wst.wsdl,
- org.wsdl4j,
- org.eclipse.core.runtime,
- org.apache.wsil4j,
- org.uddi4j,
- org.eclipse.wst.command.env.core
-Eclipse-LazyStart: true
diff --git a/bundles/org.eclipse.wst.ws.parser/about.html b/bundles/org.eclipse.wst.ws.parser/about.html
deleted file mode 100644
index 6f6b96c4c..000000000
--- a/bundles/org.eclipse.wst.ws.parser/about.html
+++ /dev/null
@@ -1,22 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
-<head>
-<title>About</title>
-<meta http-equiv=Content-Type content="text/html; charset=ISO-8859-1">
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>February 24, 2005</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/build.properties b/bundles/org.eclipse.wst.ws.parser/build.properties
deleted file mode 100644
index 94cf66ef7..000000000
--- a/bundles/org.eclipse.wst.ws.parser/build.properties
+++ /dev/null
@@ -1,6 +0,0 @@
-bin.includes = .,\
- META-INF/,\
- plugin.properties,\
- about.html
-source.. = src/
-output.. = bin/
diff --git a/bundles/org.eclipse.wst.ws.parser/plugin.properties b/bundles/org.eclipse.wst.ws.parser/plugin.properties
deleted file mode 100644
index 395ac6e50..000000000
--- a/bundles/org.eclipse.wst.ws.parser/plugin.properties
+++ /dev/null
@@ -1,16 +0,0 @@
-###############################################################################
-# Copyright (c) 2001,2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-
-#
-# Messages in plugin.xml.
-#
-PLUGIN_NAME=Web Services Description Parser
-PLUGIN_PROVIDER=Eclipse.org
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOContractReference.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOContractReference.java
deleted file mode 100644
index a96dad292..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOContractReference.java
+++ /dev/null
@@ -1,28 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.disco;
-
-public class DISCOContractReference extends DISCOReference
-{
- private String docRef_;
-
- public DISCOContractReference(String ref,String docRef)
- {
- super(ref);
- docRef_ = docRef;
- }
-
- public String getDocRef()
- {
- return docRef_;
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOParser.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOParser.java
deleted file mode 100644
index 620944923..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOParser.java
+++ /dev/null
@@ -1,123 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.disco;
-
-import java.util.Vector;
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.w3c.dom.Node;
-import org.w3c.dom.NodeList;
-import org.xml.sax.InputSource;
-
-/**
- * See http://msdn.microsoft.com/msdnmag/issues/02/02/xml/default.aspx for more
- * details on DISCO.
- */
-public class DISCOParser
-{
- private DocumentBuilder parser_;
- private final String NS_DISCO = "http://schemas.xmlsoap.org/disco/";
- private final String DISCOVERY = "discovery";
- private final String DISCOVERY_REF = "discoveryRef";
- private final String NS_CONTRACT_REF = "http://schemas.xmlsoap.org/disco/scl/";
- private final String CONTRACT_REF = "contractRef";
- private final String REF = "ref";
- private final String DOC_REF = "docRef";
-
- public DISCOParser()
- {
- try
- {
- DocumentBuilderFactory docBuilderFactory = DocumentBuilderFactory.newInstance();
- docBuilderFactory.setNamespaceAware(true);
- parser_ = docBuilderFactory.newDocumentBuilder();
- }
- catch (ParserConfigurationException pce)
- {
- parser_ = null;
- }
- }
-
- public DISCOReference[] parse(String discoURI, InputSource source) throws Exception
- {
- if (parser_ != null)
- {
- Document doc = parser_.parse(source);
- Element rootElement = doc.getDocumentElement();
- // Root element must by <disco:discovery
- // xmlns:disco="http://schemas.xmlsoap.org/disco/">
- if (rootElement != null && rootElement.getNamespaceURI().equals(NS_DISCO) && rootElement.getLocalName().equals(DISCOVERY))
- {
- NodeList childNodes = rootElement.getChildNodes();
- Vector discoReferences = new Vector();
- for (int i = 0; i < childNodes.getLength(); i++)
- {
- Node childNode = childNodes.item(i);
- if (childNode instanceof Element)
- {
- Element element = (Element)childNode;
- String localName = element.getLocalName();
- String nsURI = element.getNamespaceURI();
- if (nsURI.equals(NS_DISCO) && localName.equals(DISCOVERY_REF))
- {
- // DISCO link.
- String ref = convertToAbsoluteURI(discoURI, element.getAttribute(REF));
- discoReferences.addElement(new DISCOReference(ref));
- }
- else if (nsURI.equals(NS_CONTRACT_REF) && localName.equals(CONTRACT_REF))
- {
- // WSDL link.
- String ref = convertToAbsoluteURI(discoURI, element.getAttribute(REF));
- String docRef = convertToAbsoluteURI(discoURI, element.getAttribute(DOC_REF));
- discoReferences.addElement(new DISCOContractReference(ref, docRef));
- }
- }
- }
- int numberOfDISCOReferences = discoReferences.size();
- if (numberOfDISCOReferences > 0)
- {
- DISCOReference[] references = new DISCOReference[numberOfDISCOReferences];
- discoReferences.copyInto(references);
- return references;
- }
- }
- else
- {
- // The document is not a valid DISCO document.
- throw new Exception();
- }
- }
- return null;
- }
-
- private String convertToAbsoluteURI(String discoURI, String refURI)
- {
- if (refURI != null)
- {
- if (refURI.indexOf("://") > -1)
- {
- // refURI is already absolute.
- return refURI;
- }
- else
- {
- StringBuffer absoluteURI = new StringBuffer(discoURI.substring(0, Math.max(discoURI.lastIndexOf('\\'), discoURI.lastIndexOf('/') + 1)));
- absoluteURI.append(refURI);
- return absoluteURI.toString();
- }
- }
- return null;
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOReference.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOReference.java
deleted file mode 100644
index dd2175edb..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/disco/DISCOReference.java
+++ /dev/null
@@ -1,27 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.disco;
-
-public class DISCOReference
-{
- private String ref_;
-
- public DISCOReference(String ref)
- {
- ref_ = ref;
- }
-
- public String getRef()
- {
- return ref_;
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/NetUtils.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/NetUtils.java
deleted file mode 100644
index 527a489b1..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/NetUtils.java
+++ /dev/null
@@ -1,93 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.discovery;
-
-import java.io.IOException;
-import java.io.InputStream;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLConnection;
-
-import sun.misc.BASE64Encoder;
-
-public final class NetUtils
-{
-
- /**
- * Get the java.net.URLConnection given a string representing the URL. This class ensures
- * that proxy settings in WSAD are respected.
- * @param urlString String representing the URL.
- * @return java.net.URLCDonnection URLConnection to the URL.
- */
- public static final URLConnection getURLConnection(String urlString)
- {
- try
- {
- URL url = createURL(urlString);
- URLConnection uc = url.openConnection();
- String proxyUserName = System.getProperty("http.proxyUserName");
- String proxyPassword = System.getProperty("http.proxyPassword");
- if (proxyUserName != null && proxyPassword != null)
- {
- StringBuffer userNamePassword = new StringBuffer(proxyUserName);
- userNamePassword.append(':').append(proxyPassword);
- BASE64Encoder encoder = new BASE64Encoder();
- String encoding = encoder.encode(userNamePassword.toString().getBytes());
- userNamePassword.setLength(0);
- userNamePassword.append("Basic ").append(encoding);
- uc.setRequestProperty("Proxy-authorization",userNamePassword.toString());
- }
- return uc;
- }
- catch (MalformedURLException e)
- {
- }
- catch (IOException e)
- {
- }
- return null;
- }
-
- /**
- * Get the java.io.InputStream for a URL given a string representing the URL. This class
- * ensures that proxy settings in WSAD are respected.
- * @param urlString String representing the URL.
- * @return java.io.InputStream InputStream for reading the URL stream.
- */
- public static final InputStream getURLInputStream(String urlString)
- {
- try
- {
- URLConnection uc = getURLConnection(urlString);
- if (uc != null)
- {
- InputStream is = uc.getInputStream();
- return is;
- }
- }
- catch (IOException e)
- {
- }
- return null;
- }
-
- /**
- * Create a URL from a string.
- * @param urlString String representing the URL.
- * @return URL java.lang.URL representation of the URL.
- * @throws MalformedURLException
- */
- public static final URL createURL(String urlString) throws MalformedURLException
- {
- return new URL(urlString);
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/WebServicesParserExt.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/WebServicesParserExt.java
deleted file mode 100644
index 4e907538f..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/discovery/WebServicesParserExt.java
+++ /dev/null
@@ -1,32 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.discovery;
-
-import java.net.MalformedURLException;
-import java.net.URL;
-
-import org.eclipse.wst.ws.internal.parser.wsil.WebServicesParser;
-
-public class WebServicesParserExt extends WebServicesParser {
-
- public WebServicesParserExt() {
- super();
- }
-
- public WebServicesParserExt(String uri) {
- super(uri);
- }
-
- protected URL createURL(String url) throws MalformedURLException {
- return NetUtils.createURL(url);
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesConstants.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesConstants.java
deleted file mode 100644
index 5b2e956e7..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesConstants.java
+++ /dev/null
@@ -1,22 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public class FavoritesConstants
-{
- // Namespace
- public static final String NAMESPACE_WSDL = "http://schemas.xmlsoap.org/wsdl/";
- public static final String NAMESPACE_UDDI_V1 = "urn:uddi-org:api";
- public static final String NAMESPACE_UDDI_V2 = "urn:uddi-org:api_v2";
- public static final String NAMESPACE_UDDI_BINDING = "http://schemas.xmlsoap.org/ws/2001/10/inspection/uddi/";
- public static final String NAMESPACE_WSIL_INSPECTION = "http://schemas.xmlsoap.org/ws/2001/10/inspection/";
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesLink.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesLink.java
deleted file mode 100644
index c8c912955..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesLink.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.Link;
-
-public class FavoritesLink
-{
- protected Link link_;
-
- public FavoritesLink()
- {
- link_ = null;
- }
-
- public Link getLink()
- {
- return link_;
- }
-
- public void setLink(Link link)
- {
- link_ = link;
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesRegistryTypeAbstract.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesRegistryTypeAbstract.java
deleted file mode 100644
index d167fbea6..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesRegistryTypeAbstract.java
+++ /dev/null
@@ -1,429 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import java.io.File;
-import java.io.FileReader;
-import java.io.IOException;
-import java.util.Vector;
-
-import org.apache.wsil.Abstract;
-import org.apache.wsil.Description;
-import org.apache.wsil.Inspection;
-import org.apache.wsil.Link;
-import org.apache.wsil.Service;
-import org.apache.wsil.ServiceName;
-import org.apache.wsil.WSILDocument;
-import org.apache.wsil.WSILException;
-import org.apache.wsil.extension.uddi.BusinessDescription;
-import org.apache.wsil.extension.uddi.ServiceDescription;
-import org.apache.wsil.impl.AbstractImpl;
-import org.apache.wsil.impl.DescriptionImpl;
-import org.apache.wsil.impl.LinkImpl;
-import org.apache.wsil.impl.ServiceImpl;
-import org.apache.wsil.impl.ServiceNameImpl;
-import org.apache.wsil.impl.extension.uddi.BusinessDescriptionImpl;
-import org.apache.wsil.impl.extension.uddi.ServiceDescriptionImpl;
-import org.uddi4j.util.BusinessKey;
-import org.uddi4j.util.ServiceKey;
-
-public abstract class FavoritesRegistryTypeAbstract implements IFavoritesRegistryType
-{
- public FavoritesRegistryTypeAbstract()
- {
- }
-
- public abstract String getReadLocation();
- public abstract String getWriteLocation();
- protected abstract WSILDocument getWSILDocument();
-
- public void init()
- {
- getWSILDocument();
- }
-
- protected WSILDocument loadWSILDocument(String path, boolean force)
- {
- try
- {
- WSILDocument wsilDoc = WSILDocument.newInstance();
- wsilDoc.read(new FileReader(new File(path)));
- return wsilDoc;
- }
- catch (Throwable t)
- {
- if (force)
- {
- try
- {
- return WSILDocument.newInstance();
- }
- catch (Throwable t2)
- {
- return null;
- }
- }
- else
- return null;
- }
- }
-
- public String getFavoritesVersion()
- {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Abstract[] abstracts = inspection.getAbstracts();
- if (abstracts.length > 0)
- return abstracts[0].getText();
- else
- return null;
- }
-
- public void setFavoritesVersion(String version)
- {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Abstract abst = new AbstractImpl();
- abst.setText(version);
- inspection.removeAbstracts();
- inspection.addAbstract(abst);
- }
-
- public synchronized void save() throws WSILException, IOException
- {
- WSILDocument wsilDoc = getWSILDocument();
- if (wsilDoc != null)
- wsilDoc.write(getWriteLocation());
- }
-
- public IFavoritesUDDIRegistry[] getFavoritesUDDIRegistries()
- {
- Link[] links = loadUDDIRegistries();
- FavoritesUDDIRegistry[] registries = new FavoritesUDDIRegistry[links.length];
- for (int i = 0; i < links.length; i++)
- {
- registries[i] = new FavoritesUDDIRegistry();
- registries[i].setLink(links[i]);
- }
- return registries;
- }
-
- public IFavoritesUDDIBusiness[] getFavoritesUDDIBusinesses()
- {
- Link[] links = loadUDDIBusinesses();
- FavoritesUDDIBusiness[] businesses = new FavoritesUDDIBusiness[links.length];
- for (int i = 0; i < links.length; i++)
- {
- businesses[i] = new FavoritesUDDIBusiness();
- businesses[i].setLink(links[i]);
- }
- return businesses;
- }
-
- public IFavoritesUDDIService[] getFavoritesUDDIServices()
- {
- Service[] services = loadUDDIServices();
- FavoritesUDDIService[] uddiServices = new FavoritesUDDIService[services.length];
- for (int i = 0; i < services.length; i++)
- {
- uddiServices[i] = new FavoritesUDDIService();
- uddiServices[i].setService(services[i]);
- }
- return uddiServices;
- }
-
- public IFavoritesUDDIServiceInterface[] getFavoritesUDDIServiceInterfaces()
- {
- Service[] services = loadUDDIServiceInterfaces();
- FavoritesUDDIServiceInterface[] serInts = new FavoritesUDDIServiceInterface[services.length];
- for (int i = 0; i < services.length; i++)
- {
- serInts[i] = new FavoritesUDDIServiceInterface();
- serInts[i].setService(services[i]);
- }
- return serInts;
- }
-
- public IFavoritesWSDL[] getFavoritesWSDLs()
- {
- Service[] services = loadWSDLServices();
- FavoritesWSDL[] wsdls = new FavoritesWSDL[services.length];
- for (int i = 0; i < services.length; i++)
- {
- wsdls[i] = new FavoritesWSDL();
- wsdls[i].setService(services[i]);
- }
- return wsdls;
- }
-
- public IFavoritesWSIL[] getFavoritesWSILs()
- {
- Link[] links = loadWSILs();
- FavoritesWSIL[] wsils = new FavoritesWSIL[links.length];
- for (int i = 0; i < links.length; i++)
- {
- wsils[i] = new FavoritesWSIL();
- wsils[i].setLink(links[i]);
- }
- return wsils;
- }
-
- public Link[] loadUDDIRegistries() {
- return loadLinksByNamespace(FavoritesConstants.NAMESPACE_UDDI_V1);
- }
-
- public Link[] loadUDDIBusinesses() {
- return loadLinksByNamespace(FavoritesConstants.NAMESPACE_UDDI_V2);
- }
-
- public Service[] loadUDDIServices() {
- return loadServicesByNamespace(FavoritesConstants.NAMESPACE_UDDI_V2);
- }
-
- public Service[] loadUDDIServiceInterfaces() {
- return loadServicesByNamespace(FavoritesConstants.NAMESPACE_UDDI_V1);
- }
-
- public Service[] loadWSDLServices() {
- return loadServicesByNamespace(FavoritesConstants.NAMESPACE_WSDL);
- }
-
- public Link[] loadWSILs() {
- return loadLinksByNamespace(FavoritesConstants.NAMESPACE_WSIL_INSPECTION);
- }
-
- private Service[] loadServicesByNamespace(String namespace) {
- Vector serviceVector = new Vector();
- WSILDocument wsilDoc = getWSILDocument();
- if (wsilDoc != null)
- {
- Inspection inspection = wsilDoc.getInspection();
- Service[] services = inspection.getServices();
- for (int i = 0; i < services.length; i++)
- {
- Description[] desc = services[i].getDescriptions();
- if (desc[0].getReferencedNamespace().equals(namespace))
- serviceVector.add(services[i]);
- }
- }
- Service[] services = new Service[serviceVector.size()];
- serviceVector.copyInto(services);
- return services;
- }
-
- private Link[] loadLinksByNamespace(String namespace) {
- Vector linkVector = new Vector();
- WSILDocument wsilDoc = getWSILDocument();
- if (wsilDoc != null)
- {
- Inspection inspection = wsilDoc.getInspection();
- Link[] links = inspection.getLinks();
- for (int i = 0; i < links.length; i++)
- {
- if (links[i].getReferencedNamespace().equals(namespace))
- linkVector.add(links[i]);
- }
- }
- Link[] links = new Link[linkVector.size()];
- linkVector.copyInto(links);
- return links;
- }
-
- public void addFavoritesUDDIRegistry(IFavoritesUDDIRegistry registry)
- {
- addUDDIRegistry(registry.getName(), registry.getInquiryURL(), registry.getPublishURL(), registry.getRegistrationURL());
- }
-
- public void addFavoritesUDDIBusiness(IFavoritesUDDIBusiness business)
- {
- addUDDIBusiness(business.getName(), business.getInquiryURL(), business.getBusinessKey());
- }
-
- public void addFavoritesUDDIService(IFavoritesUDDIService service)
- {
- addUDDIService(service.getName(), service.getInquiryURL(), service.getServiceKey());
- }
-
- public void addFavoritesUDDIServiceInterface(IFavoritesUDDIServiceInterface serviceInterface)
- {
- addUDDIServiceInterface(serviceInterface.getName(), serviceInterface.getInquiryURL(), serviceInterface.getServiceInterfaceKey());
- }
-
- public void addFavoritesWSDL(IFavoritesWSDL wsdl)
- {
- addWSDLService(wsdl.getWsdlUrl());
- }
-
- public void addFavoritesWSIL(IFavoritesWSIL wsil)
- {
- addWSILLink(wsil.getWsilUrl());
- }
-
- public Link addUDDIRegistry(String registryName, String inquiryAPI, String publishAPI, String registrationURL) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Link link = new LinkImpl();
- // registry name
- Abstract abst = new AbstractImpl();
- abst.setText(registryName);
- link.addAbstract(abst);
- // inquiry URL
- Abstract abst2 = new AbstractImpl();
- abst2.setText(inquiryAPI);
- link.addAbstract(abst2);
- // publish URL
- Abstract abst3 = new AbstractImpl();
- if (publishAPI != null)
- abst3.setText(publishAPI);
- else
- abst3.setText("");
- link.addAbstract(abst3);
- // registration URL
- Abstract abst4 = new AbstractImpl();
- if (registrationURL != null)
- abst4.setText(registrationURL);
- else
- abst4.setText("");
- link.addAbstract(abst4);
- // add namespace
- link.setReferencedNamespace(FavoritesConstants.NAMESPACE_UDDI_V1);
- inspection.addLink(link);
- return link;
- }
-
- public Link addUDDIBusiness(String businessName, String inquiryAPI, String businessKey) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Link link = new LinkImpl();
- Abstract abst = new AbstractImpl();
- abst.setText(businessName);
- link.addAbstract(abst);
- link.setReferencedNamespace(FavoritesConstants.NAMESPACE_UDDI_V2);
- BusinessDescription bd = new BusinessDescriptionImpl();
- bd.setLocation(inquiryAPI);
- BusinessKey key = new BusinessKey(businessKey);
- bd.setBusinessKey(key);
- link.setExtensionElement(bd);
- inspection.addLink(link);
- return link;
- }
-
- public Service addUDDIService(String serviceName, String inquiryAPI, String serviceKey) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Service service = new ServiceImpl();
- ServiceName name = new ServiceNameImpl();
- name.setText(serviceName);
- service.addServiceName(name);
- Description desc = new DescriptionImpl();
- desc.setReferencedNamespace(FavoritesConstants.NAMESPACE_UDDI_V2);
- ServiceDescription sd = new ServiceDescriptionImpl();
- sd.setLocation(inquiryAPI);
- ServiceKey key = new ServiceKey(serviceKey);
- sd.setServiceKey(key);
- desc.setExtensionElement(sd);
- service.addDescription(desc);
- inspection.addService(service);
- return service;
- }
-
- public Service addUDDIServiceInterface(String serIntName, String inquiryAPI, String serIntKey) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Service service = new ServiceImpl();
- ServiceName name = new ServiceNameImpl();
- name.setText(serIntName);
- service.addServiceName(name);
- Description desc = new DescriptionImpl();
- desc.setReferencedNamespace(FavoritesConstants.NAMESPACE_UDDI_V1);
- ServiceDescription sd = new ServiceDescriptionImpl();
- sd.setLocation(inquiryAPI);
- ServiceKey key = new ServiceKey(serIntKey);
- sd.setServiceKey(key);
- desc.setExtensionElement(sd);
- service.addDescription(desc);
- inspection.addService(service);
- return service;
- }
-
- public Service addWSDLService(String url) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Service service = new ServiceImpl();
- Description desc = new DescriptionImpl();
- desc.setLocation(url);
- desc.setReferencedNamespace(FavoritesConstants.NAMESPACE_WSDL);
- service.addDescription(desc);
- inspection.addService(service);
- return service;
- }
-
- public Link addWSILLink(String url) {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- Link link = new LinkImpl();
- link.setLocation(url);
- link.setReferencedNamespace(FavoritesConstants.NAMESPACE_WSIL_INSPECTION);
- inspection.addLink(link);
- return link;
- }
-
- public void removeFavoritesUDDIRegistry(IFavoritesUDDIRegistry registry)
- {
- if (registry instanceof FavoritesUDDIRegistry)
- removeLink(((FavoritesUDDIRegistry)registry).getLink());
- }
-
- public void removeFavoritesUDDIBusiness(IFavoritesUDDIBusiness business)
- {
- if (business instanceof FavoritesUDDIBusiness)
- removeLink(((FavoritesUDDIBusiness)business).getLink());
- }
-
- public void removeFavoritesUDDIService(IFavoritesUDDIService service)
- {
- if (service instanceof FavoritesUDDIService)
- removeService(((FavoritesUDDIService)service).getService());
- }
-
- public void removeFavoritesUDDIServiceInterface(IFavoritesUDDIServiceInterface serviceInterface)
- {
- if (serviceInterface instanceof FavoritesUDDIServiceInterface)
- removeService(((FavoritesUDDIServiceInterface)serviceInterface).getService());
- }
-
- public void removeFavoritesWSDL(IFavoritesWSDL wsdl)
- {
- if (wsdl instanceof FavoritesWSDL)
- removeService(((FavoritesWSDL)wsdl).getService());
- }
-
- public void removeFavoritesWSIL(IFavoritesWSIL wsil)
- {
- if (wsil instanceof FavoritesWSIL)
- removeLink(((FavoritesWSIL)wsil).getLink());
- }
-
- public void removeService(Service service)
- {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- inspection.removeService(service);
- }
-
- public void removeLink(Link link)
- {
- WSILDocument wsilDoc = getWSILDocument();
- Inspection inspection = wsilDoc.getInspection();
- inspection.removeLink(link);
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesService.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesService.java
deleted file mode 100644
index 4520f9aaf..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesService.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.Service;
-
-public class FavoritesService
-{
- protected Service service_;
-
- public FavoritesService()
- {
- service_ = null;
- }
-
- public Service getService()
- {
- return service_;
- }
-
- public void setService(Service service)
- {
- service_ = service;
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIBusiness.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIBusiness.java
deleted file mode 100644
index f53883c86..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIBusiness.java
+++ /dev/null
@@ -1,49 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.extension.uddi.BusinessDescription;
-
-public class FavoritesUDDIBusiness extends FavoritesLink implements IFavoritesUDDIBusiness
-{
- public FavoritesUDDIBusiness()
- {
- super();
- }
-
- public String getName()
- {
- return (link_.getAbstracts())[0].getText();
- }
-
- public String getInquiryURL()
- {
- return ((BusinessDescription)link_.getExtensionElement()).getLocation();
- }
-
- public String getBusinessKey()
- {
- return ((BusinessDescription)link_.getExtensionElement()).getBusinessKey().getText();
- }
-
- public void setName(String name)
- {
- }
-
- public void setInquiryURL(String inquiryURL)
- {
- }
-
- public void setBusinessKey(String key)
- {
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIRegistry.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIRegistry.java
deleted file mode 100644
index 7cc8076dd..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIRegistry.java
+++ /dev/null
@@ -1,88 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.Abstract;
-import org.eclipse.wst.ws.internal.parser.plugin.ParserPlugin;
-
-public class FavoritesUDDIRegistry extends FavoritesLink implements IFavoritesUDDIRegistry
-{
- public FavoritesUDDIRegistry()
- {
- super();
- }
-
- public String getName()
- {
- String name = (link_.getAbstracts())[0].getText();
- if (name.startsWith("%"))
- {
- String translatedName = ParserPlugin.getMessage(name);
- if (translatedName != null)
- name = translatedName;
- }
- return name;
- }
-
- public String getInquiryURL()
- {
- return (link_.getAbstracts())[1].getText();
- }
-
- public String getPublishURL()
- {
- Abstract[] abstracts = link_.getAbstracts();
- if (abstracts.length > 2)
- {
- String publishURL = abstracts[2].getText();
- if (publishURL != null && publishURL.length() > 0)
- return publishURL;
- }
- return null;
- }
-
- public String getRegistrationURL()
- {
- Abstract[] abstracts = link_.getAbstracts();
- if (abstracts.length > 3)
- {
- String registrationURL = abstracts[3].getText();
- if (registrationURL != null && registrationURL.length() > 0)
- return registrationURL;
- }
- return null;
- }
-
- public void setName(String name)
- {
- (link_.getAbstracts())[0].setText(name);
- }
-
- public void setInquiryURL(String inquiryURL)
- {
- (link_.getAbstracts())[1].setText(inquiryURL);
- }
-
- public void setPublishURL(String publishURL)
- {
- Abstract[] abstracts = link_.getAbstracts();
- if (abstracts.length > 2)
- abstracts[2].setText(publishURL);
- }
-
- public void setRegistrationURL(String registrationURL)
- {
- Abstract[] abstracts = link_.getAbstracts();
- if (abstracts.length > 3)
- abstracts[3].setText(registrationURL);
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIService.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIService.java
deleted file mode 100644
index 0954f5712..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIService.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.extension.uddi.ServiceDescription;
-
-public class FavoritesUDDIService extends FavoritesService implements IFavoritesUDDIService
-{
- public FavoritesUDDIService()
- {
- super();
- }
-
- public String getName()
- {
- return (service_.getServiceNames())[0].getText();
- }
-
- public String getInquiryURL()
- {
- ServiceDescription sd = (ServiceDescription)(service_.getDescriptions())[0].getExtensionElement();
- return sd.getLocation();
- }
-
- public String getServiceKey()
- {
- ServiceDescription sd = (ServiceDescription)(service_.getDescriptions())[0].getExtensionElement();
- return sd.getServiceKey().getText();
- }
-
- public void setName(String name)
- {
- }
-
- public void setInquiryURL(String inquiryURL)
- {
- }
-
- public void setServiceKey(String key)
- {
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIServiceInterface.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIServiceInterface.java
deleted file mode 100644
index 56ec674c1..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesUDDIServiceInterface.java
+++ /dev/null
@@ -1,51 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-import org.apache.wsil.extension.uddi.ServiceDescription;
-
-public class FavoritesUDDIServiceInterface extends FavoritesService implements IFavoritesUDDIServiceInterface
-{
- public FavoritesUDDIServiceInterface()
- {
- super();
- }
-
- public String getName()
- {
- return (service_.getServiceNames())[0].getText();
- }
-
- public String getInquiryURL()
- {
- ServiceDescription sd = (ServiceDescription)(service_.getDescriptions())[0].getExtensionElement();
- return sd.getLocation();
- }
-
- public String getServiceInterfaceKey()
- {
- ServiceDescription sd = (ServiceDescription)(service_.getDescriptions())[0].getExtensionElement();
- return sd.getServiceKey().getText();
- }
-
- public void setName(String name)
- {
- }
-
- public void setInquiryURL(String inquiryURL)
- {
- }
-
- public void setServiceInterfaceKey(String key)
- {
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSDL.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSDL.java
deleted file mode 100644
index 0f340e053..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSDL.java
+++ /dev/null
@@ -1,38 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public class FavoritesWSDL extends FavoritesService implements IFavoritesWSDL
-{
- public FavoritesWSDL()
- {
- super();
- }
-
- public String getName()
- {
- return getWsdlUrl();
- }
-
- public String getWsdlUrl()
- {
- return (service_.getDescriptions())[0].getLocation();
- }
-
- public void setName(String name)
- {
- }
-
- public void setWsdlUrl(String wsdlURL)
- {
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSIL.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSIL.java
deleted file mode 100644
index 6622c7dea..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/FavoritesWSIL.java
+++ /dev/null
@@ -1,39 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public class FavoritesWSIL extends FavoritesLink implements IFavoritesWSIL
-{
- public FavoritesWSIL()
- {
- super();
- }
-
- public String getName()
- {
- return getWsilUrl();
- }
-
-
- public String getWsilUrl()
- {
- return link_.getLocation();
- }
-
- public void setName(String name)
- {
- }
-
- public void setWsilUrl(String wsilURL)
- {
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesRegistryType.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesRegistryType.java
deleted file mode 100644
index b2c96c1cb..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesRegistryType.java
+++ /dev/null
@@ -1,36 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesRegistryType
-{
- public IFavoritesUDDIRegistry[] getFavoritesUDDIRegistries();
- public IFavoritesUDDIBusiness[] getFavoritesUDDIBusinesses();
- public IFavoritesUDDIService[] getFavoritesUDDIServices();
- public IFavoritesUDDIServiceInterface[] getFavoritesUDDIServiceInterfaces();
- public IFavoritesWSDL[] getFavoritesWSDLs();
- public IFavoritesWSIL[] getFavoritesWSILs();
-
- public void addFavoritesUDDIRegistry(IFavoritesUDDIRegistry registry);
- public void addFavoritesUDDIBusiness(IFavoritesUDDIBusiness business);
- public void addFavoritesUDDIService(IFavoritesUDDIService service);
- public void addFavoritesUDDIServiceInterface(IFavoritesUDDIServiceInterface serviceInterface);
- public void addFavoritesWSDL(IFavoritesWSDL wsdl);
- public void addFavoritesWSIL(IFavoritesWSIL wsil);
-
- public void removeFavoritesUDDIRegistry(IFavoritesUDDIRegistry registry);
- public void removeFavoritesUDDIBusiness(IFavoritesUDDIBusiness business);
- public void removeFavoritesUDDIService(IFavoritesUDDIService service);
- public void removeFavoritesUDDIServiceInterface(IFavoritesUDDIServiceInterface serviceInterface);
- public void removeFavoritesWSDL(IFavoritesWSDL wsdl);
- public void removeFavoritesWSIL(IFavoritesWSIL wsil);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIBusiness.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIBusiness.java
deleted file mode 100644
index dd2d2c950..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIBusiness.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesUDDIBusiness
-{
- public String getName();
- public String getInquiryURL();
- public String getBusinessKey();
-
- public void setName(String name);
- public void setInquiryURL(String inquiryURL);
- public void setBusinessKey(String key);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIRegistry.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIRegistry.java
deleted file mode 100644
index bb035f1c1..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIRegistry.java
+++ /dev/null
@@ -1,25 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesUDDIRegistry
-{
- public String getName();
- public String getInquiryURL();
- public String getPublishURL();
- public String getRegistrationURL();
-
- public void setName(String name);
- public void setInquiryURL(String inquiryURL);
- public void setPublishURL(String publishURL);
- public void setRegistrationURL(String registrationURL);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIService.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIService.java
deleted file mode 100644
index 286370df0..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIService.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesUDDIService
-{
- public String getName();
- public String getInquiryURL();
- public String getServiceKey();
-
- public void setName(String name);
- public void setInquiryURL(String inquiryURL);
- public void setServiceKey(String key);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIServiceInterface.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIServiceInterface.java
deleted file mode 100644
index ad426cbb6..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesUDDIServiceInterface.java
+++ /dev/null
@@ -1,23 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesUDDIServiceInterface
-{
- public String getName();
- public String getInquiryURL();
- public String getServiceInterfaceKey();
-
- public void setName(String name);
- public void setInquiryURL(String inquiryURL);
- public void setServiceInterfaceKey(String key);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSDL.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSDL.java
deleted file mode 100644
index d69f824cf..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSDL.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesWSDL
-{
- public String getName();
- public String getWsdlUrl();
-
- public void setName(String name);
- public void setWsdlUrl(String wsdlURL);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSIL.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSIL.java
deleted file mode 100644
index 4c129e13b..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/favorites/IFavoritesWSIL.java
+++ /dev/null
@@ -1,21 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2003, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.favorites;
-
-public interface IFavoritesWSIL
-{
- public String getName();
- public String getWsilUrl();
-
- public void setName(String name);
- public void setWsilUrl(String wsilURL);
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/plugin/ParserPlugin.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/plugin/ParserPlugin.java
deleted file mode 100644
index d2dc6dc69..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/plugin/ParserPlugin.java
+++ /dev/null
@@ -1,111 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.plugin;
-
-import java.text.MessageFormat;
-import java.util.MissingResourceException;
-import java.util.ResourceBundle;
-
-import org.eclipse.core.runtime.Plugin;
-import org.eclipse.wst.command.internal.env.core.common.MessageUtils;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class ParserPlugin extends Plugin {
- //The shared instance.
- private static ParserPlugin plugin;
- //Resource bundle.
- private ResourceBundle resourceBundle;
-
- /**
- * The constructor.
- */
- public ParserPlugin() {
- super();
- plugin = this;
- try {
- resourceBundle = ResourceBundle.getBundle("org.eclipse.wst.ws.parser.ParserPluginResources");
- } catch (MissingResourceException x) {
- resourceBundle = null;
- }
- }
-
- /**
- * Returns the shared instance.
- */
- public static ParserPlugin getDefault() {
- return plugin;
- }
-
- /**
- * Returns the string from the plugin's resource bundle,
- * or 'key' if not found.
- */
- public static String getResourceString(String key) {
- ResourceBundle bundle = ParserPlugin.getDefault().getResourceBundle();
- try {
- return (bundle != null) ? bundle.getString(key) : key;
- } catch (MissingResourceException e) {
- return key;
- }
- }
-
- /**
- * Returns the plugin's resource bundle,
- */
- public ResourceBundle getResourceBundle() {
- return resourceBundle;
- }
-
- /**
- * Returns the message string identified by the given key from
- * the plugin.properties file for the appropriate locale.
- * @param key The message key string prefixed by a "%" symbol.
- * That is, the string passed in must be of the form "%KEY"
- * where the plugin.properties file contains a line of the
- * form: "KEY = value".
- * @return The locale-specific message.
- */
- public static String getMessage ( String key )
- {
- MessageUtils msgUtils = new MessageUtils( "org.eclipse.wst.ws.parser.plugin", plugin );
-
- if( key.startsWith("%"))
- {
- key = key.substring( 1, key.length() );
- }
-
- return msgUtils.getMessage(key);
- }
-
- /**
- * Returns the message string identified by the given key from
- * the plugin.properties file for the appropriate locale.
- * Substitution sequences in the message string
- * are replaced by the given array of substitution objects (which
- * are most frequently strings). See java.text.MessageFormat for
- * further details on substitution.
- * @param key The message key string prefixed by a "%" symbol.
- * That is, the string passed in must be of the form "%KEY"
- * where the plugin.properties file contains a line of the
- * form: "KEY = value".
- * @param args The substitution values for the message
- * as required by the message in plugin.properties and
- * by the rules of class java.text.MessageFormat.
- * @return The locale-specific message.
- */
- public static String getMessage ( String key, Object[] args )
- {
- return MessageFormat.format(getMessage(key),args);
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/HTMLHeadHandler.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/HTMLHeadHandler.java
deleted file mode 100644
index 36994bb05..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/HTMLHeadHandler.java
+++ /dev/null
@@ -1,171 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import java.io.UnsupportedEncodingException;
-import java.util.Vector;
-
-import org.xml.sax.Attributes;
-import org.xml.sax.SAXException;
-import org.xml.sax.SAXParseException;
-import org.xml.sax.helpers.DefaultHandler;
-
-public class HTMLHeadHandler extends DefaultHandler
-{
- private final char START_TAG = '<';
- private final char END_TAG = '>';
- private final String HEAD_START_TAG = "<head>";
- private final String HEAD_END_TAG = "</head>";
- private final String ROOT_START_TAG = "<root>";
- private final String ROOT_END_TAG = "</root>";
- private final String UTF8 = "UTF-8";
-
- // WSIL tag information.
- private final String META = "meta";
- private final String NAME = "name";
- private final String SERVICE_INSPECTION = "serviceInspection";
- private final String CONTENT = "content";
-
- // DISCO tag information.
- private final String LINK = "link";
- private final String TYPE = "type";
- private final String TEXT_XML = "text/xml";
- private final String REL = "rel";
- private final String ALTERNATE = "alternate";
- private final String HREF = "href";
-
- private String baseURI_;
- private Vector wsils_;
- private Vector discos_;
-
- public HTMLHeadHandler(String baseURI)
- {
- super();
- baseURI_ = baseURI;
- wsils_ = new Vector();
- discos_ = new Vector();
- }
-
- public String[] getWsils()
- {
- String[] wsils = new String[wsils_.size()];
- wsils_.copyInto(wsils);
- return wsils;
- }
-
- public String[] getDiscos()
- {
- String[] discos = new String[discos_.size()];
- discos_.copyInto(discos);
- return discos;
- }
-
- public void startElement(String uri, String localName, String qName, Attributes attributes) throws SAXException
- {
- String qNameLC = qName.toLowerCase();
- if (qNameLC.equals(META))
- {
- String nameValue = attributes.getValue(NAME);
- if (SERVICE_INSPECTION.equals(nameValue))
- {
- String wsilURI = attributes.getValue(CONTENT);
- if (baseURI_ != null && wsilURI.indexOf(":/") == -1)
- {
- StringBuffer sb = new StringBuffer();
- sb.append(baseURI_.substring(0, baseURI_.lastIndexOf("/")+1));
- sb.append(wsilURI);
- wsilURI = sb.toString();
- }
- if (!wsils_.contains(wsilURI))
- wsils_.add(wsilURI);
- }
- }
- else if (qNameLC.equals(LINK))
- {
- // See http://msdn.microsoft.com/msdnmag/issues/02/02/xml/default.aspx for more details on DISCO.
- String type = attributes.getValue(TYPE);
- String rel = attributes.getValue(REL);
- String href = attributes.getValue(HREF);
- if (TEXT_XML.equals(type) && ALTERNATE.equals(rel) && href != null)
- {
- String discoURI = href;
- if (discoURI.indexOf(":/") == -1)
- {
- StringBuffer sb = new StringBuffer();
- sb.append(baseURI_.substring(0,baseURI_.lastIndexOf("/")+1));
- sb.append(discoURI);
- discoURI = sb.toString();
- }
- if (!discos_.contains(discoURI))
- discos_.add(discoURI);
- }
- }
- }
-
- public void error(SAXParseException e) throws SAXException
- {
- }
-
- public void fatalError(SAXParseException e) throws SAXException
- {
- }
-
- public void warning(SAXParseException e) throws SAXException
- {
- }
-
- private void harvestTags(StringBuffer target,String document,String tag)
- {
- int index = document.indexOf(START_TAG);
- int documentLength = document.length();
- int tagLength = tag.length();
- while (index != -1 && (index+1+tagLength)<documentLength)
- {
- String str = document.substring(index+1,index+1+tagLength);
- if (str.toLowerCase().equals(tag))
- {
- str = document.substring(index,document.indexOf(END_TAG,index+1)+1);
- target.append(str);
- index += str.length();
- }
- else
- index++;
- index = document.indexOf(START_TAG,index);
- }
- }
-
- public byte[] harvestHeadTags(byte[] b)
- {
- String s;
- try
- {
- s = new String(b, UTF8);
- }
- catch (UnsupportedEncodingException uee)
- {
- s = new String(b);
- }
- String head = s.toLowerCase();
- int headStartIndex = head.indexOf(HEAD_START_TAG);
- int headEndIndex = head.indexOf(HEAD_END_TAG);
- StringBuffer sb = new StringBuffer();
- sb.append(ROOT_START_TAG);
- if (headStartIndex != -1 && headEndIndex != -1)
- {
- head = s.substring(headStartIndex, headEndIndex+HEAD_END_TAG.length());
- harvestTags(sb,head,META);
- harvestTags(sb,head,LINK);
- }
- sb.append(ROOT_END_TAG);
- return sb.toString().getBytes();
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/IllegalArgumentsException.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/IllegalArgumentsException.java
deleted file mode 100644
index bf42dc6b9..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/IllegalArgumentsException.java
+++ /dev/null
@@ -1,22 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-public class IllegalArgumentsException extends Exception
-{
- private static final long serialVersionUID = -2533981176285561234L;
-
- public IllegalArgumentsException(String arg)
- {
- super(arg);
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/UDDIURIHelper.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/UDDIURIHelper.java
deleted file mode 100644
index 3d007ac66..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/UDDIURIHelper.java
+++ /dev/null
@@ -1,63 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import java.text.MessageFormat;
-import java.text.ParseException;
-
-public class UDDIURIHelper
-{
- private static final String QUERYSERVICE_URI_TEMPLATE = "uddiservice:query:{0}:query:{1}";
- private static final String SERVICEKEY_URI_TEMPLATE = "uddiservice:serviceKey:{0}:serviceKey:{1}";
-
- public static final String getQueryServiceURI(String query,String inquiryURL)
- {
- String[] uriParams = {query,inquiryURL};
- return MessageFormat.format(QUERYSERVICE_URI_TEMPLATE,uriParams);
- }
-
- public static final String getServiceKeyURI(String serviceKey,String inquiryURL)
- {
- String[] uriParams = {serviceKey,inquiryURL};
- return MessageFormat.format(SERVICEKEY_URI_TEMPLATE,uriParams);
- }
-
- private static final String[] parseURI(String pattern,String uri)
- {
- try
- {
- MessageFormat mf = new MessageFormat(pattern);
- Object[] parsedResults = mf.parse(uri);
- if (parsedResults != null && parsedResults.length > 0)
- {
- String[] results = new String[parsedResults.length];
- for (int i=0;i<parsedResults.length;i++)
- results[i] = (String)parsedResults[i];
- return results;
- }
- }
- catch (ParseException e)
- {
- }
- return null;
- }
-
- public static final String[] parseServiceKeyURI(String uri)
- {
- return parseURI(SERVICEKEY_URI_TEMPLATE,uri);
- }
-
- public static final String[] parseQueryServiceURI(String uri)
- {
- return parseURI(QUERYSERVICE_URI_TEMPLATE,uri);
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WSILMessages.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WSILMessages.java
deleted file mode 100644
index 3286ba799..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WSILMessages.java
+++ /dev/null
@@ -1,22 +0,0 @@
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import org.eclipse.osgi.util.NLS;
-
-public class WSILMessages extends NLS
-{
- private static final String BUNDLE_NAME = "org.eclipse.wst.ws.internal.parser.wsil.wsil"; //$NON-NLS-1$
-
- static
- {
- NLS.initializeMessages(BUNDLE_NAME, WSILMessages.class);
- }
-
- public static String MSG_ERROR_INVALID_ARGUMENTS;
- public static String MSG_ERROR_ILLEGAL_ARGUMENTS;
- public static String MSG_ERROR_INVALID_WSDL_URI;
- public static String MSG_ERROR_INVALID_WSIL_URI;
- public static String MSG_ERROR_UNRESOLVABLE_WSDL;
- public static String MSG_ERROR_UNEXPECTED_EXCEPTION;
- public static String MSG_ERROR_MALFORMED_WSDL;
- public static String MSG_ERROR_WRITE_WSIL;
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationException.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationException.java
deleted file mode 100644
index 8ac66a620..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationException.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import java.io.IOException;
-
-public class WWWAuthenticationException extends Exception
-{
- private static final long serialVersionUID = -4918211021620316049L;
-
- private IOException ioe_;
- private String wwwAuthMsg_;
- private String url_;
-
- public WWWAuthenticationException(IOException ioe, String wwwAuthMsg, String url)
- {
- super(ioe.getMessage());
- ioe_ = ioe;
- wwwAuthMsg_ = wwwAuthMsg;
- url_ = url;
- }
-
- public IOException getIOException()
- {
- return ioe_;
- }
-
- public String getWWWAuthenticationMsg()
- {
- return wwwAuthMsg_;
- }
-
- public String getURL()
- {
- return url_;
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationHandler.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationHandler.java
deleted file mode 100644
index c7a8cab19..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WWWAuthenticationHandler.java
+++ /dev/null
@@ -1,19 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-public interface WWWAuthenticationHandler
-{
- public void handleWWWAuthentication(WWWAuthenticationException wwwae);
- public String getUsername();
- public String getPassword();
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServiceEntity.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServiceEntity.java
deleted file mode 100644
index 33e38a77f..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServiceEntity.java
+++ /dev/null
@@ -1,148 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import java.util.ArrayList;
-import java.util.List;
-
-public class WebServiceEntity
-{
- public static final int TYPE_UNKNOWN = -1;
- public static final int TYPE_HTML = 0;
- public static final int TYPE_WSIL = 1;
- public static final int TYPE_WSDL = 2;
- public static final int TYPE_UDDI_SERVICE = 3;
- public static final int TYPE_DISCO = 4;
-
- private Object parent_;
- private List children_;
- private int type_;
- private String uri_;
- private byte[] bytes_;
- private String httpUsername_;
- private String httpPassword_;
- private String documentation_;
- private Object model_;
-
- public WebServiceEntity()
- {
- parent_ = null;
- children_ = new ArrayList();
- type_ = TYPE_UNKNOWN;
- uri_ = null;
- bytes_ = null;
- httpUsername_ = null;
- httpPassword_ = null;
- documentation_ = null;
- model_ = null;
- }
-
- public Object getParent()
- {
- return parent_;
- }
-
- public void setParent(Object parent)
- {
- parent_ = parent;
- }
-
- public List getChildren()
- {
- return children_;
- }
-
- public void addChild(Object child)
- {
- children_.add(child);
- }
-
- public void removeChild(Object child)
- {
- children_.remove(child);
- }
-
- public int getType()
- {
- return type_;
- }
-
- public void setType(int type)
- {
- type_ = type;
- }
-
- public String getURI()
- {
- return uri_;
- }
-
- public void setURI(String uri)
- {
- uri_ = uri;
- }
-
- public byte[] getBytes()
- {
- return bytes_;
- }
-
- public void setBytes(byte[] bytes)
- {
- bytes_ = bytes;
- }
-
- public String getHTTPUsername()
- {
- return httpUsername_;
- }
-
- public void setHTTPUsername(String httpUsername)
- {
- httpUsername_ = httpUsername;
- }
-
- public String getHTTPPassword()
- {
- return httpPassword_;
- }
-
- public void setHTTPPassword(String httpPassword)
- {
- httpPassword_ = httpPassword;
- }
-
- public String getDocumentation()
- {
- return documentation_;
- }
-
- public void setDocumentation(String documentation)
- {
- documentation_ = documentation;
- }
-
- public Object getModel()
- {
- return model_;
- }
-
- public void setModel(Object model)
- {
- model_ = model;
- }
-
- public boolean isEntityResolved()
- {
- return (bytes_ != null);
- }
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServicesParser.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServicesParser.java
deleted file mode 100644
index 1acc20c68..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/WebServicesParser.java
+++ /dev/null
@@ -1,547 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2004 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * IBM Corporation - initial API and implementation
- ******************************************************************************/
-
-package org.eclipse.wst.ws.internal.parser.wsil;
-
-import java.io.ByteArrayInputStream;
-import java.io.ByteArrayOutputStream;
-import java.io.IOException;
-import java.io.InputStream;
-import java.io.InputStreamReader;
-import java.net.MalformedURLException;
-import java.net.URL;
-import java.net.URLConnection;
-import java.util.Hashtable;
-
-import javax.wsdl.Definition;
-import javax.wsdl.WSDLException;
-import javax.wsdl.factory.WSDLFactory;
-import javax.wsdl.xml.WSDLReader;
-import javax.xml.parsers.ParserConfigurationException;
-import javax.xml.parsers.SAXParser;
-import javax.xml.parsers.SAXParserFactory;
-
-import org.apache.wsil.Abstract;
-import org.apache.wsil.Description;
-import org.apache.wsil.Inspection;
-import org.apache.wsil.Link;
-import org.apache.wsil.Service;
-import org.apache.wsil.WSILConstants;
-import org.apache.wsil.WSILDocument;
-import org.apache.wsil.WSILException;
-import org.apache.wsil.extension.ExtensionElement;
-import org.apache.wsil.extension.uddi.ServiceDescription;
-import org.apache.wsil.extension.uddi.UDDIConstants;
-import org.apache.wsil.extension.wsdl.WSDLConstants;
-import org.eclipse.wst.ws.internal.parser.disco.DISCOContractReference;
-import org.eclipse.wst.ws.internal.parser.disco.DISCOParser;
-import org.eclipse.wst.ws.internal.parser.disco.DISCOReference;
-import org.eclipse.wst.wsdl.WSDLPlugin;
-import org.xml.sax.InputSource;
-import org.xml.sax.SAXException;
-
-import sun.misc.BASE64Encoder;
-
-public class WebServicesParser
-{
- public static final int PARSE_NONE = 0;
- public static final int PARSE_WSIL = 1<<0;
- public static final int PARSE_WSDL = 1<<1;
- public static final int PARSE_LINKS = 1<<2;
- public static final int PARSE_DISCO = 1<<3;
-
- private String uri_;
- private Hashtable uriToEntityTable_;
-
- private String httpBasicAuthUsername_;
- private String httpBasicAuthPassword_;
-
- public WebServicesParser()
- {
- this(null);
- }
-
- public WebServicesParser(String uri)
- {
- uri_ = uri;
- uriToEntityTable_ = new Hashtable();
- httpBasicAuthUsername_ = null;
- httpBasicAuthPassword_ = null;
- }
-
- public String getURI()
- {
- return uri_;
- }
-
- public void setURI(String uri)
- {
- uri_ = uri;
- }
-
- public WebServiceEntity getWebServiceEntityByURI(String uri)
- {
- if (uri != null)
- return (WebServiceEntity)uriToEntityTable_.get(uri);
- else
- return null;
- }
-
- public WSILDocument getWSILDocument(String wsilURI)
- {
- try
- {
- return getWSILDocumentVerbose(wsilURI);
- }
- catch (Throwable t)
- {
- }
- return null;
- }
-
- public WSILDocument getWSILDocumentVerbose(String wsilURI) throws MalformedURLException, IOException, WWWAuthenticationException, WSILException
- {
- WebServiceEntity wsEntity = getWebServiceEntityByURI(wsilURI);
- if (wsEntity == null)
- {
- wsEntity = new WebServiceEntity();
- wsEntity.setURI(wsilURI);
- uriToEntityTable_.put(wsilURI, wsEntity);
- }
- WSILDocument wsilDocument = (WSILDocument)wsEntity.getModel();
- if (wsilDocument == null)
- {
- byte[] b = getInputStreamAsByteArray(wsilURI);
- wsEntity.setBytes(b);
- setHTTPSettings(wsEntity);
- InputStreamReader isr = new InputStreamReader(new ByteArrayInputStream(b));
- wsilDocument = WSILDocument.newInstance();
- wsilDocument.read(isr);
- wsEntity.setType(WebServiceEntity.TYPE_WSIL);
- wsEntity.setModel(wsilDocument);
- }
- return wsilDocument;
- }
-
- public Definition getWSDLDefinition(String wsdlURI)
- {
- try
- {
- return getWSDLDefinitionVerbose(wsdlURI);
- }
- catch (Throwable t)
- {
- }
- return null;
- }
-
- public Definition getWSDLDefinitionVerbose(String wsdlURI) throws MalformedURLException, IOException, WWWAuthenticationException, WSDLException
- {
- WebServiceEntity wsEntity = getWebServiceEntityByURI(wsdlURI);
- if (wsEntity == null)
- {
- wsEntity = new WebServiceEntity();
- wsEntity.setURI(wsdlURI);
- uriToEntityTable_.put(wsdlURI, wsEntity);
- }
- Definition definition = (Definition)wsEntity.getModel();
- if (definition == null)
- {
- byte[] b = getInputStreamAsByteArray(wsdlURI);
- wsEntity.setBytes(b);
- setHTTPSettings(wsEntity);
- ByteArrayInputStream bais = new ByteArrayInputStream(b);
- WSDLFactory factory = WSDLPlugin.INSTANCE.createWSDL4JFactory();
- WSDLReader wsdlReader = factory.newWSDLReader();
- definition = wsdlReader.readWSDL(wsdlURI, new InputSource(bais));
- wsEntity.setType(WebServiceEntity.TYPE_WSDL);
- wsEntity.setModel(definition);
- }
- return definition;
- }
-
- public void parse() throws MalformedURLException, IOException, ParserConfigurationException, SAXException, WWWAuthenticationException
- {
- parseURL(PARSE_WSIL | PARSE_WSDL | PARSE_LINKS | PARSE_DISCO);
- }
-
- public void parse(int parseOption) throws MalformedURLException, IOException, ParserConfigurationException, SAXException, WWWAuthenticationException
- {
- parseURL(parseOption);
- }
-
- private void parseURL(int parseOption) throws MalformedURLException, IOException, ParserConfigurationException, SAXException, WWWAuthenticationException
- {
- WebServiceEntity wsEntity = new WebServiceEntity();
- wsEntity.setURI(uri_);
- byte[] b = getInputStreamAsByteArray(uri_);
- wsEntity.setBytes(b);
- setHTTPSettings(wsEntity);
- uriToEntityTable_.put(uri_, wsEntity);
- // parse uri_ as a HTML document
- HTMLHeadHandler headHandler = new HTMLHeadHandler(uri_);
- byte[] head = headHandler.harvestHeadTags(b);
- SAXParserFactory factory = SAXParserFactory.newInstance();
- factory.setNamespaceAware(false);
- factory.setValidating(false);
- SAXParser parser = factory.newSAXParser();
- try
- {
- parser.parse(new ByteArrayInputStream(head), headHandler);
- }
- catch (Throwable t)
- {
- }
- String[] wsilURIs = headHandler.getWsils();
- String[] discoURIs = headHandler.getDiscos();
- // true if uri_ is a HTML document
- if (wsilURIs.length > 0 || discoURIs.length > 0)
- {
- wsEntity.setType(WebServiceEntity.TYPE_HTML);
- for (int i = 0; i < wsilURIs.length; i++)
- {
- String absoluteURI = convertToAbsoluteURI(uri_, wsilURIs[i]);
- WebServiceEntity wsilEntity = new WebServiceEntity();
- wsilEntity.setType(WebServiceEntity.TYPE_WSIL);
- wsilEntity.setURI(absoluteURI);
- associate(wsEntity, wsilEntity);
- uriToEntityTable_.put(absoluteURI, wsilEntity);
- if ((parseOption | PARSE_WSIL) == parseOption)
- {
- try
- {
- parseWSIL(absoluteURI, parseOption);
- }
- catch (Throwable t)
- {
- }
- }
- }
- for (int i=0;i<discoURIs.length;i++)
- {
- WebServiceEntity discoEntity = new WebServiceEntity();
- discoEntity.setType(WebServiceEntity.TYPE_DISCO);
- discoEntity.setURI(discoURIs[i]);
- associate(wsEntity,discoEntity);
- uriToEntityTable_.put(discoURIs[i],discoEntity);
- if ((parseOption | PARSE_DISCO) == parseOption)
- {
- try
- {
- parseDISCO(discoURIs[i],parseOption);
- }
- catch (Throwable t)
- {
- }
- }
- }
- }
- // false if uri_ is not a HTML document
- // then parse uri_ as a WSIL document
- else
- {
- try
- {
- parseWSIL(uri_, parseOption);
- // no exception thrown if uri_ is a WSIL document
- wsEntity.setType(WebServiceEntity.TYPE_WSIL);
- }
- catch (Throwable t)
- {
- // exception thrown if uri_ is not a WSIL document
- // then parse uri_ as a DISCO document.
- try
- {
- parseDISCO(uri_, parseOption);
- // no exception thrown if uri_ is a DISCO document
- wsEntity.setType(WebServiceEntity.TYPE_DISCO);
- }
- catch (Throwable t2)
- {
- // exception thrown if uri_ is not a DISCO document
- // then parse uri_ as a WSDL document
- try
- {
- parseWSDL(uri_);
- // no exception thrown if uri_ is a WSDL document
- wsEntity.setType(WebServiceEntity.TYPE_WSDL);
- }
- catch (Throwable t3)
- {
- // exception thrown if uri_ is not a WSDL document
- // then do nothing
- }
- }
- }
- }
- }
-
- private void parseWSIL(String wsilURI, int parseOption) throws WSILException, MalformedURLException, IOException, WSDLException, WWWAuthenticationException
- {
- WebServiceEntity wsilEntity = getWebServiceEntityByURI(wsilURI);
- WSILDocument wsilDoc = (WSILDocument)wsilEntity.getModel();
- if (wsilDoc != null)
- {
- // Prevent infinite loops from occurring when a WSIL cycles occur.
- return;
- }
- wsilDoc = getWSILDocumentVerbose(wsilURI);
- Inspection inspection = wsilDoc.getInspection();
- Service[] services = inspection.getServices();
- for (int i = 0; i < services.length; i++)
- {
- Description[] descs = services[i].getDescriptions();
- // Set the documentation to the <service> element's first abstract.
- String documentation = null;
- Abstract[] abstracts = services[i].getAbstracts();
- if (abstracts != null && abstracts.length > 0)
- documentation = abstracts[0].getText();
- for (int j = 0; j < descs.length; j++)
- {
- String referencedNS = descs[j].getReferencedNamespace();
- // If a <description> element contains an abstract, use it to override the service documentation.
- abstracts = descs[j].getAbstracts();
- if (abstracts != null && abstracts.length > 0)
- documentation = abstracts[0].getText();
- if (WSDLConstants.NS_URI_WSDL.equals(referencedNS))
- {
- String location = descs[j].getLocation();
- if (location != null && location.length() > 0)
- {
- String absoluteURI = convertToAbsoluteURI(wsilURI, location);
- WebServiceEntity wsdlEntity = new WebServiceEntity();
- wsdlEntity.setType(WebServiceEntity.TYPE_WSDL);
- wsdlEntity.setURI(absoluteURI);
- wsdlEntity.setDocumentation(documentation);
- associate(wsilEntity, wsdlEntity);
- uriToEntityTable_.put(absoluteURI, wsdlEntity);
- if ((parseOption | PARSE_WSDL) == parseOption)
- parseWSDL(absoluteURI);
- }
- }
- else if (UDDIConstants.NS_URI_UDDI_V2.equals(referencedNS))
- {
- ExtensionElement ee = descs[j].getExtensionElement();
- if (ee instanceof ServiceDescription)
- {
- ServiceDescription sd = (ServiceDescription)ee;
- String inquiryURL = sd.getLocation();
- String serviceKey = sd.getServiceKey().getText();
- WebServiceEntity uddiServiceEntity = new WebServiceEntity();
- uddiServiceEntity.setType(WebServiceEntity.TYPE_UDDI_SERVICE);
- String uddiServiceKeyURI = UDDIURIHelper.getServiceKeyURI(serviceKey,inquiryURL);
- uddiServiceEntity.setURI(uddiServiceKeyURI);
- uddiServiceEntity.setDocumentation(documentation);
- associate(wsilEntity,uddiServiceEntity);
- uriToEntityTable_.put(uddiServiceKeyURI,uddiServiceEntity);
- // TODO: parse WSDL if necessary...
- }
- }
- }
- }
- Link[] links = inspection.getLinks();
- for (int i = 0; i < links.length; i++)
- {
- if (WSILConstants.NS_URI_WSIL.equals(links[i].getReferencedNamespace()))
- {
- String documentation = null;
- Abstract[] abstracts = links[i].getAbstracts();
- if (abstracts != null && abstracts.length > 0)
- documentation = abstracts[0].getText();
- String linkLocation = links[i].getLocation();
- String absoluteURI = convertToAbsoluteURI(wsilURI, linkLocation);
- // Prevent cycles.
- WebServiceEntity wsilLinkEntity = getWebServiceEntityByURI(absoluteURI);
- if (wsilLinkEntity == null)
- {
- wsilLinkEntity = new WebServiceEntity();
- wsilLinkEntity.setType(WebServiceEntity.TYPE_WSIL);
- wsilLinkEntity.setURI(absoluteURI);
- wsilLinkEntity.setDocumentation(documentation);
- uriToEntityTable_.put(absoluteURI, wsilLinkEntity);
- if ((parseOption | PARSE_LINKS) == parseOption)
- parseWSIL(absoluteURI, parseOption);
- }
- associate(wsilEntity,wsilLinkEntity);
- }
- }
- }
-
- private void parseDISCO(String discoURI, int parseOption) throws MalformedURLException, WWWAuthenticationException, Exception
- {
- WebServiceEntity discoEntity = getWebServiceEntityByURI(discoURI);
- byte[] b = getInputStreamAsByteArray(discoURI);
- discoEntity.setBytes(b);
- setHTTPSettings(discoEntity);
- ByteArrayInputStream bais = new ByteArrayInputStream(b);
- DISCOParser parser = new DISCOParser();
- DISCOReference[] references = parser.parse(discoURI,new InputSource(bais));
- if (references != null && references.length > 0)
- {
- for (int i=0;i<references.length;i++)
- {
- if (references[i] instanceof DISCOContractReference)
- {
- // contractRef
- DISCOContractReference reference = (DISCOContractReference)references[i];
- String ref = reference.getRef();
- String docRef = reference.getDocRef();
- WebServiceEntity wsdlEntity = new WebServiceEntity();
- wsdlEntity.setType(WebServiceEntity.TYPE_WSDL);
- wsdlEntity.setURI(ref);
- wsdlEntity.setDocumentation(docRef);
- associate(discoEntity,wsdlEntity);
- uriToEntityTable_.put(ref,wsdlEntity);
- if ((parseOption | PARSE_WSDL) == parseOption)
- parseWSDL(ref);
- }
- else
- {
- // discoveryRef
- String ref = references[i].getRef();
- // Prevent cycles.
- WebServiceEntity discoLinkEntity = getWebServiceEntityByURI(ref);
- if (discoLinkEntity == null)
- {
- discoLinkEntity = new WebServiceEntity();
- discoLinkEntity.setType(WebServiceEntity.TYPE_DISCO);
- discoLinkEntity.setURI(ref);
- uriToEntityTable_.put(ref,discoLinkEntity);
- if ((parseOption | PARSE_LINKS) == parseOption)
- parseDISCO(ref,parseOption);
- }
- associate(discoEntity,discoLinkEntity);
- }
- }
- }
- }
-
- private Definition parseWSDL(String wsdlURI) throws WSDLException, MalformedURLException, IOException, WWWAuthenticationException
- {
- return getWSDLDefinitionVerbose(wsdlURI);
- }
-
- private byte[] getInputStreamAsByteArray(String uriString) throws MalformedURLException, IOException, WWWAuthenticationException
- {
- // Try to get a cached copy of the byte[]
- WebServiceEntity wsEntity = getWebServiceEntityByURI(uriString);
- if (wsEntity != null)
- {
- byte[] bytes = wsEntity.getBytes();
- if (bytes != null)
- return bytes;
- }
- // Get the byte[] by opening a stream to the URI
- URL url = createURL(uriString);
- URLConnection conn = url.openConnection();
- // proxy server setting
- String proxyUserName = System.getProperty("http.proxyUserName");
- String proxyPassword = System.getProperty("http.proxyPassword");
- if (proxyUserName != null && proxyPassword != null)
- {
- StringBuffer userNamePassword = new StringBuffer(proxyUserName);
- userNamePassword.append(':').append(proxyPassword);
- BASE64Encoder encoder = new BASE64Encoder();
- String encoding = encoder.encode(userNamePassword.toString().getBytes());
- userNamePassword.setLength(0);
- userNamePassword.append("Basic ").append(encoding);
- conn.setRequestProperty("Proxy-authorization", userNamePassword.toString());
- }
- // HTTP basic authentication setting
- if (httpBasicAuthUsername_ != null && httpBasicAuthPassword_ != null)
- {
- StringBuffer sb = new StringBuffer(httpBasicAuthUsername_);
- sb.append(':').append(httpBasicAuthPassword_);
- BASE64Encoder encoder = new BASE64Encoder();
- String encoding = encoder.encode(sb.toString().getBytes());
- sb.setLength(0);
- sb.append("Basic ").append(encoding);
- conn.setRequestProperty("Authorization", sb.toString());
- }
- InputStream is = null;
- try
- {
- is = conn.getInputStream();
- String wwwAuthMsg = conn.getHeaderField("WWW-Authenticate");
- if (wwwAuthMsg != null)
- throw new WWWAuthenticationException(new IOException(), wwwAuthMsg, uriString);
- }
- catch (IOException ioe)
- {
- String wwwAuthMsg = conn.getHeaderField("WWW-Authenticate");
- if (wwwAuthMsg != null)
- throw new WWWAuthenticationException(ioe, wwwAuthMsg, uriString);
- else
- throw ioe;
- }
- ByteArrayOutputStream baos = new ByteArrayOutputStream();
- byte[] b = new byte[1024];
- int byteRead = is.read(b);
- while (byteRead != -1)
- {
- baos.write(b, 0, byteRead);
- byteRead = is.read(b);
- }
- is.close();
- return baos.toByteArray();
- }
-
- protected URL createURL(String url) throws MalformedURLException
- {
- return new URL(url);
- }
-
- private void associate(WebServiceEntity parent, WebServiceEntity child)
- {
- parent.addChild(child);
- child.setParent(parent);
- }
-
- private String convertToAbsoluteURI(String baseURI,String refURI)
- {
- if (refURI != null && refURI.indexOf(":") < 0)
- {
- StringBuffer absoluteURI = new StringBuffer(baseURI.substring(0,Math.max(baseURI.lastIndexOf('\\'),baseURI.lastIndexOf('/')+1)));
- absoluteURI.append(refURI);
- return absoluteURI.toString();
- }
- return refURI;
- }
-
- private void setHTTPSettings(WebServiceEntity entity)
- {
- if (httpBasicAuthUsername_ != null && httpBasicAuthPassword_ != null)
- {
- entity.setHTTPUsername(httpBasicAuthUsername_);
- entity.setHTTPPassword(httpBasicAuthPassword_);
- }
- }
-
- public String getHTTPBasicAuthUsername()
- {
- return httpBasicAuthUsername_;
- }
-
- public void setHTTPBasicAuthUsername(String username)
- {
- httpBasicAuthUsername_ = username;
- }
-
- public String getHTTPBasicAuthPassword()
- {
- return httpBasicAuthPassword_;
- }
-
- public void setHTTPBasicAuthPassword(String password)
- {
- httpBasicAuthPassword_ = password;
- }
-}
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/wsil.properties b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/wsil.properties
deleted file mode 100644
index 1e60c01ba..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/internal/parser/wsil/wsil.properties
+++ /dev/null
@@ -1,22 +0,0 @@
-###############################################################################
-# Copyright (c) 2001,2004 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-
-#
-# Messages for AddWSDLToWSILCommand
-#
-MSG_ERROR_INVALID_ARGUMENTS=IWAB0055E Invalid command arguments.
-MSG_ERROR_ILLEGAL_ARGUMENTS=IWAB0105E Illegal argument.
-MSG_ERROR_INVALID_WSDL_URI=IWAB0185E Invalid WSDL URI.
-MSG_ERROR_INVALID_WSIL_URI=IWAB0206E Invalid WSIL URI.
-MSG_ERROR_UNRESOLVABLE_WSDL=IWAB0405E WSDL is unresolvable.
-MSG_ERROR_UNEXPECTED_EXCEPTION=IWAB0451E An unexpected exception has occured.
-MSG_ERROR_MALFORMED_WSDL=IWAB0452E WSDL is malformed, error parsing WSDL.
-MSG_ERROR_WRITE_WSIL=IWAB0453E Error writing WSIL.
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/PluginMessages.java b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/PluginMessages.java
deleted file mode 100644
index 939b0d5a6..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/PluginMessages.java
+++ /dev/null
@@ -1,18 +0,0 @@
-package org.eclipse.wst.ws.parser;
-
-import org.eclipse.osgi.util.NLS;
-
-public class PluginMessages extends NLS
-{
- private static final String BUNDLE_NAME = "org.eclipse.wst.ws.parser.plugin"; //$NON-NLS-1$
-
- static
- {
- NLS.initializeMessages(BUNDLE_NAME, PluginMessages.class);
- }
-
- public static String PUBLICUDDIREGISTRYTYPE_NAME_SAP;
- public static String PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST;
- public static String PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS;
- public static String PUBLICUDDIREGISTRYTYPE_NAME_NTTCOMM;
-} \ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/plugin.properties b/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/plugin.properties
deleted file mode 100644
index 0080e4720..000000000
--- a/bundles/org.eclipse.wst.ws.parser/src/org/eclipse/wst/ws/parser/plugin.properties
+++ /dev/null
@@ -1,18 +0,0 @@
-###############################################################################
-# Copyright (c) 2004,2005 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-
-#
-# PublicUDDIRegistryType
-#
-PUBLICUDDIREGISTRYTYPE_NAME_SAP=SAP UDDI Registry
-PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST=SAP UDDI Test Registry
-PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS=XMethods Registry
-PUBLICUDDIREGISTRYTYPE_NAME_NTTCOMM=NTT Communications Registry \ No newline at end of file

Back to the top