This commit was manufactured by cvs2svn to create tag 'R1_0_2'.
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.core/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.axis.consumption.core/META-INF/MANIFEST.MF
index e9c0420..4e118de 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.core/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.core/META-INF/MANIFEST.MF
@@ -2,14 +2,14 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.axis.consumption.core; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.axis.consumption.core.plugin.WebServiceAxisConsumptionCorePlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.axis.consumption.core;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.core.command;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.core.common;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.core.plugin;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.axis.consumption.core,
+ org.eclipse.jst.ws.internal.axis.consumption.core.command,
+ org.eclipse.jst.ws.internal.axis.consumption.core.common,
+ org.eclipse.jst.ws.internal.axis.consumption.core.plugin
Require-Bundle: org.apache.ant,
org.eclipse.core.resources,
org.eclipse.core.runtime,
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.properties b/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.properties
index f32e1c0..5e9ff7c 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.properties
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.properties
@@ -14,6 +14,3 @@
#
PLUGIN_NAME=Web service Axis Consumption Core
PLUGIN_PROVIDER=Eclipse.org
-
-xpWSDDContentType = Axis Web Service Deployment Descriptor
-
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.xml b/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.xml
index c7bcbb1..c911fbf 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.xml
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.core/plugin.xml
@@ -3,7 +3,7 @@
<plugin>
- <extension point="org.eclipse.jst.ws.consumption.wsfinder">
+ <extension point="org.eclipse.jst.ws.consumption.wsfinder">
<wsfinder
id="org.eclipse.jst.ws.internal.axis.consumption.core.wsfinder.WSFinderAxis"
name="org.eclipse.jst.ws.internal.axis.consumption.core.wsfinder.WSFinderAxis"
@@ -11,24 +11,5 @@
class="org.eclipse.jst.ws.internal.axis.consumption.core.wsfinder.WSFinderAxis">
</wsfinder>
</extension>
-
- <!-- define a wsdd file type for Axis Web Service Deployment Descriptors -->
- <extension point="org.eclipse.team.core.fileTypes">
- <fileTypes
- type="text"
- extension="wsdd">
- </fileTypes>
- </extension>
-
- <!-- define a wsdd content type for Axis Web Service Deployment Descriptors -->
- <extension point="org.eclipse.core.runtime.contentTypes">
- <content-type
- priority="high"
- name="%xpWSDDContentType"
- id="wsddsource"
- base-type="org.eclipse.core.runtime.xml"
- default-charset="UTF-8"
- file-extensions="wsdd" />
- </extension>
</plugin>
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.core/src/org/eclipse/jst/ws/internal/axis/consumption/core/command/Java2WSDLCommand.java b/bundles/org.eclipse.jst.ws.axis.consumption.core/src/org/eclipse/jst/ws/internal/axis/consumption/core/command/Java2WSDLCommand.java
index ae62c04..650f9dd 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.core/src/org/eclipse/jst/ws/internal/axis/consumption/core/command/Java2WSDLCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.core/src/org/eclipse/jst/ws/internal/axis/consumption/core/command/Java2WSDLCommand.java
@@ -6,10 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060106 121199 jesper@selskabet.org - Jesper Møller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.core.command;
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.axis.consumption.ui/META-INF/MANIFEST.MF
index 0c0a89a..0c9b929 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/META-INF/MANIFEST.MF
@@ -2,18 +2,18 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.axis.consumption.ui; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.axis.consumption.ui.plugin.WebServiceAxisConsumptionUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.axis.consumption.ui;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.command;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.task;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.util;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.widgets;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.wizard.client;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.consumption.ui.wsrt;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.axis.consumption.ui,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.command,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.plugin,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.task,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.util,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.widgets,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.wizard.client,
+ org.eclipse.jst.ws.internal.axis.consumption.ui.wsrt
Require-Bundle: org.eclipse.ui,
org.eclipse.core.resources,
org.eclipse.emf.common,
@@ -41,7 +41,6 @@
org.wsdl4j,
org.apache.axis,
org.eclipse.wst.common.frameworks,
- org.eclipse.wst.common.environment,
- com.ibm.icu
+ org.eclipse.wst.common.environment
Eclipse-AutoStart: true
Plugin-Class: org.eclipse.jst.ws.internal.axis.consumption.ui.plugin.WebServiceAxisConsumptionUIPlugin
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/AxisConsumptionUI.properties b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/AxisConsumptionUI.properties
index 83cab3b..0e6925d 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/AxisConsumptionUI.properties
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/AxisConsumptionUI.properties
@@ -1,15 +1,12 @@
###############################################################################
-# Copyright (c) 2004, 2006 IBM Corporation and others.
+# Copyright (c) 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
-# yyyymmdd bug Email and other contact information
-# -------- -------- -----------------------------------------------------------
-# 20060216 126989 pmoogk@ca.ibm.com - Peter Moogk
+# IBM Corporation - initial API and implementation
###############################################################################
#
@@ -64,8 +61,8 @@
#
# Messages for WebSerivceAxisMappingsPage
#
-PAGE_TITLE_WS_BEAN2XML=Web Service Package to Namespace Mapping
-PAGE_TITLE_WS_XML2PROXY=Web Service Client Namespace to Package Mapping
+PAGE_TITLE_WS_BEAN2XML=Web Service package to namespace mapping
+PAGE_TITLE_WS_XML2PROXY=Web Service Client namespace to package mapping
PAGE_DESC_P2N_MAPPINGS=Define custom mapping for package to namespace.
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/command/DefaultsForClientJavaWSDLCommand.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/command/DefaultsForClientJavaWSDLCommand.java
index 7881c7e..93d3f54 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/command/DefaultsForClientJavaWSDLCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/command/DefaultsForClientJavaWSDLCommand.java
@@ -1,18 +1,16 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.command;
+
import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
@@ -20,7 +18,6 @@
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
-import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Status;
import org.eclipse.jdt.core.IJavaProject;
import org.eclipse.jdt.core.JavaCore;
@@ -34,153 +31,127 @@
import org.eclipse.wst.common.environment.IEnvironment;
import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelOperation;
-public class DefaultsForClientJavaWSDLCommand extends AbstractDataModelOperation
-{
- private JavaWSDLParameter javaWSDLParam_;
- private IProject proxyProject_;
- private String WSDLServiceURL_;
- private String WSDLServicePathname_;
- private String outputFolder_;
- public DefaultsForClientJavaWSDLCommand()
- {
+public class DefaultsForClientJavaWSDLCommand extends AbstractDataModelOperation {
+
+ private JavaWSDLParameter javaWSDLParam_;
+ private IProject proxyProject_;
+ private String WSDLServiceURL_;
+ private String WSDLServicePathname_;
+
+ public DefaultsForClientJavaWSDLCommand( ) {
}
-
- public IStatus execute(IProgressMonitor monitor, IAdaptable adaptable)
+
+ public IStatus execute( IProgressMonitor monitor, IAdaptable adaptable )
{
IEnvironment environment = getEnvironment();
IStatus status;
-
- if( outputFolder_ == null )
- {
- IPath[] paths = ResourceUtils.getAllJavaSourceLocations(proxyProject_);
- outputFolder_ = paths[0].toString();
- }
-
- if (javaWSDLParam_ == null)
- {
- status = StatusUtils
- .errorStatus(AxisConsumptionCoreMessages.MSG_ERROR_JAVA_WSDL_PARAM_NOT_SET);
+ if (javaWSDLParam_ == null) {
+ status = StatusUtils.errorStatus(
+ AxisConsumptionCoreMessages.MSG_ERROR_JAVA_WSDL_PARAM_NOT_SET);
environment.getStatusHandler().reportError(status);
return status;
}
+
javaWSDLParam_.setMetaInfOnly(false);
javaWSDLParam_.setServerSide(JavaWSDLParameter.SERVER_SIDE_NONE);
- ModuleCoreNature mn = ModuleCoreNature.getModuleCoreNature(proxyProject_);
- if (mn != null)
- {
- IPath webModuleServerRoot = ResourceUtils.getJavaSourceLocation(proxyProject_);
- // String output = PlatformUtils.getPlatformURL(webModuleServerRoot);
- String output = ResourceUtils.findResource(webModuleServerRoot).getLocation().toString();
- // String output =
- // ResourceUtils.getWorkspaceRoot().getFolder(webModuleServerRoot).getLocation().toString();
- IPath javaOutput = ResourceUtils.findResource( new Path( outputFolder_ )).getLocation();
- javaWSDLParam_.setJavaOutput(javaOutput.toString());
-
+
+ ModuleCoreNature mn = ModuleCoreNature.getModuleCoreNature(proxyProject_);
+ if (mn!=null)
+ {
+ IPath webModuleServerRoot = ResourceUtils.getJavaSourceLocation(proxyProject_ );
+ //String output = PlatformUtils.getPlatformURL(webModuleServerRoot);
+ String output = ResourceUtils.findResource(webModuleServerRoot).getLocation().toString();
+// String output = ResourceUtils.getWorkspaceRoot().getFolder(webModuleServerRoot).getLocation().toString();
+ javaWSDLParam_.setJavaOutput(output);
+
+
IFolder webModuleContainer = ResourceUtils.getWebComponentServerRoot(proxyProject_);
- if (webModuleContainer != null)
+ if (webModuleContainer !=null)
{
- IPath webModulePath = webModuleContainer.getFullPath();
- // output = PlatformUtils.getPlatformURL(webModulePath);
- IResource res = ResourceUtils.findResource(webModulePath);
- if (res != null)
- {
- output = res.getLocation().toString();
- }
+ IPath webModulePath = webModuleContainer.getFullPath();
+ //output = PlatformUtils.getPlatformURL(webModulePath);
+ IResource res = ResourceUtils.findResource(webModulePath);
+ if (res!=null){
+ output = res.getLocation().toString();
+ }
+ javaWSDLParam_.setOutput(output);
+ }
+ }
+ else
+ {
+ //Check if it's a plain old Java project
+ IJavaProject javaProject = null;
+
+ javaProject = JavaCore.create(proxyProject_);
+ if (javaProject != null)
+ {
+ IPath webModuleServerRoot = ResourceUtils.getJavaSourceLocation(proxyProject_);
+ String output = ResourceUtils.findResource(webModuleServerRoot).getLocation().toString();
+ javaWSDLParam_.setJavaOutput(output);
javaWSDLParam_.setOutput(output);
- }
- }
- else
- {
- // Check if it's a plain old Java project
- IJavaProject javaProject = null;
- javaProject = JavaCore.create(proxyProject_);
- if (javaProject != null)
- {
- IPath output = ResourceUtils.findResource( new Path( outputFolder_ )).getLocation();
- javaWSDLParam_.setJavaOutput(output.toString());
- javaWSDLParam_.setOutput(output.toString());
- }
- else
- {
- // Not familiar with this kind of project
- status = StatusUtils.errorStatus(AxisConsumptionUIMessages.MSG_WARN_NO_JAVA_NATURE);
+ }
+ else
+ {
+ //Not familiar with this kind of project
+ status = StatusUtils.errorStatus( AxisConsumptionUIMessages.MSG_WARN_NO_JAVA_NATURE);
+ environment.getStatusHandler().reportError(status);
+ return status;
+
+ }
+ }
+
+
+
+ if (WSDLServicePathname_ == null) {
+
+ if (WSDLServiceURL_ == null) {
+ status = StatusUtils.errorStatus(
+ AxisConsumptionUIMessages.MSG_ERROR_WSDL_LOCATION_NOT_SET);
environment.getStatusHandler().reportError(status);
return status;
}
- }
- if (WSDLServicePathname_ == null)
- {
- if (WSDLServiceURL_ == null)
- {
- status = StatusUtils.errorStatus(AxisConsumptionUIMessages.MSG_ERROR_WSDL_LOCATION_NOT_SET);
- environment.getStatusHandler().reportError(status);
- return status;
- }
- }
- else
- {
+ } else {
WSDLServiceURL_ = PlatformUtils.getFileFromPlatform(WSDLServicePathname_);
}
+
javaWSDLParam_.setInputWsdlLocation(WSDLServiceURL_);
+
return Status.OK_STATUS;
}
/**
* Returns the javaWSDLParam.
- *
* @return JavaWSDLParameter
*/
- public JavaWSDLParameter getJavaWSDLParam()
- {
+ public JavaWSDLParameter getJavaWSDLParam() {
return javaWSDLParam_;
}
/**
* Sets the javaWSDLParam.
- *
- * @param javaWSDLParam
- * The javaWSDLParam to set
+ * @param javaWSDLParam The javaWSDLParam to set
*/
- public void setJavaWSDLParam(JavaWSDLParameter javaWSDLParam)
- {
+ public void setJavaWSDLParam(JavaWSDLParameter javaWSDLParam) {
this.javaWSDLParam_ = javaWSDLParam;
}
/**
- * @param proxyProject_
- * The proxyProject_ to set.
+ * @param proxyProject_ The proxyProject_ to set.
*/
- public void setProxyProject(IProject proxyProject)
- {
+ public void setProxyProject(IProject proxyProject) {
this.proxyProject_ = proxyProject;
}
-
/**
- * @param serviceURL_
- * The wSDLServiceURL_ to set.
+ * @param serviceURL_ The wSDLServiceURL_ to set.
*/
- public void setWSDLServiceURL(String serviceURL)
- {
+ public void setWSDLServiceURL(String serviceURL) {
WSDLServiceURL_ = serviceURL;
}
-
/**
- * @param servicePathname_
- * The wSDLServicePathname_ to set.
+ * @param servicePathname_ The wSDLServicePathname_ to set.
*/
- public void setWSDLServicePathname(String servicePathname)
- {
+ public void setWSDLServicePathname(String servicePathname) {
WSDLServicePathname_ = servicePathname;
}
-
- public String getOutputFolder()
- {
- return outputFolder_;
- }
-
- public void setOutputFolder(String outputFolder)
- {
- outputFolder_ = outputFolder;
- }
}
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanCommand.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanCommand.java
index 955e06d..68b9a78 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.task;
@@ -21,12 +18,14 @@
import java.util.List;
import java.util.Map;
import java.util.Vector;
+
import javax.wsdl.Definition;
import javax.wsdl.Port;
import javax.wsdl.PortType;
import javax.wsdl.Service;
import javax.wsdl.extensions.soap.SOAPAddress;
import javax.xml.namespace.QName;
+
import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IAdaptable;
@@ -52,7 +51,6 @@
private String discoveredWsdlPortElementName;
private Vector portTypes_;
private String proxyBean_;
- private String outputFolder_;
private IProject clientProject_;
@@ -152,7 +150,6 @@
portTypes_.add(portTypeID.toString());
Stub2BeanInfo stub2BeanInfo = new Stub2BeanInfo();
stub2BeanInfo.setClientProject(clientProject_);
- stub2BeanInfo.setOutputFolder( outputFolder_ );
String portTypePkgName = NameMappingUtils.getPackageName(portType.getQName().getNamespaceURI(), pkg2nsMapping);
String portTypeClassName = computeClassName(portTypeQName.getLocalPart());
stub2BeanInfo.setPackage(portTypePkgName);
@@ -240,9 +237,4 @@
public String getProxyBean() {
return proxyBean_;
}
-
- public void setOutputFolder( String outputFolder )
- {
- outputFolder_ = outputFolder;
- }
}
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanInfo.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanInfo.java
index 8561175..a48da86 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanInfo.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/task/Stub2BeanInfo.java
@@ -1,16 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.task;
@@ -21,22 +17,28 @@
import java.io.Writer;
import java.util.Iterator;
import java.util.List;
+import java.util.StringTokenizer;
import java.util.Vector;
+
+import org.eclipse.core.resources.IFolder;
import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.Path;
+import org.eclipse.jdt.core.JavaCore;
import org.eclipse.jem.java.JavaClass;
import org.eclipse.jem.java.JavaHelpers;
import org.eclipse.jem.java.JavaParameter;
import org.eclipse.jem.java.JavaVisibilityKind;
import org.eclipse.jem.java.Method;
import org.eclipse.jst.ws.internal.common.JavaMOFUtils;
+import org.eclipse.jst.ws.internal.common.ResourceUtils;
import org.eclipse.jst.ws.internal.plugin.WebServicePlugin;
import org.eclipse.wst.command.internal.env.common.FileResourceUtils;
+import org.eclipse.wst.common.componentcore.ModuleCoreNature;
import org.eclipse.wst.common.environment.IStatusHandler;
-import com.ibm.icu.util.StringTokenizer;
public class Stub2BeanInfo
{
@@ -54,7 +56,6 @@
private Vector usedNames;
private IProject clientProject_;
- private String outputFolder_;
public Stub2BeanInfo()
{
@@ -73,11 +74,6 @@
this.clientProject_ = clientProject;
}
- public void setOutputFolder( String outputFolder )
- {
- outputFolder_ = outputFolder;
- }
-
public void setPackage(String pkgName)
{
package_ = pkgName;
@@ -173,10 +169,35 @@
sb.append(".java");
ByteArrayInputStream bais = new ByteArrayInputStream(bytes);
-
- IPath newFilePath = new Path(outputFolder_).append( sb.toString() );
-
- FileResourceUtils.createFile(WebServicePlugin.getInstance().getResourceContext(), newFilePath, bais, progressMonitor, statusMonitor);
+ IPath sourceFolderPath = null;
+ IPath filePath = null;
+ ModuleCoreNature mn = ModuleCoreNature.getModuleCoreNature(clientProject_);
+ if (mn!=null)
+ {
+ sourceFolderPath = ResourceUtils.getJavaSourceLocation(clientProject_);
+ IFolder sourceFolder = (IFolder)ResourceUtils.findResource(sourceFolderPath);
+ filePath = sourceFolder.getFile(new Path(sb.toString())).getFullPath();
+ }
+ else
+ {
+ // It's a plain old Java project
+ JavaCore.create(clientProject_);
+
+ sourceFolderPath = ResourceUtils.getJavaSourceLocation(clientProject_);
+ IResource sourceFolderResource = ResourceUtils.findResource(sourceFolderPath);
+ if (sourceFolderResource instanceof IFolder)
+ {
+ IFolder sourceFolder = (IFolder) sourceFolderResource;
+ filePath = sourceFolder.getFile(new Path(sb.toString())).getFullPath();
+ } else
+ {
+ // The source must be going directly in the project
+ filePath = clientProject_.getFile(new Path(sb.toString())).getFullPath();
+ }
+
+ }
+
+ FileResourceUtils.createFile(WebServicePlugin.getInstance().getResourceContext(), filePath, bais, progressMonitor, statusMonitor);
}
private void writePackage(Writer w) throws IOException
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/util/WSDLUtils.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/util/WSDLUtils.java
index 3cb3670..8f1a0da 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/util/WSDLUtils.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/util/WSDLUtils.java
@@ -1,23 +1,22 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.util;
+import java.text.Collator;
import java.util.Arrays;
import java.util.Iterator;
import java.util.Locale;
import java.util.Map;
+import java.util.StringTokenizer;
import javax.wsdl.Binding;
import javax.wsdl.Definition;
import javax.wsdl.Port;
@@ -29,8 +28,6 @@
import javax.xml.namespace.QName;
import org.apache.axis.wsdl.toJava.Utils;
import org.eclipse.wst.wsdl.internal.impl.wsdl4j.WSDLFactoryImpl;
-import com.ibm.icu.text.Collator;
-import com.ibm.icu.util.StringTokenizer;
public class WSDLUtils {
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/widgets/AxisProxyWidget.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/widgets/AxisProxyWidget.java
index bc08bf1..fd7e076 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/widgets/AxisProxyWidget.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/widgets/AxisProxyWidget.java
@@ -1,30 +1,24 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.widgets;
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.IPath;
import org.eclipse.jst.ws.internal.axis.consumption.ui.AxisConsumptionUIMessages;
-import org.eclipse.jst.ws.internal.common.ResourceUtils;
import org.eclipse.jst.ws.internal.ui.common.UIUtils;
import org.eclipse.swt.SWT;
import org.eclipse.swt.events.SelectionAdapter;
import org.eclipse.swt.events.SelectionEvent;
import org.eclipse.swt.widgets.Button;
-import org.eclipse.swt.widgets.Combo;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Listener;
+import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.PlatformUI;
import org.eclipse.wst.command.internal.env.ui.widgets.SimpleWidgetDataContributor;
import org.eclipse.wst.command.internal.env.ui.widgets.WidgetDataEvents;
@@ -37,7 +31,7 @@
/*CONTEXT_ID PWJB0001 for the WSDL to Java Bindings Page*/
private final String INFOPOP_PWJB_PAGE = "PWJB0001"; //$NON-NLS-1$
- private Combo outputFolderCombo_;
+ private Text folderText_;
/*CONTEXT_ID PWJB0003 for the Folder field of the WSDL to Java Bindings Page*/
private final String INFOPOP_PWJB_TEXT_FOLDER = "PWJB0003"; //$NON-NLS-1$
@@ -60,6 +54,7 @@
AxisConsumptionUIMessages.TOOLTIP_PWJB_CHECKBOX_GENPROXY,
INFOPOP_PWJB_CHECKBOX_GENPROXY );
genProxyCheckbox_.addListener( SWT.Selection, statusListener );
+
genProxyCheckbox_.addSelectionListener( new SelectionAdapter()
{
public void widgetSelected( SelectionEvent evt )
@@ -70,10 +65,11 @@
Composite textGroup = uiUtils.createComposite( parent, 2, 5, 0 );
- outputFolderCombo_ = uiUtils.createCombo( textGroup, AxisConsumptionUIMessages.LABEL_FOLDER_NAME,
+ folderText_ = uiUtils.createText( textGroup, AxisConsumptionUIMessages.LABEL_FOLDER_NAME,
AxisConsumptionUIMessages.TOOLTIP_PWJB_TEXT_FOLDER,
INFOPOP_PWJB_TEXT_FOLDER,
SWT.SINGLE | SWT.BORDER | SWT.READ_ONLY );
+ folderText_.addListener( SWT.Modify, statusListener );
showMappingsCheckbox_ = uiUtils.createCheckbox( parent, AxisConsumptionUIMessages.LABEL_EXPLORE_MAPPINGS_XML2BEAN,
AxisConsumptionUIMessages.TOOLTIP_N2P_SHOW_MAPPINGS,
@@ -89,30 +85,20 @@
{
boolean enabled = genProxyCheckbox_.getSelection();
- outputFolderCombo_.setEnabled( enabled );
+ folderText_.setEnabled( enabled );
showMappingsCheckbox_.setEnabled( enabled );
}
- public void setClientProject(IProject clientProject)
- {
- IPath[] paths = ResourceUtils.getAllJavaSourceLocations(clientProject);
-
- for (int i = 0; i < paths.length ; i++)
- {
- outputFolderCombo_.add(paths[i].toString());
- }
-
- if( paths.length > 0 )
- {
- outputFolderCombo_.select(0);
- }
+ public void setProxyFolder( String proxyFolder )
+ {
+ folderText_.setText( proxyFolder );
}
- public String getOutputFolder()
+ public String getProxyFolder()
{
- return outputFolderCombo_.getText();
+ return folderText_.getText();
}
-
+
public void setGenerateProxy( Boolean genProxy )
{
genProxyCheckbox_.setSelection( genProxy.booleanValue() );
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wizard/client/WebServiceClientAxisType.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wizard/client/WebServiceClientAxisType.java
index 311064c..9d85018 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wizard/client/WebServiceClientAxisType.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wizard/client/WebServiceClientAxisType.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.wizard.client;
@@ -52,12 +49,10 @@
dataRegistry.addMapping( AxisClientDefaultingCommand.class, "ProxyProjectFolder", AxisProxyWidget.class, "ProxyFolder", null );
dataRegistry.addMapping( AxisClientDefaultingCommand.class, "GenerateProxy", AxisProxyWidget.class);
dataRegistry.addMapping( AxisClientDefaultingCommand.class, "IsClientScenario", AxisProxyWidget.class);
- dataRegistry.addMapping( AxisClientDefaultingCommand.class, "ClientProject", AxisProxyWidget.class );
dataRegistry.addMapping( AxisClientDefaultingCommand.class, "JavaWSDLParam", AxisMappingsWidget.class, "JavaParameter", null);
// AxisProxyWidget
dataRegistry.addMapping( AxisProxyWidget.class, "GenerateProxy", ClientExtensionOutputCommand.class );
- dataRegistry.addMapping( AxisProxyWidget.class, "OutputFolder", DefaultsForClientJavaWSDLCommand.class );
//AxisMappingsWidget
dataRegistry.addMapping(AxisMappingsWidget.class, "JavaParameter", DefaultsForHTTPBasicAuthCommand.class, "JavaWSDLParam", null); //OK
diff --git a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wsrt/AxisWebServiceClient.java b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wsrt/AxisWebServiceClient.java
index 370160d..1970bcd 100644
--- a/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wsrt/AxisWebServiceClient.java
+++ b/bundles/org.eclipse.jst.ws.axis.consumption.ui/src/org/eclipse/jst/ws/internal/axis/consumption/ui/wsrt/AxisWebServiceClient.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 115144 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.consumption.ui.wsrt;
@@ -146,7 +143,6 @@
registry.addMapping(AxisClientDefaultingCommand.class, "JavaWSDLParam", Stub2BeanCommand.class);
registry.addMapping(AxisClientDefaultingCommand.class, "WebServicesParser", Stub2BeanCommand.class);
registry.addMapping(AxisClientDefaultingCommand.class, "ClientProject", Stub2BeanCommand.class);
- registry.addMapping(DefaultsForClientJavaWSDLCommand.class, "OutputFolder", Stub2BeanCommand.class );
// BuildProjectCommand()
registry.addMapping(AxisClientDefaultingCommand.class, "ClientProject", BuildProjectCommand.class, "Project", null);
registry.addMapping(AxisClientDefaultingCommand.class, "ForceBuild", BuildProjectCommand.class);
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.axis.creation.ui/META-INF/MANIFEST.MF
index 91ad911..8bf019e 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/META-INF/MANIFEST.MF
@@ -2,19 +2,19 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.axis.creation.ui; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.axis.creation.ui.plugin.WebServiceAxisCreationUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.axis.creation.ui;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.command;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.task;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.widgets.bean;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.widgets.skeleton;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.wizard.beans;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.wizard.wsdl;x-internal:=true,
- org.eclipse.jst.ws.internal.axis.creation.ui.wsrt;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.axis.creation.ui,
+ org.eclipse.jst.ws.internal.axis.creation.ui.command,
+ org.eclipse.jst.ws.internal.axis.creation.ui.plugin,
+ org.eclipse.jst.ws.internal.axis.creation.ui.task,
+ org.eclipse.jst.ws.internal.axis.creation.ui.widgets.bean,
+ org.eclipse.jst.ws.internal.axis.creation.ui.widgets.skeleton,
+ org.eclipse.jst.ws.internal.axis.creation.ui.wizard.beans,
+ org.eclipse.jst.ws.internal.axis.creation.ui.wizard.wsdl,
+ org.eclipse.jst.ws.internal.axis.creation.ui.wsrt
Require-Bundle: org.eclipse.ui,
org.eclipse.core.resources,
org.eclipse.emf.ecore,
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/plugin.xml b/bundles/org.eclipse.jst.ws.axis.creation.ui/plugin.xml
index 679562b..cc90895 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/plugin.xml
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/plugin.xml
@@ -44,8 +44,7 @@
<extension point="org.eclipse.jst.ws.consumption.ui.runtimes">
<runtime
id="org.eclipse.jst.ws.axis.creation.axisWebServiceRT"
- label="%LABEL_RUNTIME_AXIS_11"
- serverRequired="false"/>
+ label="%LABEL_RUNTIME_AXIS_11"/>
</extension>
<!-- define support for Axis Java bean bottom up and top-down support in web projects -->
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/AxisCreationUI.properties b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/AxisCreationUI.properties
index d6d3b83..6193c0e 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/AxisCreationUI.properties
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/AxisCreationUI.properties
@@ -1,15 +1,12 @@
###############################################################################
-# Copyright (c) 2004, 2006 IBM Corporation and others.
+# Copyright (c) 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
-# yyyymmdd bug Email and other contact information
-# -------- -------- -----------------------------------------------------------
-# 20060216 126989 pmoogk@ca.ibm.com - Peter Moogk
+# IBM Corporation - initial API and implementation
###############################################################################
#
@@ -56,8 +53,8 @@
TOOLTIP_PBCF_TEXT_WSDL_FOLDER=The folder of the WSDL file.
TOOLTIP_PBCF_TEXT_WSDL_FILE=The name of the WSDL file.
LABEL_URI=Web service URI:
-LABEL_OUTPUT_FOLDER_NAME=WSDL folder:
-LABEL_OUTPUT_FILE_NAME=WSDL file:
+LABEL_OUTPUT_FOLDER_NAME=WSDL Folder:
+LABEL_OUTPUT_FILE_NAME=WSDL File:
#
#WebServiceAxisBeanClassPage
@@ -74,10 +71,10 @@
TOOLTIP_PBME_TREE_METHODS=Java bean methods to include.
PAGE_TITLE_WSBEAN_CONFIG=Web Service Java Bean Identity
PAGE_DESC_WSBEAN_CONFIG=Configure the Java bean as a Web service.
-LABEL_STYLE_USE=Style and use
-STYLE_RPC_LITERAL=document/literal
-STYLE_DOC_LITERAL=document/literal (wrapped)
-STYLE_RPC_ENCODED=RPC/encoded
+LABEL_STYLE_USE=Style and Use
+STYLE_RPC_LITERAL=Document/ Literal
+STYLE_DOC_LITERAL=Document/ Literal (Wrapped)
+STYLE_RPC_ENCODED=RPC/ Encoded
#
# AxisCheckCompilerLevelCommand
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/DefaultsForServerJavaWSDLCommand.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/DefaultsForServerJavaWSDLCommand.java
index 0072362..c3afaf9 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/DefaultsForServerJavaWSDLCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/DefaultsForServerJavaWSDLCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.creation.ui.task;
@@ -37,7 +34,6 @@
import org.eclipse.jst.ws.internal.common.ResourceUtils;
import org.eclipse.jst.ws.internal.common.ServerUtils;
import org.eclipse.jst.ws.internal.consumption.ui.wsil.Utils;
-import org.eclipse.osgi.util.NLS;
import org.eclipse.wst.command.internal.env.core.common.StatusUtils;
import org.eclipse.wst.common.environment.IEnvironment;
import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelOperation;
@@ -113,11 +109,21 @@
IPath modulePath = serviceProject_.getFullPath();
IPath webinfPath = serviceProject_.getFullPath();
try {
- if (J2EEUtils.isWebComponent(serviceProject_)){
+ //if ( ResourceUtils.isWebProject(serviceProject_)) {
+ if (J2EEUtils.isWebComponent(serviceProject_)){
moduleServerRoot = ResourceUtils.getJavaSourceLocation(serviceProject_);
+
+ // should use ModuleCore.getSourceContainers();
+// IContainer container = ResourceUtils.getWebModuleServerRoot(serviceProject_);
+// if (container!=null) {
+// moduleServerRoot = container.getFullPath();
+// }
+
modulePath = J2EEUtils.getWebContentPath(serviceProject_);
- webinfPath = J2EEUtils.getWebInfPath( serviceProject_ );
+ webinfPath = J2EEUtils.getWebInfPath( serviceProject_ );
+
}
+
} catch (Exception e) {
status = StatusUtils.errorStatus( AxisConsumptionUIMessages.MSG_ERROR_DEFAULT_BEAN, e );
environment.getStatusHandler().reportError(status);
@@ -164,18 +170,9 @@
javaWSDLParam_.setStyle(JavaWSDLParameter.STYLE_WRAPPED);
javaWSDLParam_.setUse(JavaWSDLParameter.USE_LITERAL);
- String projectURL = null;
- if (serviceServerTypeID_ != null && serviceServerTypeID_.length()>0)
- {
- projectURL = ServerUtils.getEncodedWebComponentURL(serviceProject_, serviceServerTypeID_);
- }
- else
- {
- projectURL = "http://tempuri.org/";
- }
-
+ String projectURL = ServerUtils.getEncodedWebComponentURL(serviceProject_, serviceServerTypeID_);
if (projectURL == null) {
- status = StatusUtils.errorStatus(NLS.bind(AxisCreationUIMessages.MSG_ERROR_PROJECT_URL, new String[] {serviceProject_.getName()}));
+ status = StatusUtils.errorStatus( AxisCreationUIMessages.MSG_ERROR_PROJECT_URL);
environment.getStatusHandler().reportError(status);
return status;
}
@@ -184,8 +181,11 @@
javaWSDLParam_.setUrlLocation(serviceURL);
javaWSDLParam_.setMetaInfOnly(true);
+ // String javaOutput = PlatformUtils.getPlatformURL(moduleServerRoot);
+ // String output = PlatformUtils.getPlatformURL(modulePath);
String javaOutput = ResourceUtils.findResource(moduleServerRoot).getLocation().toString();
+// String javaOutput = ResourceUtils.getWorkspaceRoot().getFolder(moduleServerRoot).getLocation().toString();
String serviceName = javaWSDLParam_.getServiceName();
IPath outputPath = ResourceUtils.findResource(webinfPath).getLocation();
@@ -215,6 +215,13 @@
this.javaWSDLParam_ = javaWSDLParam;
}
+ // rm
+ /*
+ public void setModel(Model model) {
+ this.model_ = model;
+ }
+ */
+
public void setServiceProject(IProject serviceProject) {
this.serviceProject_ = serviceProject;
}
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/Skeleton2WSDLCommand.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/Skeleton2WSDLCommand.java
index 8c63031..020dafb 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/Skeleton2WSDLCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/Skeleton2WSDLCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.creation.ui.task;
@@ -205,17 +202,8 @@
}
if (soapAddress != null)
{
-
- String projectURL = null;
- if (serviceServerTypeID_ != null && serviceServerTypeID_.length()>0)
- {
- projectURL = ServerUtils.getEncodedWebComponentURL(serverProject, serviceServerTypeID_);
- }
- else
- {
- projectURL = "http://tempuri.org/";
- }
-
+// String projectURL = ResourceUtils.getEncodedWebProjectURL(serverProject);
+ String projectURL = ServerUtils.getEncodedWebComponentURL(serverProject, serviceServerTypeID_);
if (projectURL == null)
return StatusUtils.errorStatus( NLS.bind(AxisCreationUIMessages.MSG_ERROR_PROJECT_URL, new String[] {serverProject.toString()}));
StringBuffer serviceURL = new StringBuffer(projectURL);
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/UpdateAxisWSDDFileTask.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/UpdateAxisWSDDFileTask.java
index c0625d5..8d97532 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/UpdateAxisWSDDFileTask.java
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/task/UpdateAxisWSDDFileTask.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.creation.ui.task;
@@ -75,17 +72,8 @@
}
IProject project = serviceProject_;
-
- String projectURL = null;
- if (serviceServerTypeID_ != null && serviceServerTypeID_.length()>0)
- {
- projectURL = ServerUtils.getEncodedWebComponentURL(project, serviceServerTypeID_);
- }
- else
- {
- projectURL = "http://tempuri.org/";
- }
-
+ //String projectURL = ResourceUtils.getEncodedWebProjectURL(project);
+ String projectURL = ServerUtils.getEncodedWebComponentURL(project, serviceServerTypeID_);
if (projectURL == null) {
status = StatusUtils.errorStatus(NLS.bind(AxisCreationUIMessages.MSG_ERROR_PROJECT_URL,new String[] {project.toString()}));
environment.getStatusHandler().reportError(status);
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/bean/BeanClassWidget.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/bean/BeanClassWidget.java
new file mode 100644
index 0000000..9758e70
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/bean/BeanClassWidget.java
@@ -0,0 +1,172 @@
+/*******************************************************************************
+ * Copyright (c) 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.jst.ws.internal.axis.creation.ui.widgets.bean;
+
+import org.eclipse.core.resources.IProject;
+import org.eclipse.core.resources.IResource;
+import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.Path;
+import org.eclipse.jface.wizard.IWizardContainer;
+import org.eclipse.jface.wizard.IWizardPage;
+import org.eclipse.jst.ws.internal.common.ResourceUtils;
+import org.eclipse.jst.ws.internal.consumption.common.JavaResourceFilter;
+import org.eclipse.jst.ws.internal.consumption.ui.ConsumptionUIMessages;
+import org.eclipse.jst.ws.internal.ui.common.UIUtils;
+import org.eclipse.jst.ws.internal.ui.dialog.DialogUtils;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.events.SelectionAdapter;
+import org.eclipse.swt.events.SelectionEvent;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Listener;
+import org.eclipse.swt.widgets.Text;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.wst.command.internal.env.ui.widgets.SimpleWidgetDataContributor;
+import org.eclipse.wst.command.internal.env.ui.widgets.WidgetDataEvents;
+
+
+public class BeanClassWidget extends SimpleWidgetDataContributor
+{
+
+ private IProject serverProject_ = null;
+ private Composite parent_ = null;
+ private IWizardContainer context_ = null;
+ private JavaResourceFilter filter_ = new JavaResourceFilter();
+ private IResource initialResource_ = null;
+
+ /*CONTEXT_ID PBCL0001 for the Bean Selection Page*/
+ private String INFOPOP_PBCL_PAGE = "PBCL0001";
+
+ private Text beanClassText_;
+ /*CONTEXT_ID PBCL0002 for the Bean Selection field of the Bean Selection Page*/
+ private String INFOPOP_PBCL_TEXT_BEAN_CLASS = "PBCL0002";
+
+ private Button beanClassBrowseButton_;
+ /*CONTEXT_ID PBCL0003 for the Bean Class Browse button of the Bean Selection Page*/
+ private String INFOPOP_PBCL_BUTTON_BEAN_CLASS_BROWSE = "PBCL0003";
+
+ private Button beanResourceBrowseButton_;
+ /*CONTEXT_ID PBCL0004 for the Bean Resource Browse button of the Bean Selection Page*/
+ private String INFOPOP_PBCL_BUTTON_BEAN_RESOURCE_BROWSE = "PBCL0004";
+
+ public WidgetDataEvents addControls( Composite parent, Listener statusListener )
+ {
+ String pluginId_ = "org.eclipse.jst.ws.consumption.ui";
+ String thisPlugin = "org.eclipse.jst.ws.axis.creation.ui";
+ UIUtils uiUtils = new UIUtils( thisPlugin );
+
+ parent_ = parent;
+
+ Composite group = uiUtils.createComposite( parent, 4 );
+
+ group.setToolTipText( ConsumptionUIMessages.TOOLTIP_PBCL_PAGE );
+ PlatformUI.getWorkbench().getHelpSystem().setHelp( group, pluginId_ + "." + INFOPOP_PBCL_PAGE );
+
+ beanClassText_ = uiUtils.createText( group, ConsumptionUIMessages.LABEL_BEAN_CLASS_NAME,
+ ConsumptionUIMessages.TOOLTIP_PBCL_TEXT_BEAN_CLASS,
+ INFOPOP_PBCL_TEXT_BEAN_CLASS,
+ SWT.SINGLE | SWT.BORDER);
+
+ beanClassBrowseButton_ = uiUtils.createPushButton( group, ConsumptionUIMessages.BUTTON_BROWSE_CLASSES,
+ ConsumptionUIMessages.TOOLTIP_PBCL_BUTTON_BEAN_CLASS_BROWSE,
+ INFOPOP_PBCL_BUTTON_BEAN_CLASS_BROWSE );
+ beanClassBrowseButton_.addSelectionListener( new SelectionAdapter()
+ {
+ public void widgetSelected( SelectionEvent evt )
+ {
+ handleBrowseClasses();
+ }
+ } );
+
+ beanResourceBrowseButton_ = uiUtils.createPushButton( group, ConsumptionUIMessages.BUTTON_BROWSE_FILES,
+ ConsumptionUIMessages.TOOLTIP_PBCL_BUTTON_BEAN_RESOURCE_BROWSE,
+ INFOPOP_PBCL_BUTTON_BEAN_RESOURCE_BROWSE );
+ beanResourceBrowseButton_.addSelectionListener( new SelectionAdapter()
+ {
+ public void widgetSelected( SelectionEvent evt )
+ {
+ handleBrowseFiles();
+ }
+ } );
+
+ return this;
+ }
+
+ private void handleBrowseClasses()
+ {
+ String className = DialogUtils.browseClasses( parent_.getShell(),
+ serverProject_, context_ );
+
+ if (className!=null) beanClassText_.setText(className);
+
+ }
+
+ private void handleBrowseFiles()
+ {
+ IResource topResource = serverProject_;
+
+ if (topResource == null)
+ {
+ topResource = ResourceUtils.getWorkspaceRoot();
+ }
+
+ IResource resource
+ = DialogUtils.browseResources( parent_.getShell(),
+ topResource,
+ initialResource_,
+ filter_ );
+
+ if( resource != null )
+ {
+ IPath path = resource.getFullPath();
+ String basename = path.lastSegment();
+
+ if( basename != null && basename.length() > 0 )
+ {
+ String beanPackage = org.eclipse.jst.ws.internal.common.ResourceUtils.getJavaResourcePackageName(path);
+ String beanClass = (beanPackage == null ? basename : (beanPackage + "." + basename));
+
+ if( beanClass.toLowerCase().endsWith(".java") || beanClass.toLowerCase().endsWith(".class" ) )
+ {
+ beanClass = beanClass.substring( 0, beanClass.lastIndexOf('.') );
+ }
+
+ beanClassText_.setText(beanClass);
+ }
+ }
+ }
+
+ public void setCurrentPage( IWizardPage page )
+ {
+ context_ = page.getWizard().getContainer();
+ }
+
+ public void setBeanClassName(String beanClassName)
+ {
+ beanClassText_.setText(beanClassName);
+ }
+
+ public String getBeanClassName()
+ {
+ return beanClassText_.getText().trim();
+ }
+
+ public void setServerProjectName( String name )
+ {
+ serverProject_ = (IProject)ResourceUtils.findResource( new Path( name ).makeAbsolute() );
+ }
+
+ public void setInitialResource( IResource resource )
+ {
+ initialResource_ = resource;
+ }
+
+}
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidget.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidget.java
index 883649b..07a345b 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidget.java
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidget.java
@@ -6,10 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060106 121199 jesper@selskabet.org - Jesper Møller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.creation.ui.widgets.skeleton;
diff --git a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidgetDefaultingCommand.java b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidgetDefaultingCommand.java
index 1c6559a..5126f46 100644
--- a/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidgetDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.axis.creation.ui/src/org/eclipse/jst/ws/internal/axis/creation/ui/widgets/skeleton/SkeletonConfigWidgetDefaultingCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.axis.creation.ui.widgets.skeleton;
@@ -54,15 +51,8 @@
javaWSDLParam.setJavaOutput(javaOutput);
- String projectURL = null;
- if (serviceServerTypeID_ != null && serviceServerTypeID_.length()>0)
- {
- projectURL = ServerUtils.getEncodedWebComponentURL(serverProject, serviceServerTypeID_);
- }
- else
- {
- projectURL = "http://tempuri.org/";
- }
+
+ String projectURL = ServerUtils.getEncodedWebComponentURL(serverProject, serviceServerTypeID_);
if (projectURL == null) {
status = StatusUtils.errorStatus(NLS.bind(AxisCreationUIMessages.MSG_ERROR_PROJECT_URL, new String[] { serverProject.toString()}));
@@ -140,4 +130,4 @@
public void setServiceServerTypeID(String serviceServerTypeID) {
this.serviceServerTypeID_ = serviceServerTypeID;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.consumption.ui/META-INF/MANIFEST.MF
index a222769..c24b785 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/META-INF/MANIFEST.MF
@@ -2,33 +2,33 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.consumption.ui; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.2.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.consumption.ui.plugin.WebServiceConsumptionUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.consumption.ui;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.action;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.ant;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.command;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.command.data;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.common;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.extension;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.preferences;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.selection;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.server;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.binding;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.extensions;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.object;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.test;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.test.explorer;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.widgets.test.wssample;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.wizard;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.wsil;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.ui.wsrt;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.consumption.ui,
+ org.eclipse.jst.ws.internal.consumption.ui.action,
+ org.eclipse.jst.ws.internal.consumption.ui.ant,
+ org.eclipse.jst.ws.internal.consumption.ui.command,
+ org.eclipse.jst.ws.internal.consumption.ui.command.data,
+ org.eclipse.jst.ws.internal.consumption.ui.common,
+ org.eclipse.jst.ws.internal.consumption.ui.extension,
+ org.eclipse.jst.ws.internal.consumption.ui.plugin,
+ org.eclipse.jst.ws.internal.consumption.ui.preferences,
+ org.eclipse.jst.ws.internal.consumption.ui.selection,
+ org.eclipse.jst.ws.internal.consumption.ui.server,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.binding,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.extensions,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.object,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.test,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.test.explorer,
+ org.eclipse.jst.ws.internal.consumption.ui.widgets.test.wssample,
+ org.eclipse.jst.ws.internal.consumption.ui.wizard,
+ org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi,
+ org.eclipse.jst.ws.internal.consumption.ui.wsil,
+ org.eclipse.jst.ws.internal.consumption.ui.wsrt
Require-Bundle: org.eclipse.wst.ws.parser,
org.eclipse.wst.command.env,
org.eclipse.wst.command.env.ui,
@@ -71,7 +71,5 @@
org.eclipse.wst.common.environment,
org.eclipse.wst.common.project.facet.core,
org.eclipse.jst.server.core,
- org.eclipse.debug.core,
- com.ibm.icu,
- org.apache.xerces
+ org.eclipse.debug.core
Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/plugin.properties b/bundles/org.eclipse.jst.ws.consumption.ui/plugin.properties
index add2ab1..c15fe27 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/plugin.properties
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/plugin.properties
@@ -57,8 +57,8 @@
#
# Dialogs
#
-CHECKBOX_SHOW_GENERATE_JAVA_PROXY_DIALOG=Hide &Generate Java bean Proxy Dialog
-CHECKBOX_SHOW_PROXY2SAMPLE_DIALOG=Hide &Proxy To Sample Generation Dialog
+CHECKBOX_SHOW_GENERATE_JAVA_PROXY_DIALOG=Hide Generate Java bean Proxy Dialog
+CHECKBOX_SHOW_PROXY2SAMPLE_DIALOG=Hide Proxy To Sample Generation Dialog
TOOLTIP_PPAD_CHECKBOX_WSDL2PROXY=Hide the dialog for generating the Java bean proxy action.
TOOLTIP_PPAD_CHECKBOX_PROXY2SAMPLE=Hide the dialog for generating the sample application action.
@@ -92,6 +92,10 @@
#
# PublicUDDIRegistryType
#
+PUBLICUDDIREGISTRYTYPE_NAME_IBM=IBM UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST=IBM UDDI Test Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT=Microsoft UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST=Microsoft UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP=SAP UDDI Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST=SAP UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS=XMethods Registry
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/plugin.xml b/bundles/org.eclipse.jst.ws.consumption.ui/plugin.xml
index 83245a5..a36c4b1 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/plugin.xml
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/plugin.xml
@@ -30,6 +30,42 @@
<extension
point="org.eclipse.jst.ws.consumption.ui.publicUDDIRegistryType">
<publicUDDIRegistryType
+ name="%PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST"
+ class="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryIBMTest"
+ id="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryIBMTest">
+ </publicUDDIRegistryType>
+ </extension>
+
+ <extension
+ point="org.eclipse.jst.ws.consumption.ui.publicUDDIRegistryType">
+ <publicUDDIRegistryType
+ name="%PUBLICUDDIREGISTRYTYPE_NAME_IBM"
+ class="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryIBM"
+ id="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryIBM">
+ </publicUDDIRegistryType>
+ </extension>
+
+ <extension
+ point="org.eclipse.jst.ws.consumption.ui.publicUDDIRegistryType">
+ <publicUDDIRegistryType
+ name="%PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST"
+ class="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryMicrosoftTest"
+ id="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryMicrosoftTest">
+ </publicUDDIRegistryType>
+ </extension>
+
+ <extension
+ point="org.eclipse.jst.ws.consumption.ui.publicUDDIRegistryType">
+ <publicUDDIRegistryType
+ name="%PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT"
+ class="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryMicrosoft"
+ id="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistryMicrosoft">
+ </publicUDDIRegistryType>
+ </extension>
+
+ <extension
+ point="org.eclipse.jst.ws.consumption.ui.publicUDDIRegistryType">
+ <publicUDDIRegistryType
name="%PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST"
class="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistrySAPTest"
id="org.eclipse.jst.ws.internal.consumption.ui.wizard.uddi.PublicUDDIRegistrySAPTest">
@@ -164,7 +200,7 @@
name="%PLUGIN_IMPORT_WIZARD_NAME_WS"
icon="icons/import_ws.gif"
class="org.eclipse.wst.command.internal.env.ui.widgets.DynamicWizard"
- id="org.eclipse.jst.ws.consumption.ui.wsimport">
+ id="wsimport">
<description>
%PLUGIN_IMPORT_WIZARD_DESC_WS
</description>
@@ -177,7 +213,7 @@
iconbanner="icons/import_ws_wiz.gif"
name="%PLUGIN_IMPORT_WIZARD_NAME_WS"
class="org.eclipse.jst.ws.internal.consumption.ui.widgets.binding.ImportWSWidgetBinding"
- id="org.eclipse.jst.ws.consumption.ui.wsimport">
+ id="wsimport">
</dynamicWizard>
</extension>
@@ -187,7 +223,7 @@
name="%IMPORT_WIZARD_NAME_WSIL"
icon="icons/wsil/import_wsil.gif"
class="org.eclipse.wst.command.internal.env.ui.widgets.DynamicWizard"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
<description>
%IMPORT_WIZARD_DESC_WSIL
</description>
@@ -200,7 +236,7 @@
iconbanner="icons/wsil/import_wiz_banner_wsil.gif"
name="%IMPORT_WIZARD_NAME_WSIL"
class="org.eclipse.jst.ws.internal.consumption.ui.widgets.binding.ImportWSILWidgetBinding"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
</dynamicWizard>
</extension>
@@ -226,8 +262,8 @@
<page
name="%PREFERENCE_CATEGORY_TEST_FACILITY"
category="org.eclipse.wst.ws.internal.ui.preferences.name"
- class="org.eclipse.jst.ws.internal.ui.preferences.TestFacilityDefaultsPreferencePage"
- id="org.eclipse.jst.ws.internal.ui.preferences.TestFacilityDefaultsPreferencePage">
+ class="org.eclipse.jst.ws.internal.ui.preferences.ScenarioDefaultsPreferencePage"
+ id="org.eclipse.jst.ws.internal.ui.preferences.ScenarioDefaultsPreferencePage">
</page>
<page
@@ -317,7 +353,7 @@
label="%POPUP_GENERATE_WSIL"
class="org.eclipse.wst.command.internal.env.ui.widgets.popup.DynamicPopupWizard"
menubarPath="org.eclipse.jst.ws.atk.ui.webservice.category.popupMenu/popupActions"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
</action>
</objectContribution>
@@ -389,7 +425,7 @@
label="%POPUP_GENERATE_WSIL"
class="org.eclipse.wst.command.internal.env.ui.widgets.popup.DynamicPopupWizard"
menubarPath="additions"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
</action>
</objectContribution>
@@ -538,7 +574,7 @@
label="%POPUP_GENERATE_WSIL"
class="org.eclipse.wst.command.internal.env.ui.widgets.popup.DynamicPopupWizard"
menubarPath="additions"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
</action>
</objectContribution>
@@ -550,7 +586,7 @@
label="%POPUP_GENERATE_WSIL"
class="org.eclipse.wst.command.internal.env.ui.widgets.popup.DynamicPopupWizard"
menubarPath="additions"
- id="org.eclipse.jst.ws.consumption.ui.wsilimport">
+ id="wsilimport">
</action>
</objectContribution>
</extension>
@@ -664,13 +700,11 @@
key="InitialSelection"
operation="org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime.ClientRuntimeSelectionWidgetDefaultingCommand"
property="InitialInitialSelection"
- required="true"
transform="org.eclipse.jst.ws.internal.common.String2SelectionTransformer"/>
<map
key="InitialSelection"
operation="org.eclipse.jst.ws.internal.consumption.ui.widgets.WSDLSelectionWidgetDefaultingCommand"
property="InitialSelection"
- required="true"
transform="org.eclipse.jst.ws.internal.common.String2SelectionTransformer"/>
<map
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUI.properties b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUI.properties
index 6999a96..12bd4b1 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUI.properties
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUI.properties
@@ -6,12 +6,12 @@
# http://www.eclipse.org/legal/epl-v10.html
#
# Contributors:
-# IBM Corporation - initial API and implementation
-# yyyymmdd bug Email and other contact information
-# -------- -------- -----------------------------------------------------------
+# IBM Corporation - initial API and implementation
+# yyyymmdd bug Email and other contact information
+# -------- -------- -----------------------------------------------------------
# 20060204 124143 rsinha@ca.ibm.com - Rupam Kuehner
-# 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
-# 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+# 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
+# 20060411 136134 kathy@ca.ibm.com - Kathy Chan
###############################################################################
#
@@ -59,7 +59,7 @@
# General messages.
#
MSG_ERROR_TASK_EXCEPTED=IWAB0234E An internal error occurred. Details: {0}
-MSG_ERROR_NO_SERVER_RUNTIME=No suitable server can be found for the {0} Web service runtime. Go to Window > Preferences. Select Server > Installed Runtimes and configure a server runtime.
+MSG_ERROR_NO_SERVER_RUNTIME=No suitable server can be found for the {0} Web service runtime. Go to Window > Preferences. Select Server > Installed Runtimes and configure one of the following: {1}
#
@@ -73,7 +73,7 @@
LABEL_FOLDER_NAME=Folder:
LABEL_JSP_FOLDER_NAME=JSP folder:
LABEL_WEB_PROJECT_NAME=Web project:
-LABEL_WEBSERVICETYPE=&Web service type:
+LABEL_WEBSERVICETYPE=Web service type:
LABEL_J2EE_VERSION=J2EE version:
LABEL_NA=N/A
@@ -97,13 +97,13 @@
#
PAGE_TITLE_WS_PROJECT=Web Services
PAGE_DESC_WS_PROJECT=Review your Web service options and make any necessary changes before proceeding to the next page.
-BUTTON_START_WEB_PROJECT=&Start Web service in Web project
+BUTTON_START_WEB_PROJECT=Start Web service in Web project
#BUTTON_DEPLOY_WEB_PROJECT=Deploy Web service to a server type
-BUTTON_INSTALL_SERVICE_WEB_PROJECT=&Install Web service on server
-BUTTON_INSTALL_CLIENT_WEB_PROJECT=Install Web service &client on server (managed clients only)
+BUTTON_INSTALL_SERVICE_WEB_PROJECT=Install Web service on server
+BUTTON_INSTALL_CLIENT_WEB_PROJECT=Install Web service client on server (managed clients only)
GROUP_SCENARIO_SERVICE=Service
GROUP_SCENARIO_CLIENT=Client proxy
-LABEL_WEBSERVICECLIENTTYPE=Client &proxy type:
+LABEL_WEBSERVICECLIENTTYPE=Client proxy type:
@@ -111,8 +111,8 @@
# WebServiceRuntimeSelectionPage
PAGE_TITLE_WS_RUNTIME_SELECTION=Service Deployment Configuration
PAGE_DESC_WS_RUNTIME_SELECTION=Choose from the list of runtimes and deployment servers, or use the default settings.
-LABEL_RUNTIMES_LIST=&Web service runtime:
-LABEL_SERVERS_LIST=&Server:
+LABEL_RUNTIMES_LIST=Web service runtime:
+LABEL_SERVERS_LIST=Server:
LABEL_EDIT_BUTTON=Edit...
LABEL_SERVICE_EAR_MODULE=Service EAR module:
LABEL_CLIENT_EAR_MODULE=Client EAR module:
@@ -149,8 +149,6 @@
MSG_NO_SERVER=No server specified for the {0} scenario.
MSG_ERROR_STUB_ONLY={0} has only stub runtimes associated with it. Choose a different server or configure a non-stub runtime in the server preferences.
MSG_WARN_STUB_ONLY={0} has only stub runtimes associated with it so the server will not be created or started.
-MSG_WARN_NO_SERVICE_SERVER=No server has been selected. The Web service will not be deployed, installed, or run.
-MSG_WARN_NO_CLIENT_SERVER=No server has been selected. The Web service client will not be deployed, installed, or run.
MSG_SERVER_TARGET_MISMATCH=The project, {0}, has a server target which is not compatible with the selected server type
MSG_J2EE_MISMATCH=The project, {0}, has a different J2EE level from the selected J2EE level
@@ -192,9 +190,6 @@
MSG_CLIENT_CANNOT_ASSOCIATE=The client project, {0}, cannot be associated with the EAR, {1}. Choose an EAR with a J2EE level of {2} or higher.
MSG_SERVICE_CANNOT_ASSOCIATE=The service project, {0}, cannot be associated with the EAR, {1}. Choose an EAR with a J2EE level of {2} or higher.
-MSG_PROJECT_MUST_EXIST=No server can be found and {0} does not exist. Choose an existing project or use the preferences to configure a server runtime.
-
-
# WebServiceClientRuntimeSelectionPage
PAGE_TITLE_WS_CLIENT_RUNTIME_SELECTION=Client Environment Configuration
PAGE_DESC_WS_CLIENT_RUNTIME_SELECTION=Choose from the list of supported runtimes and servers for the client environment, or use the default settings.
@@ -235,7 +230,7 @@
#
# WebServiceProxyPage
#
-BUTTON_GENERATE_PROXY=&Generate a proxy
+BUTTON_GENERATE_PROXY=Generate a proxy
#
# WebServiceSkeletonConfigPage
@@ -259,8 +254,8 @@
#
PAGE_TITLE_WSTEST=Web Service Test Page
PAGE_DESC_WSTEST=Select a test facility
-CHECKBOX_TEST_WEBSERVICE=&Test the Web service
-CHECKBOX_MONITOR_WEBSERVICE=&Monitor the Web service
+CHECKBOX_TEST_WEBSERVICE=Test the Web service
+CHECKBOX_MONITOR_WEBSERVICE=Monitor the Web service
MSG_ERROR_UNABLE_TO_LAUNCH_WSDL_TEST=An error occurred. Unable to launch WSDL test facility.
#
@@ -303,7 +298,7 @@
PAGE_DESC_WS_PUBLISH=Do you want to publish your Web service?
PAGE_TITLE_WS_FIND=Find a Web service
PAGE_DESC_WS_FIND=Do you want to find a Web service?
-BUTTON_WS_PUBLISH=&Launch the Web Services Explorer to publish this Web service to a UDDI Registry
+BUTTON_WS_PUBLISH=Launch the Web Services Explorer to publish this Web service to a UDDI Registry
BUTTON_WS_PUBLISH_PRIVATE_UDDI=Launch the Web Services Explorer to publish this Web service to the Unit Test UDDI Registry
BUTTON_WS_FIND=Launch the Web Services Explorer to find a Web service from a UDDI Registry
BUTTON_WS_FIND_PRIVATE_UDDI=Launch the Web Services Explorer to find a Web service from the Unit Test UDDI Registry
@@ -415,6 +410,14 @@
TOOLTIP_TABLE_VALIDATE_MESSAGE=Use the Web Service Profile Compliance and Validation preference to enable or disable WSDL validation.
#
+# Table column heading for ValidationMessageViewerWidget
+#
+TABLE_COLUMN_VALIDATION_SEVERITY=Severity
+TABLE_COLUMN_VALIDATION_LINE=Line
+TABLE_COLUMN_VALIDATION_COLUMN=Column
+TABLE_COLUMN_VALIDATION_MESSAGE=Message
+
+#
# Tooltips for client.WebServiceClienTestPage
#
TOOLTIP_PWSM_PAGE=
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUIMessages.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUIMessages.java
index 3af84c9..f4fd908 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUIMessages.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ConsumptionUIMessages.java
@@ -6,12 +6,12 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124143 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
+ * 20060411 136134 kathy@ca.ibm.com - Kathy Chan
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui;
@@ -86,8 +86,6 @@
public static String MSG_NO_SERVER;
public static String MSG_ERROR_STUB_ONLY;
public static String MSG_WARN_STUB_ONLY;
- public static String MSG_WARN_NO_SERVICE_SERVER;
- public static String MSG_WARN_NO_CLIENT_SERVER;
public static String MSG_SERVER_TARGET_MISMATCH;
public static String MSG_J2EE_MISMATCH;
public static String MSG_SERVICE_PROJECT_EMPTY;
@@ -235,6 +233,10 @@
public static String TOOLTIP_PCON_BUTTON_BROWSE_WS;
public static String TOOLTIP_VALIDATE_TEXT_MESSAGE;
public static String TOOLTIP_TABLE_VALIDATE_MESSAGE;
+ public static String TABLE_COLUMN_VALIDATION_SEVERITY;
+ public static String TABLE_COLUMN_VALIDATION_LINE;
+ public static String TABLE_COLUMN_VALIDATION_COLUMN;
+ public static String TABLE_COLUMN_VALIDATION_MESSAGE;
public static String TOOLTIP_PWSM_PAGE;
public static String TOOLTIP_PWSM_CHECKBOX_TEST;
public static String TOOLTIP_PWSM_COMBOBOX_TEST;
@@ -330,10 +332,8 @@
public static String MSG_ERROR_WSDD_NOT_FOUND;
public static String MSG_CLIENT_CANNOT_ASSOCIATE;
public static String MSG_SERVICE_CANNOT_ASSOCIATE;
- public static String MSG_PROJECT_MUST_EXIST;
-
static {
NLS.initializeMessages(BUNDLE_NAME, ConsumptionUIMessages.class);
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ant/AntClientRootCommandFragment.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ant/AntClientRootCommandFragment.java
index f2c3194..12e2438 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ant/AntClientRootCommandFragment.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/ant/AntClientRootCommandFragment.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.ant;
@@ -115,7 +112,6 @@
dataRegistry.addMapping(AntDefaultingOperation.class, "ClientIdsFixed", ClientRuntimeSelectionWidgetDefaultingCommand.class);
dataRegistry.addMapping(AntDefaultingOperation.class, "StartService", PreClientDevelopCommand.class);
dataRegistry.addMapping(AntDefaultingOperation.class, "InstallClient", PreClientDevelopCommand.class);
- dataRegistry.addMapping(AntDefaultingOperation.class, "DeployClient", PreClientDevelopCommand.class);
// Map WSDLSelectionWidgetDefaultingCommand command.
dataRegistry.addMapping(WSDLSelectionWidgetDefaultingCommand.class, "GenWSIL", ClientExtensionDefaultingCommand.class);
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/AntDefaultingOperation.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/AntDefaultingOperation.java
index 480cd6c..9e0dfc0 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/AntDefaultingOperation.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/AntDefaultingOperation.java
@@ -1,16 +1,3 @@
-/*******************************************************************************
- * Copyright (c) 2006 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
- *******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.command;
import org.eclipse.core.commands.ExecutionException;
@@ -46,14 +33,4 @@
{
return false;
}
-
- public boolean getDeployService()
- {
- return true;
- }
-
- public boolean getDeployClient()
- {
- return true;
- }
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/data/ProjectName2IProjectTransformer.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/data/ProjectName2IProjectTransformer.java
index ac65f41..37c5817 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/data/ProjectName2IProjectTransformer.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/command/data/ProjectName2IProjectTransformer.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 124302 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.command.data;
@@ -20,21 +17,15 @@
{
public Object transform(Object value)
{
- if (value != null)
- {
- String project = (String) value;
- int slashIndex = project.indexOf('/');
- String projectName = project;
-
- if (slashIndex != -1)
- {
- projectName = project.substring(0, slashIndex);
- }
-
- return ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
- } else
- {
- return null;
- }
+ String project = (String)value;
+ int slashIndex = project.indexOf( '/' );
+ String projectName = project;
+
+ if( slashIndex != -1 )
+ {
+ projectName = project.substring( 0, slashIndex );
+ }
+
+ return ResourcesPlugin.getWorkspace().getRoot().getProject(projectName);
}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/common/ValidationUtils.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/common/ValidationUtils.java
index 62cf617..d7dd937 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/common/ValidationUtils.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/common/ValidationUtils.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 115834 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.common;
@@ -25,23 +22,17 @@
import javax.wsdl.Service;
import org.eclipse.core.resources.IContainer;
-import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.IResource;
import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
-import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.jem.util.emf.workbench.ProjectUtilities;
-import org.eclipse.jem.util.emf.workbench.WorkbenchResourceHelperBase;
-import org.eclipse.jst.j2ee.internal.project.J2EEProjectUtilities;
+import org.eclipse.jst.j2ee.internal.webservice.helper.WebServicesManager;
import org.eclipse.jst.j2ee.webservice.internal.WebServiceConstants;
import org.eclipse.jst.j2ee.webservice.wsdd.PortComponent;
import org.eclipse.jst.j2ee.webservice.wsdd.WSDLPort;
import org.eclipse.jst.j2ee.webservice.wsdd.WebServiceDescription;
-import org.eclipse.jst.j2ee.webservice.wsdd.WebServices;
-import org.eclipse.jst.j2ee.webservice.wsdd.WsddResource;
import org.eclipse.jst.server.core.FacetUtil;
import org.eclipse.jst.ws.internal.common.J2EEUtils;
import org.eclipse.jst.ws.internal.common.ResourceUtils;
@@ -51,9 +42,7 @@
import org.eclipse.osgi.util.NLS;
import org.eclipse.wst.command.internal.env.core.common.StatusUtils;
import org.eclipse.wst.command.internal.env.core.selection.SelectionListChoices;
-import org.eclipse.wst.common.componentcore.ComponentCore;
import org.eclipse.wst.common.componentcore.internal.util.IModuleConstants;
-import org.eclipse.wst.common.componentcore.resources.IVirtualComponent;
import org.eclipse.wst.common.project.facet.core.IFacetedProject;
import org.eclipse.wst.common.project.facet.core.IFacetedProjectTemplate;
import org.eclipse.wst.common.project.facet.core.IProjectFacet;
@@ -348,16 +337,11 @@
return false;
- //Make a list of all the wsdl-port's in webservices.xml
- if (!(wsXML instanceof IFile))
- {
- return false;
- }
-
- Resource res = WorkbenchResourceHelperBase.getResource((IFile)wsXML, true);
- WsddResource wsddRes = (WsddResource)res;
- WebServices webServices = wsddRes.getWebServices();
- Iterator wsDescs = webServices.getWebServiceDescriptions().iterator();
+ //Make a list of all the wsdl-port's in webservices.xml
+ WebServicesManager wsm = WebServicesManager.getInstance();
+ //WebServiceEditModel wsEditModel = wsm.getWSEditModel(p);
+ //WebServices ws = wsEditModel.getWebServices();
+ Iterator wsDescs = wsm.getInternalWebServicesDescriptions().iterator();
ArrayList wsdlPortList = new ArrayList();
while(wsDescs.hasNext())
{
@@ -394,51 +378,40 @@
}
/**
+ * @deprecated
*
*/
private IResource getWebServcesXML(IProject p)
{
- //Get the module root.
- IResource moduleRoot = getModuleRoot(p);
+ //
+// J2EENature nature = (J2EENature) J2EENature.getRegisteredRuntime(p);
+// if (nature == null)
+// return null;
+
+// IResource moduleRoot = nature.getModuleServerRoot();
+// IResource moduleRoot = ResourceUtils.getWebModuleServerRoot(p);
+ IResource moduleRoot = J2EEUtils.getFirstWebContentContainer(p);
if (!(moduleRoot instanceof IContainer))
return null;
- IResource webServicesXML = null;
- if (J2EEProjectUtilities.isDynamicWebProject(p))
+ IResource webServicesXML=null;
+// if (nature instanceof J2EEWebNatureRuntime)
+ if (ResourceUtils.isWebProject(p))
{
StringBuffer wsPath = new StringBuffer();
wsPath.append("WEB-INF/");
wsPath.append(WebServiceConstants.WEBSERVICE_DD_SHORT_NAME);
- webServicesXML = ((IContainer) moduleRoot).findMember(wsPath.toString());
+ webServicesXML = ((IContainer)moduleRoot).findMember(wsPath.toString());
}
- else
+ else //Must be an Application Client Module or an EJB Module
{
StringBuffer wsPath = new StringBuffer();
wsPath.append("META-INF/");
wsPath.append(WebServiceConstants.WEBSERVICE_DD_SHORT_NAME);
- webServicesXML = ((IContainer) moduleRoot).findMember(wsPath.toString());
+ webServicesXML = ((IContainer)moduleRoot).findMember(wsPath.toString());
}
- return webServicesXML;
- }
-
- private IResource getModuleRoot(IProject p)
- {
- IPath modulePath = null;
- try
- {
- IVirtualComponent vc = ComponentCore.createComponent(p);
- if (vc != null)
- {
- modulePath = vc.getRootFolder().getWorkspaceRelativePath();
- }
- }
- catch(Exception ex)
- {
-
- }
- IResource res = ResourceUtils.findResource(modulePath);
- return res;
+ return webServicesXML;
}
private ArrayList getPortNamesFromWsdl(String wsdlURL, WebServicesParser parser)
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/ClientRootFragment.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/ClientRootFragment.java
index 93a52f5..d6517aa 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/ClientRootFragment.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/ClientRootFragment.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.extension;
@@ -93,8 +92,6 @@
registry.addMapping( PreClientDevelopCommand.class, "Ear", RunClientFragment.class );
//Mappings from framework to framework commands
- registry.addMapping( PreClientDevelopCommand.class, "Context", PreClientDeployCommand.class );
-
registry.addMapping( PreClientDevelopCommand.class, "WebService", PreClientAssembleCommand.class );
registry.addMapping( PreClientDevelopCommand.class, "Project", PreClientAssembleCommand.class );
registry.addMapping( PreClientDevelopCommand.class, "Module", PreClientAssembleCommand.class );
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDeployCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDeployCommand.java
index 08f589e..28203c6 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDeployCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDeployCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.extension;
@@ -19,25 +16,11 @@
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelOperation;
-import org.eclipse.wst.ws.internal.wsrt.IContext;
public class PreClientDeployCommand extends AbstractDataModelOperation
{
- private IContext context_;
-
public IStatus execute( IProgressMonitor monitor, IAdaptable adaptable )
{
- if (context_.getDeploy())
- {
- //If and when there are framework specific deploy things to be done,
- //do them here.
- }
-
return Status.OK_STATUS;
}
-
- public void setContext(IContext context)
- {
- context_=context;
- }
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDevelopCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDevelopCommand.java
index 5c66bd3..5c4d697 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDevelopCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/extension/PreClientDevelopCommand.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.extension;
@@ -54,7 +53,6 @@
private IWebServiceClient webServiceClient_;
private String j2eeLevel_;
private ResourceContext resourceContext_;
- private boolean deploy_;
private boolean test_;
private boolean install_;
private boolean run_;
@@ -93,7 +91,7 @@
webServiceClient_ = wsrt.getWebServiceClient(wsInfo);
WebServiceScenario scenario = WebServiceScenario.CLIENT_LITERAL;
- context_ = new SimpleContext(true, true, deploy_, install_, run_, true, test_,
+ context_ = new SimpleContext(true, true, true, install_, run_, true, test_,
false, scenario, resourceContext_.isOverwriteFilesEnabled(),
resourceContext_.isCreateFoldersEnabled(), resourceContext_
.isCheckoutFilesEnabled());
@@ -214,11 +212,6 @@
{
ear_ = ear;
}
-
- public void setDeployClient(boolean deployClient)
- {
- deploy_ = deployClient;
- }
public void setInstallClient(boolean installClient)
{
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/PersistentProjectTopologyContext.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/PersistentProjectTopologyContext.java
index 5662e98..1e83b5a 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/PersistentProjectTopologyContext.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/PersistentProjectTopologyContext.java
@@ -10,15 +10,13 @@
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060202 119780 pmoogk@ca.ibm.com - Peter Moogk
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.preferences;
+import java.util.StringTokenizer;
import org.eclipse.jst.ws.internal.consumption.ui.plugin.WebServiceConsumptionUIPlugin;
import org.eclipse.wst.command.internal.env.context.PersistentContext;
-import com.ibm.icu.util.StringTokenizer;
public class PersistentProjectTopologyContext extends PersistentContext implements ProjectTopologyContext
@@ -31,18 +29,6 @@
public void load()
{
- //Load the service project types
- String[] serviceIds = ProjectTopologyDefaults.getServiceTypes();
- StringBuffer serviceSb = new StringBuffer();
- for (int i = 0; i < serviceIds.length; i++)
- {
- if (i != 0)
- serviceSb.append(" ");
- serviceSb.append(serviceIds[i]);
- }
- setDefaultStringIfNoDefault(PREFERENCE_SERVICE_TYPES, serviceSb.toString());
-
- //Load the client project types
String[] ids = ProjectTopologyDefaults.getClientTypes();
StringBuffer sb = new StringBuffer();
for (int i = 0; i < ids.length; i++)
@@ -55,36 +41,6 @@
setDefault(PREFERENCE_USE_TWO_EARS, ProjectTopologyDefaults.isUseTwoEARs());
}
- public void setServiceTypes(String[] ids)
- {
- StringBuffer sb = new StringBuffer();
- for (int i = 0; i < ids.length; i++)
- {
- if (i != 0)
- sb.append(" ");
- sb.append(ids[i]);
- }
- setValue(PREFERENCE_SERVICE_TYPES, sb.toString());
- }
-
- public String[] getServiceTypes()
- {
- StringTokenizer st = new StringTokenizer(getValueAsString(PREFERENCE_SERVICE_TYPES));
- String[] s = new String[st.countTokens()];
- for (int i = 0; i < s.length; i++)
- s[i] = st.nextToken();
- return s;
- }
-
- public String[] getDefaultServiceTypes()
- {
- StringTokenizer st = new StringTokenizer(getDefaultString(PREFERENCE_SERVICE_TYPES));
- String[] s = new String[st.countTokens()];
- for (int i = 0; i < s.length; i++)
- s[i] = st.nextToken();
- return s;
- }
-
public void setClientTypes(String[] ids)
{
StringBuffer sb = new StringBuffer();
@@ -105,15 +61,6 @@
s[i] = st.nextToken();
return s;
}
-
- public String[] getDefaultClientTypes()
- {
- StringTokenizer st = new StringTokenizer(getDefaultString(PREFERENCE_CLIENT_TYPES));
- String[] s = new String[st.countTokens()];
- for (int i = 0; i < s.length; i++)
- s[i] = st.nextToken();
- return s;
- }
public void setUseTwoEARs(boolean use)
{
@@ -126,12 +73,8 @@
public ProjectTopologyContext copy() {
TransientProjectTopologyContext context = new TransientProjectTopologyContext();
- context.setServiceTypes(getServiceTypes());
- context.setDefaultServiceTypes(getDefaultServiceTypes());
context.setClientTypes(getClientTypes());
- context.setDefaultClientTypes(getDefaultClientTypes());
context.setUseTwoEARs(isUseTwoEARs());
return context;
}
-
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyContext.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyContext.java
index cc21c4b..023ad73 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyContext.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyContext.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.preferences;
@@ -20,20 +17,14 @@
* This constant String is used to lookup the preferred order of the different client types
**/
public static final String PREFERENCE_CLIENT_TYPES = "clientTypes";
- public static final String PREFERENCE_SERVICE_TYPES = "serviceTypes";
/**
* This constant String is used to lookup the two EAR option
**/
public static final String PREFERENCE_USE_TWO_EARS = "useTwoEARs";
- public void setServiceTypes(String[] ids);
- public String[] getServiceTypes();
- public String[] getDefaultServiceTypes();
-
public void setClientTypes(String[] ids);
public String[] getClientTypes();
- public String[] getDefaultClientTypes();
public void setUseTwoEARs(boolean use);
public boolean isUseTwoEARs();
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyDefaults.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyDefaults.java
index e19e1f5..113183c 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyDefaults.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyDefaults.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.preferences;
@@ -18,12 +15,6 @@
public class ProjectTopologyDefaults
{
-
- public static final String[] getServiceTypes()
- {
- return WebServiceRuntimeExtensionUtils2.getAllServiceProjectTypes();
- }
-
public static final String[] getClientTypes()
{
return WebServiceRuntimeExtensionUtils2.getAllClientProjectTypes();
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyPreferencePage.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyPreferencePage.java
index fe3db67..d4ebe1a 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyPreferencePage.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/ProjectTopologyPreferencePage.java
@@ -1,21 +1,17 @@
/*******************************************************************************
- * Copyright (c) 2003, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.preferences;
import java.util.Vector;
-
import org.eclipse.jface.preference.PreferencePage;
import org.eclipse.jface.viewers.ColumnWeightData;
import org.eclipse.jface.viewers.IStructuredContentProvider;
@@ -35,9 +31,9 @@
import org.eclipse.swt.widgets.Button;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Group;
import org.eclipse.swt.widgets.Table;
import org.eclipse.swt.widgets.TableColumn;
+import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.IWorkbenchPreferencePage;
import org.eclipse.ui.PlatformUI;
@@ -51,11 +47,6 @@
/*CONTEXT_ID PTPP0001 for the Project Topology Preference Page*/
private String INFOPOP_PTPP_PAGE = WebServiceUIPlugin.ID + ".PPTP0001";
- private TableViewer serviceTypeViewer_;
- private Button serviceMoveUp_;
- private Button serviceMoveDown_;
- private Vector serviceTypes_;
-
private TableViewer clientTypeViewer_;
private Button moveUp_;
private Button moveDown_;
@@ -77,62 +68,17 @@
parent.setLayoutData( new GridData( GridData.FILL_HORIZONTAL ) );
PlatformUI.getWorkbench().getHelpSystem().setHelp(parent,INFOPOP_PTPP_PAGE);
- Group serviceTypeComposite = new Group( parent, SWT.NONE );
- GridLayout servicegl = new GridLayout();
- servicegl.numColumns = 2;
- servicegl.marginHeight = 0;
- servicegl.marginWidth = 0;
- serviceTypeComposite.setLayout(servicegl);
- serviceTypeComposite.setLayoutData( new GridData( GridData.FILL_HORIZONTAL ));
- serviceTypeComposite.setText(WSUIPluginMessages.LABEL_SERVICE_TYPE_NAME);
-
- Table serviceTable= new Table(serviceTypeComposite, SWT.BORDER | SWT.SINGLE | SWT.FULL_SELECTION | SWT.H_SCROLL | SWT.V_SCROLL);
- GridData servicegd = new GridData(GridData.FILL_HORIZONTAL | GridData.FILL_VERTICAL);
- servicegd.widthHint = 256;
- serviceTable.setLayoutData(servicegd);
- serviceTable.setToolTipText(WSUIPluginMessages.TOOLTIP_SERVICE_TYPE_TABLE_VIEWER);
+ Text clientTypeLabel = new Text(parent, SWT.READ_ONLY | SWT.WRAP);
+ clientTypeLabel.setText(WSUIPluginMessages.LABEL_CLIENT_TYPE_NAME);
+ clientTypeLabel.setLayoutData( new GridData( GridData.FILL_HORIZONTAL));
- serviceTypes_ = new Vector();
- serviceTypeViewer_ = new TableViewer(serviceTable);
- serviceTypeViewer_.setContentProvider(new ClientTypeContentProvider());
- serviceTypeViewer_.setLabelProvider(new ClientTypeLabelProvider());
- serviceTypeViewer_.setInput(serviceTypes_);
-
- TableLayout serviceTableLayout = new TableLayout();
- TableColumn serviceTableColumn = new TableColumn(serviceTable, SWT.NONE);
- serviceTableColumn.setText(WSUIPluginMessages.LABEL_SERVICE_TYPE_NAME);
- ColumnWeightData serviceColumnData = new ColumnWeightData(256, 256, false);
- serviceTableLayout.addColumnData(serviceColumnData);
- serviceTable.setLayout(serviceTableLayout);
-
- Composite servicec = new Composite(serviceTypeComposite, SWT.NONE);
- servicegl = new GridLayout();
- servicegl.numColumns = 1;
- servicegl.marginHeight = 10;
- servicegl.marginWidth = 0;
- servicec.setLayout(servicegl);
-
- serviceMoveUp_ = new Button(servicec, SWT.PUSH);
- serviceMoveUp_.setText(WSUIPluginMessages.LABEL_MOVE_UP);
- serviceMoveUp_.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
- serviceMoveUp_.addSelectionListener(this);
- serviceMoveUp_.setToolTipText(WSUIPluginMessages.TOOLTIP_MOVE_UP);
-
- serviceMoveDown_ = new Button(servicec, SWT.PUSH);
- serviceMoveDown_.setText(WSUIPluginMessages.LABEL_MOVE_DOWN);
- serviceMoveDown_.setLayoutData(new GridData(GridData.HORIZONTAL_ALIGN_FILL));
- serviceMoveDown_.addSelectionListener(this);
- serviceMoveDown_.setToolTipText(WSUIPluginMessages.TOOLTIP_MOVE_DOWN);
-
-
- Group clientTypeComposite = new Group( parent, SWT.NONE );
+ Composite clientTypeComposite = new Composite(parent, SWT.NONE);
GridLayout gl = new GridLayout();
gl.numColumns = 2;
gl.marginHeight = 0;
gl.marginWidth = 0;
clientTypeComposite.setLayout(gl);
clientTypeComposite.setLayoutData( new GridData( GridData.FILL_HORIZONTAL ));
- clientTypeComposite.setText(WSUIPluginMessages.LABEL_CLIENT_TYPE_NAME);
Table table= new Table(clientTypeComposite, SWT.BORDER | SWT.SINGLE | SWT.FULL_SELECTION | SWT.H_SCROLL | SWT.V_SCROLL);
GridData gd = new GridData(GridData.FILL_HORIZONTAL | GridData.FILL_VERTICAL);
@@ -211,48 +157,20 @@
*/
public void init(IWorkbench workbench) { }
-
- /**
- * Adds the String elements of array a into Vector v. If String array b contains any elements
- * that are not already in array a, appends these elements from array b to the end of Vector v.
- * @param a a String array
- * @param b a String array
- * @param v a non-null Vector
- */
- private void setVectorContentsFromTwoArrays(String[] a, String[] b, Vector v)
- {
- for (int i = 0; i < a.length; i++)
- {
- v.add(a[i]);
- }
-
- for (int i = 0; i < b.length; i++)
- {
- if (v.indexOf(b[i]) == -1)
- {
- v.add(b[i]);
- }
- }
- }
-
/**
* Initializes states of the controls to their burned-in defaults.
*/
private void initializeDefaults()
{
- ProjectTopologyContext context = WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- serviceTypes_.clear();
- String[] defaultServiceTypes = context.getDefaultServiceTypes();
- String[] allServiceTypes = ProjectTopologyDefaults.getServiceTypes();
- setVectorContentsFromTwoArrays(defaultServiceTypes, allServiceTypes, serviceTypes_);
- serviceTypeViewer_.refresh();
-
clientTypes_.clear();
- String[] defaultClientTypes = context.getDefaultClientTypes();
- String[] allClientTypes = ProjectTopologyDefaults.getClientTypes();
- setVectorContentsFromTwoArrays(defaultClientTypes, allClientTypes, clientTypes_);
- clientTypeViewer_.refresh();
+ String[] types = ProjectTopologyDefaults.getClientTypes();
+ for (int i = 0; i < types.length; i++)
+ {
+ clientTypes_.add(types[i]);
+ }
+
+ clientTypeViewer_.refresh();
twoEAR_.setSelection(true);
}
@@ -261,35 +179,29 @@
*/
private void initializeValues()
{
- //Initial service project types.
ProjectTopologyContext context = WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- String[] serviceTypesFromContext = context.getServiceTypes();
- String[] allServiceTypes = ProjectTopologyDefaults.getServiceTypes();
- setVectorContentsFromTwoArrays(serviceTypesFromContext, allServiceTypes, serviceTypes_);
- if (allServiceTypes.length > serviceTypesFromContext.length)
+ String[] types = context.getClientTypes();
+ for (int i = 0; i < types.length; i++)
+ clientTypes_.add(types[i]);
+ // check whether we missed any types from the default list
+ boolean missed = false;
+ types = ProjectTopologyDefaults.getClientTypes();
+ for (int i = 0; i < types.length; i++)
{
- String[] serviceTypesArray = new String[serviceTypes_.size()];
- serviceTypes_.copyInto(serviceTypesArray);
- context.setServiceTypes(serviceTypesArray);
+ if (clientTypes_.indexOf(types[i]) == -1)
+ {
+ clientTypes_.add(types[i]);
+ missed = true;
+ }
}
- // refresh viewer
- serviceTypeViewer_.refresh();
-
-
- //Initialize client project types.
- String[] clientTypesFromContext = context.getClientTypes();
- String[] allClientTypes = ProjectTopologyDefaults.getClientTypes();
- setVectorContentsFromTwoArrays(clientTypesFromContext, allClientTypes, clientTypes_);
- if (allClientTypes.length > clientTypesFromContext.length)
+ if (missed)
{
- String[] clientTypesArray = new String[clientTypes_.size()];
- clientTypes_.copyInto(clientTypesArray);
- context.setClientTypes(clientTypesArray);
+ types = new String[clientTypes_.size()];
+ clientTypes_.copyInto(types);
+ context.setClientTypes(types);
}
-
// refresh viewer
clientTypeViewer_.refresh();
-
twoEAR_.setSelection(context.isUseTwoEARs());
}
@@ -299,9 +211,6 @@
private void storeValues()
{
ProjectTopologyContext context = WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- String[] serviceTypesArray = new String[serviceTypes_.size()];
- serviceTypes_.copyInto(serviceTypesArray);
- context.setServiceTypes(serviceTypesArray);
String[] types = new String[clientTypes_.size()];
clientTypes_.copyInto(types);
context.setClientTypes(types);
@@ -314,41 +223,20 @@
public void widgetSelected(SelectionEvent e)
{
- if (e.widget == serviceMoveUp_ || e.widget == serviceMoveDown_)
+ int index = clientTypeViewer_.getTable().getSelectionIndex();
+ if (index != -1)
{
- int index = serviceTypeViewer_.getTable().getSelectionIndex();
- if (index != -1)
+ if (e.widget == moveUp_ && index > 0)
{
- if (e.widget == serviceMoveUp_ && index > 0)
- {
- Object object = serviceTypes_.remove(index);
- serviceTypes_.insertElementAt(object, index-1);
- serviceTypeViewer_.refresh();
- }
- else if (e.widget == serviceMoveDown_ && index < serviceTypes_.size()-1)
- {
- Object object = serviceTypes_.remove(index);
- serviceTypes_.insertElementAt(object, index+1);
- serviceTypeViewer_.refresh();
- }
+ Object object = clientTypes_.remove(index);
+ clientTypes_.insertElementAt(object, index-1);
+ clientTypeViewer_.refresh();
}
- }
- else if (e.widget == moveUp_ || e.widget == moveDown_)
- {
- int index = clientTypeViewer_.getTable().getSelectionIndex();
- if (index != -1)
+ else if (e.widget == moveDown_ && index < clientTypes_.size()-1)
{
- if (e.widget == moveUp_ && index > 0)
- {
- Object object = clientTypes_.remove(index);
- clientTypes_.insertElementAt(object, index - 1);
- clientTypeViewer_.refresh();
- } else if (e.widget == moveDown_ && index < clientTypes_.size() - 1)
- {
- Object object = clientTypes_.remove(index);
- clientTypes_.insertElementAt(object, index + 1);
- clientTypeViewer_.refresh();
- }
+ Object object = clientTypes_.remove(index);
+ clientTypes_.insertElementAt(object, index+1);
+ clientTypeViewer_.refresh();
}
}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/TransientProjectTopologyContext.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/TransientProjectTopologyContext.java
index 1102733..0737788 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/TransientProjectTopologyContext.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/preferences/TransientProjectTopologyContext.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.preferences;
@@ -17,25 +14,11 @@
public class TransientProjectTopologyContext implements ProjectTopologyContext
{
- private String[] serviceTypes;
- private String[] defaultServiceTypes;
-
private String[] clientTypes;
- private String[] defaultClientTypes;
-
private boolean twoEARs;
public TransientProjectTopologyContext () {}
- public void setServiceTypes(String[] serviceTypes)
- {
- this.serviceTypes = serviceTypes;
- }
- public String[] getServiceTypes()
- {
- return serviceTypes;
- }
-
public void setClientTypes(String[] clientTypes)
{
this.clientTypes = clientTypes;
@@ -56,35 +39,8 @@
public ProjectTopologyContext copy() {
TransientProjectTopologyContext context = new TransientProjectTopologyContext();
- context.setServiceTypes(getServiceTypes());
- context.setDefaultServiceTypes(getDefaultServiceTypes());
context.setClientTypes(getClientTypes());
- context.setDefaultClientTypes(getDefaultClientTypes());
context.setUseTwoEARs(isUseTwoEARs());
return context;
}
-
-
-public void setDefaultServiceTypes(String[] defaultServiceTypes)
-{
- this.defaultServiceTypes = defaultServiceTypes;
-}
-
-public String[] getDefaultServiceTypes()
-{
- return defaultServiceTypes;
-
-}
-
-
-public void setDefaultClientTypes(String[] defaultClientTypes)
-{
- this.defaultClientTypes = defaultClientTypes;
-}
-
-public String[] getDefaultClientTypes()
-{
- return defaultClientTypes;
-
-}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/ClientWizardWidgetDefaultingCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/ClientWizardWidgetDefaultingCommand.java
index 73caf2e..f71c986 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/ClientWizardWidgetDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/ClientWizardWidgetDefaultingCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets;
@@ -65,12 +62,7 @@
//String runtime = registry.getAllClientRuntimes()[0];
String runtime = WebServiceRuntimeExtensionUtils2.getAllRuntimesForClientSide()[0];
//String server = registry.getAllClientServerFactoryIds()[0];
- String[] servers = WebServiceRuntimeExtensionUtils2.getAllClientServerFactoryIds();
- String server = null;
- if (servers != null && servers.length>0)
- {
- server = servers[0];
- }
+ String server = WebServiceRuntimeExtensionUtils2.getAllClientServerFactoryIds()[0];
TypeRuntimeServer result = new TypeRuntimeServer();
// rskreg
@@ -85,4 +77,4 @@
{
return Status.OK_STATUS;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/binding/ClientWidgetBinding.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/binding/ClientWidgetBinding.java
index b0b14b3..bc2eada 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/binding/ClientWidgetBinding.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/binding/ClientWidgetBinding.java
@@ -1,18 +1,16 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
* 20060204 121605 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060223 129020 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.binding;
@@ -114,7 +112,7 @@
//dataRegistry.addMapping(ClientRuntimeSelectionWidgetDefaultingCommand.class, "Runtime2ClientTypes", ClientRuntimeSelectionWidget.class);
//dataRegistry.addMapping(ClientRuntimeSelectionWidgetDefaultingCommand.class, "ClientComponentName", ClientRuntimeSelectionWidget.class);
//dataRegistry.addMapping(ClientRuntimeSelectionWidgetDefaultingCommand.class, "ClientEarComponentName", ClientRuntimeSelectionWidget.class);
- dataRegistry.addMapping(ClientRuntimeSelectionWidgetDefaultingCommand.class, "ClientNeedEAR", ClientRuntimeSelectionWidget.class);
+ dataRegistry.addMapping(ClientRuntimeSelectionWidgetDefaultingCommand.class, "ClientNeedEAR", ClientRuntimeSelectionWidget.class,"NeedEAR",null);
// After ClientRuntimeSelectionWidget
dataRegistry.addMapping(ClientRuntimeSelectionWidget.class, "ClientTypeRuntimeServer", ClientExtensionDefaultingCommand.class);
@@ -313,7 +311,6 @@
dataRegistry.addMapping(WSDLSelectionOutputCommand.class, "WebServicesParser", CheckForServiceProjectCommand.class);
// Setup the PreClientDevelopCommand.
- dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "DeployClient", PreClientDevelopCommand.class);
dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "InstallClient", PreClientDevelopCommand.class);
//Always start the client if it is installed.
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ClientExtensionDefaultingCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ClientExtensionDefaultingCommand.java
index 80fcd73..536ddb9 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ClientExtensionDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ClientExtensionDefaultingCommand.java
@@ -1,29 +1,25 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.extensions;
import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
-import org.eclipse.jem.util.emf.workbench.ProjectUtilities;
import org.eclipse.jst.ws.internal.common.ServerUtils;
import org.eclipse.jst.ws.internal.consumption.ui.ConsumptionUIMessages;
-import org.eclipse.jst.ws.internal.consumption.ui.wsrt.RuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.osgi.util.NLS;
@@ -42,7 +38,6 @@
private TypeRuntimeServer clientIds_;
private String clientRuntimeId_;
private Boolean testService;
- private Boolean deployClient;
private Boolean installClient;
private ResourceContext resourceContext;
@@ -285,14 +280,6 @@
}
/**
- * @return Returns the deployService.
- */
- public Boolean getDeployClient()
- {
- return deployClient;
- }
-
- /**
* @return Returns the installClient.
*/
public Boolean getInstallClient()
@@ -482,11 +469,6 @@
//when the user clicks Finish prior to page 3 of the wizard.
IStatus status = Status.OK_STATUS;
-
- //default deployClient to true. It will get set to false later if there is no
- //server type selected.
- deployClient = Boolean.TRUE;
-
String scenario = ConsumptionUIMessages.MSG_CLIENT_SUB;
//Ensure server and runtime are non-null
@@ -502,60 +484,30 @@
if( serverId == null || serverId.length()==0)
{
- //Popup and error if the selected client project does not exist.
- IProject clientProject = ProjectUtilities.getProject(clientProjectName_);
- if (!clientProject.exists())
- {
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[]{runtimeLabel } ) );
- env.getStatusHandler().reportError(status);
- }
- else
- {
- RuntimeDescriptor desc = WebServiceRuntimeExtensionUtils2.getRuntimeById(runtimeId);
-
- if (desc.getServerRequired())
- {
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[] { scenario }));
- env.getStatusHandler().reportError(status);
- }
- else
- {
- // No server has been selected and the selected Web service runtime
- // does not
- // require a server. Set deploy, install, run, and test to false.
- deployClient = Boolean.FALSE;
- installClient = Boolean.FALSE;
- testService = Boolean.FALSE;
- }
- }
+ status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[]{ scenario } ) );
+ env.getStatusHandler().reportError(status);
}
- //If the server is non-null, ensure the server, runtime, and type are compatible
- if (serverId != null && serverId.length() > 0)
+ //ensure the server, runtime, and type are compatible
+ if (!WebServiceRuntimeExtensionUtils2.isServerClientRuntimeTypeSupported(serverId, runtimeId, typeId))
+ {
+ String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverId);
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_INVALID_SRT_SELECTIONS, new String[]{ serverLabel, runtimeLabel } ) );
+ env.getStatusHandler().reportError(status);
+ }
+
+ //Determine if the selected server type has only stub runtimes associated with it.
+ //If so, set install and test to false in the context.
+ IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverId);
+ if (nonStubRuntime == null)
{
- if (!WebServiceRuntimeExtensionUtils2.isServerClientRuntimeTypeSupported(serverId, runtimeId, typeId))
- {
- String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverId);
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_INVALID_SRT_SELECTIONS, new String[] { serverLabel,
- runtimeLabel }));
- env.getStatusHandler().reportError(status);
- }
-
- // Determine if the selected server type has only stub runtimes associated
- // with it.
- // If so, set install and test to false in the context.
- IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverId);
- if (nonStubRuntime == null)
- {
- installClient = Boolean.FALSE;
- testService = Boolean.FALSE;
- }
+ installClient = Boolean.FALSE;
+ testService = Boolean.FALSE;
}
return status;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ServerExtensionDefaultingCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ServerExtensionDefaultingCommand.java
index 34beebf..e30ae4f 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ServerExtensionDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/extensions/ServerExtensionDefaultingCommand.java
@@ -1,29 +1,25 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.extensions;
import org.eclipse.core.commands.ExecutionException;
-import org.eclipse.core.resources.IProject;
import org.eclipse.core.runtime.IAdaptable;
import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
-import org.eclipse.jem.util.emf.workbench.ProjectUtilities;
import org.eclipse.jst.ws.internal.common.ServerUtils;
import org.eclipse.jst.ws.internal.consumption.ui.ConsumptionUIMessages;
-import org.eclipse.jst.ws.internal.consumption.ui.wsrt.RuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.osgi.util.NLS;
@@ -37,7 +33,6 @@
public class ServerExtensionDefaultingCommand extends AbstractDataModelOperation
{
- private Boolean deployService;
private Boolean installService;
private Boolean startService;
private Boolean testService;
@@ -176,14 +171,6 @@
}
/**
- * @return Returns the deployService.
- */
- public Boolean getDeployService()
- {
- return deployService;
- }
-
- /**
* @return Returns the installService.
*/
public Boolean getInstallService()
@@ -309,11 +296,6 @@
//when the user clicks Finish prior to page 3 of the wizard.
IStatus status = Status.OK_STATUS;
-
- //default deployService to true. It will get set to false later if there is no
- //server type selected.
- deployService = Boolean.TRUE;
-
String scenario = ConsumptionUIMessages.MSG_SERVICE_SUB;
//Ensure server and runtime are non-null
@@ -329,59 +311,28 @@
if( serverId == null || serverId.length()==0)
{
- //Popup and error if the selected service project does not exist.
- IProject serviceProject = ProjectUtilities.getProject(serviceProjectName_);
- if (!serviceProject.exists())
- {
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[]{ runtimeLabel } ) );
- env.getStatusHandler().reportError(status);
- }
- else
- {
-
- RuntimeDescriptor desc = WebServiceRuntimeExtensionUtils2.getRuntimeById(runtimeId);
- if (desc.getServerRequired())
- {
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[] { scenario }));
- env.getStatusHandler().reportError(status);
- }
- else
- {
- // No server has been selected and the selected Web service runtime
- // does not require a server. Set deploy, install, run, and test to false.
- deployService = Boolean.FALSE;
- installService = Boolean.FALSE;
- startService = Boolean.FALSE;
- testService = Boolean.FALSE;
- }
- }
+ status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[]{ scenario } ) );
+ env.getStatusHandler().reportError(status);
}
- //If the server is non-null, ensure the server, runtime, and type are compatible
- if (serverId != null && serverId.length() > 0)
+ //ensure the server, runtime, and type are compatible
+ if (!WebServiceRuntimeExtensionUtils2.isServerRuntimeTypeSupported(serverId, runtimeId, typeId))
+ {
+ String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverId);
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_INVALID_SRT_SELECTIONS, new String[]{ serverLabel, runtimeLabel } ) );
+ env.getStatusHandler().reportError(status);
+ }
+
+ //Determine if the selected server type has only stub runtimes associated with it.
+ //If so, set install, run, and test to false in the context.
+ IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverId);
+ if (nonStubRuntime == null)
{
- if (!WebServiceRuntimeExtensionUtils2.isServerRuntimeTypeSupported(serverId, runtimeId, typeId))
- {
- String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverId);
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
- status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_INVALID_SRT_SELECTIONS, new String[] { serverLabel,
- runtimeLabel }));
- env.getStatusHandler().reportError(status);
- }
-
- // Determine if the selected server type has only stub runtimes associated
- // with it.
- // If so, set install, run, and test to false in the context.
- IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverId);
- if (nonStubRuntime == null)
- {
- installService = Boolean.FALSE;
- startService = Boolean.FALSE;
- testService = Boolean.FALSE;
- }
+ installService = Boolean.FALSE;
+ startService = Boolean.FALSE;
+ testService = Boolean.FALSE;
}
-
return status;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ObjectSelectionWidget.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ObjectSelectionWidget.java
index 578c502..25a07a0 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ObjectSelectionWidget.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ObjectSelectionWidget.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060224 129387 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.object;
@@ -25,7 +22,6 @@
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Point;
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
@@ -98,6 +94,7 @@
if (object instanceof IObjectSelectionWidget)
{
Control shell = parent.getShell();
+ int x = shell.getSize().x;
composite = new Composite(parent, SWT.NONE);
GridLayout gl = new GridLayout();
gl.marginHeight = 0;
@@ -108,32 +105,9 @@
child = (IObjectSelectionWidget)object;
child.addControls(composite, statusListener);
child.setInitialSelection(initialSelection);
-
- Point origSize = shell.getSize();
- Point compSize = composite.computeSize(SWT.DEFAULT, SWT.DEFAULT);
- int newX = origSize.x;
- int newY = origSize.y;
-
- // Note: we are trying to determine here if the wizard page should
- // be resized based on the size of the control that is
- // given to us by the extension. The hard coded constants
- // below represent the vertical and horizontal pixels that need
- // to go around object selection control. Hopefully, a more
- // programatic method of doing this can be found in the future.
- if( compSize.x + 20 > origSize.x )
- {
- newX = compSize.x + 20;
- }
-
- if( compSize.y + 205 > origSize.y )
- {
- newY = compSize.y + 205;
- }
-
- composite.setSize(newX - 20, newY - 205 );
- parent.setSize(newX - 10, newY - 195 );
- shell.setSize(newX, newY);
-
+ composite.setSize(x-20, composite.computeSize(SWT.DEFAULT, SWT.DEFAULT).y);
+ parent.setSize(x-10, parent.computeSize(SWT.DEFAULT, SWT.DEFAULT).y);
+ shell.setSize(x, shell.computeSize(SWT.DEFAULT, SWT.DEFAULT).y);
shell.setRedraw(true);
shell.redraw();
shell.update();
@@ -256,4 +230,4 @@
}
return null;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ValidationMessageViewerWidget.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ValidationMessageViewerWidget.java
index bc54f59..5770d55 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ValidationMessageViewerWidget.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/object/ValidationMessageViewerWidget.java
@@ -4,12 +4,12 @@
* 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
- * yyyymmdd bug Email and other contact information
+ * IBM Corporation - initial API and implementation
+ *yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
- * 20060310 131352 pmoogk@ca.ibm.com - Peter Moogk
+ * 20060411 136134 kathy@ca.ibm.com - Kathy Chan
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.object;
@@ -29,11 +29,11 @@
import org.eclipse.swt.layout.GridData;
import org.eclipse.swt.layout.GridLayout;
import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Listener;
import org.eclipse.swt.widgets.Table;
import org.eclipse.swt.widgets.TableColumn;
import org.eclipse.swt.widgets.TableItem;
-import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.ISharedImages;
import org.eclipse.ui.PlatformUI;
import org.eclipse.wst.command.internal.env.core.common.StatusUtils;
@@ -48,7 +48,11 @@
private TableViewer tableViewer_;
private Table table_;
private String message = null;
- static final String columns_[] = {"severity", "line", "column", "message"};
+ static final String columns_[] = {ConsumptionUIMessages.TABLE_COLUMN_VALIDATION_SEVERITY,
+ ConsumptionUIMessages.TABLE_COLUMN_VALIDATION_LINE,
+ ConsumptionUIMessages.TABLE_COLUMN_VALIDATION_COLUMN,
+ ConsumptionUIMessages.TABLE_COLUMN_VALIDATION_MESSAGE};
+
static final int columnsWidth_[] = {10, 10, 10, 60};
@@ -68,7 +72,7 @@
composite.setLayout(gl);
composite.setLayoutData(new GridData(GridData.FILL_BOTH));
- Text messageLabel = new Text( composite, SWT.READ_ONLY);
+ Label messageLabel = new Label( composite, SWT.WRAP);
messageLabel.setText( ConsumptionUIMessages.LABEL_VALIDATE_MESSAGES);
GridData gd = new GridData(GridData.HORIZONTAL_ALIGN_FILL);
messageLabel.setLayoutData(gd);
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidget.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidget.java
index 4f44992..3d4ee20 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidget.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidget.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime;
@@ -222,45 +221,35 @@
}
else
{
- //Non-existing project is only permitted if there is a server selected.
- if (serverFactoryId==null || serverFactoryId.length()==0)
- {
- finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_PROJECT_MUST_EXIST, new String[]{projectName}));
- }
- else
- {
- // Look at the project type to ensure that it is suitable for the
- // selected runtime and server.
- String templateId = getClientComponentType();
+ //Look at the project type to ensure that it is suitable for the selected runtime
+ //and server.
+
+ String templateId = getClientComponentType();
- if (templateId != null && templateId.length() > 0)
+ if (templateId != null && templateId.length()>0)
+ {
+ //Check if the runtime supports it.
+ if (!WebServiceRuntimeExtensionUtils2.doesClientTypeAndRuntimeSupportTemplate(typeId, runtimeId, templateId))
{
- // Check if the runtime supports it.
- if (!WebServiceRuntimeExtensionUtils2.doesClientTypeAndRuntimeSupportTemplate(typeId, runtimeId, templateId))
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ String templateLabel = FacetUtils.getTemplateLabelById(templateId);
+ finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_CLIENT_RUNTIME_DOES_NOT_SUPPORT_TEMPLATE, new String[]{runtimeLabel, templateLabel}));
+ }
+
+ //Check if the server supports it.
+ if (serverFactoryId!=null && serverFactoryId.length()>0)
+ {
+ if (!valUtils.doesServerSupportTemplate(serverFactoryId, templateId))
{
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
String templateLabel = FacetUtils.getTemplateLabelById(templateId);
- finalStatus = StatusUtils.errorStatus(NLS.bind(
- ConsumptionUIMessages.MSG_CLIENT_RUNTIME_DOES_NOT_SUPPORT_TEMPLATE, new String[] { runtimeLabel,
- templateLabel }));
- }
-
- // Check if the server supports it.
- if (serverFactoryId != null && serverFactoryId.length() > 0)
- {
- if (!valUtils.doesServerSupportTemplate(serverFactoryId, templateId))
- {
- String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
- String templateLabel = FacetUtils.getTemplateLabelById(templateId);
- finalStatus = StatusUtils.errorStatus(NLS.bind(
- ConsumptionUIMessages.MSG_CLIENT_SERVER_DOES_NOT_SUPPORT_TEMPLATE, new String[] { serverLabel,
- templateLabel }));
- }
+ finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_CLIENT_SERVER_DOES_NOT_SUPPORT_TEMPLATE, new String[]{serverLabel, templateLabel}));
}
}
}
+
}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidgetDefaultingCommand.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidgetDefaultingCommand.java
index bde33e5..896c2f9 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidgetDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ClientRuntimeSelectionWidgetDefaultingCommand.java
@@ -1,19 +1,16 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
* 20060206 126408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060222 115834 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime;
@@ -41,14 +38,13 @@
import org.eclipse.jst.ws.internal.consumption.common.FacetUtils;
import org.eclipse.jst.ws.internal.consumption.common.RequiredFacetVersion;
import org.eclipse.jst.ws.internal.consumption.ui.ConsumptionUIMessages;
-import org.eclipse.jst.ws.internal.consumption.ui.common.ValidationUtils;
import org.eclipse.jst.ws.internal.consumption.ui.plugin.WebServiceConsumptionUIPlugin;
import org.eclipse.jst.ws.internal.consumption.ui.preferences.PersistentServerRuntimeContext;
import org.eclipse.jst.ws.internal.consumption.ui.preferences.ProjectTopologyContext;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.ClientRuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.FacetMatchCache;
-import org.eclipse.jst.ws.internal.consumption.ui.wsrt.RuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.ServiceRuntimeDescriptor;
+import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.osgi.util.NLS;
@@ -94,18 +90,18 @@
private ResourceContext resourceContext_;
private boolean test_;
- //A note on initial projects ...
- //The difference between clientInitialProject_ and initialProject_ is that
- //clientInitialProject_ comes from the ObjectSelectionOutputCommand while initialProject_
- //comes from SelectionCommand (i.e. it is the project containing the thing that was selected before
- //the wizard was launched). In the defaulting algorithm, clientInitialProject_ will
- //be given first priority. If, however, it is deemed that clientInitialProject_ is not a valid project
- //because it contains the J2EE Web service for which we are trying to create a client, initialProject_
- //will be given second priority.
- private IProject initialProject_; //This is the project containing the selection prior to the wizard being launched.
- private IProject clientInitialProject_; //This is the project containing the object selection from page 2.
+ //A note on initialSelections ...
+ //The difference between clientInitialProject/Component_ and initialInitialSelection is that
+ //clientInitialProject/Component_ comes from the ObjectSelectionOutputCommand while initialInitialSelection
+ //is the actual thing that was selected before the wizard was launched. In the runtime/j2ee/project
+ //defaulting algorithm, clientInitialSelection will be given first priority. If, however, it is
+ //deemed that clientInitialProject is not a valid initial selection, initialInitialSelection
+ //will be given second priority. Things that could make an initialSelection invalid include
+ //1. The containing project contains the Web service for which we are trying to create a client
+ //2. The containing project has a J2EE level, server target, and project type combination which
+ // is not supported by any of the registered Web service runtimes.
+ private IProject clientInitialProject_;
private String wsdlURI_;
- private WebServicesParser parser_;
public ClientRuntimeSelectionWidgetDefaultingCommand()
{
@@ -186,45 +182,14 @@
}
else
{
- ValidationUtils vu = new ValidationUtils();
-
- // Set the runtime based on the project containing the object selection/initial selection.
- DefaultRuntimeTriplet drt = null;
-
- if (!vu.isProjectServiceProject(clientInitialProject_, wsdlURI_, parser_))
- {
- //If clientIntialProject_ does not contain the J2EE Web service, choose a clientRuntime based on it.
- drt = getDefaultRuntime(clientInitialProject_, clientIds_.getTypeId(), true);
- clientFacetMatcher_ = drt.getFacetMatcher();
- clientProjectName_ = drt.getProjectName();
- clientRuntimeId_ = drt.getRuntimeId();
- }
- else
- {
- //clientInitialProject_ contains the J2EE Web service so don't use it.
- //Try using the initalProject_ instead.
- if (!vu.isProjectServiceProject(initialProject_, wsdlURI_, parser_))
- {
- //If intialProject_ does not contain the J2EE Web service, choose a clientRuntime based on it.
- drt = getDefaultRuntime(initialProject_, clientIds_.getTypeId(), true);
- clientFacetMatcher_ = drt.getFacetMatcher();
- clientProjectName_ = drt.getProjectName();
- clientRuntimeId_ = drt.getRuntimeId();
- }
- else
- {
- //Both clientIntialProject_ and initialProject_ contain the J2EE Web service
- //and cannot be used to influence clientRuntime defaulting.
- //Choose a clientRuntime but don't choose clientInitialProject_
- //as the clientProject.
- drt = getDefaultRuntime(null, clientIds_.getTypeId(), true);
- clientRuntimeId_ = drt.getRuntimeId();
- }
- }
+ // Set the runtime based on the initial selection
+ DefaultRuntimeTriplet drt = getDefaultRuntime(clientInitialProject_, clientIds_.getTypeId(), true);
+ clientFacetMatcher_ = drt.getFacetMatcher();
+ clientProjectName_ = drt.getProjectName();
+ clientRuntimeId_ = drt.getRuntimeId();
if (clientRuntimeId_ == null)
{
- // TODO:
// return and error.
}
clientIds_.setRuntimeId(WebServiceRuntimeExtensionUtils2.getClientRuntimeDescriptorById(clientRuntimeId_).getRuntime()
@@ -374,18 +339,11 @@
return Status.OK_STATUS;
}
- // No suitable server was found. Popup an error if the default Web service
- // runtime requires a server.
- RuntimeDescriptor runtimeDescriptor = WebServiceRuntimeExtensionUtils2.getRuntimeById(clientIds_.getRuntimeId());
- if (runtimeDescriptor.getServerRequired())
- {
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(clientIds_.getRuntimeId());
- IStatus status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[] {
- runtimeLabel}));
- return status;
- }
-
- return Status.OK_STATUS;
+ //No suitable server was found. Popup an error.
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(clientIds_.getRuntimeId());
+ String serverLabels = getServerLabels(clientRuntimeId_);
+ IStatus status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[]{runtimeLabel, serverLabels}) );
+ return status;
}
private IServer getServerFromClientRuntimeId()
@@ -656,6 +614,7 @@
{
String[] templates = WebServiceRuntimeExtensionUtils2.getClientProjectTemplates(clientIds_.getTypeId(), clientIds_.getRuntimeId());
+ //Pick the Web one if it's there, otherwise pick the first one.
//Walk the list of client project types in the project topology preference
ProjectTopologyContext ptc= WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
String[] preferredTemplateIds = ptc.getClientTypes();
@@ -698,7 +657,6 @@
private String getDefaultClientProjectName()
{
- ValidationUtils vu = new ValidationUtils();
IProject[] projects = FacetUtils.getAllProjects();
ClientRuntimeDescriptor desc = WebServiceRuntimeExtensionUtils2.getClientRuntimeDescriptorById(clientRuntimeId_);
RequiredFacetVersion[] rfvs = desc.getRequiredFacetVersions();
@@ -706,34 +664,32 @@
//Check each project and its facetRuntime for compatibility with the clientRuntime
for (int i=0; i<projects.length; i++)
{
- if (!vu.isProjectServiceProject(projects[i], wsdlURI_, parser_))
+
+ Set facetVersions = FacetUtils.getFacetsForProject(projects[i].getName());
+ org.eclipse.wst.common.project.facet.core.runtime.IRuntime fRuntime = null;
+ String fRuntimeName = null;
+ fRuntime = FacetUtils.getFacetRuntimeForProject(projects[i].getName());
+ if (fRuntime != null)
{
- Set facetVersions = FacetUtils.getFacetsForProject(projects[i].getName());
- org.eclipse.wst.common.project.facet.core.runtime.IRuntime fRuntime = null;
- String fRuntimeName = null;
- fRuntime = FacetUtils.getFacetRuntimeForProject(projects[i].getName());
- if (fRuntime != null)
+ fRuntimeName = fRuntime.getName();
+ }
+
+ if (facetVersions != null)
+ {
+
+ //FacetMatcher fm = FacetUtils.match(rfvs, facetVersions);
+ FacetMatcher fm = FacetMatchCache.getInstance().getMatchForProject(true, clientRuntimeId_, projects[i].getName());
+ boolean facetRuntimeMatches = true;
+ if (fRuntimeName != null)
{
- fRuntimeName = fRuntime.getName();
+ facetRuntimeMatches = FacetUtils.isFacetRuntimeSupported(rfvs, fRuntimeName);
}
-
- if (facetVersions != null)
+
+ if (fm.isMatch() && facetRuntimeMatches)
{
-
- // FacetMatcher fm = FacetUtils.match(rfvs, facetVersions);
- FacetMatcher fm = FacetMatchCache.getInstance().getMatchForProject(true, clientRuntimeId_, projects[i].getName());
- boolean facetRuntimeMatches = true;
- if (fRuntimeName != null)
- {
- facetRuntimeMatches = FacetUtils.isFacetRuntimeSupported(rfvs, fRuntimeName);
- }
-
- if (fm.isMatch() && facetRuntimeMatches)
- {
- clientFacetMatcher_ = fm;
- return projects[i].getName();
- }
- }
+ clientFacetMatcher_ = fm;
+ return projects[i].getName();
+ }
}
}
@@ -955,36 +911,23 @@
//Haven't returned yet so this means that the intitially selected project cannot be used
//to influence the selection of the service/client runtime.
- //Use the preferred project types to influence the selection of a runtime.
+ //If this is client defaulting, use the preferred client project types to
+ //influence the selection of a runtime.
+ if (isClient)
+ {
ProjectTopologyContext ptc = WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- String[] preferredTemplateIds = null;
- if (isClient)
- {
- preferredTemplateIds = ptc.getClientTypes();
- }
- else
- {
- preferredTemplateIds = ptc.getServiceTypes();
- }
-
+ String[] preferredTemplateIds = ptc.getClientTypes();
for (int n=0; n<preferredTemplateIds.length; n++)
{
String preferredTemplateId = preferredTemplateIds[n];
+ //Set templateFacetVersions = FacetUtils.getInitialFacetVersionsFromTemplate(preferredTemplateId);
for (int m=0; m<preferredRuntimeIds.length; m++)
{
- //If this client or service runtime supports this template, choose it and exit.
- boolean matches = false;
- if (isClient)
- {
- matches = WebServiceRuntimeExtensionUtils2.doesClientRuntimeSupportTemplate(preferredRuntimeIds[m], preferredTemplateId);
- }
- else
- {
- matches = WebServiceRuntimeExtensionUtils2.doesServiceRuntimeSupportTemplate(preferredRuntimeIds[m], preferredTemplateId);
- }
-
+ //If this clientRuntime supports this template, choose it and exit.
+ //ClientRuntimeDescriptor desc = WebServiceRuntimeExtensionUtils2.getClientRuntimeDescriptorById(preferredRuntimeIds[m]);
+ boolean matches = WebServiceRuntimeExtensionUtils2.doesClientRuntimeSupportTemplate(preferredRuntimeIds[m], preferredTemplateId);
if (matches)
{
DefaultRuntimeTriplet drt = new DefaultRuntimeTriplet();
@@ -995,7 +938,7 @@
}
}
}
-
+ }
//Still haven't returned. Return the first preferred service/client runtime id.
if (preferredRuntimeIds.length > 0)
@@ -1087,7 +1030,26 @@
return ResourceUtils.getDefaultClientEARProjectName();
}
}
-
+
+
+ private String getServerLabels(String clientRuntimeId)
+ {
+ String[] validServerFactoryIds = WebServiceRuntimeExtensionUtils2.getServerFactoryIdsByClientRuntime(clientRuntimeId);
+ //String[] validServerLabels = new String[validServerFactoryIds.length];
+ StringBuffer validServerLabels = new StringBuffer();
+ for (int i=0; i<validServerFactoryIds.length; i++)
+ {
+ if (i>0)
+ {
+ validServerLabels.append(", ");
+ }
+ validServerLabels.append(WebServiceRuntimeExtensionUtils.getServerLabelById(validServerFactoryIds[i]));
+
+ }
+ return validServerLabels.toString();
+ }
+
+
/*
* Update the client project, client project type and clientRuntime as needed.
* Used by ServerRuntimeSelectionWidgetDefaultingCommand to update client side
@@ -1179,7 +1141,8 @@
*/
public void setInitialInitialSelection(IStructuredSelection initialInitialSelection)
{
- initialProject_ = getProjectFromInitialSelection(initialInitialSelection);
+ // TODO Delete this method and corresponding mappings
+ // if no longer required.
}
public boolean getClientNeedEAR()
@@ -1191,7 +1154,8 @@
* @param parser_ The parser_ to set.
*/
public void setWebServicesParser(WebServicesParser parser) {
- parser_ = parser;
+ // TODO Delete this method and corresponding mappings
+ // if no longer required.
}
public void setWsdlURI(String wsdlURI)
@@ -1307,4 +1271,4 @@
this.runtimeId_ = runtimeId_;
}
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ProjectSelectionWidget.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ProjectSelectionWidget.java
index 9544750..e47c1a4 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ProjectSelectionWidget.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/ProjectSelectionWidget.java
@@ -1,18 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124143 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 122661 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060223 129020 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime;
@@ -117,15 +114,19 @@
if (isClient_)
{
- moduleProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_PROJECT, ConsumptionUIMessages.LABEL_CLIENT_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
- projectType_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_TYPE, ConsumptionUIMessages.TOOLTIP_PWCR_COMBO_CLIENT_TYPE, INFOPOP_PWRS_COMBO_CLIENT_PROJECT_TYPE, SWT.SINGLE | SWT.BORDER);
+ projectType_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_TYPE, ConsumptionUIMessages.TOOLTIP_PWCR_COMBO_CLIENT_TYPE, INFOPOP_PWRS_COMBO_CLIENT_PROJECT_TYPE, SWT.SINGLE | SWT.BORDER);
+ moduleProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_PROJECT, ConsumptionUIMessages.LABEL_CLIENT_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
+ //module_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_MODULE", ConsumptionUIMessages.LABEL_CLIENT_MODULE", INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
earProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_EAR_PROJECT, ConsumptionUIMessages.LABEL_CLIENT_EAR_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
+ //earModule_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_CLIENT_EAR_MODULE", ConsumptionUIMessages.LABEL_CLIENT_EAR_MODULE", INFOPOP_PWRS_COMBO_EAR, SWT.SINGLE | SWT.BORDER );
}
else
- {
- moduleProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_PROJECT, ConsumptionUIMessages.LABEL_SERVICE_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
+ {
projectType_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_TYPE, ConsumptionUIMessages.TOOLTIP_PWCR_COMBO_SERVICE_TYPE, INFOPOP_PWRS_COMBO_SERVICE_PROJECT_TYPE, SWT.SINGLE | SWT.BORDER);
+ moduleProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_PROJECT, ConsumptionUIMessages.LABEL_SERVICE_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
+ //module_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_MODULE", ConsumptionUIMessages.LABEL_SERVICE_MODULE", INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
earProject_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_EAR_PROJECT, ConsumptionUIMessages.LABEL_SERVICE_EAR_PROJECT, INFOPOP_PWRS_COMBO_PROJECT, SWT.SINGLE | SWT.BORDER );
+ //earModule_ = uiUtils.createCombo(parent, ConsumptionUIMessages.LABEL_SERVICE_EAR_MODULE, ConsumptionUIMessages.LABEL_SERVICE_EAR_MODULE, INFOPOP_PWRS_COMBO_EAR, SWT.SINGLE | SWT.BORDER );
}
//Temporarily remove the listeners
@@ -134,7 +135,6 @@
{
public void modifyText(ModifyEvent evt)
{
- handleProjectTypeChanged();
statusListener_.handleEvent( null );
}
};
@@ -176,7 +176,163 @@
moduleProject_.removeModifyListener( moduleProjectListener_ );
earProject_.removeModifyListener( earProjectListener_ );
}
-
+
+ /*
+ private void handleModuleProjectChanged(String moduleName)
+ {
+ String projectName = moduleProject_.getText();
+ IProject project = null;
+
+ if( projectName.equals( "" ) )
+ {
+ module_.setItems( new String[0] );
+
+ return;
+ }
+
+ project = ProjectUtilities.getProject( projectName );
+
+
+ IVirtualComponent[] components = J2EEUtils.getComponentsByType( project, componentType_ );
+ String[] modules = new String[components.length];
+
+ for( int index = 0; index < components.length; index++ )
+ {
+ modules[index] = components[index].getName();
+ }
+
+ module_.setItems( modules );
+
+ if( modules.length > 0 )
+ {
+ if (moduleName != null)
+ {
+ module_.setText(moduleName);
+ }
+ else
+ {
+ module_.setText( modules[0] );
+ }
+
+ }
+ else
+ {
+ module_.setText( projectName );
+ }
+
+ }
+ */
+
+ /*
+ private void handleModuleChanged()
+ {
+ IVirtualComponent component = getEarModuleForModule();
+
+ if( component != null )
+ {
+ String earProject = component.getProject().getName();
+ String componentName = component.getName();
+
+ // This will cause the module list to be update via a listener.
+ earProject_.setText( earProject );
+ earModule_.setText( componentName );
+ }
+ else
+ {
+ earProject_.setText( "" );
+ earModule_.setText( "" );
+ }
+
+ updateEAREnabledState();
+ }
+ */
+
+ /*
+ private void handleEarProjectChanged()
+ {
+
+ String projectName = earProject_.getText();
+
+ if( projectName != null && !projectName.equals( "" ))
+ {
+ IProject project = ProjectUtilities.getProject( projectName );
+
+ IVirtualComponent[] components = J2EEUtils.getComponentsByType( project, J2EEUtils.EAR );
+ String[] earModules = new String[components.length];
+
+ for( int index = 0; index < components.length; index++ )
+ {
+ earModules[index] = components[index].getName();
+ }
+
+ earModule_.setItems( earModules );
+
+ if( earModules.length > 0 )
+ {
+ earModule_.setText( earModules[0] );
+ }
+ else
+ {
+ earModule_.setText( projectName );
+ }
+ }
+ else
+ {
+ earModule_.setItems( new String[0] );
+ }
+ }
+ */
+
+ /*
+ private IVirtualComponent getEarModuleForModule()
+ {
+ String projectName = moduleProject_.getText();
+
+ if( projectName.equals( "" ) )
+ {
+ return null;
+ }
+
+ IProject project = ProjectUtilities.getProject( projectName );
+
+ IVirtualComponent[] components = J2EEUtils.getReferencingEARComponents( project );
+
+ return components.length == 0 ? null : components[0];
+ }
+ */
+
+ /*
+ public void setProjectChoices(SelectionListChoices projects)
+ {
+ listenersOff();
+
+ projects_ = projects;
+
+ String selectedModuleProject = projects.getList().getSelection();
+ String selectedEarModuleProject = projects.getChoice().getList().getSelection();
+ String[] projectNames = getProjects();
+
+ moduleProject_.setItems( projectNames );
+ moduleProject_.setText( selectedModuleProject );
+ earProject_.setItems( projectNames );
+ earProject_.setText( selectedEarModuleProject );
+
+ handleModuleProjectChanged(initialModuleName_);
+ handleModuleChanged();
+ updateEAREnabledState();
+ listenersOn();
+ }
+ */
+
+
+
+ /*
+ public SelectionListChoices getProjectChoices()
+ {
+ return projects_;
+ }
+ */
+
public String getProjectName()
{
return moduleProject_.getText();
@@ -187,7 +343,6 @@
listenersOff();
moduleProject_.setText( name );
handleProjectChanged();
- updateEARState();
listenersOn();
}
@@ -214,7 +369,6 @@
else
projectType_.setText("");
- handleProjectTypeChanged();
listenersOn();
}
@@ -285,7 +439,6 @@
moduleProject_.setItems(projectNames);
moduleProject_.setText(selectedModuleProject);
handleProjectChanged();
- updateEARState();
listenersOn();
}
@@ -303,14 +456,10 @@
earProject_.select(0);
}
- private void handleProjectTypeChanged()
- {
- updateEARState();
- }
-
private void handleProjectChanged()
- {
- updateTemplates();
+ {
+ updateEARState();
+ updateTemplates();
}
private void updateTemplates()
@@ -328,7 +477,7 @@
{
populateProjectTypeCombo();
projectType_.setEnabled(true);
- }
+ }
}
}
@@ -362,18 +511,12 @@
}
else
{
+
+ if (isClient_)
+ {
// Select the preferred client project type.
ProjectTopologyContext ptc = WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- String[] preferredTemplateIds = null;
- if (isClient_)
- {
- preferredTemplateIds = ptc.getClientTypes();
- }
- else
- {
- preferredTemplateIds = ptc.getServiceTypes();
- }
-
+ String[] preferredTemplateIds = ptc.getClientTypes();
boolean selected = false;
outer: for (int j = 0; j < preferredTemplateIds.length; j++)
{
@@ -393,6 +536,19 @@
{
projectType_.select(0);
}
+
+ } else
+ {
+ // If a "..web.." template is there, pick that as the default.
+ int webTemplateIndex = getWebTemplateIndex(templates);
+ if (webTemplateIndex > -1)
+ {
+ projectType_.select(webTemplateIndex);
+ } else
+ {
+ projectType_.select(0);
+ }
+ }
}
}
}
@@ -411,6 +567,19 @@
return -1;
}
+ private int getWebTemplateIndex(String[] templateIds)
+ {
+ for (int i=0; i<templateIds.length; i++)
+ {
+ if (templateIds[i].indexOf("web") > -1)
+ {
+ return i;
+ }
+ }
+
+ return -1;
+ }
+
private void updateEARState()
{
if(!projectNeedsEAR(moduleProject_.getText()))
@@ -457,34 +626,7 @@
private boolean projectNeedsEAR(String projectName)
{
- //If the project is a simple Java project or the project type is
- //Java utility return false.
- if (projectName != null && projectName.length()>0)
- {
- IProject project = ProjectUtilities.getProject(projectName);
- if (project.exists())
- {
- if (FacetUtils.isJavaProject(project))
- {
- return false;
- }
- }
- }
-
- //Project didn't rule out the need for an EAR
- //so check the proect type
- String templateId = getComponentType();
- if (templateId != null && templateId.length()>0)
- {
- if (FacetUtils.isUtilityTemplate(templateId))
- {
- return false;
- }
- }
-
-
- //Project or project type didn't rule out the need for an EAR
- //so check the server type.
+ //Use the server type
if (trsIds_ != null && trsIds_.getServerId() != null)
{
String targetId = ServerUtils.getRuntimeTargetIdFromFactoryId(trsIds_.getServerId());
@@ -496,7 +638,7 @@
}
}
}
-
+
return true;
}
@@ -615,4 +757,4 @@
return finalStatus;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/RuntimeServerSelectionWidget.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/RuntimeServerSelectionWidget.java
index f95d580..e1f6567 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/RuntimeServerSelectionWidget.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/widgets/runtime/RuntimeServerSelectionWidget.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime;
@@ -20,7 +19,6 @@
import org.eclipse.jst.ws.internal.common.ServerUtils;
import org.eclipse.jst.ws.internal.consumption.ui.ConsumptionUIMessages;
import org.eclipse.jst.ws.internal.consumption.ui.wizard.RuntimeServerSelectionDialog;
-import org.eclipse.jst.ws.internal.consumption.ui.wsrt.RuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.jst.ws.internal.ui.common.UIUtils;
@@ -196,14 +194,10 @@
if( ids_.getRuntimeId() == null || runtimeLabel == null || runtimeLabel.equals("" ))
{
status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_NO_RUNTIME, new String[]{ scenario } ) );
- }
+ }
else if( ids_.getServerId() == null || serverLabel.equals( "" ))
{
- RuntimeDescriptor desc = WebServiceRuntimeExtensionUtils2.getRuntimeById(ids_.getRuntimeId());
- if (desc.getServerRequired())
- {
- status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[]{ scenario } ) );
- }
+ status = StatusUtils.errorStatus( NLS.bind(ConsumptionUIMessages.MSG_NO_SERVER, new String[]{ scenario } ) );
}
//
@@ -229,39 +223,23 @@
}
- //If no errors for detected, check for warnings
if (status.getSeverity() != Status.ERROR)
{
-
- // Check if server type is null and the user opted to install on page 1.
+ // Check if only stub runtime is available for the selected server type
+
String serverFactoryId = ids_.getServerId();
- if (serverFactoryId == null || serverFactoryId.length() == 0)
- {
- if (isClientContext_)
- {
- status = StatusUtils.warningStatus(NLS.bind(ConsumptionUIMessages.MSG_WARN_NO_CLIENT_SERVER, new String[0]));
- } else
- {
- status = StatusUtils.warningStatus(NLS.bind(ConsumptionUIMessages.MSG_WARN_NO_SERVICE_SERVER, new String[0]));
- }
-
- }
- else
+ //
+ IServerType serverType = ServerCore.findServerType(serverFactoryId);
+ if (serverType != null)
{
- // Check if only stub runtime is available for the selected server type
- IServerType serverType = ServerCore.findServerType(serverFactoryId);
- if (serverType != null)
+ // Find a Runtime which is not a stub
+ IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverFactoryId);
+ if (install_ && nonStubRuntime == null)
{
-
- // Find a Runtime which is not a stub
- IRuntime nonStubRuntime = ServerUtils.getNonStubRuntime(serverFactoryId);
- if (install_ && nonStubRuntime == null)
- {
- String servertypeLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
- status = StatusUtils.warningStatus(NLS.bind(ConsumptionUIMessages.MSG_WARN_STUB_ONLY,
- new String[] { servertypeLabel }));
- }
+ String servertypeLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
+ status = StatusUtils.warningStatus(NLS
+ .bind(ConsumptionUIMessages.MSG_WARN_STUB_ONLY, new String[] { servertypeLabel }));
}
}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/RuntimeServerSelectionDialog.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/RuntimeServerSelectionDialog.java
index 6ffaac2..e8ba923 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/RuntimeServerSelectionDialog.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/RuntimeServerSelectionDialog.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wizard;
@@ -476,7 +473,7 @@
runtimes = WebServiceRuntimeExtensionUtils2.getRuntimesByServiceType(typeId_);
}
else {
- runtimes = WebServiceRuntimeExtensionUtils2.getRuntimesByClientType(typeId_);
+ runtimes = WebServiceRuntimeExtensionUtils2.getAllRuntimesForClientSide();
}
TreeItem[] runtimeName = new TreeItem[runtimes.length];
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/TypeSelectionMetadata.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/TypeSelectionMetadata.java
index 8275acc..198c12d 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/TypeSelectionMetadata.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/TypeSelectionMetadata.java
@@ -1,21 +1,17 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wizard;
-import com.ibm.icu.util.StringTokenizer;
-
+import java.util.StringTokenizer;
//
// This class holds the set of distinguishing factors in determining
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBM.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBM.java
new file mode 100644
index 0000000..7f3aa24
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBM.java
@@ -0,0 +1,41 @@
+/*******************************************************************************
+ * Copyright (c) 2002, 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.jst.ws.internal.consumption.ui.wizard.uddi;
+
+import org.eclipse.wst.ws.parser.PluginMessages;
+
+public class PublicUDDIRegistryIBM implements PublicUDDIRegistryType
+{
+
+ // Copyright
+ public static final String copyright = "(c) Copyright IBM Corporation 2002.";
+
+ public PublicUDDIRegistryIBM() {
+ }
+
+ public String getName() {
+ return PluginMessages.PUBLICUDDIREGISTRYTYPE_NAME_IBM;
+ }
+
+ public String getInquiryURL() {
+ return "http://uddi.ibm.com/ubr/inquiryapi";
+ }
+
+ public String getPublishURL() {
+ return "https://uddi.ibm.com/ubr/publishapi";
+ }
+
+ public String getRegistrationURL() {
+ return "http://uddi.ibm.com/ubr/registry.html";
+ }
+
+}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBMTest.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBMTest.java
new file mode 100644
index 0000000..78d2c0c
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryIBMTest.java
@@ -0,0 +1,41 @@
+/*******************************************************************************
+ * Copyright (c) 2002, 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.jst.ws.internal.consumption.ui.wizard.uddi;
+
+import org.eclipse.wst.ws.parser.PluginMessages;
+
+public class PublicUDDIRegistryIBMTest implements PublicUDDIRegistryType
+{
+
+ // Copyright
+ public static final String copyright = "(c) Copyright IBM Corporation 2002.";
+
+ public PublicUDDIRegistryIBMTest() {
+ }
+
+ public String getName() {
+ return PluginMessages.PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST;
+ }
+
+ public String getInquiryURL() {
+ return "http://uddi.ibm.com/testregistry/inquiryapi";
+ }
+
+ public String getPublishURL() {
+ return "https://uddi.ibm.com/testregistry/publishapi";
+ }
+
+ public String getRegistrationURL() {
+ return "http://uddi.ibm.com/testregistry/registry.html";
+ }
+
+}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoft.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoft.java
new file mode 100644
index 0000000..bbbb8d7
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoft.java
@@ -0,0 +1,41 @@
+/*******************************************************************************
+ * Copyright (c) 2002, 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.jst.ws.internal.consumption.ui.wizard.uddi;
+
+import org.eclipse.wst.ws.parser.PluginMessages;
+
+public class PublicUDDIRegistryMicrosoft implements PublicUDDIRegistryType
+{
+
+ // Copyright
+ public static final String copyright = "(c) Copyright IBM Corporation 2002.";
+
+ public PublicUDDIRegistryMicrosoft() {
+ }
+
+ public String getName() {
+ return PluginMessages.PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT;
+ }
+
+ public String getInquiryURL() {
+ return "http://uddi.microsoft.com/inquire";
+ }
+
+ public String getPublishURL() {
+ return "https://uddi.microsoft.com/publish";
+ }
+
+ public String getRegistrationURL() {
+ return "https://uddi.microsoft.com/register.aspx";
+ }
+
+}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoftTest.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoftTest.java
new file mode 100644
index 0000000..a6f9bee
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wizard/uddi/PublicUDDIRegistryMicrosoftTest.java
@@ -0,0 +1,41 @@
+/*******************************************************************************
+ * Copyright (c) 2002, 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.jst.ws.internal.consumption.ui.wizard.uddi;
+
+import org.eclipse.wst.ws.parser.PluginMessages;
+
+public class PublicUDDIRegistryMicrosoftTest implements PublicUDDIRegistryType
+{
+
+ // Copyright
+ public static final String copyright = "(c) Copyright IBM Corporation 2002.";
+
+ public PublicUDDIRegistryMicrosoftTest() {
+ }
+
+ public String getName() {
+ return PluginMessages.PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST;
+ }
+
+ public String getInquiryURL() {
+ return "http://test.uddi.microsoft.com/inquire";
+ }
+
+ public String getPublishURL() {
+ return "https://test.uddi.microsoft.com/publish";
+ }
+
+ public String getRegistrationURL() {
+ return "http://test.uddi.microsoft.com/register.aspx";
+ }
+
+}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ClientType.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ClientType.java
index e3c4b51..85a0260 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ClientType.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ClientType.java
@@ -1,21 +1,18 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
import java.util.Hashtable;
+import java.util.StringTokenizer;
import org.eclipse.core.runtime.IConfigurationElement;
-import com.ibm.icu.util.StringTokenizer;
public class ClientType {
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/RuntimeDescriptor.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/RuntimeDescriptor.java
index ac2bb37..b629537 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/RuntimeDescriptor.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/RuntimeDescriptor.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
@@ -22,8 +19,6 @@
private IConfigurationElement elem;
private String id;
private String label;
- private String serverRequiredString;
- private boolean serverRequired;
public RuntimeDescriptor(IConfigurationElement elem)
@@ -54,21 +49,4 @@
return new String[]{"13", "14"};
}
- public boolean getServerRequired()
- {
- if (serverRequiredString == null)
- {
- //Defaults to true if the extension omits this attribute
- serverRequired = true;
-
- serverRequiredString = elem.getAttribute("serverRequired");
- if (serverRequiredString != null)
- {
- serverRequired = Boolean.valueOf(serverRequiredString).booleanValue();
- }
-
- }
- return serverRequired;
- }
-
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ServiceType.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ServiceType.java
index 417cc29..85bf5af 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ServiceType.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/ServiceType.java
@@ -1,22 +1,19 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
import java.util.Hashtable;
+import java.util.StringTokenizer;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.wst.ws.internal.wsrt.WebServiceScenario;
-import com.ibm.icu.util.StringTokenizer;
public class ServiceType {
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceImpl.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceImpl.java
index b375424..b5630e9 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceImpl.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceImpl.java
@@ -1,20 +1,17 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
+import java.util.StringTokenizer;
import org.eclipse.core.runtime.IConfigurationElement;
-import com.ibm.icu.util.StringTokenizer;
public class WebServiceImpl {
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeExtensionUtils2.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeExtensionUtils2.java
index ced7f6f..b9dc950 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeExtensionUtils2.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeExtensionUtils2.java
@@ -1,17 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
@@ -59,35 +57,6 @@
return null;
}
-
- public static String[] getAllServiceProjectTypes()
- {
- ArrayList finalTemplateIdList = new ArrayList();
- Iterator iter = registry.serviceRuntimes_.values().iterator();
-
- //Loop through all the serviceRuntimes
- while (iter.hasNext())
- {
- ServiceRuntimeDescriptor desc = (ServiceRuntimeDescriptor)iter.next();
-
- //Get the templates for this service runtime
- Set templates = FacetMatchCache.getInstance().getTemplatesForServiceRuntime(desc.getId());
-
- //Add the template ids to the list if they have not already been added
- Iterator itr = templates.iterator();
- while (itr.hasNext())
- {
- IFacetedProjectTemplate template = (IFacetedProjectTemplate)itr.next();
- if (!finalTemplateIdList.contains(template.getId()))
- {
- finalTemplateIdList.add(template.getId());
- }
- }
- }
-
- return (String[])finalTemplateIdList.toArray(new String[]{});
- }
-
public static String[] getAllClientProjectTypes()
{
ArrayList finalTemplateIdList = new ArrayList();
@@ -217,21 +186,17 @@
public static String getServiceRuntimeId(TypeRuntimeServer trs, String projectName, String templateId)
{
- boolean serverSelected = (trs.getServerId() != null) && (trs.getServerId().length() > 0);
- //Find the first service runtime that supports the implementation type, runtime, server, and project
+ //Find the first client runtime that supports the implementation type, runtime, server, and project
String[] descs = getServiceRuntimesByServiceType(trs.getTypeId());
for (int i=0; i<descs.length; i++)
{
ServiceRuntimeDescriptor desc = getServiceRuntimeDescriptorById(descs[i]);
if (desc.getRuntime().getId().equals(trs.getRuntimeId()))
{
- if (serverSelected)
+ boolean supportsServer = doesServiceRuntimeSupportServer(desc.getId(), trs.getServerId());
+ if (!supportsServer)
{
- boolean supportsServer = doesServiceRuntimeSupportServer(desc.getId(), trs.getServerId());
- if (!supportsServer)
- {
- continue;
- }
+ continue;
}
IProject project = ProjectUtilities.getProject(projectName);
@@ -540,7 +505,7 @@
public static String getDefaultServerValueFor(String typeId)
{
String[] fIds = getServerFactoryIdsByServiceType(typeId);
- if (fIds==null || fIds.length==0)
+ if (fIds==null)
return null;
return fIds[0];
@@ -818,7 +783,6 @@
public static String getClientRuntimeId(TypeRuntimeServer trs, String projectName, String templateId)
{
- boolean serverSelected = (trs.getServerId()!=null) && (trs.getServerId().length()>0);
//Find the first client runtime that supports the implementation type, runtime, server, and project
String[] descs = getClientRuntimesByType(trs.getTypeId());
for (int i=0; i<descs.length; i++)
@@ -826,13 +790,10 @@
ClientRuntimeDescriptor desc = getClientRuntimeDescriptorById(descs[i]);
if (desc.getRuntime().getId().equals(trs.getRuntimeId()))
{
- if (serverSelected)
+ boolean supportsServer = doesClientRuntimeSupportServer(desc.getId(), trs.getServerId());
+ if (!supportsServer)
{
- boolean supportsServer = doesClientRuntimeSupportServer(desc.getId(), trs.getServerId());
- if (!supportsServer)
- {
- continue;
- }
+ continue;
}
IProject project = ProjectUtilities.getProject(projectName);
@@ -912,10 +873,7 @@
//Check if this serviceRuntime supports the implementation type
if (desc.getClientImplementationType().getId().equals(clientImplId))
{
- if (!runtimeIds.contains(desc.getRuntime().getId()))
- {
- runtimeIds.add(desc.getRuntime().getId());
- }
+ runtimeIds.add(desc.getRuntime().getId());
}
}
diff --git a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeInfo.java b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeInfo.java
index a8e2562..a69832c 100644
--- a/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeInfo.java
+++ b/bundles/org.eclipse.jst.ws.consumption.ui/src/org/eclipse/jst/ws/internal/consumption/ui/wsrt/WebServiceRuntimeInfo.java
@@ -1,23 +1,21 @@
+/*
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.ui.wsrt;
import java.util.Hashtable;
+import java.util.StringTokenizer;
import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.wst.ws.internal.wsrt.IWebServiceRuntime;
-import com.ibm.icu.util.StringTokenizer;
public class WebServiceRuntimeInfo {
diff --git a/bundles/org.eclipse.jst.ws.consumption/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.consumption/META-INF/MANIFEST.MF
index aa1abde..6efc9f0 100644
--- a/bundles/org.eclipse.jst.ws.consumption/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.consumption/META-INF/MANIFEST.MF
@@ -2,28 +2,28 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.consumption; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.2.qualifier
Bundle-ClassPath: wsc.jar,
webserviceutils.jar
Bundle-Activator: org.eclipse.jst.ws.internal.consumption.plugin.WebServiceConsumptionPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.consumption;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.codegen;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.codegen.bean;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.codegen.javamofvisitoractions;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.codegen.javamofvisitors;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.command.common;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.common;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.datamodel.beanmodel;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.datamodel.validate;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.datamodel.wsdlmodel;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.fragments;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.sampleapp.codegen;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.sampleapp.command;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.sampleapp.common;x-internal:=true,
- org.eclipse.jst.ws.internal.consumption.wsfinder;x-internal:=true,
+Export-Package: org.eclipse.jst.ws.internal.consumption,
+ org.eclipse.jst.ws.internal.consumption.codegen,
+ org.eclipse.jst.ws.internal.consumption.codegen.bean,
+ org.eclipse.jst.ws.internal.consumption.codegen.javamofvisitoractions,
+ org.eclipse.jst.ws.internal.consumption.codegen.javamofvisitors,
+ org.eclipse.jst.ws.internal.consumption.command.common,
+ org.eclipse.jst.ws.internal.consumption.common,
+ org.eclipse.jst.ws.internal.consumption.datamodel.beanmodel,
+ org.eclipse.jst.ws.internal.consumption.datamodel.validate,
+ org.eclipse.jst.ws.internal.consumption.datamodel.wsdlmodel,
+ org.eclipse.jst.ws.internal.consumption.fragments,
+ org.eclipse.jst.ws.internal.consumption.plugin,
+ org.eclipse.jst.ws.internal.consumption.sampleapp.codegen,
+ org.eclipse.jst.ws.internal.consumption.sampleapp.command,
+ org.eclipse.jst.ws.internal.consumption.sampleapp.common,
+ org.eclipse.jst.ws.internal.consumption.wsfinder,
org.eclipse.jst.ws.util
Require-Bundle: org.eclipse.jem,
org.eclipse.jem.workbench,
@@ -57,6 +57,5 @@
org.eclipse.wst.common.environment,
org.eclipse.wst.common.project.facet.core,
org.eclipse.jst.server.core,
- com.ibm.icu,
org.eclipse.ui
Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateFacetedProjectCommand.java b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateFacetedProjectCommand.java
index 27ebdab..c5e20ad 100644
--- a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateFacetedProjectCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateFacetedProjectCommand.java
@@ -12,7 +12,6 @@
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
* 20060217 126757 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.command.common;
@@ -124,7 +123,7 @@
private IStatus checkDataReady()
{
- if (projectName == null)
+ if (projectName == null || serverFactoryId == null)
{
return StatusUtils.errorStatus(NLS.bind(ConsumptionMessages.MSG_ERROR_PROJECT_CREATION, new String[] {projectName}));
}
@@ -192,40 +191,37 @@
private void setFacetRuntime()
{
- if (serverInstanceId != null && serverInstanceId.length()>0)
- {
- IServer server = ServerCore.findServer(serverInstanceId);
- IRuntime sRuntime = server.getRuntime();
- facetRuntime = FacetUtil.getRuntime(sRuntime);
- }
- else
- {
- if (serverFactoryId != null && serverFactoryId.length() > 0)
- {
- //Find a non Stub runtime that matches this server type
- IRuntime serverRuntime = ServerUtils.getNonStubRuntime(serverFactoryId);
- if (serverRuntime != null)
- {
- facetRuntime = FacetUtil.getRuntime(serverRuntime);
- }
- else
- {
- //Accept stub runtime.
- IServerType st = ServerCore.findServerType(serverFactoryId);
- String runtimeTypeId = st.getRuntimeType().getId();
- //Find the facet runtime
- IRuntime[] runtimes = ServerCore.getRuntimes();
- for (int i=0; i<runtimes.length; i++)
- {
- IRuntime sRuntime = runtimes[i];
- if (sRuntime.getRuntimeType().getId().equals(runtimeTypeId))
- {
- facetRuntime = FacetUtil.getRuntime(sRuntime);
- }
- }
- }
- }
- }
+ if (serverInstanceId != null && serverInstanceId.length()>0)
+ {
+ IServer server = ServerCore.findServer(serverInstanceId);
+ IRuntime sRuntime = server.getRuntime();
+ facetRuntime = FacetUtil.getRuntime(sRuntime);
+ }
+ else
+ {
+ //Find a non Stub runtime that matches this server type
+ IRuntime serverRuntime = ServerUtils.getNonStubRuntime(serverFactoryId);
+ if (serverRuntime != null)
+ {
+ facetRuntime = FacetUtil.getRuntime(serverRuntime);
+ }
+ else
+ {
+ //Accept stub runtime.
+ IServerType st = ServerCore.findServerType(serverFactoryId);
+ String runtimeTypeId = st.getRuntimeType().getId();
+ //Find the facet runtime
+ IRuntime[] runtimes = ServerCore.getRuntimes();
+ for (int i=0; i<runtimes.length; i++)
+ {
+ IRuntime sRuntime = runtimes[i];
+ if (sRuntime.getRuntimeType().getId().equals(runtimeTypeId))
+ {
+ facetRuntime = FacetUtil.getRuntime(sRuntime);
+ }
+ }
+ }
+ }
}
/*
diff --git a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateModuleCommand.java b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateModuleCommand.java
index e0cce92..1821b89 100644
--- a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateModuleCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/CreateModuleCommand.java
@@ -10,7 +10,7 @@
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner *
- * 20060217 126757 rsinha@ca.ibm.com - Rupam Kuehner
+ * 20060217 126757 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.command.common;
diff --git a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/common/FacetUtils.java b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/common/FacetUtils.java
index 93e9172..0aa1a45 100644
--- a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/common/FacetUtils.java
+++ b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/common/FacetUtils.java
@@ -10,7 +10,7 @@
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060217 126757 rsinha@ca.ibm.com - Rupam Kuehner
+ * 20060217 126757 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.consumption.common;
@@ -21,6 +21,7 @@
import java.util.Iterator;
import java.util.List;
import java.util.Set;
+import java.util.StringTokenizer;
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.ResourcesPlugin;
@@ -48,7 +49,6 @@
import org.eclipse.wst.common.project.facet.core.IFacetedProject.Action.Type;
import org.eclipse.wst.common.project.facet.core.runtime.IRuntime;
import org.eclipse.wst.common.project.facet.core.runtime.RuntimeManager;
-import com.ibm.icu.util.StringTokenizer;
public class FacetUtils
{
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.creation.ui/META-INF/MANIFEST.MF
index 263b52e..851f254 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.creation.ui/META-INF/MANIFEST.MF
@@ -2,20 +2,20 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.creation.ui; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.creation.ui.plugin.WebServiceCreationUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.creation.ui;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.ant;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.extension;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.preferences;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.server;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.widgets;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.widgets.binding;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.widgets.runtime;x-internal:=true,
- org.eclipse.jst.ws.internal.creation.ui.widgets.test;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.creation.ui,
+ org.eclipse.jst.ws.internal.creation.ui.ant,
+ org.eclipse.jst.ws.internal.creation.ui.extension,
+ org.eclipse.jst.ws.internal.creation.ui.plugin,
+ org.eclipse.jst.ws.internal.creation.ui.preferences,
+ org.eclipse.jst.ws.internal.creation.ui.server,
+ org.eclipse.jst.ws.internal.creation.ui.widgets,
+ org.eclipse.jst.ws.internal.creation.ui.widgets.binding,
+ org.eclipse.jst.ws.internal.creation.ui.widgets.runtime,
+ org.eclipse.jst.ws.internal.creation.ui.widgets.test
Require-Bundle: org.eclipse.wst.command.env,
org.eclipse.wst.command.env.ui,
org.eclipse.wst.command.env.core,
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/plugin.properties b/bundles/org.eclipse.jst.ws.creation.ui/plugin.properties
index 5e18d4a..c124705 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/plugin.properties
+++ b/bundles/org.eclipse.jst.ws.creation.ui/plugin.properties
@@ -25,10 +25,10 @@
# Web Services Preferance Pages
#
# Dialogs
-CHECKBOX_SHOW_DEPLOY_WEB_SERVICE_DIALOG=Hide &Create Web service Dialog
-CHECKBOX_SHOW_GENERATE_SKELETON_DIALOG=Hide Generate Java Bean S&keleton Dialog
+CHECKBOX_SHOW_DEPLOY_WEB_SERVICE_DIALOG=Hide Create Web service Dialog
+CHECKBOX_SHOW_GENERATE_SKELETON_DIALOG=Hide Generate Java Bean Skeleton Dialog
CHECKBOX_SHOW_GENERATE_WSDL_FILES_DIALOG=Hide Generate WSDL Files Dialog
-CHECKBOX_SHOW_PUBLISH_WSDL_DIALOG=Hide Publish &WSDL Dialog
+CHECKBOX_SHOW_PUBLISH_WSDL_DIALOG=Hide Publish WSDL Dialog
PREFERENCE_CATEGORY_SCENARIO_DEFAULTS=Scenario Defaults
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/plugin.xml b/bundles/org.eclipse.jst.ws.creation.ui/plugin.xml
index 386150c..fb08480 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/plugin.xml
+++ b/bundles/org.eclipse.jst.ws.creation.ui/plugin.xml
@@ -39,7 +39,7 @@
name="%PLUGIN_EXPORT_WIZARD_NAME_WS"
icon="icons/export_ws.gif"
class="org.eclipse.wst.command.internal.env.ui.widgets.DynamicWizard"
- id="org.eclipse.jst.ws.consumption.ui.wsexport">
+ id="wsexport">
<description>
%PLUGIN_EXPORT_WIZARD_DESC_WS
</description>
@@ -52,7 +52,7 @@
iconbanner="icons/export_ws_wiz.gif"
name="%PLUGIN_EXPORT_WIZARD_NAME_WS"
class="org.eclipse.jst.ws.internal.creation.ui.widgets.binding.ExportWSWidgetBinding"
- id="org.eclipse.jst.ws.consumption.ui.wsexport">
+ id="wsexport">
</dynamicWizard>
</extension>
@@ -254,13 +254,11 @@
key="InitialSelection"
operation="org.eclipse.jst.ws.internal.creation.ui.widgets.ServerWizardWidgetDefaultingCommand"
property="InitialSelection"
- required="true"
transform="org.eclipse.jst.ws.internal.common.String2SelectionTransformer"/>
<map
key="InitialSelection"
operation="org.eclipse.jst.ws.internal.consumption.ui.widgets.object.ObjectSelectionOutputCommand"
property="ObjectSelection"
- required="true"
transform="org.eclipse.jst.ws.internal.common.String2SelectionTransformer"/>
<map
key="Project"
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/ant/AntServiceRootCommandFragment.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/ant/AntServiceRootCommandFragment.java
index f26be75..40ad678 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/ant/AntServiceRootCommandFragment.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/ant/AntServiceRootCommandFragment.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.ant;
@@ -93,7 +90,6 @@
dataRegistry.addMapping(AntDefaultingOperation.class, "ClientIdsFixed", ServerRuntimeSelectionWidgetDefaultingCommand.class);
dataRegistry.addMapping(AntDefaultingOperation.class, "StartService", PreServiceDevelopCommand.class);
dataRegistry.addMapping(AntDefaultingOperation.class, "InstallService", PreServiceDevelopCommand.class);
- dataRegistry.addMapping(AntDefaultingOperation.class, "DeployService", PreServiceDevelopCommand.class);
// Map ServerRuntimeSelectionWidgetDefaultingCommand
dataRegistry.addMapping(ServerRuntimeSelectionWidgetDefaultingCommand.class, "ServiceTypeRuntimeServer", ServerExtensionDefaultingCommand.class);
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDeployCommand.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDeployCommand.java
index 4e55759..b4668ec 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDeployCommand.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDeployCommand.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.extension;
@@ -19,24 +16,11 @@
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelOperation;
-import org.eclipse.wst.ws.internal.wsrt.IContext;
public class PreServiceDeployCommand extends AbstractDataModelOperation
{
- private IContext context_;
public IStatus execute( IProgressMonitor monitor, IAdaptable adaptable )
{
- if (context_.getDeploy())
- {
- //If and when there are framework specific deploy things to be done,
- //do them here.
- }
-
return Status.OK_STATUS;
}
-
- public void setContext(IContext context)
- {
- context_=context;
- }
}
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDevelopCommand.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDevelopCommand.java
index 3df8d7e..9d2d376 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDevelopCommand.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/PreServiceDevelopCommand.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.extension;
@@ -54,7 +53,6 @@
private String j2eeLevel_;
private ResourceContext resourceContext_;
- private boolean deploy_;
private boolean install_;
private boolean run_;
private boolean client_;
@@ -109,7 +107,7 @@
wsInfo.setWsdlURL(wsdlURL);
}
- context_ = new SimpleContext(true, true, deploy_, install_, run_, client_, test_, publish_,
+ context_ = new SimpleContext(true, true, true, install_, run_, client_, test_, publish_,
scenario,
resourceContext_.isOverwriteFilesEnabled(),
resourceContext_.isCreateFoldersEnabled(),
@@ -236,11 +234,6 @@
{
install_ = installService;
}
-
- public void setDeployService(boolean deployService)
- {
- deploy_ = deployService;
- }
public void setStartService(boolean startService)
{
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/ServiceRootFragment.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/ServiceRootFragment.java
index b3d9c2c..36dad87 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/ServiceRootFragment.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/extension/ServiceRootFragment.java
@@ -1,16 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.extension;
@@ -102,8 +101,6 @@
registry.addMapping( PreServiceDevelopCommand.class, "EarProject", PreServiceAssembleCommand.class );
registry.addMapping( PreServiceDevelopCommand.class, "Ear", PreServiceAssembleCommand.class );
- registry.addMapping( PreServiceDevelopCommand.class, "Context", PreServiceDeployCommand.class );
-
registry.addMapping( PreServiceDevelopCommand.class, "WebService", PreServiceInstallCommand.class );
registry.addMapping( PreServiceDevelopCommand.class, "Project", PreServiceInstallCommand.class );
registry.addMapping( PreServiceDevelopCommand.class, "Module", PreServiceInstallCommand.class );
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/binding/ServerWidgetBinding.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/binding/ServerWidgetBinding.java
index 1797b8f..9dd1600 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/binding/ServerWidgetBinding.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/binding/ServerWidgetBinding.java
@@ -1,17 +1,16 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
* 20060204 121605 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.widgets.binding;
@@ -382,7 +381,6 @@
dataRegistry.addMapping( ServerExtensionDefaultingCommand.class, "TestService", PreClientDevelopCommand.class);
dataRegistry.addMapping( ServerWizardWidgetOutputCommand.class, "ResourceContext", PreClientDevelopCommand.class);
- dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "DeployClient", PreClientDevelopCommand.class );
dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "InstallClient", PreClientDevelopCommand.class );
dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "InstallClient", PreClientDevelopCommand.class, "StartService", null);
dataRegistry.addMapping( ClientExtensionDefaultingCommand.class, "ClientTypeRuntimeServer", PreClientDevelopCommand.class );
@@ -514,7 +512,6 @@
dataRegistry.addMapping(ServerExtensionDefaultingCommand.class, "ServiceTypeRuntimeServer", ClientTestDelegateCommand.class);
// Setup the PreServiceDevelopCommand.
- dataRegistry.addMapping( ServerExtensionDefaultingCommand.class, "DeployService", PreServiceDevelopCommand.class);
dataRegistry.addMapping( ServerExtensionDefaultingCommand.class, "InstallService", PreServiceDevelopCommand.class);
dataRegistry.addMapping( ServerExtensionDefaultingCommand.class, "StartService", PreServiceDevelopCommand.class);
dataRegistry.addMapping( ServerExtensionDefaultingCommand.class, "TestService", PreServiceDevelopCommand.class);
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidget.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidget.java
index 88334ad..0ad7f22 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidget.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidget.java
@@ -1,17 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
- * 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 100190 pmoogk@ca.ibm.com - Peter Moogk
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * 20060204 124408 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.widgets.runtime;
@@ -284,7 +282,7 @@
{
IStatus serviceStatus = runtimeWidget_.getStatus();
IStatus projectStatus = projectWidget_.getStatus();
- IStatus clientStatus = isClientWidgetVisible_ ? clientWidget_.getStatus() : Status.OK_STATUS;
+ IStatus clientStatus = clientWidget_.getStatus();
IStatus finalStatus = Status.OK_STATUS;
@@ -295,7 +293,8 @@
}
else if( clientStatus.getSeverity() == Status.ERROR )
{
- finalStatus = clientStatus;
+ if (isClientWidgetVisible_)
+ finalStatus = clientStatus;
}
else if ( projectStatus.getSeverity()== Status.ERROR) {
finalStatus = projectStatus;
@@ -334,44 +333,35 @@
}
else
{
- //Non-existing project is only permitted if there is a server selected.
- if (serverFactoryId==null || serverFactoryId.length()==0)
- {
- finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_PROJECT_MUST_EXIST, new String[]{projectName}));
- }
- else
- {
- // Look at the project type to ensure that it is suitable for the
- // selected runtime and server.
- String templateId = getServiceComponentType();
+ //Look at the project type to ensure that it is suitable for the selected runtime
+ //and server.
+
+ String templateId = getServiceComponentType();
- if (templateId != null && templateId.length() > 0)
+ if (templateId != null && templateId.length()>0)
+ {
+ //Check if the runtime supports it.
+ if (!WebServiceRuntimeExtensionUtils2.doesServiceTypeAndRuntimeSupportTemplate(typeId, runtimeId, templateId))
{
- // Check if the runtime supports it.
- if (!WebServiceRuntimeExtensionUtils2.doesServiceTypeAndRuntimeSupportTemplate(typeId, runtimeId, templateId))
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ String templateLabel = FacetUtils.getTemplateLabelById(templateId);
+ finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_SERVICE_RUNTIME_DOES_NOT_SUPPORT_TEMPLATE, new String[]{runtimeLabel, templateLabel}));
+ }
+
+ //Check if the server supports it.
+ if (serverFactoryId!=null && serverFactoryId.length()>0)
+ {
+ if (!valUtils.doesServerSupportTemplate(serverFactoryId, templateId))
{
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(runtimeId);
+ String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
String templateLabel = FacetUtils.getTemplateLabelById(templateId);
- finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_SERVICE_RUNTIME_DOES_NOT_SUPPORT_TEMPLATE,
- new String[] { runtimeLabel, templateLabel }));
- }
-
- // Check if the server supports it.
- if (serverFactoryId != null && serverFactoryId.length() > 0)
- {
- if (!valUtils.doesServerSupportTemplate(serverFactoryId, templateId))
- {
- String serverLabel = WebServiceRuntimeExtensionUtils2.getServerLabelById(serverFactoryId);
- String templateLabel = FacetUtils.getTemplateLabelById(templateId);
- finalStatus = StatusUtils.errorStatus(NLS.bind(
- ConsumptionUIMessages.MSG_SERVICE_SERVER_DOES_NOT_SUPPORT_TEMPLATE,
- new String[] { serverLabel, templateLabel }));
- }
+ finalStatus = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_SERVICE_SERVER_DOES_NOT_SUPPORT_TEMPLATE, new String[]{serverLabel, templateLabel}));
}
}
}
+
}
}
diff --git a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidgetDefaultingCommand.java b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidgetDefaultingCommand.java
index 5eae02e..43a9705 100644
--- a/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidgetDefaultingCommand.java
+++ b/bundles/org.eclipse.jst.ws.creation.ui/src/org/eclipse/jst/ws/internal/creation/ui/widgets/runtime/ServerRuntimeSelectionWidgetDefaultingCommand.java
@@ -1,17 +1,15 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
+ * IBM Corporation - initial API and implementation
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 121071 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
*******************************************************************************/
package org.eclipse.jst.ws.internal.creation.ui.widgets.runtime;
@@ -37,8 +35,8 @@
import org.eclipse.jst.ws.internal.consumption.ui.preferences.ProjectTopologyContext;
import org.eclipse.jst.ws.internal.consumption.ui.widgets.runtime.ClientRuntimeSelectionWidgetDefaultingCommand;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.FacetMatchCache;
-import org.eclipse.jst.ws.internal.consumption.ui.wsrt.RuntimeDescriptor;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.ServiceRuntimeDescriptor;
+import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils;
import org.eclipse.jst.ws.internal.consumption.ui.wsrt.WebServiceRuntimeExtensionUtils2;
import org.eclipse.jst.ws.internal.data.TypeRuntimeServer;
import org.eclipse.osgi.util.NLS;
@@ -310,15 +308,10 @@
}
//No suitable server was found. Popup an error.
- RuntimeDescriptor runtimeDescriptor = WebServiceRuntimeExtensionUtils2.getRuntimeById(serviceIds_.getRuntimeId());
- if (runtimeDescriptor.getServerRequired())
- {
- String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(serviceIds_.getRuntimeId());
- IStatus status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[]{runtimeLabel}) );
- return status;
- }
-
- return Status.OK_STATUS;
+ String runtimeLabel = WebServiceRuntimeExtensionUtils2.getRuntimeLabelById(serviceIds_.getRuntimeId());
+ String serverLabels = getServerLabels(serviceIds_.getRuntimeId());
+ IStatus status = StatusUtils.errorStatus(NLS.bind(ConsumptionUIMessages.MSG_ERROR_NO_SERVER_RUNTIME, new String[]{runtimeLabel, serverLabels}) );
+ return status;
}
private IServer getServerFromServiceRuntimeId()
@@ -359,33 +352,72 @@
return null;
}
+ /*
+ private IServer getFirstSupportedServer(IServer[] servers, String serviceRuntimeId, IProject serviceProject)
+ {
+ if (servers != null && servers.length > 0) {
+ for (int i = 0; i < servers.length; i++)
+ {
+ String serverFactoryId = servers[i].getServerType().getId();
+ if (WebServiceRuntimeExtensionUtils2.doesServiceRuntimeSupportServer(serviceRuntimeId, serverFactoryId))
+ {
+ //TODO check if the server type supports the project before returning.
+ return servers[i];
+ }
+ }
+ }
+ return null;
+ }
+ */
+ private String getServerLabels(String serviceRuntimeId)
+ {
+ String[] validServerFactoryIds = WebServiceRuntimeExtensionUtils2.getServerFactoryIdsByServiceRuntime(serviceRuntimeId);
+ //String[] validServerLabels = new String[validServerFactoryIds.length];
+ StringBuffer validServerLabels = new StringBuffer();
+ for (int i=0; i<validServerFactoryIds.length; i++)
+ {
+ if (i>0)
+ {
+ validServerLabels.append(", ");
+ }
+ validServerLabels.append(WebServiceRuntimeExtensionUtils.getServerLabelById(validServerFactoryIds[i]));
+
+ }
+ return validServerLabels.toString();
+ }
+
private String getDefaultServiceProjectTemplate()
{
String[] templates = WebServiceRuntimeExtensionUtils2.getServiceProjectTemplates(serviceIds_.getTypeId(), serviceIds_.getRuntimeId());
- //Walk the list of service project types in the project topology preference
- ProjectTopologyContext ptc= WebServiceConsumptionUIPlugin.getInstance().getProjectTopologyContext();
- String[] preferredTemplateIds = ptc.getServiceTypes();
- for (int j = 0; j < preferredTemplateIds.length; j++)
+ //Pick the Web one if it's there, otherwise pick the first one.
+ for (int i=0; i<templates.length; i++)
{
- for (int i = 0; i < templates.length; i++)
+ String templateId = templates[i];
+ if (templateId.indexOf("web") != -1)
{
- String templateId = templates[i];
- if (templateId.equals(preferredTemplateIds[j]))
+ boolean matches = WebServiceRuntimeExtensionUtils2.doesServiceRuntimeSupportTemplate(serviceRuntimeId_, templateId);
+ if (matches)
{
- boolean matches = WebServiceRuntimeExtensionUtils2.doesServiceRuntimeSupportTemplate(serviceRuntimeId_, templateId);
- if (matches)
- {
- return templates[i];
- }
- }
+ return templates[i];
+ }
+ }
+ }
+
+ //Didn't find a "web" type. Return the first one that is a match. Calculate the facet matcher for the template
+ //so that we know what to create and what to add during module creation.
+ for (int j = 0; j < templates.length; j++)
+ {
+ String templateId = templates[j];
+ boolean matches = WebServiceRuntimeExtensionUtils2.doesServiceRuntimeSupportTemplate(serviceRuntimeId_, templateId);
+ if (matches)
+ {
+ return templates[j];
}
}
- //Since the preferredTemplateIds contains the union of all project types for all service runtimes, we are
- //guaranteed to have returned by now, so the code below will never be executed under normal
- //circumstances. Just return something to satisfy the compiler.
+ //Still nothing, return the first one if available.
if (templates.length > 0)
return templates[0];
@@ -572,4 +604,4 @@
return serviceNeedEAR_;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.uddiregistry/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.uddiregistry/META-INF/MANIFEST.MF
index 1897c7d..355c430 100644
--- a/bundles/org.eclipse.jst.ws.uddiregistry/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.uddiregistry/META-INF/MANIFEST.MF
@@ -2,21 +2,20 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.uddiregistry; singleton:=true
-Bundle-Version: 1.0.100.qualifier
+Bundle-Version: 1.0.0.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.uddiregistry.plugin.WebServiceUDDIRegistryPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.uddiregistry;x-internal:=true,
- org.eclipse.jst.ws.internal.uddiregistry.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.uddiregistry.widgets;x-internal:=true,
- org.eclipse.jst.ws.internal.uddiregistry.widgets.binding;x-internal:=true,
- org.eclipse.jst.ws.internal.uddiregistry.wizard;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.uddiregistry.plugin,
+ org.eclipse.jst.ws.internal.uddiregistry.widgets,
+ org.eclipse.jst.ws.internal.uddiregistry.widgets.binding,
+ org.eclipse.jst.ws.internal.uddiregistry.wizard,
+ org.eclipse.jst.ws.internal.uddiregistry
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.eclipse.jst.ws.ui,
org.eclipse.wst.command.env.core,
org.eclipse.wst.command.env,
org.eclipse.wst.command.env.ui,
- org.eclipse.wst.common.frameworks,
- com.ibm.icu
+ org.eclipse.wst.common.frameworks
Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.jst.ws.uddiregistry/src/org/eclipse/jst/ws/internal/uddiregistry/wizard/PrivateUDDIRegistryTypeRegistry.java b/bundles/org.eclipse.jst.ws.uddiregistry/src/org/eclipse/jst/ws/internal/uddiregistry/wizard/PrivateUDDIRegistryTypeRegistry.java
index 375510e..5fd441e 100644
--- a/bundles/org.eclipse.jst.ws.uddiregistry/src/org/eclipse/jst/ws/internal/uddiregistry/wizard/PrivateUDDIRegistryTypeRegistry.java
+++ b/bundles/org.eclipse.jst.ws.uddiregistry/src/org/eclipse/jst/ws/internal/uddiregistry/wizard/PrivateUDDIRegistryTypeRegistry.java
@@ -1,24 +1,21 @@
/*******************************************************************************
- * Copyright (c) 2002, 2006 IBM Corporation and others.
+ * Copyright (c) 2002, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.uddiregistry.wizard;
+import java.util.StringTokenizer;
import java.util.Vector;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.Platform;
-import com.ibm.icu.util.StringTokenizer;
public class PrivateUDDIRegistryTypeRegistry {
diff --git a/bundles/org.eclipse.jst.ws.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws.ui/META-INF/MANIFEST.MF
index 9dd22ee..6ef0740 100644
--- a/bundles/org.eclipse.jst.ws.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws.ui/META-INF/MANIFEST.MF
@@ -2,17 +2,17 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws.ui; singleton:=true
-Bundle-Version: 1.0.100.qualifier
+Bundle-Version: 1.0.0.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.ui.plugin.WebServiceUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal.ui;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.action;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.common;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.dialog;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.plugin;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.preferences;x-internal:=true,
- org.eclipse.jst.ws.internal.ui.uddi;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal.ui.action,
+ org.eclipse.jst.ws.internal.ui.common,
+ org.eclipse.jst.ws.internal.ui.dialog,
+ org.eclipse.jst.ws.internal.ui.plugin,
+ org.eclipse.jst.ws.internal.ui.preferences,
+ org.eclipse.jst.ws.internal.ui.uddi,
+ org.eclipse.jst.ws.internal.ui
Require-Bundle: org.eclipse.wst.command.env,
org.eclipse.wst.command.env.ui,
org.eclipse.wst.command.env.core,
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPlugin.properties b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPlugin.properties
index 1dcddc3..21d64a1 100644
--- a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPlugin.properties
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPlugin.properties
@@ -1,15 +1,12 @@
###############################################################################
-# Copyright (c) 2004, 2006 IBM Corporation and others.
+# Copyright (c) 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
-# yyyymmdd bug Email and other contact information
-# -------- -------- -----------------------------------------------------------
-# 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+# IBM Corporation - initial API and implementation
###############################################################################
#
@@ -36,9 +33,9 @@
#
#Scenario Defaults
-BUTTON_LAUNCH_SAMPLE=&Launch the sample when generated
-LABEL_MOVE_UP=Move &up
-LABEL_MOVE_DOWN=Move &down
+BUTTON_LAUNCH_SAMPLE=Launch the sample when generated
+LABEL_MOVE_UP=Move up
+LABEL_MOVE_DOWN=Move down
#
# Preferences Tooltips
@@ -47,10 +44,9 @@
#Scenario Defaults
TOOLTIP_PPSD_PAGE=Set the defaults for the Web service scenarios.
TOOLTIP_PPSD_CHECKBOX_LAUNCH_SAMPLE=Launch the sample application after generation.
-TOOLTIP_SERVICE_TYPE_TABLE_VIEWER=Preferred order of the list of service project types
-TOOLTIP_CLIENT_TYPE_TABLE_VIEWER=Preferred order of the list of client project types
-TOOLTIP_MOVE_UP=Move the selected project type up the list
-TOOLTIP_MOVE_DOWN=Move the selected project type down the list
+TOOLTIP_CLIENT_TYPE_TABLE_VIEWER=Preferred order of the list of client types
+TOOLTIP_MOVE_UP=Move the selected client type up the list
+TOOLTIP_MOVE_DOWN=Move the selected client type down the list
#
# Resource Managment
@@ -58,9 +54,9 @@
TOOLTIP_PPRM_CHECKBOX_OVERWRITE_FILES=Overwrite files without warning.
TOOLTIP_PPRM_CHECKBOX_CREATE_FOLDERS=Create folders when necessary.
TOOLTIP_PPRM_CHECKBOX_CHECK_OUT=Check out files without warning.
-BUTTON_CREATE_FOLDERS=&Create folders when necessary
-BUTTON_OVERWRITE_FILES=&Overwrite files without warning
-BUTTON_CHECKOUT_FILES=C&heck out files without warning
+BUTTON_CREATE_FOLDERS=Create folders when necessary
+BUTTON_OVERWRITE_FILES=Overwrite files without warning
+BUTTON_CHECKOUT_FILES=Check out files without warning
#
# General messages.
@@ -99,9 +95,9 @@
TOOLTIP_PTPP_PAGE=Preference that control the project topology of your Web service and client scenarios.
TOOLTIP_ENABLE_TWO_EARS=Enable this option if you want to generate your Web service and Web service client in different EAR projects.
-LABEL_ENABLE_TWO_EARS=&Generate Web service and Web service client in different EAR projects
-LABEL_CLIENT_TYPE_NAME=Client project types
-LABEL_SERVICE_TYPE_NAME=Service project types
+LABEL_ENABLE_TWO_EARS=Generate Web service and Web service client in different EAR projects
+LABEL_CLIENT_TYPE_NAME=Client type:
+
#
# Resource Browser
#
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPluginMessages.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPluginMessages.java
index aac3fbd..7f57583 100644
--- a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPluginMessages.java
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/WSUIPluginMessages.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060227 124392 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.ui;
@@ -38,7 +35,6 @@
public static String TOOLTIP_PPSD_PAGE;
public static String TOOLTIP_PPSD_CHECKBOX_LAUNCH_SAMPLE;
public static String TOOLTIP_CLIENT_TYPE_TABLE_VIEWER;
- public static String TOOLTIP_SERVICE_TYPE_TABLE_VIEWER;
public static String TOOLTIP_MOVE_UP;
public static String TOOLTIP_MOVE_DOWN;
public static String TOOLTIP_PPRM_PAGE;
@@ -64,9 +60,8 @@
public static String LABEL_CLIENT_TYPE_NAME;
public static String DIALOG_TITLE_RESOURCE_BROWSER;
public static String TOOLTIP_RESOURCE_TREE;
- public static String LABEL_SERVICE_TYPE_NAME;
static {
NLS.initializeMessages(BUNDLE_NAME, WSUIPluginMessages.class);
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/action/LaunchImportWizardAction.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/action/LaunchImportWizardAction.java
index 825db19..9597ab9 100644
--- a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/action/LaunchImportWizardAction.java
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/action/LaunchImportWizardAction.java
@@ -36,7 +36,7 @@
try
{
- wizard.setInitialData( "org.eclipse.jst.ws.consumption.ui.wsimport" );
+ wizard.setInitialData( "wsimport" );
wizard.init( PlatformUI.getWorkbench(), selection_ );
}
catch( CoreException exc )
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/plugin/WebServiceUIPlugin.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/plugin/WebServiceUIPlugin.java
index 368f4a6..722b311 100644
--- a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/plugin/WebServiceUIPlugin.java
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/plugin/WebServiceUIPlugin.java
@@ -13,7 +13,9 @@
import java.net.MalformedURLException;
import java.net.URL;
import java.text.MessageFormat;
+
import org.eclipse.jface.resource.ImageDescriptor;
+import org.eclipse.jst.ws.internal.ui.preferences.PersistentActionDialogsContext;
import org.eclipse.ui.plugin.AbstractUIPlugin;
import org.eclipse.wst.command.internal.env.core.common.MessageUtils;
@@ -37,6 +39,8 @@
*/
private static WebServiceUIPlugin instance_;
+ private PersistentActionDialogsContext actionDialogsContext_;
+
/**
* Constructs a runtime plugin object for this plugin.
*/
@@ -53,6 +57,17 @@
static public WebServiceUIPlugin getInstance() {
return instance_;
}
+
+
+ public PersistentActionDialogsContext getActionDialogsContext()
+ {
+ if (actionDialogsContext_ == null)
+ {
+ actionDialogsContext_ = new PersistentActionDialogsContext();
+ actionDialogsContext_.load();
+ }
+ return actionDialogsContext_;
+ }
/**
* Returns the message string identified by the given key from
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceType.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceType.java
new file mode 100644
index 0000000..7e2ba9c
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceType.java
@@ -0,0 +1,48 @@
+/*******************************************************************************
+ * Copyright (c) 2002, 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.jst.ws.internal.ui.preferences;
+
+public class ActionDialogPreferenceType {
+
+ private String id_;
+ public void setId (String id) {
+ id_ = id;
+ }
+ public String getId() {
+ return id_;
+ }
+
+ private String name_;
+ public void setName(String name) {
+ name_ = name;
+ }
+ public String getName() {
+ return name_;
+ }
+
+ private String infopop_;
+ public void setInfopop (String infopop) {
+ infopop_ = infopop;
+ }
+ public String getInfopop () {
+ return infopop_;
+ }
+
+ private String tooltip_;
+ public void setTooltip (String tooltip) {
+ tooltip_= tooltip;
+ }
+ public String getTooltip () {
+ return tooltip_;
+ }
+
+ }
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceTypeRegistry.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceTypeRegistry.java
new file mode 100644
index 0000000..e6a3a3f
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogPreferenceTypeRegistry.java
@@ -0,0 +1,114 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 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.jst.ws.internal.ui.preferences;
+
+import java.util.Enumeration;
+import java.util.Hashtable;
+
+import org.eclipse.core.runtime.CoreException;
+import org.eclipse.core.runtime.IConfigurationElement;
+import org.eclipse.core.runtime.IExtensionRegistry;
+import org.eclipse.core.runtime.Platform;
+
+public class ActionDialogPreferenceTypeRegistry
+{
+ private static ActionDialogPreferenceTypeRegistry instance_;
+
+ private Hashtable typesByName_;
+
+ //
+ // Loads WebServiceType objects into this registry.
+ // This is done by querying the plugin registry for all extensions
+ // hanging on the webServiceType extension point. Extensions
+ // must implement the org.eclipse.jst.ws.ui.wizard.WebServiceType
+ // interface.
+ //
+ private void loadDialogsPreferences ()
+ {
+ IExtensionRegistry reg = Platform.getExtensionRegistry();
+ IConfigurationElement[] config = reg.getConfigurationElementsFor(
+ "org.eclipse.jst.ws.ui",
+ "actionDialogPreferenceType");
+ for(int idx=0; idx<config.length; idx++)
+ {
+ IConfigurationElement elem = config[idx];
+ try
+ {
+ Object actionDialogPreferenceType = elem.createExecutableExtension("class");
+ if (actionDialogPreferenceType instanceof ActionDialogPreferenceType)
+ {
+ ActionDialogPreferenceType dialog = (ActionDialogPreferenceType) actionDialogPreferenceType;
+ dialog.setId((String)elem.getAttribute("id"));
+ dialog.setName((String)elem.getAttribute("name"));
+ dialog.setInfopop((String)elem.getAttribute("infopop"));
+ dialog.setTooltip((String)elem.getAttribute("tooltip"));
+ add(dialog);
+ }
+ } catch (CoreException e)
+ {
+ }
+ }
+ }
+
+ //
+ // Loads actionDialogPreferenceType objects into this registry.
+ // See method getInstance().
+ //
+ private void load ()
+ {
+ typesByName_ = new Hashtable();
+ loadDialogsPreferences();
+ }
+
+ //
+ // Add the given WebServiceType to this registry.
+ // See method load().
+ //
+ private void add ( ActionDialogPreferenceType dialog )
+ {
+ typesByName_.put(dialog.getId(),dialog);
+ }
+
+ /**
+ * Returns a singleton instance of this class.
+ * @return A singleton WebServiceTypeRegistry object.
+ */
+ public static ActionDialogPreferenceTypeRegistry getInstance ()
+ {
+ if (instance_ == null)
+ {
+ instance_ = new ActionDialogPreferenceTypeRegistry();
+ instance_.load();
+ }
+ return instance_;
+ }
+
+ /**
+ * Returns all registered <code>WebServiceType</code> objects.
+ * @return All registered <code>WebServiceType</code> objects.
+ */
+ public ActionDialogPreferenceType[] getActionDialogsPrefrences ()
+ {
+ ActionDialogPreferenceType[] dialogs = new ActionDialogPreferenceType[typesByName_.size()];
+ Enumeration e = typesByName_.elements();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ dialogs[i] = (ActionDialogPreferenceType)e.nextElement();
+ }
+ return dialogs;
+ }
+
+ public ActionDialogPreferenceType getActionDialogPrefrenceTypeByName (String name)
+ {
+ return (name == null ? null : (ActionDialogPreferenceType)typesByName_.get(name));
+ }
+}
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogsPreferencePage.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogsPreferencePage.java
new file mode 100644
index 0000000..8e25b51
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ActionDialogsPreferencePage.java
@@ -0,0 +1,220 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 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.jst.ws.internal.ui.preferences;
+
+import java.util.Enumeration;
+import java.util.Hashtable;
+
+import org.eclipse.jface.preference.IPreferenceStore;
+import org.eclipse.jface.preference.PreferencePage;
+import org.eclipse.jst.ws.internal.ui.plugin.WebServiceUIPlugin;
+import org.eclipse.swt.SWT;
+import org.eclipse.swt.layout.GridLayout;
+import org.eclipse.swt.widgets.Button;
+import org.eclipse.swt.widgets.Composite;
+import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Event;
+import org.eclipse.swt.widgets.Label;
+import org.eclipse.swt.widgets.Listener;
+import org.eclipse.ui.IWorkbench;
+import org.eclipse.ui.IWorkbenchPreferencePage;
+import org.eclipse.ui.PlatformUI;
+import org.eclipse.ui.help.IWorkbenchHelpSystem;
+import org.eclipse.wst.command.internal.env.ui.EnvironmentUIMessages;
+
+;
+
+public class ActionDialogsPreferencePage extends PreferencePage implements IWorkbenchPreferencePage, Listener
+{
+ /*CONTEXT_ID PPAD0001 for the Action Dialogs Preference Page*/
+ private String INFOPOP_PPAD_PAGE = WebServiceUIPlugin.ID + ".PPAD0001";
+ //
+ private Button showAll;
+ /*CONTEXT_ID PPAD0002 for the show all check box on the Action Dialogs Preference Page*/
+ private String INFOPOP_PPAD_BUTTON_SHOW_ALL = WebServiceUIPlugin.ID + ".PPAD0002";
+ //
+ private Button hideAll;
+ /*CONTEXT_ID PPAD0003 for the hide all check box on the Action Dialogs Preference Page*/
+ private String INFOPOP_PPAD_BUTTON_HIDE_ALL = WebServiceUIPlugin.ID + ".PPAD0003";
+
+ private Hashtable checkBoxes_;
+
+ /**
+ * Creates preference page controls on demand.
+ * @param parent the parent for the preference page
+ */
+ protected Control createContents(Composite superparent)
+ {
+ checkBoxes_ = new Hashtable();
+ addOptionalDialogsCheckBoxes (superparent);
+ new Label(superparent, SWT.HORIZONTAL);
+
+ IWorkbenchHelpSystem helpSystem = PlatformUI.getWorkbench().getHelpSystem();
+
+ Composite parent = new Composite( superparent, SWT.NONE );
+ GridLayout layout = new GridLayout();
+ layout.numColumns = 2;
+ parent.setLayout( layout );
+ parent.setToolTipText(EnvironmentUIMessages.TOOLTIP_PPAD_PAGE);
+ helpSystem.setHelp(parent,INFOPOP_PPAD_PAGE);
+
+ showAll = new Button(parent, SWT.NONE);
+ showAll.setText(EnvironmentUIMessages.BUTTON_SHOW_ALL_DIALOGS);
+ showAll.addListener(SWT.Selection, this);
+ showAll.setToolTipText(EnvironmentUIMessages.TOOLTIP_PPAD_BUTTON_SHOW_ALL);
+ helpSystem.setHelp(showAll,INFOPOP_PPAD_BUTTON_SHOW_ALL);
+
+ hideAll = new Button(parent, SWT.NONE);
+ hideAll.setText(EnvironmentUIMessages.BUTTON_HIDE_ALL_DIALOGS);
+ hideAll.addListener ( SWT.Selection, this);
+ hideAll.setToolTipText(EnvironmentUIMessages.TOOLTIP_PPAD_BUTTON_HIDE_ALL);
+ helpSystem.setHelp(hideAll,INFOPOP_PPAD_BUTTON_HIDE_ALL);
+
+ initializeValues();
+ org.eclipse.jface.dialogs.Dialog.applyDialogFont(superparent);
+ return parent;
+ }
+
+ private String getMessage(String key)
+ {
+ return WebServiceUIPlugin.getMessage(key);
+ }
+
+ public void handleEvent (Event event)
+ {
+ if (showAll == event.widget)
+ handleShowAllEvent();
+
+ else if ( hideAll == event.widget)
+ handleHideAllEvent();
+ }
+
+ private void handleShowAllEvent ()
+ {
+ Enumeration e = checkBoxes_.elements();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ Button dialog = (Button) e.nextElement();
+ dialog.setSelection( true );
+ }
+ }
+
+ private void handleHideAllEvent ()
+ {
+ Enumeration e = checkBoxes_.elements();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ Button dialog = (Button) e.nextElement();
+ dialog.setSelection( false );
+ }
+ }
+
+ private void addOptionalDialogsCheckBoxes ( Composite parent)
+ {
+ PersistentActionDialogsContext context = WebServiceUIPlugin.getInstance().getActionDialogsContext();
+ ActionDialogPreferenceType[] dialogs = context.getDialogs();
+ for (int i = 0; i < dialogs.length; i++) {
+ Button checkBox = createCheckBox(parent , dialogs[i].getName());
+ checkBox.setToolTipText(getMessage(dialogs[i].getTooltip()));
+ PlatformUI.getWorkbench().getHelpSystem().setHelp(checkBox,dialogs[i].getInfopop());
+ checkBoxes_.put(dialogs[i].getId(), checkBox);
+ }
+ }
+
+ private Button createCheckBox( Composite parent, String text )
+ {
+ Button button = new Button( parent, SWT.CHECK );
+ button.setText( text );
+ return button;
+ }
+
+ /**
+ * Does anything necessary because the default button has been pressed.
+ */
+ protected void performDefaults()
+ {
+ super.performDefaults();
+ initializeDefaults();
+ }
+
+ /**
+ * Do anything necessary because the OK button has been pressed.
+ * @return whether it is okay to close the preference page
+ */
+ public boolean performOk()
+ {
+ storeValues();
+ return true;
+ }
+
+ protected void performApply()
+ {
+ performOk();
+ }
+
+ /**
+ * @see IWorkbenchPreferencePage
+ */
+ public void init(IWorkbench workbench) { }
+
+ /**
+ * The proxy information is stored in the preference store.
+ */
+ public IPreferenceStore getPreferenceStore()
+ {
+ return WebServiceUIPlugin.getInstance().getPreferenceStore();
+ }
+
+ /**
+ * Initializes states of the controls using default values
+ * in the preference store.
+ */
+ private void initializeDefaults()
+ {
+ Enumeration e = checkBoxes_.elements();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ Button dialog = (Button) e.nextElement();
+ dialog.setSelection(true);
+ }
+ }
+
+ /**
+ * Initializes states of the controls from the preferences.
+ */
+ private void initializeValues()
+ {
+ PersistentActionDialogsContext context = WebServiceUIPlugin.getInstance().getActionDialogsContext();
+ Enumeration e = checkBoxes_.keys();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ String id = (String) e.nextElement();
+ Button button = (Button) checkBoxes_.get(id);
+ button.setSelection(context.isActionDialogEnabled(id));
+ }
+ }
+
+ /**
+ * Stores the values of the controls back to the preference store.
+ */
+ private void storeValues()
+ {
+ PersistentActionDialogsContext context = WebServiceUIPlugin.getInstance().getActionDialogsContext();
+
+ Enumeration e = checkBoxes_.keys();
+ for (int i=0; e.hasMoreElements(); i++)
+ {
+ String id = (String) e.nextElement();
+ context.setActionDialogEnabled(id, ((Button)checkBoxes_.get(id)).getSelection());
+ }
+ }
+}
+
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/PersistentActionDialogsContext.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/PersistentActionDialogsContext.java
new file mode 100644
index 0000000..cabefe4
--- /dev/null
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/PersistentActionDialogsContext.java
@@ -0,0 +1,52 @@
+/*******************************************************************************
+ * Copyright (c) 2000, 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.jst.ws.internal.ui.preferences;
+
+import org.eclipse.jst.ws.internal.ui.plugin.WebServiceUIPlugin;
+import org.eclipse.wst.command.internal.env.context.PersistentContext;
+
+
+public class PersistentActionDialogsContext extends PersistentContext
+{
+ private ActionDialogPreferenceType [] dialogs_;
+
+public PersistentActionDialogsContext ()
+{
+ super( WebServiceUIPlugin.getInstance());
+}
+public void load()
+{
+ ActionDialogPreferenceTypeRegistry reg = ActionDialogPreferenceTypeRegistry.getInstance();
+ dialogs_ = reg.getActionDialogsPrefrences();
+ for (int i = 0; i < dialogs_.length; i++) {
+ setDefault(dialogs_[i].getId(), true);
+ }
+}
+
+public ActionDialogPreferenceType[] getDialogs()
+{
+ return dialogs_;
+}
+
+public void setActionDialogEnabled ( String id, boolean value)
+{
+ setValue (id, value);
+}
+
+public boolean isActionDialogEnabled( String id)
+{
+ if (id == null )
+ return true;
+ return getValueAsBoolean(id);
+}
+
+}
diff --git a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/TestFacilityDefaultsPreferencePage.java b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ScenarioDefaultsPreferencePage.java
similarity index 94%
rename from bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/TestFacilityDefaultsPreferencePage.java
rename to bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ScenarioDefaultsPreferencePage.java
index a012ffd..f7a8bf1 100644
--- a/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/TestFacilityDefaultsPreferencePage.java
+++ b/bundles/org.eclipse.jst.ws.ui/src/org/eclipse/jst/ws/internal/ui/preferences/ScenarioDefaultsPreferencePage.java
@@ -1,16 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060217 113169 pmoogk@ca.ibm.com - Peter Moogk
- * 20060222 118711 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.ui.preferences;
@@ -46,7 +42,7 @@
-public class TestFacilityDefaultsPreferencePage extends PreferencePage implements IWorkbenchPreferencePage, SelectionListener
+public class ScenarioDefaultsPreferencePage extends PreferencePage implements IWorkbenchPreferencePage, SelectionListener
{
private TableViewer webServiceTestTypeViewer_;
@@ -203,8 +199,7 @@
{
ScenarioContext context = WebServicePlugin.getInstance().getScenarioContext();
ScenarioDefaults defaults = new ScenarioDefaults();
-
- launchSample.setSelection( context.isLaunchSampleEnabled());
+ //pgm launchSample.setSelection( context.isLaunchSampleEnabled());
String[] types = context.getWebServiceTestTypes();
for (int i = 0; i < types.length; i++)
@@ -240,7 +235,7 @@
webServiceTestTypes_.copyInto(types);
context.setWebServiceTestTypes(types);
- context.setLaunchSampleEnabled(launchSample.getSelection());
+ //pgm context.setLaunchSampleEnabled(launchSample.getSelection());
}
public void widgetDefaultSelected(SelectionEvent e)
diff --git a/bundles/org.eclipse.jst.ws/META-INF/MANIFEST.MF b/bundles/org.eclipse.jst.ws/META-INF/MANIFEST.MF
index 2753a6e..862a89e 100644
--- a/bundles/org.eclipse.jst.ws/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.jst.ws/META-INF/MANIFEST.MF
@@ -2,19 +2,19 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.jst.ws
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.2.qualifier
Bundle-Activator: org.eclipse.jst.ws.internal.plugin.WebServicePlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.jst.ws.internal;x-internal:=true,
- org.eclipse.jst.ws.internal.command;x-internal:=true,
- org.eclipse.jst.ws.internal.common;x-internal:=true,
- org.eclipse.jst.ws.internal.context;x-internal:=true,
- org.eclipse.jst.ws.internal.data;x-internal:=true,
- org.eclipse.jst.ws.internal.dialog;x-internal:=true,
- org.eclipse.jst.ws.internal.ext;x-internal:=true,
- org.eclipse.jst.ws.internal.ext.test;x-internal:=true,
- org.eclipse.jst.ws.internal.plugin;x-internal:=true
+Export-Package: org.eclipse.jst.ws.internal,
+ org.eclipse.jst.ws.internal.command,
+ org.eclipse.jst.ws.internal.common,
+ org.eclipse.jst.ws.internal.context,
+ org.eclipse.jst.ws.internal.data,
+ org.eclipse.jst.ws.internal.dialog,
+ org.eclipse.jst.ws.internal.ext,
+ org.eclipse.jst.ws.internal.ext.test,
+ org.eclipse.jst.ws.internal.plugin
Require-Bundle: org.eclipse.wst.command.env,
org.eclipse.wst.command.env.ui,
org.eclipse.wst.command.env.core,
@@ -46,6 +46,5 @@
org.eclipse.jem.util,
org.eclipse.jst.common.frameworks,
org.eclipse.wst.common.environment,
- org.eclipse.wst.common.project.facet.core,
- com.ibm.icu
+ org.eclipse.wst.common.project.facet.core
Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/J2EEActionAdapterFactory.java b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/J2EEActionAdapterFactory.java
index 2bf7bf0..63b9f9a 100644
--- a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/J2EEActionAdapterFactory.java
+++ b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/J2EEActionAdapterFactory.java
@@ -6,11 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 125574 zina@ca.ibm.com - Zina Mostafia
- * 20060222 225574 gilberta@ca.ibm.com - Gilbert Andrews
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
/*
* Created on May 8, 2004
@@ -20,7 +16,6 @@
import java.io.File;
import java.net.MalformedURLException;
import java.net.URL;
-
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.IPath;
@@ -46,38 +41,19 @@
}
//has to be under the webcontent
- public static final String EJB_MODULE = "ejbModule";
- public static final String APPCLIENT_MODULE = "appClientModule";
- public static final String WEB_MODULE = "WebContent";
-
+ public static String WEB_CONTENT = "WebContent";
public static String getWSDLURI(ServiceRef serviceImpl)
{
- String moduleRoot = null;
- IProject project = ProjectUtilities.getProject(serviceImpl);
- if(J2EEUtils.isWebComponent(project))
- {
- moduleRoot = WEB_MODULE;
- }
- else if (J2EEUtils.isEJBComponent(project))
- {
- moduleRoot = EJB_MODULE;
- }
- else if (J2EEUtils.isAppClientComponent(project))
- {
- moduleRoot = APPCLIENT_MODULE;
- }
- IPath path = project.getLocation().addTrailingSeparator();
- path = path.append(moduleRoot).addTrailingSeparator();
- path = path.append(serviceImpl.getWsdlFile());
- File file = new File(path.toString());
- try{
- URL url = file.toURL();
- return url.toString();
- }catch(MalformedURLException e){return null;}
-
-
-
-
+ IProject project = ProjectUtilities.getProject(serviceImpl);
+ IPath path = project.getLocation().addTrailingSeparator();
+ path = path.append(WEB_CONTENT).addTrailingSeparator();
+ path = path.append(serviceImpl.getWsdlFile());
+ File file = new File(path.toString());
+ try{
+ URL url = file.toURL();
+ return url.toString();
+ }catch(MalformedURLException e){return null;}
+
}
public static String getWSDLURI(WSDLResourceImpl wsdlRI)
diff --git a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/String2SelectionTransformer.java b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/String2SelectionTransformer.java
index f2351b0..817d820 100644
--- a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/String2SelectionTransformer.java
+++ b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/common/String2SelectionTransformer.java
@@ -4,12 +4,12 @@
* 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
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
- * 20060222 128094 joan@ca.ibm.com - Joan Haggarty
+ * 20060303 128094 joan@ca.ibm.com - Joan Haggarty
*******************************************************************************/
package org.eclipse.jst.ws.internal.common;
diff --git a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/context/PersistentScenarioContext.java b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/context/PersistentScenarioContext.java
index 34e090b..e5ae338 100644
--- a/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/context/PersistentScenarioContext.java
+++ b/bundles/org.eclipse.jst.ws/src/org/eclipse/jst/ws/internal/context/PersistentScenarioContext.java
@@ -1,27 +1,24 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060216 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.jst.ws.internal.context;
import java.util.Enumeration;
+import java.util.StringTokenizer;
import java.util.Vector;
import org.eclipse.jst.ws.internal.ext.test.WebServiceTestExtension;
import org.eclipse.jst.ws.internal.ext.test.WebServiceTestRegistry;
import org.eclipse.jst.ws.internal.plugin.WebServicePlugin;
import org.eclipse.wst.command.internal.env.context.PersistentContext;
-import com.ibm.icu.util.StringTokenizer;
public class PersistentScenarioContext extends PersistentContext implements ScenarioContext
diff --git a/bundles/org.eclipse.wst.command.env.core/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.command.env.core/META-INF/MANIFEST.MF
index a84045b..b224dbc 100644
--- a/bundles/org.eclipse.wst.command.env.core/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.command.env.core/META-INF/MANIFEST.MF
@@ -2,17 +2,17 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.command.env.core
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.command.internal.env.core;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.common;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.context;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.data;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.fragment;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.registry;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.selection;x-internal:=true,
- org.eclipse.wst.command.internal.env.core.uri;x-internal:=true
+Export-Package: org.eclipse.wst.command.internal.env.core.data,
+ org.eclipse.wst.command.internal.env.core.fragment,
+ org.eclipse.wst.command.internal.env.core.registry,
+ org.eclipse.wst.command.internal.env.core,
+ org.eclipse.wst.command.internal.env.core.common,
+ org.eclipse.wst.command.internal.env.core.context,
+ org.eclipse.wst.command.internal.env.core.selection,
+ org.eclipse.wst.command.internal.env.core.uri
Require-Bundle: org.eclipse.wst.common.frameworks,
org.eclipse.core.commands,
org.eclipse.core.runtime,
diff --git a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/ClassEntry.java b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/ClassEntry.java
index 41e5c56..0d08d10 100644
--- a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/ClassEntry.java
+++ b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/ClassEntry.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060313 130958 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.core.data;
@@ -18,60 +15,8 @@
public class ClassEntry
{
- // A list of getter methods for a particular class.
+ public Object lastObject_;
public Vector getterList_;
-
- // A list of setter methods for a particular class.
public Vector setterList_;
-
- // A list of instance objects for this class. Only the last entry
- // should be looked at.
- private Vector objectList_ = new Vector();
-
- // A list of Interger objects that represent an ordering of objects.
- // The number of entries in the objectList vector and the orderList vector
- // should be the same. Each entry in the objectList vector is
- // corelated with each entry in the orderList vector.
- private Vector orderList_ = new Vector();
-
- public void addObject( Object object, int order )
- {
- objectList_.add(object);
- orderList_.add( new Integer(order) );
- }
-
- public Object getLastObject()
- {
- Object result = null;
-
- if( objectList_.size() > 0 )
- {
- result = objectList_.lastElement();
- }
-
- return result;
- }
-
- public int getLastOrder()
- {
- int result = -1;
-
- if( orderList_.size() > 0 )
- {
- result = ((Integer)orderList_.lastElement()).intValue();
- }
-
- return result;
- }
-
- public void removeObject( Object object )
- {
- int removalIndex = objectList_.indexOf(object);
-
- if( removalIndex != -1 )
- {
- objectList_.remove(removalIndex);
- orderList_.remove(removalIndex);
- }
- }
+ public int order_;
}
diff --git a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/DataFlowManager.java b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/DataFlowManager.java
index e7ffe03..30ce90f 100644
--- a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/DataFlowManager.java
+++ b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/data/DataFlowManager.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060313 130958 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.core.data;
@@ -27,7 +24,7 @@
private DataMappingRegistryImpl registry_;
private Hashtable classTable_;
private int order_;
- private IEnvironment environment_;
+ private IEnvironment environment_;
public DataFlowManager( DataMappingRegistryImpl registry, IEnvironment environment )
{
@@ -42,20 +39,6 @@
return registry_;
}
- // Remove this instance object from the mapping table.
- public void unprocess( Object object )
- {
- String objectType = object.getClass().getName();
- ClassEntry classEntry = (ClassEntry)classTable_.get( objectType );
-
- if( classEntry != null )
- {
- classEntry.removeObject(object);
- }
- }
-
- // Add this object to our mapping table and call the setters
- // that have corresponding getter objects.
public void process( Object object )
{
// Add this object to the classTable_ if required.
@@ -69,8 +52,9 @@
classEntry = new ClassEntry();
classTable_.put( objectType, classEntry );
}
-
- classEntry.addObject(object, order_++ );
+
+ classEntry.lastObject_ = object;
+ classEntry.order_ = order_++;
// Now process the setters for this object
Vector ruleEntries = registry_.getRuleEntries( objectType );
@@ -176,27 +160,22 @@
if( classEntry != null )
{
- Object lastObject = classEntry.getLastObject();
+ if( classEntry.getterList_ == null )
+ {
+ // Build the getter list.
+ classEntry.getterList_ = getGetterList( classEntry.lastObject_ );
+ }
- if( lastObject != null )
- {
- if( classEntry.getterList_ == null )
- {
- // Build the getter list.
- classEntry.getterList_ = getGetterList( lastObject );
- }
-
- for( int index = 0; index < classEntry.getterList_.size(); index++ )
- {
- Method getter = (Method)classEntry.getterList_.elementAt( index );
+ for( int index = 0; index < classEntry.getterList_.size(); index++ )
+ {
+ Method getter = (Method)classEntry.getterList_.elementAt( index );
- if( getter.getName().equals( "get" + sourceProperty ))
- {
- getterFound.order = classEntry.getLastOrder();
- getterFound.method = getter;
- getterFound.object = lastObject;
- break;
- }
+ if( getter.getName().equals( "get" + sourceProperty ))
+ {
+ getterFound.order = classEntry.order_;
+ getterFound.method = getter;
+ getterFound.object = classEntry.lastObject_;
+ break;
}
}
}
diff --git a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/fragment/CommandFragmentEngine.java b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/fragment/CommandFragmentEngine.java
index 0faeffc..4b98c58 100644
--- a/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/fragment/CommandFragmentEngine.java
+++ b/bundles/org.eclipse.wst.command.env.core/src/org/eclipse/wst/command/internal/env/core/fragment/CommandFragmentEngine.java
@@ -1,16 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060223 129232 pmoogk@ca.ibm.com - Peter Moogk
- * 20060313 130958 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.core.fragment;
@@ -68,27 +64,6 @@
environment_ = environment;
}
- public String toString()
- {
- String newline = System.getProperty("line.separator");
- StringBuffer buffer = new StringBuffer();
-
- buffer.append(newline);
- buffer.append("Command stack start:");
- buffer.append(newline);
-
- for( int index = 0; index < commandStack_.size(); index++ )
- {
- CommandListEntry entry = (CommandListEntry)commandStack_.elementAt(index);
- entry.dump(buffer, index);
- }
-
- buffer.append("Command start end:");
- buffer.append(newline);
-
- return buffer.toString();
- }
-
/**
* @return returns the Data mapping registry.
*/
@@ -302,7 +277,6 @@
try
{
cmd.undo( null, null );
- dataManager_.unprocess(cmd);
}
catch( Exception exc )
{
@@ -453,14 +427,6 @@
public CommandFragment fragment_;
public int parentIndex_;
public boolean fragmentStopped_;
- public boolean beforeExecute_;
-
- public void dump( StringBuffer buffer, int index )
- {
- String newline = System.getProperty("line.separator");
- String line = " " + index + "- frag: " + fragment_.getId() + " parIndex: " + parentIndex_ + " stop: " + fragmentStopped_ + " beforeExecute: " + beforeExecute_ ;
- buffer.append(line);
- buffer.append(newline);
- }
+ public boolean beforeExecute_;
}
}
diff --git a/bundles/org.eclipse.wst.command.env.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.command.env.ui/META-INF/MANIFEST.MF
index 83d273f..82e13c5 100644
--- a/bundles/org.eclipse.wst.command.env.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.command.env.ui/META-INF/MANIFEST.MF
@@ -2,18 +2,18 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.command.env.ui; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.wst.command.internal.env.ui.plugin.EnvUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.command.internal.env.ui;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.dialog;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.eclipse;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.plugin;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.preferences;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.registry;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.widgets;x-internal:=true,
- org.eclipse.wst.command.internal.env.ui.widgets.popup;x-internal:=true
+Export-Package: org.eclipse.wst.command.internal.env.ui,
+ org.eclipse.wst.command.internal.env.ui.dialog,
+ org.eclipse.wst.command.internal.env.ui.eclipse,
+ org.eclipse.wst.command.internal.env.ui.plugin,
+ org.eclipse.wst.command.internal.env.ui.preferences,
+ org.eclipse.wst.command.internal.env.ui.registry,
+ org.eclipse.wst.command.internal.env.ui.widgets,
+ org.eclipse.wst.command.internal.env.ui.widgets.popup
Require-Bundle: org.eclipse.wst.command.env.core,
org.eclipse.wst.command.env,
org.eclipse.core.runtime,
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUI.properties b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUI.properties
index 0c74610..7b5414c 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUI.properties
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUI.properties
@@ -9,8 +9,8 @@
# IBM Corporation - initial API and implementation
###############################################################################
-BUTTON_SHOW_ALL_DIALOGS=&Show All
-BUTTON_HIDE_ALL_DIALOGS=&Hide All
+BUTTON_SHOW_ALL_DIALOGS=Show All
+BUTTON_HIDE_ALL_DIALOGS=Hide All
CHECKBOX_DO_NOT_SHOW_DIALOG_AGAIN=Do not show me this dialog box again.
TOOLTIP_PPAD_PAGE=Control to show/hide the dialogs that appear when a pop-up action is executed.
@@ -23,7 +23,5 @@
WIZARD_PAGE_DESC_ANT=Select workspace folder for Ant script and properties files
MSG_STATUS_COPYING_ANT_FILES=Copying web services Ant files
MSG_ERR_COPYING_ANT_FILES=Error encountered copying Ant files
-MSG_WARNING_FILE_EXISTS=The file {0} exists. Do you want to overwrite?
-DIALOG_TITLE_OVERWRITE=Confirm Overwrite
MSG_ERROR_WIZARD_ID_NOT_FOUND=IWAB0013E Could not find wizard id: {0}
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUIMessages.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUIMessages.java
index a332a5f..c7ce6df 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUIMessages.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/EnvironmentUIMessages.java
@@ -33,8 +33,6 @@
public static String WIZARD_PAGE_DESC_ANT;
public static String MSG_STATUS_COPYING_ANT_FILES;
public static String MSG_ERR_COPYING_ANT_FILES;
- public static String MSG_WARNING_FILE_EXISTS;
- public static String DIALOG_TITLE_OVERWRITE;
static {
NLS.initializeMessages(BUNDLE_NAME, EnvironmentUIMessages.class);
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizard.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizard.java
index c23d71f..274290f 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizard.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizard.java
@@ -1,18 +1,6 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2006 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060315 128711 joan@ca.ibm.com - Joan Haggarty
- *******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.dialog;
+
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
@@ -30,8 +18,6 @@
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.jface.wizard.Wizard;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.widgets.MessageBox;
import org.eclipse.ui.INewWizard;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.IWorkbenchPage;
@@ -49,6 +35,7 @@
import org.eclipse.wst.command.internal.env.ui.plugin.EnvUIPlugin;
import org.eclipse.wst.common.environment.IStatusHandler;
import org.eclipse.wst.common.environment.NullStatusHandler;
+//import org.eclipse.wst.common.environment.IEnvironment;
public class AntFileImportWizard extends Wizard implements INewWizard {
@@ -91,7 +78,6 @@
//jvh: TODO: add extension so extenders of the command framework can register properties files to import
// here we pick up all registered Ant files and import - also would be nice to allow user to choose a subset
String[] sourceFiles = new String[]{"ant/wsgen.xml", "ant/axisclient.properties", "ant/axisservice.properties"}; //$NON-NLS$
- int filecount = 0;
for (int i = 0; i < sourceFiles.length; i++) {
String fileSource = sourceFiles[i];
String targetFile = fileSource;
@@ -103,16 +89,7 @@
}
Plugin sourcePlugin = EnvPlugin.getInstance();
//jvh: TODO - add real progress monitor in here...
-
- IStatus status = copyIFile(sourcePlugin, fileSource, destination, targetFile, (IProgressMonitor)new NullProgressMonitor());
- if (status == Status.CANCEL_STATUS)
- {
- filecount++;
- }
- }
- if (filecount == sourceFiles.length)
- {
- return false; //don't close if all files were not written out - give user opportunity to change destination
+ copyIFile(sourcePlugin, fileSource, destination, targetFile, (IProgressMonitor)new NullProgressMonitor());
}
}
return true;
@@ -129,31 +106,22 @@
try
{
ResourceContext context = new TransientResourceContext();
- // check to see if file exists before copy
- IResource resource = FileResourceUtils.findResource(target);
+ context.setOverwriteFilesEnabled(true);
+ context.setCreateFoldersEnabled(true);
+ context.setCheckoutFilesEnabled(true);
+ IResource resource = FileResourceUtils.findResource(target);
+ if(resource != null) return Status.OK_STATUS;
+ FileResourceUtils.createFile(context,
+ target,
+ plugin.openStream(new Path(source)),
+ monitor, (IStatusHandler)new NullStatusHandler());
- if (resource != null)
- {
- MessageBox overwriteBox = new MessageBox(getShell(), SWT.ICON_QUESTION|SWT.YES|SWT.NO);
- overwriteBox.setMessage(EnvironmentUIMessages.bind(EnvironmentUIMessages.MSG_WARNING_FILE_EXISTS, target.toString()));
- overwriteBox.setText(EnvironmentUIMessages.DIALOG_TITLE_OVERWRITE);
- int result = overwriteBox.open();
- if (result != SWT.NO)
- FileResourceUtils.createFile(context, target, plugin.openStream(new Path(source)),
- monitor, (IStatusHandler)new NullStatusHandler());
- else
- return Status.CANCEL_STATUS;
- }
- else
- {
- FileResourceUtils.createFile(context, target, plugin.openStream(new Path(source)),
- monitor, (IStatusHandler)new NullStatusHandler());
- }
+
}
catch (Exception e) {
return StatusUtils.errorStatus(EnvironmentUIMessages.MSG_ERR_COPYING_ANT_FILES, e);
}
- }
+ }
return Status.OK_STATUS;
}
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizardPage.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizardPage.java
index ec53a3c..da94422 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizardPage.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/dialog/AntFileImportWizardPage.java
@@ -1,15 +1,3 @@
-/*******************************************************************************
- * Copyright (c) 2005, 2006 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- *******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.dialog;
import org.eclipse.core.runtime.IPath;
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/DynamicWizard.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/DynamicWizard.java
index 77772e5..5b94b66 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/DynamicWizard.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/DynamicWizard.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060223 129232 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.widgets;
@@ -97,10 +94,11 @@
private String iconBannerName_;
private Bundle bundle_;
private SimpleCanFinishRegistry canFinishRegistry_;
+ private WizardPageManager pageManager_;
private String wizardTitle_;
private DataObjectCommand dataObjectCommand_ = null;
- private WizardPageManager pageManager_;
-
+
+ protected IWizardPage startPage_ = null;
protected IConfigurationElement wizardElement_;
protected IConfigurationElement originalElement_;
protected CommandWidgetBinding commandWidgetBinding_;
@@ -219,6 +217,7 @@
}
dataObjectCommand_ = new DataObjectCommand();
+ startPage_ = null;
canFinishRegistry_ = new SimpleCanFinishRegistry();
pageManager_ = new WizardPageManager( widgetRegistry_,
getWizardPageFactory(),
@@ -310,7 +309,12 @@
**/
public IWizardPage getStartingPage()
{
- return pageManager_.getStartingPage();
+ if( startPage_ == null )
+ {
+ startPage_ = pageManager_.getNextPage();
+ }
+
+ return startPage_;
}
/**
@@ -381,7 +385,8 @@
pageManager_ = null;
wizardTitle_ = null;
dataObjectCommand_ = null;
+ startPage_ = null;
commandWidgetBinding_ = null;
WidgetRegistry.initialize();
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/SimpleCommandEngineManager.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/SimpleCommandEngineManager.java
index 243175f..a92bb29 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/SimpleCommandEngineManager.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/SimpleCommandEngineManager.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060223 129232 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.widgets;
@@ -41,7 +38,7 @@
{
protected CommandFragmentEngine engine_;
protected DataFlowManager dataManager_;
- protected EclipseEnvironment environment_;
+ private EclipseEnvironment environment_;
private boolean foundStop_;
private boolean doNotRunInTransaction_;
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/WizardPageManager.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/WizardPageManager.java
index 0c795ce..37a8fe0 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/WizardPageManager.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/WizardPageManager.java
@@ -1,16 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060223 129232 pmoogk@ca.ibm.com - Peter Moogk
- * 20060313 130958 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.widgets;
@@ -24,7 +20,6 @@
import org.eclipse.wst.command.internal.env.core.fragment.CommandFragment;
import org.eclipse.wst.command.internal.env.eclipse.EclipseEnvironment;
import org.eclipse.wst.command.internal.env.ui.registry.WidgetRegistry;
-import org.eclipse.wst.common.environment.ILog;
@@ -69,16 +64,6 @@
widgetStackStack_ = new Stack();
}
- public IWizardPage getStartingPage()
- {
- if( firstPage_ == null )
- {
- firstPage_ = (PageWizardDataEvents)getNextPage();
- }
-
- return firstPage_;
- }
-
public IStatus runForwardToNextStop()
{
firstFragment_ = true;
@@ -130,11 +115,6 @@
// when we move forward below the data is available.
if( currentPage_ != null ) currentPage_.getDataEvents().externalize();
- if( environment_.getLog().isEnabled() )
- {
- environment_.getLog().log(ILog.INFO, "ws_dt_cmd_engine", 5010, this, "Cmd stack dump:", engine_ );
- }
-
nextPage_ = getNextPageInGroup( widgetFactory_, true );
if( nextPage_ == null )
@@ -203,10 +183,6 @@
undoToLastPage();
}
- // Since we are moving backwards we need to remove the
- // current page object from the mapping table.
- dataManager_.unprocess( currentPage_.getDataEvents() );
-
currentPage_ = page;
}
else if( isPageVisible )
@@ -229,6 +205,8 @@
{
if( currentPage_ != null ) page.setPreviousPage( currentPage_ );
+ if( firstPage_ == null ) firstPage_ = page;
+
currentPage_ = page;
}
}
@@ -499,4 +477,4 @@
INamedWidgetContributorFactory factory_;
Stack stack_;
}
-}
+}
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/popup/DynamicPopupWizard.java b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/popup/DynamicPopupWizard.java
index 5fdc31c..4738f8b 100644
--- a/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/popup/DynamicPopupWizard.java
+++ b/bundles/org.eclipse.wst.command.env.ui/src/org/eclipse/wst/command/internal/env/ui/widgets/popup/DynamicPopupWizard.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2004, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060223 129232 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.ui.widgets.popup;
@@ -124,7 +121,7 @@
dialog.setPageSize( 400, 500 );
dialog.create();
- if( getStartingPage() != null )
+ if( startPage_ != null )
{
dialog.open();
}
diff --git a/bundles/org.eclipse.wst.command.env/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.command.env/META-INF/MANIFEST.MF
index e29dfce..ab1b10b 100644
--- a/bundles/org.eclipse.wst.command.env/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.command.env/META-INF/MANIFEST.MF
@@ -3,18 +3,18 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.command.env; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.2.qualifier
Bundle-Activator: org.eclipse.wst.command.internal.env.plugin.EnvPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.command.internal.env;x-internal:=true,
- org.eclipse.wst.command.internal.env.ant;x-internal:=true,
- org.eclipse.wst.command.internal.env.commandline;x-internal:=true,
- org.eclipse.wst.command.internal.env.common;x-internal:=true,
- org.eclipse.wst.command.internal.env.context;x-internal:=true,
- org.eclipse.wst.command.internal.env.eclipse;x-internal:=true,
- org.eclipse.wst.command.internal.env.plugin;x-internal:=true,
- org.eclipse.wst.command.internal.env.preferences;x-internal:=true
+Export-Package: org.eclipse.wst.command.internal.env.ant,
+ org.eclipse.wst.command.internal.env,
+ org.eclipse.wst.command.internal.env.commandline,
+ org.eclipse.wst.command.internal.env.common,
+ org.eclipse.wst.command.internal.env.context,
+ org.eclipse.wst.command.internal.env.eclipse,
+ org.eclipse.wst.command.internal.env.plugin,
+ org.eclipse.wst.command.internal.env.preferences
Require-Bundle: org.eclipse.wst.command.env.core,
org.eclipse.core.runtime,
org.eclipse.core.resources,
diff --git a/bundles/org.eclipse.wst.command.env/ant/axisclient.properties b/bundles/org.eclipse.wst.command.env/ant/axisclient.properties
index d8b7756..f5ed32b 100644
--- a/bundles/org.eclipse.wst.command.env/ant/axisclient.properties
+++ b/bundles/org.eclipse.wst.command.env/ant/axisclient.properties
@@ -1,5 +1,5 @@
-!--ScenarioType REQUIRED. Differentiates from "service" scenario. See axisservice.properties.
-ScenarioType=client
+!--scenarioType REQUIRED. Differentiates from "service" scenario. See axisservice.properties.
+scenarioType=client
!--InitialSelection REQUIRED. Workspace relative URI to the input WSDL or Java.
InitialSelection=/dynamicWebProjectName/WebContent/wsdl/myService.wsdl
@@ -8,43 +8,39 @@
!-- Client.RuntimeId, Client.ServerId
ListRuntimes=true
ListServers=true
-!-- Verbose will list informational messages as well as errors if set to true
-Verbose=true
-
-!--Client.RuntimeId - ID of web service runtime
+!--type:String - ID of web service runtime
Client.RuntimeId=org.eclipse.jst.ws.axis.creation.axisWebServiceRT
-!--Client.ServerId - ID of target server
+!--type:String - ID of target server
Client.ServerId=org.eclipse.jst.server.tomcat.50
-!--ClientProjectName - name of Client project - this property can be used to give the client project a
+!--type:String - name of Client project - this property can be used to give the client project a
!-- different name than the project containing the initial selection
-!--ClientProjectName=clientProjectName
-
-!--ClientComponentType- name of Client EAR project - set only if applicable for selected server type
-!--ClientEarProjectName=clientEARProjectName
-
-!--ClientComponentType - type of Client project - must be one of: jst.web, jst.java - only jst.web is valid for Axis
-!--ClientComponentType=jst.web
+ClientProjectName=clientProjectName
+!--type:String - name of Client EAR project - set only if applicable for selected server type
+ClientEarProjectName=clientEARProjectName
+!--type:String - type of Client project - must be one of: jst.web, jst.java
+!-- only jst.web is valid for Axis
+ClientComponentType=jst.web
!-- CustomizeClientMappings - set to true to supply package-namespace mappings type: boolean
-!--CustomizeClientMappings=false
+CustomizeClientMappings=false
-!-- Mappings
+!-- type:String
!-- Workspace relative URI to property file containing mappings
!-- Mappings are used to override the default package names of the generated Java classes.
!-- Need not be set if CustomizeClientMappings is false
!-- The content of the properties file must be of the format package = namespace.
-!--Mappings=/testProj/mappings/mappings.txt
+Mappings=/testProj/mappings/mappings.txt
!--OverwriteFilesEnabled - set to true to overwrite files that already exist. type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!-- OverwriteFilesEnabled=true
+OverwriteFilesEnabled=true
!--CreateFoldersEnabled - set to true create folders necessary during file generation type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!-- CreateFoldersEnabled=true
+CreateFoldersEnabled=true
!--CheckoutFilesEnabled - set to true to check out files with no warning to the user type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!-- CheckoutFilesEnabled=true
+CheckoutFilesEnabled=true
diff --git a/bundles/org.eclipse.wst.command.env/ant/axisservice.properties b/bundles/org.eclipse.wst.command.env/ant/axisservice.properties
index c1a6ee8..065f980 100644
--- a/bundles/org.eclipse.wst.command.env/ant/axisservice.properties
+++ b/bundles/org.eclipse.wst.command.env/ant/axisservice.properties
@@ -1,61 +1,53 @@
-!-- ScenarioType REQUIRED. Differentiates from "client" scenario. See axisclient.properties.
-ScenarioType=service
+!-- REQUIRED. Differentiates from "client" scenario. See axisclient.properties.
+scenarioType=service
-!-- InitialSelection REQUIRED. Workspace relative URI to the input WSDL or Java
+!-- REQUIRED. Workspace relative URI to the input WSDL or Java
InitialSelection=/dynamicWebProjectName/WebContent/myService.wsdl
!--Utility property values - use these to list valid values for the following properties:
!-- Service.RuntimeId, Service.ServerId
ListRuntimes=true
ListServers=true
-!-- Verbose will list informational messages as well as errors if set to true
-Verbose=true
-!-- Service.RuntimeId - ID of web service runtime
+!-- type:String - ID of web service runtime
Service.RuntimeId=org.eclipse.jst.ws.axis.creation.axisWebServiceRT
-!-- Service.ServerId - ID of target server
+!--type:String - ID of target server
Service.ServerId=org.eclipse.jst.server.tomcat.50
!-- Service.TypeId - "Top Down EJB" or "Bottom Up EJB"
!-- Java Bean is default for both Top Down and Bottom Up
!-- Service.TypeId=Top Down EJB
-!-- ServiceProjectName - !--type:String - name of Service project - this property can be used to give the service project a different name than the project containing the initial selection. type: String
-!--ServiceProjectName=serviceProjectName
-!-- ServiceProjectName - !--type:String - name of Service project - this property can be used to give the service project a different name than the project containing the initial selection. type: String
-!--ServiceEarProjectName=serviceEarProjectName
+!--ServiceProjectName - !--type:String - name of Service project - this property can be used to give the service project a different name than the project containing the initial selection. type: String
+ServiceProjectName=serviceProjectName
+!--ServiceProjectName - !--type:String - name of Service project - this property can be used to give the service project a different name than the project containing the initial selection. type: String
+ServiceEarProjectName=serviceEarProjectName
-!-- Mappings
-!-- Top down or bottom up scenario. Workspace relative URI to property file containing mappings.
+!-- AXIS SERVICE ----
+!-- All scenarios. String: workspace relative URI to property file containing mappings
!-- Top Down: Mappings are used to override the default package names of the generated Java template classes.
!-- The content of the properties file must be of the format namespace=package
!-- Bottom Up: Mappings are used to override the default namespace names in the generated WSDL.
!-- The content of the properties file must be of the format package = namespace
-!--Mappings=/testProj/mappings/mappings.txt
+Mappings=/testProj/mappings/mappings.txt
-!-- JavaOutput
!-- Top down - String: the workspace relative URI for a Java source folder for the generated Java code - must be existing workspace source folder
-!--JavaOutput=/projectName/JavaSource
+JavaOutput=/projectName/JavaSource
-!-- Methods
!-- Bottom up - space delimited string of method signatures (i.e. method1(parmType1) method2(parmType2)) to be exposed in output WSDL. If no list is provided, all methods are exposed.
-!-- Methods=
-
-!-- Style
+Methods=
!-- Bottom up - String: one of: RPC, DOCUMENT, WRAPPED
-!--Style=DOCUMENT
-
-!-- Use
+Style=DOCUMENT
!-- Bottom up - String: one of: LITERAL, ENCODED
-!--Use=LITERAL
+Use=LITERAL
!--OverwriteFilesEnabled - set to true to overwrite files that already exist. type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!--OverwriteFilesEnabled=true
+OverwriteFilesEnabled=true
!--CreateFoldersEnabled - set to true create folders necessary during file generation type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!--CreateFoldersEnabled=true
+CreateFoldersEnabled=true
!--CheckoutFilesEnabled - set to true to check out files with no warning to the user type:boolean
!-- note for non-interactive mode it is recommended that this be set to true
-!--CheckoutFilesEnabled=true
+CheckoutFilesEnabled=true
diff --git a/bundles/org.eclipse.wst.command.env/schema/antdatamapping.exsd b/bundles/org.eclipse.wst.command.env/schema/antdatamapping.exsd
index 4d2b664..95d9cad 100644
--- a/bundles/org.eclipse.wst.command.env/schema/antdatamapping.exsd
+++ b/bundles/org.eclipse.wst.command.env/schema/antdatamapping.exsd
@@ -69,13 +69,6 @@
</documentation>
</annotation>
</attribute>
- <attribute name="required" type="boolean" use="optional" default="false">
- <annotation>
- <documentation>
-
- </documentation>
- </annotation>
- </attribute>
</complexType>
</element>
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/Environment.properties b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/Environment.properties
index 413d700..adfb459 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/Environment.properties
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/Environment.properties
@@ -24,12 +24,10 @@
MSG_ERROR_IO=IWAB0006E An input/output error occurred while processing the resource "{0}".
MSG_ERROR_FILE_OVERWRITE_DISABLED=IWAB0164E Cannot create the file "{1}" relative to the path "{0}" because automatic file overwriting has not been enabled. Do you want to enable it for this file?
MSG_ERROR_UNEXPECTED_ERROR=IWAB0014E Unexpected exception occured.
-MSG_ERROR_ANT_DATA_TRANSFORM=Exception transforming Ant property key {0} using transformation {1}.
-MSG_ERROR_ANT_CALL_SETTER=Exception invoking setter method {0} for Ant property.
-MSG_ERROR_ANT_CMD_FRAGMENT=Exception retrieving Ant command fragment from registry.
-MSG_ERROR_ANT_SCENARIO_TYPE=Cannot determine scenario type. Please ensure ScenarioType Ant property is set.
-MSG_ERROR_ANT_REQUIRED_PROPERTY=Required property {0} was not set in the Ant property file.
-MSG_INFO_ANT__PROPERTY_DEFAULT=Property {0} was not set in the Ant property file. A default value will be used.
+MSG_ERR_ANT_DATA_TRANSFORM=Exception transforming Ant property key {0} using transformation {1}.
+MSG_ERR_ANT_CALL_SETTER=Exception invoking setter method {0} for Ant property.
+MSG_ERR_ANT_CMD_FRAGMENT=Exception retrieving Ant command fragment from registry.
+MSG_ERR_ANT_SCENARIO_TYPE=Cannot determine scenario type. Please ensure scenarioType Ant property is set.
LABEL_YES=Yes
LABEL_YES_TO_ALL=Yes All
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/EnvironmentMessages.java b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/EnvironmentMessages.java
index 2c73816..7025e31 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/EnvironmentMessages.java
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/EnvironmentMessages.java
@@ -32,12 +32,10 @@
public static String MSG_ERROR_IO;
public static String MSG_ERROR_FILE_OVERWRITE_DISABLED;
public static String MSG_ERROR_UNEXPECTED_ERROR;
- public static String MSG_ERROR_ANT_DATA_TRANSFORM;
- public static String MSG_ERROR_ANT_CALL_SETTER;
- public static String MSG_ERROR_ANT_CMD_FRAGMENT;
- public static String MSG_ERROR_ANT_SCENARIO_TYPE;
- public static String MSG_ERROR_ANT_REQUIRED_PROPERTY;
- public static String MSG_INFO_ANT__PROPERTY_DEFAULT;
+ public static String MSG_ERR_ANT_DATA_TRANSFORM;
+ public static String MSG_ERR_ANT_CALL_SETTER;
+ public static String MSG_ERR_ANT_CMD_FRAGMENT;
+ public static String MSG_ERR_ANT_SCENARIO_TYPE;
public static String LABEL_YES;
public static String LABEL_YES_TO_ALL;
public static String LABEL_CANCEL;
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntController.java b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntController.java
index 914c295..4080a0f 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntController.java
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntController.java
@@ -65,7 +65,7 @@
}
else //problem getting the root fragment - scenario type is likely missing
{
- handler.reportError(new Status(IStatus.ERROR, "ws_ant", 9999, EnvironmentMessages.MSG_ERROR_ANT_SCENARIO_TYPE, null));
+ handler.reportError(new Status(IStatus.ERROR, "ws_ant", 9999, EnvironmentMessages.MSG_ERR_ANT_SCENARIO_TYPE, null));
return;
}
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntEnvironment.java b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntEnvironment.java
index 6cbb5c7..d65dbc9 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntEnvironment.java
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/ant/AntEnvironment.java
@@ -34,7 +34,6 @@
import org.eclipse.wst.command.internal.env.core.data.Transformer;
import org.eclipse.wst.command.internal.env.core.fragment.CommandFragment;
import org.eclipse.wst.command.internal.env.eclipse.EclipseEnvironment;
-import org.eclipse.wst.command.internal.env.plugin.EnvPlugin;
import org.eclipse.wst.common.environment.ILog;
import org.eclipse.wst.common.environment.IStatusHandler;
import org.eclipse.wst.common.frameworks.datamodel.AbstractDataModelOperation;
@@ -54,7 +53,7 @@
private Hashtable operationDataRecord_ = new Hashtable();
private boolean mappingComplete_;
private ClassEntry classEntry;
-
+
// extensionPoint names and namespace
private static String MAPPER_EXT_PT = "antDataMapping"; //$NON-NLS-1$
private static String SCENARIO_EXT_PT = "antScenario"; //$NON-NLS-1$
@@ -65,16 +64,11 @@
private static final String MAPPER_KEY_ATTRIBUTE= "key"; //$NON-NLS-1$
private static final String MAPPER_PROPERTY_ATTRIBUTE= "property"; //$NON-NLS-1$
private static final String MAPPER_TRANSFORM_ATTRIBUTE= "transform"; //$NON-NLS-1$
- private static final String MAPPER_REQUIRED_ATTRIBUTE= "required"; //$NON-NLS-1$
-
+
// antScenario extension point attributes
private static final String SCENARIO_TYPE_ATTRIBUTE = "scenarioType"; //$NON-NLS-1$
private static final String SCENARIO_CLASS_ATTRIBUTE = "class"; //$NON-NLS-1$
- // Ant property IDs
- private static final String VERBOSE_PROPERTY = "Verbose"; //$NON-NLS-1$
- private static final String SCENARIO_TYPE_PROPERTY = "ScenarioType"; //$NON-NLS-1$
-
private AntController controller_;
public AntEnvironment(AntController controller, ResourceContext context, IStatusHandler handler, Hashtable properties)
@@ -84,24 +78,11 @@
controller_ = controller;
}
- public boolean verbose()
- {
- String verbose=getProperty(VERBOSE_PROPERTY);
-
- if (verbose != null)
- {
- verbose = verbose.toLowerCase();
- if (verbose.equals("true"))
- return true;
- }
- return false;
- }
-
// returns String since the property table built by Ant is property value pairs where the value is a String
private String getProperty(String key)
{
Object property = antProperties_.get(key);
- if (property != null && (!property.toString().equals("")))
+ if (property != null)
return property.toString().trim();
return null;
}
@@ -228,7 +209,7 @@
catch (CoreException cex) {
Status errorStatus = new Status(Status.ERROR, "ws_ant", 5092, cex.getMessage(), cex);
getStatusHandler().reportError(errorStatus);
- getLog().log(ILog.ERROR, "ws_ant", 5092, this, "getMappingExtensions", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_DATA_TRANSFORM, key, transform));
+ getLog().log(ILog.ERROR, "ws_ant", 5092, this, "getMappingExtensions", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERR_ANT_DATA_TRANSFORM, key, transform));
throw new CoreException(errorStatus);
}
@@ -263,29 +244,7 @@
holder.value_ = value;
dataTable.put(property, holder);
}
- }
- else if(ce.getAttribute(MAPPER_REQUIRED_ATTRIBUTE)!=null && ce.getAttribute(MAPPER_REQUIRED_ATTRIBUTE).equals("true"))
- {
- String msg = EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_REQUIRED_PROPERTY, key.toString());
- Status statusObj = new Status(IStatus.ERROR,
- EnvPlugin.ID,
- IStatus.ERROR,
- msg,
- null);
- getStatusHandler().reportError(statusObj);
- getLog().log(ILog.ERROR, "ws_ant", 9999, this, "getMappingExtensions", msg);
- }
- else if (verbose())
- {
- String msg = EnvironmentMessages.bind(EnvironmentMessages.MSG_INFO_ANT__PROPERTY_DEFAULT, key.toString());
- Status statusObj = new Status(IStatus.INFO,
- EnvPlugin.ID,
- IStatus.INFO,
- msg,
- null);
- getStatusHandler().reportInfo(statusObj);
- getLog().log(ILog.INFO, "ws_ant", 9999, this, "getMappingExtensions", msg);
- }
+ }
}
}
return dataTable.elements();
@@ -320,7 +279,7 @@
catch (Exception exc)
{
getStatusHandler().reportError(new Status(Status.ERROR, "ws_ant", 5093, exc.getMessage(), exc));
- getLog().log(ILog.ERROR, "ws_ant", 5093, this, "transformAndSet", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_DATA_TRANSFORM, mapping.key_, mapping.transform_));
+ getLog().log(ILog.ERROR, "ws_ant", 5093, this, "transformAndSet", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERR_ANT_DATA_TRANSFORM, mapping.key_, mapping.transform_));
throw new IllegalArgumentException(exc.getMessage());
}
}
@@ -413,7 +372,7 @@
catch(Exception cex){
Status errorStatus = new Status(Status.ERROR, "ws_ant", 5094, cex.getMessage(), cex);
getStatusHandler().reportError(errorStatus);
- getLog().log(ILog.ERROR, "ws_ant", 5094, this, "callSetter", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_CALL_SETTER, setterMethodName));
+ getLog().log(ILog.ERROR, "ws_ant", 5094, this, "callSetter", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERR_ANT_CALL_SETTER, setterMethodName));
throw new CoreException(errorStatus);
}
}
@@ -476,7 +435,7 @@
catch(Exception e){
Status errorStatus = new Status(Status.ERROR, "ws_ant", 5095, e.getMessage(), e);
getStatusHandler().reportError(errorStatus);
- getLog().log(ILog.ERROR, "ws_ant", 5095, this, "callPrimitiveSetter", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_CALL_SETTER, element.getName()));
+ getLog().log(ILog.ERROR, "ws_ant", 5095, this, "callPrimitiveSetter", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERR_ANT_CALL_SETTER, element.getName()));
throw new CoreException(errorStatus);
}
}
@@ -505,7 +464,7 @@
{
Status errorStatus = new Status(Status.ERROR, "ws_ant", 5096, exc.getMessage(), exc);
getStatusHandler().reportError(errorStatus);
- getLog().log(ILog.ERROR, "ws_ant", 5096, this, "callSetterConstructor", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERROR_ANT_CALL_SETTER, element.getName()));
+ getLog().log(ILog.ERROR, "ws_ant", 5096, this, "callSetterConstructor", EnvironmentMessages.bind(EnvironmentMessages.MSG_ERR_ANT_CALL_SETTER, element.getName()));
throw new CoreException(errorStatus);
}
}
@@ -524,7 +483,7 @@
{
//look up the commandFragment in the scenarioRegistry extension point with an ID corresponding to the scenario property in the propertytable
- String scenarioProperty = (String)getProperty(SCENARIO_TYPE_PROPERTY);
+ String scenarioProperty = (String)getProperty(SCENARIO_TYPE_ATTRIBUTE);
IExtensionRegistry reg = Platform.getExtensionRegistry();
IExtensionPoint extPt = reg.getExtensionPoint(EXT_PT_NAMESPACE, SCENARIO_EXT_PT);
@@ -548,7 +507,7 @@
{
Status errorStatus = new Status(Status.ERROR, "ws_ant", 5097, exception.getMessage(), exception);
getStatusHandler().reportError(errorStatus);
- getLog().log(ILog.ERROR, "ws_ant", 5097, this, "getRootCommandFragment", EnvironmentMessages.MSG_ERROR_ANT_CMD_FRAGMENT);
+ getLog().log(ILog.ERROR, "ws_ant", 5097, this, "getRootCommandFragment", EnvironmentMessages.MSG_ERR_ANT_CMD_FRAGMENT);
}
}
}
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/common/FileResourceUtils.java b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/common/FileResourceUtils.java
index 81142a3..0c85096 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/common/FileResourceUtils.java
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/common/FileResourceUtils.java
@@ -4,12 +4,11 @@
* 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060112 121199 jesper@selskabet.org - Jesper Møller
+ * IBM Corporation - initial API and implementation
+ * yyyymmdd bug # email comment
+ * 20060112 [121199] jesper@selskabet.org - Jesper S Moller contributed patch for createFileAtLocation and makeFolderPathAtLocation
*******************************************************************************/
package org.eclipse.wst.command.internal.env.common;
diff --git a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/plugin/EnvPlugin.java b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/plugin/EnvPlugin.java
index 6eb1c42..cb8f4ab 100644
--- a/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/plugin/EnvPlugin.java
+++ b/bundles/org.eclipse.wst.command.env/src/org/eclipse/wst/command/internal/env/plugin/EnvPlugin.java
@@ -22,11 +22,6 @@
private static EnvPlugin instance;
/**
- * The identifier of the descriptor of this plugin in plugin.xml.
- */
- public static final String ID = "org.eclipse.wst.command.env";
-
- /**
* The constructor.
*/
public EnvPlugin() {
diff --git a/bundles/org.eclipse.wst.ws.explorer/.cvsignore b/bundles/org.eclipse.wst.ws.explorer/.cvsignore
index a8fd994..7b4a75f 100644
--- a/bundles/org.eclipse.wst.ws.explorer/.cvsignore
+++ b/bundles/org.eclipse.wst.ws.explorer/.cvsignore
@@ -6,4 +6,3 @@
*.jar
*.war
explorersrc.zip
-javaCompiler.*.args
diff --git a/bundles/org.eclipse.wst.ws.explorer/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.ws.explorer/META-INF/MANIFEST.MF
index d553271..3aab59c 100644
--- a/bundles/org.eclipse.wst.ws.explorer/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.ws.explorer/META-INF/MANIFEST.MF
@@ -2,16 +2,50 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.ws.explorer; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-ClassPath: explorer.jar,
wsexplorer-properties.jar
Bundle-Activator: org.eclipse.wst.ws.internal.explorer.plugin.ExplorerPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.ws.internal.explorer;x-internal:=true,
- org.eclipse.wst.ws.internal.explorer.favorites;x-internal:=true,
- org.eclipse.wst.ws.internal.explorer.plugin;x-internal:=true,
- org.eclipse.wst.ws.internal.explorer.popup;x-internal:=true
+Export-Package: org.eclipse.wst.ws.internal.explorer,
+ org.eclipse.wst.ws.internal.explorer.favorites,
+ org.eclipse.wst.ws.internal.explorer.platform.actions,
+ org.eclipse.wst.ws.internal.explorer.platform.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.datamodel,
+ org.eclipse.wst.ws.internal.explorer.platform.engine,
+ org.eclipse.wst.ws.internal.explorer.platform.engine.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.engine.data,
+ org.eclipse.wst.ws.internal.explorer.platform.engine.transformer,
+ org.eclipse.wst.ws.internal.explorer.platform.favorites.actions,
+ org.eclipse.wst.ws.internal.explorer.platform.favorites.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.favorites.datamodel,
+ org.eclipse.wst.ws.internal.explorer.platform.favorites.perspective,
+ org.eclipse.wst.ws.internal.explorer.platform.perspective,
+ org.eclipse.wst.ws.internal.explorer.platform.uddi.actions,
+ org.eclipse.wst.ws.internal.explorer.platform.uddi.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.uddi.datamodel,
+ org.eclipse.wst.ws.internal.explorer.platform.uddi.perspective,
+ org.eclipse.wst.ws.internal.explorer.platform.uddi.util,
+ org.eclipse.wst.ws.internal.explorer.platform.util,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.actions,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.datamodel,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.impl,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.util,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.transformer,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.transport,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.util,
+ org.eclipse.wst.ws.internal.explorer.platform.wsdl.xsd,
+ org.eclipse.wst.ws.internal.explorer.platform.wsil.actions,
+ org.eclipse.wst.ws.internal.explorer.platform.wsil.constants,
+ org.eclipse.wst.ws.internal.explorer.platform.wsil.datamodel,
+ org.eclipse.wst.ws.internal.explorer.platform.wsil.perspective,
+ org.eclipse.wst.ws.internal.explorer.platform.wsil.transformer,
+ org.eclipse.wst.ws.internal.explorer.plugin,
+ org.eclipse.wst.ws.internal.explorer.popup
Require-Bundle: org.eclipse.core.runtime,
org.eclipse.core.resources,
org.eclipse.tomcat,
@@ -33,6 +67,5 @@
org.eclipse.wst.common.frameworks,
org.eclipse.wst.common.frameworks.ui,
org.eclipse.wst.common.environment,
- org.eclipse.wst.common.uriresolver,
- com.ibm.icu
+ org.eclipse.wst.common.uriresolver
Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.wst.ws.explorer/properties/favorites_default.wsil b/bundles/org.eclipse.wst.ws.explorer/properties/favorites_default.wsil
index 015cac3..10658f4 100644
--- a/bundles/org.eclipse.wst.ws.explorer/properties/favorites_default.wsil
+++ b/bundles/org.eclipse.wst.ws.explorer/properties/favorites_default.wsil
@@ -6,6 +6,34 @@
<abstract xml:lang="en-US">v5_0_1_0</abstract>
<link referencedNamespace="urn:uddi-org:api">
+ <abstract xml:lang="en-US">%PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST</abstract>
+ <abstract xml:lang="en-US">http://uddi.ibm.com/testregistry/inquiryapi</abstract>
+ <abstract xml:lang="en-US">https://uddi.ibm.com/testregistry/publishapi</abstract>
+ <abstract xml:lang="en-US">http://uddi.ibm.com/testregistry/registry.html</abstract>
+ </link>
+
+ <link referencedNamespace="urn:uddi-org:api">
+ <abstract xml:lang="en-US">%PUBLICUDDIREGISTRYTYPE_NAME_IBM</abstract>
+ <abstract xml:lang="en-US">http://uddi.ibm.com/ubr/inquiryapi</abstract>
+ <abstract xml:lang="en-US">https://uddi.ibm.com/ubr/publishapi</abstract>
+ <abstract xml:lang="en-US">http://uddi.ibm.com/ubr/registry.html</abstract>
+ </link>
+
+ <link referencedNamespace="urn:uddi-org:api">
+ <abstract xml:lang="en-US">%PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST</abstract>
+ <abstract xml:lang="en-US">http://test.uddi.microsoft.com/inquire</abstract>
+ <abstract xml:lang="en-US">https://test.uddi.microsoft.com/publish</abstract>
+ <abstract xml:lang="en-US">https://test.uddi.microsoft.com/register.aspx</abstract>
+ </link>
+
+ <link referencedNamespace="urn:uddi-org:api">
+ <abstract xml:lang="en-US">%PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT</abstract>
+ <abstract xml:lang="en-US">http://uddi.microsoft.com/inquire</abstract>
+ <abstract xml:lang="en-US">https://uddi.microsoft.com/publish</abstract>
+ <abstract xml:lang="en-US">https://uddi.microsoft.com/register.aspx</abstract>
+ </link>
+
+ <link referencedNamespace="urn:uddi-org:api">
<abstract xml:lang="en-US">%PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST</abstract>
<abstract xml:lang="en-US">http://udditest.sap.com/UDDI/api/inquiry/</abstract>
<abstract xml:lang="en-US">https://udditest.sap.com/UDDI/api/publish/</abstract>
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-properties/uddi.properties b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-properties/uddi.properties
index 4c37a11..eddd983 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-properties/uddi.properties
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-properties/uddi.properties
@@ -25,6 +25,7 @@
FORM_LABEL_REGISTRY_NAME=Registry Name
FORM_LABEL_INQUIRY_URL=Inquiry URL
FORM_LABEL_CHECK_USER_DEFINED_CATEGORIES=Check for user-defined categories
+DEFAULT_REGISTRY_NAME=IBM UDDI Test Registry
MSG_ERROR_INVALID_REGISTRY_NAME=IWAB0136E Enter a valid registry name.
MSG_ERROR_INVALID_INQUIRY_URL=IWAB0138E Enter a valid inquiry URL.
MSG_INFO_REGISTRY_OPENED=IWAB0139I The registry named %1 located at %2 was opened successfully.
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/OpenRegistryTool.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/OpenRegistryTool.java
index 0f37be3..a2aee33 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/OpenRegistryTool.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/OpenRegistryTool.java
@@ -6,10 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060224 122752 cbrealey@ca.ibm.com - Chris Brealey
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.uddi.perspective;
@@ -39,8 +36,8 @@
{
controller_ = toolManager_.getNode().getNodeManager().getController();
UDDIPerspective uddiPerspective = controller_.getUDDIPerspective();
- setProperty(UDDIActionInputs.REGISTRY_NAME,uddiPerspective.getDefaultUDDIRegistry().getName());
- setProperty(UDDIActionInputs.INQUIRY_URL,uddiPerspective.getDefaultUDDIRegistry().getInquiryURL());
+ setProperty(UDDIActionInputs.REGISTRY_NAME,uddiPerspective.getMessage("DEFAULT_REGISTRY_NAME"));
+ setProperty(UDDIActionInputs.INQUIRY_URL,uddiPerspective.getIBMPublicUDDITestRegistry().getInquiryURL());
}
public String getSelectToolActionHref(boolean forHistory)
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/UDDIPerspective.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/UDDIPerspective.java
index 1368db6..7285e22 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/UDDIPerspective.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/uddi/perspective/UDDIPerspective.java
@@ -6,10 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060224 122752 cbrealey@ca.ibm.com - Chris Brealey
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.uddi.perspective;
@@ -50,7 +47,7 @@
public class UDDIPerspective extends Perspective
{
private Hashtable knownRegistries_;
- private IFavoritesUDDIRegistry defaultUDDIRegistry_;
+ private IFavoritesUDDIRegistry ibmPublicUDDITestRegistry_;
private Model navigatorModel_;
private NodeManager navigatorManager_;
private int wsdlType_;
@@ -63,6 +60,9 @@
private String actionsContainerFramesetRows_;
private String savedActionsContainerFramesetRows_;
+ private final String IBM_TEST_REG_INQUIRY_URL = "http://uddi.ibm.com/testregistry/inquiryapi";
+ private final String IBM_TEST_REG_PUBLISH_URL = "https://uddi.ibm.com/testregistry/publishapi";
+
public UDDIPerspective(Controller controller)
{
super("uddi",controller);
@@ -76,10 +76,12 @@
knownRegistries_ = new Hashtable();
for (int i=0;i<favRegistriesDefault.length;i++)
{
+ if (favRegistriesDefault[i].getInquiryURL().equals(IBM_TEST_REG_INQUIRY_URL) && favRegistriesDefault[i].getPublishURL().equals(IBM_TEST_REG_PUBLISH_URL))
+ ibmPublicUDDITestRegistry_ = favRegistriesDefault[i];
knownRegistries_.put(favRegistriesDefault[i].getInquiryURL(),favRegistriesDefault[i]);
}
- if (favRegistriesDefault.length > 0)
- defaultUDDIRegistry_ = favRegistriesDefault[0];
+ if (ibmPublicUDDITestRegistry_ == null && favRegistriesDefault.length > 0)
+ ibmPublicUDDITestRegistry_ = favRegistriesDefault[0];
navigatorModel_ = new BasicModel("uddiModel");
UDDIMainElement uddiMainElement = new UDDIMainElement(getMessage("NODE_NAME_UDDI_MAIN"),navigatorModel_);
@@ -177,9 +179,9 @@
return null;
}
- public final IFavoritesUDDIRegistry getDefaultUDDIRegistry()
+ public final IFavoritesUDDIRegistry getIBMPublicUDDITestRegistry()
{
- return defaultUDDIRegistry_;
+ return ibmPublicUDDITestRegistry_;
}
public final void preloadUDDIRegistries(String[] inquiryURLs, String[] publishURLs)
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/HTMLUtils.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/HTMLUtils.java
index 83cf955..7ebcb0a 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/HTMLUtils.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/HTMLUtils.java
@@ -6,10 +6,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.util;
@@ -149,9 +146,6 @@
/**
* Replace special characters with HTML entities representing these characters.
- * Note that this will also convert normal spaces into non-breaking spaces, which may be good for
- * presentation but not for editing.
- *
* @return String The converted String. Note: Order is important so that corrected entity references are not re-mangled.
*/
public static final String charactersToHTMLEntities(String s) {
@@ -164,18 +158,6 @@
}
/**
- * Replace special characters with HTML entities representing these characters
- * @return String The converted String. Note: Order is important so that corrected entity references are not re-mangled.
- */
- public static final String charactersToHTMLEntitiesStrict(String s) {
- s = stringReplace(s, AMPERSAND, AMPERSAND_HTML_ENTITY);
- s = stringReplace(s, LESS_THAN, LESS_THAN_HTML_ENTITY);
- s = stringReplace(s, GREATER_THAN, GREATER_THAN_HTML_ENTITY);
- s = stringReplace(s, QUOTATION, QUOTATION_HTML_ENTITY);
- return s;
- }
-
- /**
* Replace HTML character entities with their associated characters.
* @return String The converted String.
*/
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/QuickSort.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/QuickSort.java
index d018ee4..9fa7e2e 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/QuickSort.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/util/QuickSort.java
@@ -1,21 +1,18 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060217 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.util;
+import java.text.Collator;
import java.util.Vector;
-import com.ibm.icu.text.Collator;
public class QuickSort
{
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDElementFragment.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDElementFragment.java
index 2b78f02..e560d90 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDElementFragment.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDElementFragment.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2002, 2006 IBM Corporation and others.
+ * Copyright (c) 2002, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060119 123539 jesper@selskabet.org - Jesper Møller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.impl;
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDSimpleListFragment.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDSimpleListFragment.java
index a6c6661..764f842 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDSimpleListFragment.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/fragment/impl/XSDSimpleListFragment.java
@@ -1,19 +1,17 @@
/*******************************************************************************
- * Copyright (c) 2002, 2006 IBM Corporation and others.
+ * Copyright (c) 2002, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060217 127138 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.impl;
import java.util.Hashtable;
+import java.util.StringTokenizer;
import org.eclipse.wst.ws.internal.explorer.platform.wsdl.constants.FragmentConstants;
import org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.IXSDFragment;
import org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.IXSDSimpleListFragment;
@@ -27,7 +25,6 @@
import org.w3c.dom.Element;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
-import com.ibm.icu.util.StringTokenizer;
public abstract class XSDSimpleListFragment extends XSDMapFragment implements IXSDSimpleListFragment
{
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/transport/HTTPTransport.java b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/transport/HTTPTransport.java
index 1487621..7d5c2c4 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/transport/HTTPTransport.java
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer-src/org/eclipse/wst/ws/internal/explorer/platform/wsdl/transport/HTTPTransport.java
@@ -10,8 +10,6 @@
* yyyymmdd bug Email and other contact information
* -------- -------- -----------------------------------------------------------
* 20060131 125777 jesper@selskabet.org - Jesper S Moller
- * 20060222 118019 andyzhai@ca.ibm.com - Andy Zhai
- * 20060222 128564 jesper@selskabet.org - Jesper S Moller
*******************************************************************************/
package org.eclipse.wst.ws.internal.explorer.platform.wsdl.transport;
@@ -36,13 +34,11 @@
{
private final String SYS_PROP_HTTPS_PROXY_HOST = "https.proxyHost";
private final String SYS_PROP_HTTPS_PROXY_PORT = "https.proxyPort";
- private final String SYS_PROP_HTTPS_NON_PROXY_HOSTS = "https.nonProxyHosts";
private final String SYS_PROP_HTTP_PROXY_HOST = "http.proxyHost";
private final String SYS_PROP_HTTP_PROXY_PORT = "http.proxyPort";
private final String SYS_PROP_HTTP_PROXY_USER_NAME = "http.proxyUserName";
private final String SYS_PROP_HTTP_PROXY_PASSWORD = "http.proxyPassword";
- private final String SYS_PROP_HTTP_NON_PROXY_HOSTS = "http.nonProxyHosts";
-
+
private final String HTTP_METHOD = "POST";
private final String HTTP_VERSION = "HTTP/1.1";
private final String HTTP_HEADER_SOAP_ACTION = "SOAPAction";
@@ -88,7 +84,6 @@
private final int DEFAULT_HTTPS_PORT = 443;
private final String DEFAULT_SOAP_ENCODING = "UTF-8";
private final String DEFAULT_HTTP_HEADER_ENCODING = "iso-8859-1";
- private final boolean DEFAULT_CASE_SENSITIVE_FOR_HOST_NAME = false;
private String httpBasicAuthUsername;
private String httpBasicAuthPassword;
@@ -169,9 +164,9 @@
return getHTTPHeader(HTTP_HEADER_CONTENT_TYPE, CONTENT_TYPE_VALUE);
}
- private String getContentLength(byte[] payloadAsBytes)
+ private String getContentLength(String payload)
{
- return getHTTPHeader(HTTP_HEADER_CONTENT_LENGTH, String.valueOf(payloadAsBytes.length));
+ return getHTTPHeader(HTTP_HEADER_CONTENT_LENGTH, String.valueOf(payload.length()));
}
private String getSOAPAction(String soapAction)
@@ -293,13 +288,11 @@
public void send(URL url, String soapAction, String payload) throws UnknownHostException, IOException
{
- byte[] payloadAsUTF8 = payload.getBytes(DEFAULT_SOAP_ENCODING);
-
StringBuffer httpHeader = new StringBuffer();
httpHeader.append(getMethod(url));
httpHeader.append(getHost(url));
httpHeader.append(getContentType());
- httpHeader.append(getContentLength(payloadAsUTF8));
+ httpHeader.append(getContentLength(payload));
httpHeader.append(getAccept());
httpHeader.append(getUserAgent());
httpHeader.append(getCacheControl());
@@ -315,7 +308,7 @@
InputStream is = socket.getInputStream();
OutputStream os = socket.getOutputStream();
os.write(httpHeader.toString().getBytes(DEFAULT_HTTP_HEADER_ENCODING));
- os.write(payloadAsUTF8);
+ os.write(payload.getBytes(DEFAULT_SOAP_ENCODING));
os.flush();
httpResponse = new HTTPResponse();
readHTTPResponseHeader(is, httpResponse);
@@ -479,18 +472,13 @@
int port = url.getPort();
String proxyHost = System.getProperty(SYS_PROP_HTTP_PROXY_HOST);
int proxyPort = Integer.getInteger(SYS_PROP_HTTP_PROXY_PORT, DEFAULT_HTTP_PORT).intValue();
-
- String nonProxyHosts = System.getProperty(SYS_PROP_HTTP_NON_PROXY_HOSTS);
-
- // String proxyUserName = System.getProperty(SYS_PROP_HTTP_PROXY_USER_NAME);
- // String proxyPassword = System.getProperty(SYS_PROP_HTTP_PROXY_PASSWORD);
+// String proxyUserName = System.getProperty(SYS_PROP_HTTP_PROXY_USER_NAME);
+// String proxyPassword = System.getProperty(SYS_PROP_HTTP_PROXY_PASSWORD);
if (url.getProtocol().equalsIgnoreCase(HTTPS))
{
proxyHost = System.getProperty(SYS_PROP_HTTPS_PROXY_HOST);
proxyPort = Integer.getInteger(SYS_PROP_HTTPS_PROXY_PORT, DEFAULT_HTTPS_PORT).intValue();
- nonProxyHosts = System.getProperty(SYS_PROP_HTTPS_NON_PROXY_HOSTS);
-
- if (proxyHost != null && proxyHost.length() > 0 && !isHostInNonProxyHosts(host, nonProxyHosts, DEFAULT_CASE_SENSITIVE_FOR_HOST_NAME))
+ if (proxyHost != null && proxyHost.length() > 0)
{
// TODO:
// SSL with proxy server
@@ -504,54 +492,10 @@
// as demonstrated in the following (original) line of code:
// s = SSLUtils.buildSSLSocket(host, (port > 0 ? port : DEFAULT_HTTPS_PORT), proxyHost, proxyPort, proxyUserName, proxyPassword);
}
- else if (proxyHost != null && proxyHost.length() > 0 && !isHostInNonProxyHosts(host, nonProxyHosts, DEFAULT_CASE_SENSITIVE_FOR_HOST_NAME))
+ else if (proxyHost != null && proxyHost.length() > 0)
s = new Socket(proxyHost, proxyPort);
else
s = new Socket(host, (port > 0 ? port : DEFAULT_HTTP_PORT));
return s;
}
-
- private boolean isHostInNonProxyHosts(String host, String nonProxyHosts, boolean caseSensitive)
- {
- if (caseSensitive) return host.matches(createPatternFromString(nonProxyHosts));
- else return host.toLowerCase().matches(createPatternFromString(nonProxyHosts.toLowerCase()));
- }
-
- /*
- * This method is used to generate a valid regular expression for a
- * normal java String used in the proxy mechanism.
- * For example, the http.nonProxyHosts contains following String:
- * "192.168.2.*|localhost|*.ibm.com" . It would be
- * transformed into: "192\.168\.2\.\w*|localhost|\w*\.ibm\.com"
- * Thus, following host string would match above pattern:
- * 192.168.2.5 192.168.2. 192.168.2.666 192.168.2.w
- * localhost
- * torolab.ibm.com .ibm.com 123.ibm.com
- *
- * Two transformations are done:
- * 1. replace all "." into "\." As in regular expression, '.' represents
- * any charater. "\.' represents the real character '.'
- * 2. In order to get the real meaning of "*" used in property
- * http.nonProxyHosts, "\w*" is used to replace "*"
- * "\w" represent a word character: [a-zA-Z_0-9]
- *
- * Restriction:
- * The validity of address is not checked.
- * (192.168.2.555 and 192.168.2.com are OK)
- *
- * TODO check whether * occurs in address or hostname.
- * if it occuus in address representation, replace "*" with "\d*"
- * and check: value < 256 ?
- */
- private String createPatternFromString(String str)
- {
- /* This is the same as following more understandable way:
- * return str.replace(".", "\\.").replace("*", "\\w*");
- * But, replace(CharSequence target, CharSequence replacement) can only be
- * supported after j2se 1.5, on the other hand,
- * replaceAll(String regex, String replacement) can be supported before
- * j2se 1.5.
- */
- return str == null ? null : str.replaceAll("\\.", "\\.").replaceAll("\\*", "\\w*");
- }
}
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/forms/FragmentsSoapView.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/forms/FragmentsSoapView.jsp
index 53d8b7d..ff2c753 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/forms/FragmentsSoapView.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/forms/FragmentsSoapView.jsp
@@ -7,10 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
%>
<%@ page contentType="text/html; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
@@ -90,7 +87,7 @@
if (numberOfAttributes == 0)
header.append('>');
%>
- <%=HTMLUtils.charactersToHTMLEntitiesStrict(header.toString())%>
+ <%=HTMLUtils.charactersToHTMLEntities(header.toString())%>
</td>
</tr>
</table>
@@ -270,7 +267,7 @@
<img width=<%=sourceContentIndentationImageWidth%> height=16 src="<%=response.encodeURL(controller.getPathWithContext("images/space.gif"))%>">
</td>
<td width="100%">
- <textarea id="soap_body_content" name="<%=FragmentConstants.SOURCE_CONTENT%>" class="bigtextareaenter"><%=HTMLUtils.charactersToHTMLEntitiesStrict(sourceContent.toString())%></textarea>
+ <textarea id="soap_body_content" name="<%=FragmentConstants.SOURCE_CONTENT%>" class="bigtextareaenter"><%=sourceContent.toString()%></textarea>
</td>
</tr>
</table>
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentJSP.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentJSP.jsp
index cc9c9f0..c00694f 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentJSP.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentJSP.jsp
@@ -7,10 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
%>
<%@ page contentType="text/html; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
@@ -58,7 +55,7 @@
<table cellpadding=3 cellspacing=0 class="<%=(xsdConfig.getIsWSDLPart() ? "fixfragtable" : "innerfixfragtable")%>">
<tr>
<td>
- <textarea id="<%=frag.getID()%>" name="<%=frag.getID()%>" class="textareaenter" readonly><%=HTMLUtils.charactersToHTMLEntitiesStrict(sb.toString())%></textarea>
+ <textarea id="<%=frag.getID()%>" name="<%=frag.getID()%>" class="textareaenter" readonly><%=sb.toString()%></textarea>
<%
/*
StringBuffer url = new StringBuffer();
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentXML.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentXML.jsp
index 5ee0313..6a90818 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentXML.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultRFragmentXML.jsp
@@ -1,18 +1,3 @@
-<%
-/*******************************************************************************
- * Copyright (c) 2002, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
- *******************************************************************************/
-%>
<%@ page contentType="text/xml; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
org.eclipse.wst.ws.internal.explorer.platform.wsdl.datamodel.*,
org.eclipse.wst.ws.internal.explorer.platform.wsdl.fragment.*,
@@ -96,7 +81,7 @@
for (int i = 0; i < instanceDocuments.length; i++) {
if (instanceDocuments[i] == null)
continue;
- sb.append(HTMLUtils.charactersToHTMLEntitiesStrict(XMLUtils.serialize(instanceDocuments[i], true)));
+ sb.append(HTMLUtils.charactersToHTMLEntities(XMLUtils.serialize(instanceDocuments[i], true)));
}
%>
<%=sb.toString()%>
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultWFragmentJSP.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultWFragmentJSP.jsp
index b82f3b3..10a2f7f 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultWFragmentJSP.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDDefaultWFragmentJSP.jsp
@@ -7,10 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
%>
<%@ page contentType="text/html; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
@@ -52,7 +49,7 @@
<table cellpadding=3 cellspacing=0 class="<%=(xsdConfig.getIsWSDLPart() ? "fixfragtable" : "innerfixfragtable")%>">
<tr>
<td>
- <textarea id="<%=frag.getID()%>" name="<%=frag.getID()%>" class="textareaenter"><%=((param != null) ? HTMLUtils.charactersToHTMLEntitiesStrict(param) : "")%></textarea>
+ <textarea id="<%=frag.getID()%>" name="<%=frag.getID()%>" class="textareaenter"><%=((param != null) ? param : "")%></textarea>
</td>
</tr>
</table>
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicDateTimeFixWFragmentJSP.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicDateTimeFixWFragmentJSP.jsp
index 8b84992..68391d3 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicDateTimeFixWFragmentJSP.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicDateTimeFixWFragmentJSP.jsp
@@ -7,10 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
%>
<%@ page contentType="text/html; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
@@ -68,7 +65,7 @@
<%
String value = frag.getParameterValue(frag.getID(), i);
%>
- <input type="text" id="<%=frag.getID()%>" name="<%=fragIDString%>" value="<%=((value != null) ? HTMLUtils.charactersToHTMLEntitiesStrict(value) : "")%>" size="50" class="tabletextenter">
+ <input type="text" id="<%=frag.getID()%>" name="<%=fragIDString%>" value="<%=((value != null) ? value : "")%>" size="50" class="tabletextenter">
</td>
<td valign="center" align="left" nowrap>
<a href="javascript:openCalendarBrowser(<%=request.getParameter(ActionInputs.CALENDAR_TYPE)%>,'contentborder','<%=fragIDString%>',<%=i%>)"><%=controller.getMessage("FORM_LINK_BROWSE")%></a>
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicFixWFragmentJSP.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicFixWFragmentJSP.jsp
index f3f18de..877601d 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicFixWFragmentJSP.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl/fragment/XSDSimpleAtomicFixWFragmentJSP.jsp
@@ -7,10 +7,7 @@
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
- * IBM Corporation - initial API and implementation
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060222 127443 jesper@selskabet.org - Jesper S Moller
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
%>
<%@ page contentType="text/html; charset=UTF-8" import="org.eclipse.wst.ws.internal.explorer.platform.wsdl.perspective.*,
@@ -66,7 +63,7 @@
<%
String value = frag.getParameterValue(frag.getID(), i);
%>
- <input type="text" id="<%=frag.getID()%>" name="<%=frag.getID()%>" value="<%=((value != null) ? HTMLUtils.charactersToHTMLEntitiesStrict(value) : "")%>" size="50" class="tabletextenter">
+ <input type="text" id="<%=frag.getID()%>" name="<%=frag.getID()%>" value="<%=((value != null) ? value : "")%>" size="50" class="tabletextenter">
</td>
</tr>
<%
diff --git a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl_content.jsp b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl_content.jsp
index 0ccbb53..432dd8d 100644
--- a/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl_content.jsp
+++ b/bundles/org.eclipse.wst.ws.explorer/wsexplorer/wsdl_content.jsp
@@ -34,13 +34,6 @@
HttpSession currentSession = (HttpSession)application.getAttribute(sessionId);
Controller controller = (Controller)currentSession.getAttribute("controller");
int wsdlType = controller.getWSDLType();
-
- Iterator wsIterator = WebServiceFinder.instance().getWebServices();
- Vector allWebServices = new Vector();
- while (wsIterator.hasNext())
- {
- allWebServices.add(wsIterator.next());
- }
%>
<html>
<head>
@@ -104,8 +97,8 @@
String httpProtocol = "http://";
String httpsProtocol = "https://";
wsdlURLs_.removeAllElements();
-
- Iterator ws = allWebServices.iterator();
+
+ Iterator ws = WebServiceFinder.instance().getWebServices();
while (ws.hasNext())
{
diff --git a/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF
index 61452fe..4d33646 100644
--- a/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.ws.parser/META-INF/MANIFEST.MF
@@ -2,15 +2,15 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.ws.parser
-Bundle-Version: 1.0.100.qualifier
+Bundle-Version: 1.0.0.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,
+Export-Package: org.eclipse.wst.ws.internal.parser.disco,
+ org.eclipse.wst.ws.internal.parser.discovery,
+ org.eclipse.wst.ws.internal.parser.favorites,
+ org.eclipse.wst.ws.internal.parser.plugin,
+ org.eclipse.wst.ws.internal.parser.wsil,
org.eclipse.wst.ws.parser
Require-Bundle: org.eclipse.wst.wsdl,
org.wsdl4j,
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
index 939b0d5..9609cb5 100644
--- 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
@@ -11,6 +11,10 @@
NLS.initializeMessages(BUNDLE_NAME, PluginMessages.class);
}
+ public static String PUBLICUDDIREGISTRYTYPE_NAME_IBM;
+ public static String PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST;
+ public static String PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT;
+ public static String PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST;
public static String PUBLICUDDIREGISTRYTYPE_NAME_SAP;
public static String PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST;
public static String PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS;
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
index 0080e47..ec8bde8 100644
--- 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
@@ -12,6 +12,10 @@
#
# PublicUDDIRegistryType
#
+PUBLICUDDIREGISTRYTYPE_NAME_IBM=IBM UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST=IBM UDDI Test Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT=Microsoft UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST=Microsoft UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP=SAP UDDI Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST=SAP UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS=XMethods Registry
diff --git a/bundles/org.eclipse.wst.ws.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.ws.ui/META-INF/MANIFEST.MF
index f28fab5..29a2412 100644
--- a/bundles/org.eclipse.wst.ws.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.ws.ui/META-INF/MANIFEST.MF
@@ -2,16 +2,16 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.ws.ui; singleton:=true
-Bundle-Version: 1.0.100.qualifier
+Bundle-Version: 1.0.0.qualifier
Bundle-Activator: org.eclipse.wst.ws.internal.ui.plugin.WSUIPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.ws.internal.ui;x-internal:=true,
- org.eclipse.wst.ws.internal.ui.plugin;x-internal:=true,
- org.eclipse.wst.ws.internal.ui.preferences;x-internal:=true,
- org.eclipse.wst.ws.internal.ui.wsi.preferences;x-internal:=true,
- org.eclipse.wst.ws.internal.ui.wsi.properties;x-internal:=true,
- org.eclipse.wst.ws.internal.ui.wsrt;x-internal:=true
+Export-Package: org.eclipse.wst.ws.internal.ui.wsrt,
+ org.eclipse.wst.ws.internal.ui.plugin,
+ org.eclipse.wst.ws.internal.ui.preferences,
+ org.eclipse.wst.ws.internal.ui.wsi.preferences,
+ org.eclipse.wst.ws.internal.ui.wsi.properties,
+ org.eclipse.wst.ws.internal.ui
Require-Bundle: org.eclipse.ui,
org.eclipse.core.runtime,
org.eclipse.core.resources,
diff --git a/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/WstWSUIPlugin.properties b/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/WstWSUIPlugin.properties
index 76f7380..44a8b7d 100644
--- a/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/WstWSUIPlugin.properties
+++ b/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/WstWSUIPlugin.properties
@@ -38,11 +38,11 @@
TOOLTIP_PWSI_RADIO_IGNORE_NON_WSI=Silently allow choices that do not comply with WS-I.
TOOLTIP_PWSI_RADIO_FOLLOW_WSI_PREFERENCE=Project would use WS-I compliance level set in Workspace Preference.
-LABEL_WSI_SSBP=WS-I S&SBP compliance level
+LABEL_WSI_SSBP=WS-I SSBP compliance level
TOOLTIP_PWSI_SSBP_LABEL=WS-I Simple SOAP Binding Profile compliance level
TOOLTIP_PWSI_SSBP_COMBO=Choose the WS-I Simple SOAP Binding Profile compliance level
-LABEL_WSI_AP=WS-I A&P compliance level
+LABEL_WSI_AP=WS-I AP compliance level
TOOLTIP_PWSI_AP_LABEL=WS-I Attachment Profile compliance level
TOOLTIP_PWSI_AP_COMBO=Choose the WS-I Attachment Profile compliance level
@@ -50,11 +50,11 @@
# WSDL Validation
#
LABEL_WSDLVAL=Select whether WSDL validation should be performed on wizards that consume WSDL files
-LABEL_WSDLVAL_NONE=&No wizard WSDL validation
-LABEL_WSDLVAL_REMOTE=Wizard WSDL validation for &remote files only
-LABEL_WSDLVAL_ALL=Wizard WSDL validation for &all WSDL files
+LABEL_WSDLVAL_NONE=No wizard WSDL validation
+LABEL_WSDLVAL_REMOTE=Wizard WSDL validation for remote files only
+LABEL_WSDLVAL_ALL=Wizard WSDL validation for all WSDL files
LABEL_WAIT_FOR_WSDLVAL=Wait for WSDL validation to complete before moving along the wizards?
-BUTTON_WAIT_FOR_WSDLVAL=&Wait for pending WSDL validation to complete
+BUTTON_WAIT_FOR_WSDLVAL=Wait for pending WSDL validation to complete
TOOLTIP_PWSI_RADIO_WSDLVAL_NONE=Do not perform WSDL validation on the WSDL file or URL input to the Web Services wizard
TOOLTIP_PWSI_RADIO_WSDLVAL_REMOTE=Only perform WSDL validation on remote WSDL file or URL input to the Web Services wizard
TOOLTIP_PWSI_RADIO_WSDLVAL_ALL=Perform WSDL validation on all WSDL file or URL input to the Web Services wizard
diff --git a/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/wsi/preferences/WSICompliancePreferencePage.java b/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/wsi/preferences/WSICompliancePreferencePage.java
index f2cd9af..32cdb63 100644
--- a/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/wsi/preferences/WSICompliancePreferencePage.java
+++ b/bundles/org.eclipse.wst.ws.ui/src/org/eclipse/wst/ws/internal/ui/wsi/preferences/WSICompliancePreferencePage.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060310 131352 pmoogk@ca.ibm.com - Peter Moogk
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.ui.wsi.preferences;
@@ -27,7 +24,6 @@
import org.eclipse.swt.widgets.Group;
import org.eclipse.swt.widgets.Label;
import org.eclipse.swt.widgets.Listener;
-import org.eclipse.swt.widgets.Text;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.IWorkbenchPreferencePage;
import org.eclipse.ui.PlatformUI;
@@ -63,14 +59,14 @@
private Group validationSelectionGroup_;
- private Text wsdlValidationLabel_;
+ private Label wsdlValidationLabel_;
/*CONTEXT_ID PWSI0009 for the No Wizard WSDL validation button on the Profile Compliance and Validation page*/
private Button validateNoWsdlButton_;
/*CONTEXT_ID PWSI00010 for the Wizard WSDL validation for remote files only button on the Profile Compliance and Validation page*/
private Button validateRemoteWsdlButton_;
/*CONTEXT_ID PWSI00011 for the Wizard WSDL validation for all files button on the Profile Compliance and Validation page*/
private Button validateAllWsdlButton_;
- private Text waitForWsdlValidationLabel_;
+ private Label waitForWsdlValidationLabel_;
/*CONTEXT_ID PWSI00012 for the Wait for pending WSDL validation to complete checkbox on the Profile Compliance and Validation page*/
private Button waitForWSDLValidationCheckbox_;
@@ -157,7 +153,7 @@
GridData gd = new GridData(GridData.FILL_HORIZONTAL);
validationSelectionGroup_.setLayoutData(gd);
- wsdlValidationLabel_ = new Text(validationSelectionGroup_, SWT.READ_ONLY);
+ wsdlValidationLabel_ = new Label(validationSelectionGroup_, SWT.NONE);
wsdlValidationLabel_.setText(WstWSUIPluginMessages.LABEL_WSDLVAL);
wsdlValidationLabel_.setToolTipText(WstWSUIPluginMessages.TOOLTIP_PWSI_WSDLVAL_LABEL);
helpSystem.setHelp(wsdlValidationLabel_, INFOPOP_PWSI_WSDLVAL_LABEL);
@@ -182,7 +178,7 @@
new Label(validationSelectionGroup_, SWT.NONE);;
- waitForWsdlValidationLabel_ = new Text(validationSelectionGroup_, SWT.READ_ONLY);
+ waitForWsdlValidationLabel_ = new Label(validationSelectionGroup_, SWT.NONE);
waitForWsdlValidationLabel_.setText(WstWSUIPluginMessages.LABEL_WAIT_FOR_WSDLVAL);
waitForWsdlValidationLabel_.setToolTipText(WstWSUIPluginMessages.TOOLTIP_PWSI_LABEL_WAIT_FOR_WSDLVAL);
diff --git a/bundles/org.eclipse.wst.ws/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.ws/META-INF/MANIFEST.MF
index accfbf1..201b6b1 100644
--- a/bundles/org.eclipse.wst.ws/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.ws/META-INF/MANIFEST.MF
@@ -2,35 +2,35 @@
Bundle-ManifestVersion: 2
Bundle-Name: %PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.ws; singleton:=true
-Bundle-Version: 1.0.100.qualifier
+Bundle-Version: 1.0.0.qualifier
Bundle-Activator: org.eclipse.wst.ws.internal.plugin.WSPlugin
Bundle-Vendor: %PLUGIN_PROVIDER
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.ws.internal;x-internal:=true,
- org.eclipse.wst.ws.internal.common;x-internal:=true,
- org.eclipse.wst.ws.internal.data;x-internal:=true,
- org.eclipse.wst.ws.internal.datamodel;x-internal:=true,
- org.eclipse.wst.ws.internal.ext;x-internal:=true,
- org.eclipse.wst.ws.internal.extensions;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.registry;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.registry.impl;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.registry.util;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.rtindex;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.rtindex.impl;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.rtindex.util;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.taxonomy;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.taxonomy.impl;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.taxonomy.util;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.uddiregistry;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.uddiregistry.impl;x-internal:=true,
- org.eclipse.wst.ws.internal.model.v10.uddiregistry.util;x-internal:=true,
- org.eclipse.wst.ws.internal.monitor;x-internal:=true,
- org.eclipse.wst.ws.internal.plugin;x-internal:=true,
- org.eclipse.wst.ws.internal.preferences;x-internal:=true,
- org.eclipse.wst.ws.internal.registry;x-internal:=true,
- org.eclipse.wst.ws.internal.wsfinder;x-internal:=true,
- org.eclipse.wst.ws.internal.wsil;x-internal:=true,
- org.eclipse.wst.ws.internal.wsrt;x-internal:=true
+Export-Package: org.eclipse.wst.ws.internal,
+ org.eclipse.wst.ws.internal.common,
+ org.eclipse.wst.ws.internal.data,
+ org.eclipse.wst.ws.internal.datamodel,
+ org.eclipse.wst.ws.internal.ext,
+ org.eclipse.wst.ws.internal.extensions,
+ org.eclipse.wst.ws.internal.model.v10.registry,
+ org.eclipse.wst.ws.internal.model.v10.registry.impl,
+ org.eclipse.wst.ws.internal.model.v10.registry.util,
+ org.eclipse.wst.ws.internal.model.v10.rtindex,
+ org.eclipse.wst.ws.internal.model.v10.rtindex.impl,
+ org.eclipse.wst.ws.internal.model.v10.rtindex.util,
+ org.eclipse.wst.ws.internal.model.v10.taxonomy,
+ org.eclipse.wst.ws.internal.model.v10.taxonomy.impl,
+ org.eclipse.wst.ws.internal.model.v10.taxonomy.util,
+ org.eclipse.wst.ws.internal.model.v10.uddiregistry,
+ org.eclipse.wst.ws.internal.model.v10.uddiregistry.impl,
+ org.eclipse.wst.ws.internal.model.v10.uddiregistry.util,
+ org.eclipse.wst.ws.internal.monitor,
+ org.eclipse.wst.ws.internal.plugin,
+ org.eclipse.wst.ws.internal.preferences,
+ org.eclipse.wst.ws.internal.registry,
+ org.eclipse.wst.ws.internal.wsfinder,
+ org.eclipse.wst.ws.internal.wsil,
+ org.eclipse.wst.ws.internal.wsrt
Require-Bundle: org.eclipse.core.runtime,
org.eclipse.wst.internet.monitor.core,
org.eclipse.wst.server.core,
diff --git a/bundles/org.eclipse.wst.ws/plugin.properties b/bundles/org.eclipse.wst.ws/plugin.properties
index ec0837f..691114c 100644
--- a/bundles/org.eclipse.wst.ws/plugin.properties
+++ b/bundles/org.eclipse.wst.ws/plugin.properties
@@ -23,6 +23,10 @@
MSG_ERROR_UNABLE_TO_START_MONITOR=IWAB0001E Unable to monitor port {0} of {1}.
# Currently known public UDDI registries
+PUBLICUDDIREGISTRYTYPE_NAME_IBM=IBM UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_IBM_TEST=IBM UDDI Test Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT=Microsoft UDDI Registry
+PUBLICUDDIREGISTRYTYPE_NAME_MICROSOFT_TEST=Microsoft UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP=SAP UDDI Registry
PUBLICUDDIREGISTRYTYPE_NAME_SAP_TEST=SAP UDDI Test Registry
PUBLICUDDIREGISTRYTYPE_NAME_XMETHODS=XMethods Registry
diff --git a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployClientFragment.java b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployClientFragment.java
index 6e37498..1cf5fe7 100644
--- a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployClientFragment.java
+++ b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployClientFragment.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.extensions;
@@ -39,7 +36,7 @@
{
ICommandFactory factory = null;
- if( webServiceClient_ == null || !context_.getDeploy())
+ if( webServiceClient_ == null )
{
factory = new SimpleCommandFactory( new Vector() );
}
diff --git a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployServiceFragment.java b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployServiceFragment.java
index f1da8a4..3ad5ed7 100644
--- a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployServiceFragment.java
+++ b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/extensions/DeployServiceFragment.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 119111 rsinha@ca.ibm.com - Rupam Kuehner
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.extensions;
@@ -39,7 +36,7 @@
{
ICommandFactory factory = null;
- if( webService_ == null || !context_.getDeploy())
+ if( webService_ == null )
{
factory = new SimpleCommandFactory( new Vector() );
}
diff --git a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/wsrt/WebServiceInfo.java b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/wsrt/WebServiceInfo.java
index 517c44d..348a086 100644
--- a/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/wsrt/WebServiceInfo.java
+++ b/bundles/org.eclipse.wst.ws/src/org/eclipse/wst/ws/internal/wsrt/WebServiceInfo.java
@@ -1,15 +1,12 @@
/*******************************************************************************
- * Copyright (c) 2005, 2006 IBM Corporation and others.
+ * Copyright (c) 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
- * yyyymmdd bug Email and other contact information
- * -------- -------- -----------------------------------------------------------
- * 20060221 128905 kathy@ca.ibm.com - Kathy Chan
+ * IBM Corporation - initial API and implementation
*******************************************************************************/
package org.eclipse.wst.ws.internal.wsrt;
@@ -23,8 +20,6 @@
private java.lang.String wsdlURL;
private java.lang.String endPointURL;
private java.lang.String implURL;
- private java.lang.String[] implURLs;
-
public java.lang.String getEndPointURL()
{
return endPointURL;
@@ -81,13 +76,6 @@
{
this.wsdlURL = wsdlURL;
}
- public java.lang.String[] getImplURLs()
- {
- return implURLs;
- }
- public void setImplURLs(java.lang.String[] implURLs)
- {
- this.implURLs = implURLs;
- }
+
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/.classpath b/bundles/org.eclipse.wst.wsdl.ui/.classpath
index 905c508..ed58bc2 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/.classpath
+++ b/bundles/org.eclipse.wst.wsdl.ui/.classpath
@@ -2,7 +2,6 @@
<classpath>
<classpathentry kind="src" path="src"/>
<classpathentry kind="src" path="src-validation"/>
- <classpathentry kind="src" path="src-refactor"/>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="output" path="bin"/>
diff --git a/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.core.prefs
index b48794a..5c6c6e4 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.core.prefs
+++ b/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.core.prefs
@@ -1,17 +1,21 @@
-#Wed Mar 08 00:52:29 EST 2006
+#Mon Jan 30 18:57:13 EST 2006
eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+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=warning
org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled
org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled
org.eclipse.jdt.core.compiler.problem.discouragedReference=warning
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
@@ -30,7 +34,6 @@
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.rawTypeReference=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
@@ -45,10 +48,10 @@
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=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.wsdl.ui/.settings/org.eclipse.jdt.ui.prefs b/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index bbf7ac8..0000000
--- a/bundles/org.eclipse.wst.wsdl.ui/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Mon Jan 30 23:38:15 EST 2006
-eclipse.preferences.version=1
-internal.default.compliance=default
diff --git a/bundles/org.eclipse.wst.wsdl.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.wsdl.ui/META-INF/MANIFEST.MF
index 5ceb382..06c1d68 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.wsdl.ui/META-INF/MANIFEST.MF
@@ -3,51 +3,49 @@
Bundle-Name: %_UI_PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.wsdl.ui; singleton:=true
Bundle-Version: 1.0.1.qualifier
-Bundle-Activator: org.eclipse.wst.wsdl.ui.internal.WSDLEditorPlugin
-Bundle-Vendor: %providerName
+Bundle-Activator: org.eclipse.core.internal.compatibility.PluginActivator
+Bundle-Vendor: Eclipse.org
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.wsdl.ui.internal;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.actions;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.commands;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.contentgenerator;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.contentgenerator.ui;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.dialogs;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.dialogs.types;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.extension;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.filter;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.gef.util.editparts;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.gef.util.editpolicies;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.gef.util.figures;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.graph;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.graph.editparts;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.graph.editpolicies;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.graph.figures;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.graph.model;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.icons;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.model;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.nsedit;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.outline;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.parameters;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.properties.section;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.reconciler;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.refactor;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.refactor.actions;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.search;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.text;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.typesystem;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.util;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.util.flatui;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.util.ui;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.validation;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.viewers;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.viewers.widgets;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.visitor;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.widgets;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.wizards;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.xsd;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.xsd.actions;x-internal:=true,
- org.eclipse.wst.wsdl.ui.internal.xsd.graph.editparts;x-internal:=true
+Export-Package: org.eclipse.wst.wsdl.ui.internal,
+ org.eclipse.wst.wsdl.ui.internal.actions,
+ org.eclipse.wst.wsdl.ui.internal.commands,
+ org.eclipse.wst.wsdl.ui.internal.contentgenerator,
+ org.eclipse.wst.wsdl.ui.internal.contentgenerator.ui,
+ org.eclipse.wst.wsdl.ui.internal.dialogs,
+ org.eclipse.wst.wsdl.ui.internal.dialogs.types,
+ org.eclipse.wst.wsdl.ui.internal.extension,
+ org.eclipse.wst.wsdl.ui.internal.filter,
+ org.eclipse.wst.wsdl.ui.internal.gef.util.editparts,
+ org.eclipse.wst.wsdl.ui.internal.gef.util.editpolicies,
+ org.eclipse.wst.wsdl.ui.internal.gef.util.figures,
+ org.eclipse.wst.wsdl.ui.internal.graph,
+ org.eclipse.wst.wsdl.ui.internal.graph.editparts,
+ org.eclipse.wst.wsdl.ui.internal.graph.editpolicies,
+ org.eclipse.wst.wsdl.ui.internal.graph.figures,
+ org.eclipse.wst.wsdl.ui.internal.graph.model,
+ org.eclipse.wst.wsdl.ui.internal.icons,
+ org.eclipse.wst.wsdl.ui.internal.model,
+ org.eclipse.wst.wsdl.ui.internal.nsedit,
+ org.eclipse.wst.wsdl.ui.internal.outline,
+ org.eclipse.wst.wsdl.ui.internal.parameters,
+ org.eclipse.wst.wsdl.ui.internal.properties.section,
+ org.eclipse.wst.wsdl.ui.internal.reconciler,
+ org.eclipse.wst.wsdl.ui.internal.text,
+ org.eclipse.wst.wsdl.ui.internal.typesystem,
+ org.eclipse.wst.wsdl.ui.internal.util,
+ org.eclipse.wst.wsdl.ui.internal.util.flatui,
+ org.eclipse.wst.wsdl.ui.internal.util.ui,
+ org.eclipse.wst.wsdl.ui.internal.validation,
+ org.eclipse.wst.wsdl.ui.internal.viewers,
+ org.eclipse.wst.wsdl.ui.internal.viewers.widgets,
+ org.eclipse.wst.wsdl.ui.internal.visitor,
+ org.eclipse.wst.wsdl.ui.internal.widgets,
+ org.eclipse.wst.wsdl.ui.internal.wizards,
+ org.eclipse.wst.wsdl.ui.internal.xsd,
+ org.eclipse.wst.wsdl.ui.internal.xsd.actions,
+ org.eclipse.wst.wsdl.ui.internal.xsd.graph.editparts
Require-Bundle: org.eclipse.core.resources,
+ org.eclipse.core.runtime.compatibility,
org.eclipse.emf.common,
org.eclipse.emf.ecore,
org.eclipse.gef,
@@ -67,16 +65,11 @@
org.eclipse.xsd,
org.eclipse.wst.wsdl,
org.eclipse.wst.common.ui.properties,
- org.eclipse.wst.common.core,
org.eclipse.wst.xsd.ui,
org.eclipse.emf.edit,
org.eclipse.emf.edit.ui,
org.eclipse.wst.validation,
org.wsdl4j,
- org.eclipse.wst.wsdl.validation,
- org.eclipse.ltk.core.refactoring,
- org.eclipse.ltk.ui.refactoring,
- com.ibm.icu,
- org.eclipse.core.runtime,
- org.apache.xerces
-Eclipse-LazyStart: true
+ org.eclipse.wst.wsdl.validation
+Eclipse-AutoStart: true
+Plugin-Class: org.eclipse.wst.wsdl.ui.internal.WSDLEditorPlugin
diff --git a/bundles/org.eclipse.wst.wsdl.ui/build.properties b/bundles/org.eclipse.wst.wsdl.ui/build.properties
index df3cd81..2743386 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/build.properties
+++ b/bundles/org.eclipse.wst.wsdl.ui/build.properties
@@ -16,6 +16,5 @@
about.html
jars.compile.order = .
source.. = src/,\
- src-validation,\
- src-refactor/
+ src-validation
output.. = bin/
diff --git a/bundles/org.eclipse.wst.wsdl.ui/plugin.properties b/bundles/org.eclipse.wst.wsdl.ui/plugin.properties
index 98f5822..0cfcffe 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/plugin.properties
+++ b/bundles/org.eclipse.wst.wsdl.ui/plugin.properties
@@ -11,7 +11,6 @@
!
! Plugin
!
-providerName = Eclipse.org
_UI_PLUGIN_NAME = WSDL Editor
_UI_EDITOR_NAME = WSDL Editor
_UI_WSDL_LABEL = WSDL Files
@@ -300,6 +299,7 @@
_UI_PREF_PAGE_DEFAULT_TARGET_NAMESPACE = Default Target Namespace:
_UI_PREF_PAGE_AUTO_REGENERATE_BINDING = Regenerate Binding on save
+_UI_PREF_PAGE_PROMPT_REGEN_BINDING_ON_SAVE = Prompt Regenerate Binding on save
_UI_PREF_PAGE_CREATING_FILES = Creating files
_UI_CREATE_MESSAGE_CHECKBOX_LABEL = Create default messages
@@ -313,15 +313,6 @@
_WARN_NAME_INVALID_CHAR = IWAX1404W Name field contains invalid character ('
_UI_NAME_INVALID_CHAR_END = ')
-!======================================================================================
-!
-! refactoring
-!
-!======================================================================================
-refactoringActionSet.label=Refactor
-refactoring.menu.label=Refactor
-refactoring.renameAction.label=Re&name...
-
! Copied from sse
23concat_EXC_=Resource {0} does not exist.
32concat_EXC_=Editor could not be open on {0}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/plugin.xml b/bundles/org.eclipse.wst.wsdl.ui/plugin.xml
index 5a78818..d866198 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/plugin.xml
+++ b/bundles/org.eclipse.wst.wsdl.ui/plugin.xml
@@ -323,79 +323,4 @@
</run>
</validator>
</extension>
-
- <!-- Search participant extension that supports XMLComponentSearchPatten on WSDL resources -->
- <extension
- point="org.eclipse.wst.common.core.searchParticipants">
- <searchParticipant
- id="org.eclipse.wst.wsdl.search.WSDLSearchParticipant"
- class="org.eclipse.wst.wsdl.ui.internal.search.WSDLSearchParticipant">
- <enablement>
- <or>
- <with variable="pattern">
- <instanceof value="org.eclipse.wst.xml.core.internal.search.XMLComponentSearchPattern"/>
- </with>
- </or>
- </enablement>
- </searchParticipant>
- </extension>
-
-
-
- <!-- Refactoring CORE -->
- <extension
- point="org.eclipse.ltk.core.refactoring.renameParticipants">
- <renameParticipant
- name="WSDL Rename Particpant"
- class="org.eclipse.wst.wsdl.ui.internal.refactor.WSDLComponentRenameParticipant"
- id="org.eclipse.wst.wsdl.ui.refactoring.WSDLComponentRenameParticipant">
- <enablement>
- <or>
- <with variable="element">
- <instanceof value="org.eclipse.wst.wsdl.WSDLElement"/>
- </with>
- <with variable="element">
- <instanceof value="org.eclipse.xsd.XSDNamedComponent"/>
- </with>
- </or>
- </enablement>
- </renameParticipant>
- </extension>
-
-
- <!-- Refactoring UI extensions -->
- <extension point="org.eclipse.ui.popupMenus">
- <objectContribution
- id="org.eclipse.wst.wsdl.ui.refactoring.menu.objectContrib"
- objectClass="org.eclipse.wst.wsdl.WSDLElement">
- <action
- id="org.eclipse.wst.wsdl.ui.refactoring.menu.refactorGroup.object"
- enablesFor="1"
- style="pulldown"
- menubarPath="additions"
- label="%refactoring.menu.label"
- class="org.eclipse.wst.wsdl.ui.internal.refactor.actions.WSDLRefactorGroupActionDelegate">
- </action>
- </objectContribution>
-
- <viewerContribution
- id="org.eclipse.wst.xsd.ui.refactoring.menu.source"
- targetID="org.eclipse.wst.wsdl.wsdlsource.source.EditorContext">
- <action id="org.eclipse.wst.wsdl.ui.refactoring.menu.refactorGroup.source"
- style="pulldown"
- menubarPath="additions"
- label="%refactoring.menu.label"
- class="org.eclipse.wst.wsdl.ui.internal.refactor.actions.WSDLRefactorGroupActionDelegate">
- </action>
- </viewerContribution>
- </extension>
-
- <extension point="org.eclipse.ui.commands">
- <command
- name="%command.wsdl.refactor.rename.element.name"
- description="%command.wsdl.refactor.rename.element.description"
- categoryId="org.eclipse.ui.category.edit"
- id="org.eclipse.wst.wsdl.ui.refactor.rename.element">
- </command>
- </extension>
</plugin>
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/refactor/actions/WSDLRefactorGroupActionDelegate.java b/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/refactor/actions/WSDLRefactorGroupActionDelegate.java
index 7d4c071..02fcfdf 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/refactor/actions/WSDLRefactorGroupActionDelegate.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/refactor/actions/WSDLRefactorGroupActionDelegate.java
@@ -23,8 +23,8 @@
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.IFileEditorInput;
import org.eclipse.ui.IWorkbenchPartSite;
-import org.eclipse.wst.sse.core.StructuredModelManager;
import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
+import org.eclipse.wst.sse.core.internal.provisional.StructuredModelManager;
import org.eclipse.wst.wsdl.Definition;
import org.eclipse.wst.wsdl.WSDLFactory;
import org.eclipse.wst.wsdl.internal.util.WSDLResourceFactoryImpl;
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/search/WSDLSearchParticipant.java b/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/search/WSDLSearchParticipant.java
index 40041e5..d8508b6 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/search/WSDLSearchParticipant.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src-refactor/org/eclipse/wst/wsdl/ui/internal/search/WSDLSearchParticipant.java
@@ -13,7 +13,6 @@
import java.util.ArrayList;
import java.util.List;
-import java.util.Map;
import org.eclipse.wst.common.core.search.SearchParticipant;
import org.eclipse.wst.common.core.search.SearchPlugin;
@@ -31,21 +30,12 @@
private static String ID = "org.eclipse.wst.wsdl.search.WSDLSearchParticipant";
private static String XSD_PARTICIPANNT_ID = "org.eclipse.wst.xsd.search.XSDSearchParticipant";
+
- public WSDLSearchParticipant()
- {
- super();
- id = ID;
- }
-
- public String[] getSupportedContentTypes()
- {
- String[] result = { "org.eclipse.wst.wsdl.wsdlsource" };
- return result;
- }
-
- public boolean isApplicable(SearchPattern pattern, Map searchOptions)
- {
+ public boolean initialize(SearchPattern pattern, String[] contentTypes){
+
+ super.initialize(pattern, contentTypes);
+ id = ID;
if(pattern instanceof XMLComponentSearchPattern ){
XMLComponentSearchPattern componentPattern = (XMLComponentSearchPattern)pattern;
String namespace = componentPattern.getMetaName().getNamespace();
@@ -55,16 +45,17 @@
}
}
return false;
- }
-
+ }
+
+
public ComponentSearchContributor getSearchContributor() {
return new WSDLSearchContributor();
}
- public void beginSearching(SearchPattern pattern, Map searchOptions) {
+ public void beginSearching(SearchPattern pattern) {
- super.beginSearching(pattern, searchOptions);
+ super.beginSearching(pattern);
List patterns = new ArrayList();
if(pattern instanceof XMLComponentDeclarationPattern){
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditor.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditor.java
index a18f890..91d66e5 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditor.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditor.java
@@ -282,18 +282,7 @@
if (object instanceof Node) {
node = (Node) object;
- }
- else if (object instanceof String){
- // The string is expected to be a URI fragment used to identify a WSDL element.
- // The URI fragment should be relative to the definition being edited in this editor.
-
- String uriFragment = (String)object;
- EObject eObject = getDefinition().eResource().getEObject(uriFragment);
-
- if (eObject != null) {
- node = ((WSDLElement)eObject).getElement();
- }
- }
+ }
else {
node = WSDLEditorUtil.getInstance().getNodeForObject(object);
}
@@ -674,7 +663,14 @@
}
}
- public INavigationLocation createEmptyNavigationLocation() {
+ public void openOnSelection(String specification) {
+ EObject eObject = getDefinition().eResource().getEObject(specification);
+ if (eObject != null) {
+ getSelectionManager().setSelection(new StructuredSelection(eObject));
+ }
+ }
+
+ public INavigationLocation createEmptyNavigationLocation() {
return new InternalTextSelectionNavigationLocation(textEditor, false);
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditorPlugin.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditorPlugin.java
index 708afef..f9e5dfb 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditorPlugin.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLEditorPlugin.java
@@ -18,11 +18,11 @@
import org.eclipse.core.resources.IWorkspace;
import org.eclipse.core.resources.ResourcesPlugin;
-import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionPoint;
import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.IPath;
+import org.eclipse.core.runtime.IPluginDescriptor;
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Platform;
import org.eclipse.jface.preference.IPreferenceStore;
@@ -34,8 +34,6 @@
import org.eclipse.wst.wsdl.ui.internal.extension.ExtensibilityItemTreeProviderRegistry;
import org.eclipse.wst.wsdl.ui.internal.extension.NSKeyedExtensionRegistry;
import org.eclipse.wst.wsdl.ui.internal.extension.WSDLEditorExtensionRegistry;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
public class WSDLEditorPlugin extends AbstractUIPlugin //, IPluginHelper
{
@@ -75,9 +73,9 @@
* Resources helper.
*/
- public WSDLEditorPlugin()
+ public WSDLEditorPlugin(IPluginDescriptor descriptor)
{
- super();
+ super(descriptor);
instance = this;
// TODO... remove this code when we add 'dependenciesChangedPolicy'
@@ -95,24 +93,6 @@
{
}
}
-
-
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- */
- public void start(BundleContext context) throws Exception
- {
- super.start(context);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
- */
- public void stop(BundleContext context) throws Exception
- {
- super.stop(context);
- }
public WSDLEditorExtensionRegistry getWSDLEditorExtensionRegistry()
{
@@ -189,14 +169,7 @@
*/
public static URL getInstallURL()
{
- try
- {
- return FileLocator.resolve(instance.getBundle().getEntry("/"));
- }
- catch (IOException e)
- {
- return null;
- }
+ return getInstance().getDescriptor().getInstallURL();
}
/**
@@ -231,7 +204,7 @@
try
{
IPath installPath = new Path(getInstallURL().toExternalForm()).removeTrailingSeparator();
- String installStr = FileLocator.toFileURL(new URL(installPath.toString())).getFile();
+ String installStr = Platform.asLocalURL(new URL(installPath.toString())).getFile();
return new Path(installStr);
}
catch (IOException e)
@@ -428,8 +401,8 @@
{
try
{
- Bundle bundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
- registry.add(bundle, className);
+ ClassLoader pluginClsLoader = element.getDeclaringExtension().getDeclaringPluginDescriptor().getPlugin().getClass().getClassLoader();
+ registry.add(pluginClsLoader, className);
}
catch (Exception e)
{
@@ -487,13 +460,13 @@
String namespace = element.getAttribute(ATT_NAME_SPACE);
if (namespace != null)
{
- Bundle bundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
+ ClassLoader pluginClasssLoader = element.getDeclaringExtension().getDeclaringPluginDescriptor().getPluginClassLoader();
if (attributeNames.length == 1)
{
String className = element.getAttribute(attributeNames[0]);
if (className != null)
{
- nsKeyedExtensionRegistry.put(namespace, className, bundle);
+ nsKeyedExtensionRegistry.put(namespace, className, pluginClasssLoader);
}
}
else
@@ -508,7 +481,7 @@
map.put(attributeName, className);
}
}
- nsKeyedExtensionRegistry.put(namespace, map, bundle);
+ nsKeyedExtensionRegistry.put(namespace, map, pluginClasssLoader);
}
}
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlink.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlink.java
index fc37ece..61088f5 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlink.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlink.java
@@ -8,112 +8,97 @@
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
-
package org.eclipse.wst.wsdl.ui.internal;
+import java.lang.reflect.Method;
+
import org.eclipse.core.resources.IFile;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.text.IRegion;
import org.eclipse.jface.text.hyperlink.IHyperlink;
-import org.eclipse.jface.viewers.ISelectionProvider;
-import org.eclipse.jface.viewers.StructuredSelection;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.IFileEditorInput;
import org.eclipse.ui.IWorkbenchPage;
import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.ide.IDE;
-import org.eclipse.wst.xsd.ui.internal.Logger;
+import org.eclipse.ui.part.FileEditorInput;
/**
- * WSDLHyperlink knows how to open links from wsdl files.
- *
- * @see WSDLHyperlinkDetector
+ * WSDL Hyperlink that knows how to open links from wsdl files
*/
-public class WSDLHyperlink implements IHyperlink
-{
- private IRegion fRegion;
- private String fResource;
- private String fSpec;
+public class WSDLHyperlink implements IHyperlink {
+ private IRegion fRegion;
+ private String fResource;
+ private String fSpec;
- public WSDLHyperlink(IRegion region, String resource, String spec)
- {
- fRegion = region;
- fResource = resource;
- fSpec = spec;
- }
+ public WSDLHyperlink(IRegion region, String resource, String spec) {
+ fRegion = region;
+ fResource = resource;
+ fSpec = spec;
+ }
- public IRegion getHyperlinkRegion()
- {
- return fRegion;
- }
+ public IRegion getHyperlinkRegion() {
+ return fRegion;
+ }
- public String getTypeLabel()
- {
- return null;
- }
+ public String getTypeLabel() {
+ return null;
+ }
- public String getHyperlinkText()
- {
- return null;
- }
+ public String getHyperlinkText() {
+ return null;
+ }
- public void open()
- {
- /*
- * ISSUE: There are cleaner ways to find the right file based on a URI
- * string and cleaner ways to find which editor to open for the file. See
- * other IHyperlink and IHyperlinkDetector implementors for examples.
- */
- String pattern = "platform:/resource";
- if (fResource != null && fResource.startsWith(pattern))
- {
- Path path = new Path(fResource.substring(pattern.length()));
- IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path);
+ public void open() {
+ /*
+ * ISSUE: There are cleaner ways to find the right file based on a URI
+ * string and cleaner ways to find which editor to open for the file.
+ * See other IHyperlink and IHyperlinkDetector implementors for
+ * examples.
+ */
+ String pattern = "platform:/resource";
+ if (fResource != null && fResource.startsWith(pattern)) {
+ try {
+ Path path = new Path(fResource.substring(pattern.length()));
+ IFile file = ResourcesPlugin.getWorkspace().getRoot().getFile(path);
- IWorkbenchPage workbenchPage = PlatformUI.getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ IWorkbenchPage workbenchPage = WSDLEditorPlugin.getInstance().getWorkbench().getActiveWorkbenchWindow().getActivePage();
+ IEditorPart editorPart = workbenchPage.getActiveEditor();
- IEditorPart editorPart = workbenchPage.getActiveEditor();
+ if (editorPart.getEditorInput() instanceof IFileEditorInput && ((IFileEditorInput) editorPart.getEditorInput()).getFile().equals(file)) {
+ workbenchPage.getNavigationHistory().markLocation(editorPart);
+ }
+ else {
+ try {
+ if (fResource.endsWith("xsd")) {
+ editorPart = workbenchPage.openEditor(new FileEditorInput(file), WSDLEditorPlugin.XSD_EDITOR_ID);
+ }
+ else {
+ // Since we are already in the wsdleditor
+ editorPart = workbenchPage.openEditor(new FileEditorInput(file), editorPart.getEditorSite().getId());
+ }
+ }
+ catch (PartInitException initEx) {
+ }
+ }
- // When using the cursor or the mouse to move around in the text
- // editor, the location history is not updated, so we make sure we keep
- // a reference to where we are. If we use other navigation means, like the
- // outline view, this call will not add a new location history entry, as
- // it is the same as the last location set through the outline driven
- // navigation.
-
- boolean sameEditor = editorPart.getEditorInput() instanceof IFileEditorInput && ((IFileEditorInput) editorPart.getEditorInput()).getFile().equals(file);
-
- workbenchPage.getNavigationHistory().markLocation(editorPart);
-
- if (!sameEditor)
- {
- try
- {
- // The target is in a different file, so open the target's enclosing
- // resource in it's own editor. Let the workbench decide what editor
- // to open based on the file's content type.
-
- editorPart = IDE.openEditor(workbenchPage, file, true);
- }
- catch (PartInitException e)
- {
- Logger.log(Logger.WARNING_DEBUG, e.getMessage(), e);
- return;
- }
- }
-
- // Attempt to retrieve the target editor's selection manager and try to
- // change the selection to the thing (schema component, wsdl element, etc)
- // pointed to by fSpec.
-
- ISelectionProvider selectionProvider = (ISelectionProvider) editorPart.getAdapter(ISelectionProvider.class);
-
- if (selectionProvider != null)
- {
- selectionProvider.setSelection(new StructuredSelection(fSpec));
- }
- }
- }
-}
\ No newline at end of file
+ /*
+ * ISSUE: This just does not look like a safe thing to do. One
+ * simple solution would be to have an interface for
+ * openOnSelection that your editors can implement. Or, java
+ * editor has something like a utility that is able to find
+ * the offset/location for a given element in a file. Once you
+ * have offset/location, you can just call setSelection.
+ */
+ Class theClass = editorPart.getClass();
+ Class[] methodArgs = {String.class};
+ Method method = theClass.getMethod("openOnSelection", methodArgs);
+ Object args[] = {fSpec};
+ method.invoke(editorPart, args);
+ workbenchPage.getNavigationHistory().markLocation(editorPart);
+ }
+ catch (Exception e) {
+ }
+ }
+ }
+}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlinkDetector.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlinkDetector.java
index fdf9e51..0309b0e 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlinkDetector.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/WSDLHyperlinkDetector.java
@@ -8,100 +8,122 @@
* Contributors:
* IBM Corporation - initial API and implementation
*******************************************************************************/
-
package org.eclipse.wst.wsdl.ui.internal;
+import java.util.ArrayList;
+import java.util.List;
+
import org.eclipse.jface.text.IDocument;
import org.eclipse.jface.text.IRegion;
+import org.eclipse.jface.text.ITextViewer;
+import org.eclipse.jface.text.Region;
import org.eclipse.jface.text.hyperlink.IHyperlink;
-import org.eclipse.wst.sse.core.StructuredModelManager;
+import org.eclipse.jface.text.hyperlink.IHyperlinkDetector;
import org.eclipse.wst.sse.core.internal.provisional.IStructuredModel;
+import org.eclipse.wst.sse.core.internal.provisional.IndexedRegion;
+import org.eclipse.wst.sse.core.internal.provisional.StructuredModelManager;
import org.eclipse.wst.wsdl.Definition;
import org.eclipse.wst.wsdl.ui.internal.text.WSDLModelAdapter;
import org.eclipse.wst.wsdl.ui.internal.util.OpenOnSelectionHelper;
-import org.eclipse.wst.wsdl.util.WSDLConstants;
import org.eclipse.wst.xml.core.internal.provisional.document.IDOMDocument;
import org.eclipse.wst.xml.core.internal.provisional.document.IDOMModel;
-import org.eclipse.wst.xml.core.internal.provisional.document.IDOMNode;
-import org.eclipse.wst.xsd.ui.internal.BaseHyperlinkDetector;
+import org.w3c.dom.Node;
/**
- * Detects hyperlinks for WSDL files. Used by the WSDL text editor to provide a
- * "Go to declaration" functionality similar with the one provided by the Java
- * editor.
+ * Detects hyperlinks for WSDL files
*/
-public class WSDLHyperlinkDetector extends BaseHyperlinkDetector
-{
- /*
- * (non-Javadoc)
- */
- protected IHyperlink createHyperlink(IDocument document, IDOMNode node, IRegion region)
- {
- // Here we're trying to find the target component's resource and spec.
+public class WSDLHyperlinkDetector implements IHyperlinkDetector {
+ /**
+ * Gets the definition from document
+ *
+ * @param document
+ * @return Definition
+ */
+ private Definition getDefinition(IDocument document) {
+ Definition definition = null;
+ IStructuredModel model = StructuredModelManager.getModelManager().getExistingModelForRead(document);
+ if (model != null) {
+ try {
+ if (model instanceof IDOMModel) {
+ IDOMDocument domDoc = ((IDOMModel) model).getDocument();
+ if (domDoc != null) {
+ WSDLModelAdapter modelAdapter = (WSDLModelAdapter) domDoc.getAdapterFor(WSDLModelAdapter.class);
- Definition definition = getDefinition(document);
- OpenOnSelectionHelper helper = new OpenOnSelectionHelper(definition);
- String[] targetData = helper.computeSpecification(node);
+ /*
+ * ISSUE: if adapter does not already exist for domDoc
+ * getAdapterFor will create one. So why is this null
+ * check/creation needed?
+ */
+ if (modelAdapter == null) {
+ modelAdapter = new WSDLModelAdapter();
+ domDoc.addAdapter(modelAdapter);
+ modelAdapter.createDefinition(domDoc.getDocumentElement(), domDoc);
+ }
- if (targetData != null)
- {
- String resource = targetData[0];
- String spec = targetData[1];
- return new WSDLHyperlink(region, resource, spec);
- }
+ definition = modelAdapter.getDefinition();
+ }
+ }
+ }
+ finally {
+ model.releaseFromRead();
+ }
+ }
+ return definition;
+ }
- return null;
- }
+ public IHyperlink[] detectHyperlinks(ITextViewer textViewer, IRegion region, boolean canShowMultipleHyperlinks) {
+ // for now, only capable of creating 1 hyperlink
+ List hyperlinks = new ArrayList(0);
- /**
- * Gets the definition from document
- *
- * @param document
- * @return Definition
- */
- private Definition getDefinition(IDocument document)
- {
- Definition definition = null;
- IStructuredModel model = StructuredModelManager.getModelManager().getExistingModelForRead(document);
- if (model != null)
- {
- try
- {
- if (model instanceof IDOMModel)
- {
- IDOMDocument domDoc = ((IDOMModel) model).getDocument();
- if (domDoc != null)
- {
- WSDLModelAdapter modelAdapter = (WSDLModelAdapter) domDoc.getAdapterFor(WSDLModelAdapter.class);
- // ISSUE: if adapter does not already exist for domDoc getAdapterFor
- // will create one. So why is this null check/creation needed?
- if (modelAdapter == null)
- {
- modelAdapter = new WSDLModelAdapter();
- domDoc.addAdapter(modelAdapter);
- modelAdapter.createDefinition(domDoc.getDocumentElement(), domDoc);
- }
- definition = modelAdapter.getDefinition();
- }
- }
- }
- finally
- {
- model.releaseFromRead();
- }
- }
- return definition;
- }
+ if (region != null && textViewer != null) {
+ IDocument document = textViewer.getDocument();
+ Node node = getCurrentNode(document, region.getOffset());
- /*
- * (non-Javadoc)
- */
- protected boolean isLinkableAttribute(String name)
- {
- boolean isLinkable = name.equals(WSDLConstants.BINDING_ATTRIBUTE) ||
- name.equals(WSDLConstants.ELEMENT_ATTRIBUTE) ||
- name.equals(WSDLConstants.TYPE_ATTRIBUTE) ||
- name.equals(WSDLConstants.MESSAGE_ATTRIBUTE);
- return isLinkable;
- }
-}
\ No newline at end of file
+ if (node != null) {
+ Definition definition = getDefinition(textViewer.getDocument());
+ OpenOnSelectionHelper helper = new OpenOnSelectionHelper(definition);
+ String[] array = helper.computeSpecification(node);
+ if (array != null) {
+ IRegion nodeRegion = region;
+ if (node instanceof IndexedRegion) {
+ IndexedRegion indexed = (IndexedRegion) node;
+ nodeRegion = new Region(indexed.getStartOffset(), indexed.getLength());
+ }
+ hyperlinks.add(new WSDLHyperlink(nodeRegion, array[0], array[1]));
+ }
+ }
+ }
+ if (hyperlinks.size() == 0)
+ return null;
+ return (IHyperlink[]) hyperlinks.toArray(new IHyperlink[0]);
+ }
+
+ /**
+ * Returns the node the cursor is currently on in the document. null if no
+ * node is selected
+ *
+ * @param offset
+ * @return Node either element, doctype, text, or null
+ */
+ private Node getCurrentNode(IDocument document, int offset) {
+ // get the current node at the offset (returns either: element,
+ // doctype, text)
+ IndexedRegion inode = null;
+ IStructuredModel sModel = null;
+ try {
+ sModel = StructuredModelManager.getModelManager().getExistingModelForRead(document);
+ inode = sModel.getIndexedRegion(offset);
+ if (inode == null)
+ inode = sModel.getIndexedRegion(offset - 1);
+ }
+ finally {
+ if (sModel != null)
+ sModel.releaseFromRead();
+ }
+
+ if (inode instanceof Node) {
+ return (Node) inode;
+ }
+ return null;
+ }
+}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/SourceEditorActionBarContributor.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/SourceEditorActionBarContributor.java
index ccef1da..472ca0d 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/SourceEditorActionBarContributor.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/SourceEditorActionBarContributor.java
@@ -16,6 +16,7 @@
import org.eclipse.ui.IActionBars;
import org.eclipse.ui.IEditorActionBarContributor;
import org.eclipse.ui.IEditorPart;
+import org.eclipse.ui.part.EditorActionBarContributor;
import org.eclipse.ui.part.MultiPageEditorActionBarContributor;
import org.eclipse.wst.sse.ui.StructuredTextEditor;
import org.eclipse.wst.sse.ui.internal.ExtendedEditorActionBuilder;
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLActionBarContributor.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLActionBarContributor.java
index b7f9855..1ac3e78 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLActionBarContributor.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLActionBarContributor.java
@@ -15,6 +15,7 @@
import org.eclipse.jface.action.IToolBarManager;
import org.eclipse.ui.IEditorPart;
import org.eclipse.ui.actions.ActionFactory;
+import org.eclipse.ui.part.EditorActionBarContributor;
import org.eclipse.ui.texteditor.ITextEditor;
import org.eclipse.ui.texteditor.ITextEditorActionConstants;
import org.eclipse.wst.wsdl.ui.internal.WSDLEditor;
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLMenuActionContributor.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLMenuActionContributor.java
index ce494be..ba1026d 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLMenuActionContributor.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/actions/WSDLMenuActionContributor.java
@@ -58,6 +58,7 @@
import org.eclipse.wst.wsdl.ui.internal.util.CreateWSDLElementHelper;
import org.eclipse.wst.wsdl.ui.internal.util.NameUtil;
import org.eclipse.wst.wsdl.ui.internal.util.WSDLEditorUtil;
+import org.eclipse.wst.wsdl.ui.internal.widgets.NewComponentDialog;
import org.eclipse.wst.wsdl.ui.internal.widgets.NewComponentWithChildDialog;
import org.eclipse.wst.wsdl.ui.internal.wizards.BindingWizard;
import org.eclipse.wst.wsdl.ui.internal.wizards.PortWizard;
@@ -334,7 +335,15 @@
menu.add(deleteAtion);
deleteAtion.setEnabled(isEditable);
}
-
+
+ // Allow Rename through a dialog mechanism..... This should be changed when
+ // direct editing is ready
+ if (object instanceof WSDLElement && isEditable) {
+ RenameDialogAction renameDialog = new RenameDialogAction((WSDLElement) object);
+ if (renameDialog.showRenameDialog())
+ menu.add(renameDialog);
+ }
+
// insertion point for popupMenus extension
menu.add(new Separator(IWorkbenchActionConstants.MB_ADDITIONS));
}
@@ -1145,4 +1154,103 @@
wizardDialog.create();
wizardDialog.open();
}
+}
+
+//This is a temporary class to allow renaming. This should be replaced when direct
+//renaming is ready
+class RenameDialogAction extends Action {
+ private WSDLElement element;
+ private String defaultName = "NewName";
+ private List usedNames = new ArrayList();
+ private boolean useSmartRename = false;
+ private boolean showDialog = false;
+
+ public RenameDialogAction(WSDLElement selection) {
+ setText(WSDLEditorPlugin.getWSDLString("_UI_ACTION_RENAME"));
+ element = selection;
+ initialize();
+ }
+
+ public void run() {
+ String result;
+
+ NewComponentDialog dialog = new NewComponentDialog(WSDLEditorPlugin.getShell(), WSDLEditorPlugin.getWSDLString("_UI_ACTION_RENAME"), defaultName, usedNames);
+ int rc = dialog.createAndOpen();
+ if (rc == IDialogConstants.OK_ID)
+ {
+ result = dialog.getName();
+ if (useSmartRename) {
+ SmartRenameAction smartRename = new SmartRenameAction(element, result);
+ smartRename.run();
+ }
+ else {
+ RenameAction rename = new RenameAction(element, result);
+ rename.run();
+ }
+ }
+ }
+
+ public void initialize() {
+ if (element instanceof Fault) {
+ usedNames = NameUtil.getUsedFaultNames((Operation) ((Fault) element).eContainer());
+ defaultName = ((Fault) element).getName();
+
+ showDialog = true;
+ useSmartRename = true;
+ }
+ else if (element instanceof Message) {
+ usedNames = NameUtil.getUsedMessageNames(element.getEnclosingDefinition());
+ defaultName = ((Message) element).getQName().getLocalPart();
+
+ showDialog = true;
+ useSmartRename = true;
+ }
+ else if (element instanceof Operation) {
+ usedNames = NameUtil.getUsedOperationNames((PortType) ((Operation) element).eContainer());
+ defaultName = ((Operation) element).getName();
+
+ showDialog = true;
+ useSmartRename = true;
+ }
+ else if (element instanceof Part) {
+ usedNames = NameUtil.getUsedPartNames((Message) ((Part) element).eContainer());
+ defaultName = ((Part) element).getName();
+
+ showDialog = true;
+ useSmartRename = true;
+ }
+ else if (element instanceof PortType) {
+ usedNames = NameUtil.getUsedPortTypeNames(element.getEnclosingDefinition());
+ defaultName = ((PortType) element).getQName().getLocalPart();
+
+ showDialog = true;
+ useSmartRename = false;
+ }
+ else if (element instanceof Port) {
+ usedNames = NameUtil.getUsedPortNames((Service) ((Port) element).eContainer());
+ defaultName = ((Port) element).getName();
+
+ showDialog = true;
+ useSmartRename = true;
+ }
+ else if (element instanceof Binding) {
+ usedNames = NameUtil.getUsedBindingNames(element.getEnclosingDefinition());
+ defaultName = ((Binding) element).getQName().getLocalPart();
+
+ showDialog = true;
+ useSmartRename = false;
+ }
+ else if (element instanceof Service) {
+ usedNames = NameUtil.getUsedServiceNames(element.getEnclosingDefinition());
+ defaultName = ((Service) element).getQName().getLocalPart();
+
+ showDialog = true;
+ useSmartRename = false;
+ }
+ usedNames.remove(defaultName);
+ }
+
+ public boolean showRenameDialog() {
+ return showDialog;
+ }
}
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentFinder.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentFinder.java
index 3673cbb..297501c 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentFinder.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentFinder.java
@@ -14,85 +14,58 @@
import java.util.Iterator;
import java.util.List;
-import org.eclipse.core.runtime.CoreException;
-import org.eclipse.core.runtime.NullProgressMonitor;
-import org.eclipse.wst.common.core.search.SearchEngine;
-import org.eclipse.wst.common.core.search.SearchMatch;
-//import org.eclipse.wst.common.core.search.SearchParticipant;
-//import org.eclipse.wst.common.core.search.SearchPlugin;
-import org.eclipse.wst.common.core.search.pattern.QualifiedName;
-import org.eclipse.wst.common.core.search.pattern.SearchPattern;
-import org.eclipse.wst.common.core.search.scope.ProjectSearchScope;
-import org.eclipse.wst.common.core.search.scope.SearchScope;
-import org.eclipse.wst.common.core.search.scope.WorkspaceSearchScope;
-import org.eclipse.wst.common.core.search.util.CollectingSearchRequestor;
-//import org.eclipse.wst.wsdl.util.WSDLConstants;
-import org.eclipse.wst.xml.core.internal.search.XMLComponentDeclarationPattern;
+import org.eclipse.core.runtime.Path;
import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLComponentFinder;
-import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLComponentSpecification;
+import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLQuickScan;
public class WSDLComponentFinder extends XMLComponentFinder {
- QualifiedName metaName;
- public WSDLComponentFinder(QualifiedName metaName) {
- this.metaName = metaName;
- }
+ List lookupTagPaths;
-
- protected void findComponents(SearchEngine searchEngine, List list, int scope)
- {
- SearchScope searchScope = new WorkspaceSearchScope();
- if (scope == ENCLOSING_PROJECT_SCOPE)
- {
- searchScope = new ProjectSearchScope(currentIFile.getProject().getLocation());
- }
- try {
- CollectingSearchRequestor requestor = new CollectingSearchRequestor();
-
- XMLComponentDeclarationPattern pattern = new XMLComponentDeclarationPattern(new QualifiedName("*", "*"), metaName, SearchPattern.R_PATTERN_MATCH);
-
- // TODO (cs) rethink the commented out code below. Is there some reason for narrowing to list of search particpants?
- // It seems the only benefit may be to filter our xsd component declarations that aren't defined
- // in stand alone wsdl documents. Perhaps it's best to do this with an additional property arg on the
- // declaration pattern or perhaps simply doing some 'post' filtering.
- //
- //String participantId = metaName.getNamespace().equals(WSDLConstants.WSDL_NAMESPACE_URI) ?
- // "org.eclipse.wst.wsdl.search.WSDLSearchParticipant" :
- // "org.eclipse.wst.xsd.search.XSDSearchParticipant";
- //SearchParticipant particpant = SearchPlugin.getDefault().getSearchParticipant(participantId);
- //SearchParticipant[] participants = { particpant };
-
- // TODO (cs) I'm betting we'll need to provide some hook here to allow extenders to configure
- // the search options. Currently we just pass in null.
- searchEngine.search(pattern, requestor, searchScope, null, new NullProgressMonitor());
-
- for (Iterator i = requestor.getResults().iterator(); i.hasNext(); )
- {
- SearchMatch match = (SearchMatch)i.next();
- XMLComponentSpecification spec = new XMLComponentSpecification(metaName);
- spec.setFileLocation(match.getFile().getLocation().toString());
- Object o = match.map.get("name");
- if (o != null && o instanceof QualifiedName)
- {
- QualifiedName qualifiedName = (QualifiedName)o;
- if (qualifiedName.getLocalName() != null)
- {
- spec.addAttributeInfo("name", qualifiedName.getLocalName());
- spec.setTargetNamespace(qualifiedName.getNamespace());
- list.add(spec);
- }
- }
- }
- } catch (CoreException e) {
- e.printStackTrace();
- //status.add(e.getStatus());
- }
+ public WSDLComponentFinder(List tagPaths) {
+ lookupTagPaths = new ArrayList();
+ lookupTagPaths.addAll(tagPaths);
}
public List getWorkbenchResourceComponents(int scope) {
+ List components = new ArrayList();
+ List filePaths = new ArrayList();
+
+ // We don't want to search through the current file we're working on.
+ if (currentIFile != null) {
+ excludeFiles.add(currentIFile.getLocation().toOSString());
+ }
+
+ // Find files matching the search criteria specified in List extensions and
+ // List excludeFiles.
+ switch (scope) {
+ case ENCLOSING_PROJECT_SCOPE:
+ filePaths = getEnclosingProjectFiles();
+ break;
+
+ case ENTIRE_WORKSPACE_SCOPE:
+ filePaths = getWorkspaceFiles();
+ break;
+
+ default:
+ break;
+ }
+
+ // Search for the components in each of the files specified in the path.
+ List attributes = new ArrayList();
+ String[] nameAttr = new String[1];
+ nameAttr[0] = "name";
+ attributes.add(nameAttr);
+ attributes.add(nameAttr);
+ attributes.add(nameAttr);
+ attributes.add(nameAttr);
- List list = new ArrayList();
- SearchEngine searchEngine = new SearchEngine();
- findComponents(searchEngine, list, scope);
- return list;
+ Iterator pathsIterator = filePaths.iterator();
+ while (pathsIterator.hasNext()) {
+// String stringPath = ((Path) pathsIterator.next()).toOSString();
+ String stringPath = ((Path) pathsIterator.next()).toString();
+ components.addAll(XMLQuickScan.getTagInfo(stringPath, lookupTagPaths, attributes));
+ }
+
+ return components;
}
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentSelectionProvider.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentSelectionProvider.java
index dcb8fdc..9ef24c0 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentSelectionProvider.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLComponentSelectionProvider.java
@@ -17,7 +17,6 @@
import org.eclipse.core.resources.IFile;
import org.eclipse.jface.viewers.ILabelProvider;
import org.eclipse.swt.graphics.Image;
-import org.eclipse.wst.common.core.search.pattern.QualifiedName;
import org.eclipse.wst.wsdl.Definition;
import org.eclipse.wst.wsdl.Import;
import org.eclipse.wst.wsdl.WSDLElement;
@@ -31,9 +30,7 @@
import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLComponentSelectionDialog;
import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLComponentSelectionProvider;
import org.eclipse.wst.xsd.ui.internal.dialogs.types.xml.XMLComponentSpecification;
-import org.eclipse.wst.xsd.ui.internal.search.IXSDSearchConstants;
import org.eclipse.wst.xsd.ui.internal.util.XSDDOMHelper;
-import org.eclipse.wst.wsdl.ui.internal.search.IWSDLSearchConstants;
import org.eclipse.wst.wsdl.ui.internal.util.WSDLEditorUtil;
import org.eclipse.xsd.XSDComplexTypeDefinition;
import org.eclipse.xsd.XSDElementDeclaration;
@@ -52,7 +49,7 @@
private WSDLComponentSelectionDialog dialog;
private WSDLComponentLabelProvider labelProvider;
private Definition definition;
- private QualifiedName metaName;
+ private List lookupTagPaths;
private int kind;
/*
@@ -62,46 +59,55 @@
this.kind = kind;
List validExt = new ArrayList(1);
validExt.add("wsdl");
- this.metaName = getQualifiedName(kind);
- wsdlComponentFinder = new WSDLComponentFinder(metaName);
+ this.lookupTagPaths = getLookupTagPath();
+ wsdlComponentFinder = new WSDLComponentFinder(lookupTagPaths);
wsdlComponentFinder.setFile(file);
- //wsdlComponentFinder.setValidExtensions(validExt);
+ wsdlComponentFinder.setValidExtensions(validExt);
this.definition = definition;
labelProvider = new WSDLComponentLabelProvider();
}
- protected QualifiedName getQualifiedName(int kind)
- {
+ protected List getLookupTagPath()
+ {
+ List list = new ArrayList();
switch (kind)
{
case WSDLConstants.BINDING :
{
- return IWSDLSearchConstants.BINDING_META_NAME;
+ list.add("/definitions/binding");
+ break;
}
case WSDLConstants.PORT_TYPE :
{
- return IWSDLSearchConstants.PORT_TYPE_META_NAME;
+ list.add("/definitions/portType");
+ break;
}
case WSDLConstants.MESSAGE :
{
- return IWSDLSearchConstants.MESSAGE_META_NAME;
+ list.add("/definitions/message");
+ break;
}
case WSDLEditorUtil.TYPE :
{
- // TODO... need to combine complex and simple into a single meta name
- return IXSDSearchConstants.COMPLEX_TYPE_META_NAME;
+ list.add("/definitions/types/schema/simpleType");
+ list.add("/definitions/types/schema/complexType");
+ list.add("/schema/complexType");
+ list.add("/schema/simpleType");
+ break;
}
case WSDLEditorUtil.ELEMENT :
{
- return IXSDSearchConstants.ELEMENT_META_NAME;
+ list.add("/definitions/types/schema/element");
+ list.add("/schema/element");
+ break;
}
}
- return null;
+ return list;
}
public WSDLComponentSelectionProvider(IFile file, Definition definition, int kind, List validExt) {
this(file, definition, kind);
- //wsdlComponentFinder.setValidExtensions(validExt);
+ wsdlComponentFinder.setValidExtensions(validExt);
}
public void setDialog(WSDLComponentSelectionDialog dialog) {
@@ -112,11 +118,11 @@
return null;
}
- private void createWSDLComponentObjects(IComponentList list, List inputComponents, QualifiedName metaName) {
+ private void createWSDLComponentObjects(IComponentList list, List inputComponents, String tagPath) {
Iterator it = inputComponents.iterator();
while (it.hasNext()) {
WSDLElement wsdlElement = (WSDLElement) it.next();
- XMLComponentSpecification spec = new XMLComponentSpecification(metaName);
+ XMLComponentSpecification spec = new XMLComponentSpecification(tagPath);
spec.addAttributeInfo("name", wsdlElement.getElement().getAttribute("name"));
spec.setTargetNamespace(wsdlElement.getEnclosingDefinition().getTargetNamespace());
@@ -127,11 +133,11 @@
}
}
- private void createXSDComponentObjects(IComponentList list, List inputComponents, QualifiedName metaName) {
+ private void createXSDComponentObjects(IComponentList list, List inputComponents, String tagPath) {
Iterator it = inputComponents.iterator();
while (it.hasNext()) {
XSDNamedComponent xsdElement = (XSDNamedComponent) it.next();
- XMLComponentSpecification spec = new XMLComponentSpecification(metaName);
+ XMLComponentSpecification spec = new XMLComponentSpecification(tagPath);
spec.addAttributeInfo("name", xsdElement.getName());
spec.setTargetNamespace(xsdElement.getTargetNamespace());
@@ -144,10 +150,10 @@
public void getComponents(IComponentList list, boolean quick) {
if (quick) {
- //Iterator tags = lookupTagPaths.iterator();
- //while (tags.hasNext()) {
- getComponentsQuick(list, metaName);
- //}
+ Iterator tags = lookupTagPaths.iterator();
+ while (tags.hasNext()) {
+ getComponentsQuick(list, (String) tags.next());
+ }
}
else {
// Grab components from workspace locations
@@ -172,11 +178,11 @@
}
}
- private void getComponentsQuick(IComponentList list, QualifiedName metaName) {
+ private void getComponentsQuick(IComponentList list, String tagPath) {
// Grab components within the file
- if (metaName == IWSDLSearchConstants.BINDING_META_NAME) {
+ if (tagPath.equals("/definitions/binding")) {
// Grab explictly defined components
- createWSDLComponentObjects(list, definition.getEBindings(), metaName);
+ createWSDLComponentObjects(list, definition.getEBindings(), tagPath);
// Grab directly imported components
Iterator importsIt = getWSDLFileImports(definition.getEImports()).iterator();
@@ -185,12 +191,12 @@
Definition importDefinition = importItem.getEDefinition();
List importedComponents = importDefinition.getEBindings();
- createWSDLComponentObjects(list, importedComponents, metaName);
+ createWSDLComponentObjects(list, importedComponents, tagPath);
}
}
- else if (metaName == IWSDLSearchConstants.PORT_TYPE_META_NAME) {
+ else if (tagPath.equals("/definitions/portType")) {
// Grab explictly defined components
- createWSDLComponentObjects(list, definition.getEPortTypes(), metaName);
+ createWSDLComponentObjects(list, definition.getEPortTypes(), tagPath);
// Grab directly imported components
Iterator importsIt = getWSDLFileImports(definition.getEImports()).iterator();
@@ -199,12 +205,12 @@
Definition importDefinition = importItem.getEDefinition();
List importedComponents = importDefinition.getEPortTypes();
- createWSDLComponentObjects(list, importedComponents, metaName);
+ createWSDLComponentObjects(list, importedComponents, tagPath);
}
}
- else if (metaName == IWSDLSearchConstants.MESSAGE_META_NAME) {
+ else if (tagPath.equals("/definitions/message")) {
// Grab explictly defined components
- createWSDLComponentObjects(list, definition.getEMessages(), metaName);
+ createWSDLComponentObjects(list, definition.getEMessages(), tagPath);
// Grab directly imported components
Iterator importsIt = getWSDLFileImports(definition.getEImports()).iterator();
@@ -213,32 +219,31 @@
Definition importDefinition = importItem.getEDefinition();
List importedComponents = importDefinition.getEMessages();
- createWSDLComponentObjects(list, importedComponents, metaName);
+ createWSDLComponentObjects(list, importedComponents, tagPath);
}
}
- /*TODO... fix these cases
- else if (metaName == IXSDSearchConstants.COMPLEX_TYPE_META_NAME) {
- createXSDInlineTypesObjects(list, metaName);
+ else if (tagPath.equals("/definitions/types/schema/complexType")) {
+ createXSDInlineTypesObjects(list, tagPath);
}
- else if (metaName.equals("/definitions/types/schema/simpleType")) {
- createXSDInlineTypesObjects(list, metaName);
- }*/
- else if (metaName == IXSDSearchConstants.ELEMENT_META_NAME) {
- createXSDElementObjects(list, metaName);
+ else if (tagPath.equals("/definitions/types/schema/simpleType")) {
+ createXSDInlineTypesObjects(list, tagPath);
+ }
+ else if (tagPath.equals("/definitions/types/schema/element")) {
+ createXSDElementObjects(list, tagPath);
createRegularImportXSDElementObjects(list);
}
- else if (metaName == IXSDSearchConstants.COMPLEX_TYPE_META_NAME){
- createXSDInlineWrapperTypeObjects(list, metaName);
+ else if (tagPath.equals("/schema/complexType")) {
+ createXSDInlineWrapperTypeObjects(list, tagPath);
createXSDBuiltInTypeObjects(list);
createRegularImportXSDTypeObjects(list);
}
- else if (metaName == IXSDSearchConstants.SIMPLE_TYPE_META_NAME) {
- createXSDInlineWrapperTypeObjects(list, metaName);
+ else if (tagPath.equals("/schema/simpleType")) {
+ createXSDInlineWrapperTypeObjects(list, tagPath);
}
- //else if (metaName.equals("/schema/element")) {
- // createXSDInlineWrapperElementObjects(list, metaName);
- //}
+ else if (tagPath.equals("/schema/element")) {
+ createXSDInlineWrapperElementObjects(list, tagPath);
+ }
}
private List getWSDLFileImports(List wsdlImports) {
@@ -258,7 +263,7 @@
private void createXSDBuiltInTypeObjects(IComponentList list) {
for (int i = 0; i < XSDDOMHelper.dataType.length; i++) {
String builtIn = XSDDOMHelper.dataType[i][0];
- XMLComponentSpecification spec = new XMLComponentSpecification(null);//BUILT_IN_TYPE);
+ XMLComponentSpecification spec = new XMLComponentSpecification(BUILT_IN_TYPE);
spec.addAttributeInfo("name", builtIn);
spec.setTargetNamespace(XSDConstants.SCHEMA_FOR_SCHEMA_URI_2001);
@@ -316,8 +321,8 @@
}
}
- createXSDComponentObjects(list, complexList, IXSDSearchConstants.COMPLEX_TYPE_META_NAME);
- createXSDComponentObjects(list, simpleList, IXSDSearchConstants.SIMPLE_TYPE_META_NAME);
+ createXSDComponentObjects(list, complexList, complexPath);
+ createXSDComponentObjects(list, simpleList, simplePath);
}
}
}
@@ -354,13 +359,13 @@
Iterator schemaIt = schemas.iterator();
while (schemaIt.hasNext()) {
List elementList = ((XSDSchema) schemaIt.next()).getElementDeclarations();
- createXSDComponentObjects(list, elementList, IXSDSearchConstants.ELEMENT_META_NAME);
+ createXSDComponentObjects(list, elementList, path);
}
}
}
}
- private void createXSDInlineTypesObjects(IComponentList list, QualifiedName tagPath) {
+ private void createXSDInlineTypesObjects(IComponentList list, String tagPath) {
// Handle inline schemas
if (definition.getETypes() == null) {
return;
@@ -398,7 +403,7 @@
}
}
- private void createXSDElementObjects(IComponentList list, QualifiedName tagPath) {
+ private void createXSDElementObjects(IComponentList list, String tagPath) {
if (definition.getETypes() == null) {
return;
}
@@ -423,7 +428,7 @@
}
}
- private void createXSDInlineWrapperTypeObjects(IComponentList list, QualifiedName tagPath) {
+ private void createXSDInlineWrapperTypeObjects(IComponentList list, String tagPath) {
// Handle inline schemas
if (definition.getETypes() == null) {
return;
@@ -469,7 +474,7 @@
}
}
- private void createXSDInlineWrapperElementObjects(IComponentList list, QualifiedName tagPath) {
+ private void createXSDInlineWrapperElementObjects(IComponentList list, String tagPath) {
if (definition.getETypes() == null) {
return;
}
@@ -575,26 +580,26 @@
public Image getImage(Object element) {
XMLComponentTreeObject specification = (XMLComponentTreeObject) element;
XMLComponentSpecification spec = (XMLComponentSpecification) specification.getXMLComponentSpecification().get(0);
- if (spec.getMetaName() == IWSDLSearchConstants.BINDING_META_NAME) {
+ if (spec.getTagPath().equals("/definitions/binding")) {
return WSDLEditorPlugin.getInstance().getImage("icons/binding_obj.gif");
}
- else if (spec.getMetaName() == IWSDLSearchConstants.PORT_TYPE_META_NAME) {
- return WSDLEditorPlugin.getInstance().getImage("icons/portType_obj.gif");
+ else if (spec.getTagPath().equals("/definitions/portType")) {
+ return WSDLEditorPlugin.getInstance().getImage("icons/port_obj.gif");
}
- else if (spec.getMetaName() == IWSDLSearchConstants.MESSAGE_META_NAME) {
+ else if (spec.getTagPath().equals("/definitions/message")) {
return WSDLEditorPlugin.getInstance().getImage("icons/message_obj.gif");
}
- else if (spec.getMetaName() == IXSDSearchConstants.COMPLEX_TYPE_META_NAME){
- //|| spec.getMetaName() == ("/schema/complexType"))
+ else if (spec.getTagPath().equals("/definitions/types/schema/complexType") ||
+ spec.getTagPath().equals("/schema/complexType")) {
return XSDEditorPlugin.getXSDImage("icons/XSDComplexType.gif");
}
- else if (spec.getMetaName() == IXSDSearchConstants.SIMPLE_TYPE_META_NAME ||
- //spec.getMetaName() == ("/schema/simpleType") ||
- spec.getMetaName() == null /*BUILT_IN_TYPE*/){
+ else if (spec.getTagPath().equals("/definitions/types/schema/simpleType") ||
+ spec.getTagPath().equals("/schema/simpleType") ||
+ spec.getTagPath().equals("BUILT_IN_TYPE")) {
return XSDEditorPlugin.getXSDImage("icons/XSDSimpleType.gif");
}
- else if (spec.getMetaName() == IXSDSearchConstants.ELEMENT_META_NAME){
- // ||spec.getMetaName() == ("/schema/element"))
+ else if (spec.getTagPath().equals("/definitions/types/schema/element") ||
+ spec.getTagPath().equals("/schema/element")) {
return XSDEditorPlugin.getXSDImage("icons/XSDElement.gif");
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLSetComponentHelper.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLSetComponentHelper.java
index 0d1f2a9..f14c6b1 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLSetComponentHelper.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/dialogs/types/WSDLSetComponentHelper.java
@@ -56,7 +56,7 @@
}
public void setXSDTypeComponent(Part part, XMLComponentSpecification spec) {
- if (spec.getMetaName() != null) {
+ if (!spec.getTagPath().equals(WSDLComponentSelectionProvider.BUILT_IN_TYPE)) {
addImportIfNecessary(spec);
}
String componentObject = getPrefixedComponentName(spec);
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/NSKeyedExtensionRegistry.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/NSKeyedExtensionRegistry.java
index eff406f..03b7ea4 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/NSKeyedExtensionRegistry.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/NSKeyedExtensionRegistry.java
@@ -12,8 +12,6 @@
import java.util.HashMap;
-import org.osgi.framework.Bundle;
-
public class NSKeyedExtensionRegistry
{
protected HashMap map = new HashMap();
@@ -23,22 +21,22 @@
{
}
- public void put(String namespaceURI, String className, Bundle bundle)
+ public void put(String namespaceURI, String className, ClassLoader classLoader)
{
ExtensionInfo info = (ExtensionInfo) map.get(namespaceURI);
if (info == null)
{
- info = new SinglePropertyExtensionInfo(className, bundle);
+ info = new SinglePropertyExtensionInfo(className, classLoader);
map.put(namespaceURI, info);
}
}
- public void put(String namespaceURI, HashMap propertyToClassNameMap, Bundle bundle)
+ public void put(String namespaceURI, HashMap propertyToClassNameMap, ClassLoader classLoader)
{
ExtensionInfo info = (ExtensionInfo) map.get(namespaceURI);
if (info == null)
{
- info = new MultiPropertyExtensionInfo(propertyToClassNameMap, bundle);
+ info = new MultiPropertyExtensionInfo(propertyToClassNameMap, classLoader);
map.put(namespaceURI, info);
}
}
@@ -61,11 +59,11 @@
private abstract class ExtensionInfo
{
- protected Bundle bundle;
+ protected ClassLoader classLoader;
- public ExtensionInfo(Bundle bundle)
+ public ExtensionInfo(ClassLoader classLoader)
{
- this.bundle = bundle;
+ this.classLoader = classLoader;
}
public abstract Object getObject(String property);
@@ -77,9 +75,9 @@
protected Object object;
protected boolean error;
- public SinglePropertyExtensionInfo(String className, Bundle bundle)
+ public SinglePropertyExtensionInfo(String className, ClassLoader classLoader)
{
- super(bundle);
+ super(classLoader);
this.className = className;
}
@@ -89,7 +87,7 @@
{
try
{
- Class theClass = bundle.loadClass(className);
+ Class theClass = classLoader != null ? classLoader.loadClass(className) : Class.forName(className);
object = theClass.newInstance();
}
catch (Exception e)
@@ -107,9 +105,9 @@
protected HashMap propertyToClassNameTable;
protected HashMap propertyToObjectTable = new HashMap();
- public MultiPropertyExtensionInfo(HashMap propertToClassNameTable, Bundle bundle)
+ public MultiPropertyExtensionInfo(HashMap propertToClassNameTable, ClassLoader classLoader)
{
- super(bundle);
+ super(classLoader);
this.propertyToClassNameTable = propertToClassNameTable;
}
@@ -124,7 +122,7 @@
{
try
{
- Class theClass = bundle.loadClass(className);
+ Class theClass = classLoader != null ? classLoader.loadClass(className) : Class.forName(className);
result = theClass.newInstance();
propertyToObjectTable.put(property, result);
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/WSDLEditorExtensionRegistry.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/WSDLEditorExtensionRegistry.java
index 47ee082..f8e2435 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/WSDLEditorExtensionRegistry.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/extension/WSDLEditorExtensionRegistry.java
@@ -15,7 +15,6 @@
import java.util.List;
import org.eclipse.wst.wsdl.ui.internal.WSDLEditor;
-import org.osgi.framework.Bundle;
public class WSDLEditorExtensionRegistry
{
@@ -105,19 +104,4 @@
e.printStackTrace();
}
}
- public void add(Bundle bundle, String className)
- {
- // TODO... consider defered instantiation of WSDLEditorExtensions
- try
- {
-
- Class theClass = bundle.loadClass(className);
- WSDLEditorExtension extension = (WSDLEditorExtension)theClass.newInstance();
- registeredExtensionList.add(extension);
- }
- catch (Exception e)
- {
- e.printStackTrace();
- }
- }
}
\ No newline at end of file
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/OpenOnSelectionHelper.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/OpenOnSelectionHelper.java
index 63ed5d9..bfa7fd1 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/OpenOnSelectionHelper.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/OpenOnSelectionHelper.java
@@ -202,12 +202,12 @@
}
else if (isMatchingAttribute(WSDLConstants.ELEMENT_ATTRIBUTE))
{
- result = part.getElementDeclaration();
+ result = part.getElement();
}
}
else if (part.getEnclosingDefinition() == definition)
{
- result = part.getTypeDefinition() != null ? (Object)part.getTypeDefinition() : (Object)part.getElementDeclaration();
+ result = part.getTypeDefinition() != null ? (Object)part.getTypeDefinition() : (Object)part.getElement();
}
return result;
}
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/WSDLPreferencePage.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/WSDLPreferencePage.java
index a51b5e8..779b282 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/WSDLPreferencePage.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/util/WSDLPreferencePage.java
@@ -75,7 +75,7 @@
BooleanFieldEditor generateBindingOnSave = new BooleanFieldEditor(generateLabel, generateLabel, parent);
addField(generateBindingOnSave);
- String showGenerateDialogLabel = "Prompt Regenerate Binding on save"; // TODO: Externalize
+ String showGenerateDialogLabel = WSDLEditorPlugin.getWSDLString("_UI_PREF_PAGE_PROMPT_REGEN_BINDING_ON_SAVE");
BooleanFieldEditor showGenerateDialog = new BooleanFieldEditor(showGenerateDialogLabel, showGenerateDialogLabel, parent);
addField(showGenerateDialog);
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/viewers/widgets/AttributesTable.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/viewers/widgets/AttributesTable.java
index d57b181..26b04cc 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/viewers/widgets/AttributesTable.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/viewers/widgets/AttributesTable.java
@@ -10,7 +10,7 @@
*******************************************************************************/
package org.eclipse.wst.wsdl.ui.internal.viewers.widgets;
-import com.ibm.icu.text.Collator;
+import java.text.Collator;
import java.util.Arrays;
import java.util.Comparator;
import java.util.List;
diff --git a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/wizards/NewWSDLWizard.java b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/wizards/NewWSDLWizard.java
index 0a28db1..8c73cbe 100644
--- a/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/wizards/NewWSDLWizard.java
+++ b/bundles/org.eclipse.wst.wsdl.ui/src/org/eclipse/wst/wsdl/ui/internal/wizards/NewWSDLWizard.java
@@ -18,7 +18,6 @@
import javax.xml.namespace.QName;
import org.eclipse.core.resources.IFile;
-import org.eclipse.core.runtime.CoreException;
import org.eclipse.core.runtime.IPath;
import org.eclipse.core.runtime.Path;
import org.eclipse.core.runtime.Preferences;
@@ -29,12 +28,10 @@
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.jface.wizard.Wizard;
import org.eclipse.swt.widgets.Display;
-import org.eclipse.ui.IEditorDescriptor;
import org.eclipse.ui.INewWizard;
import org.eclipse.ui.IWorkbench;
import org.eclipse.ui.IWorkbenchWindow;
import org.eclipse.ui.PartInitException;
-import org.eclipse.ui.PlatformUI;
import org.eclipse.ui.part.FileEditorInput;
import org.eclipse.wst.common.ui.internal.UIPlugin;
import org.eclipse.wst.sse.core.internal.encoding.CommonEncodingPreferenceNames;
@@ -253,20 +250,13 @@
Display.getDefault().asyncExec(new Runnable() {
public void run() {
try {
- String editorId = null;
- IEditorDescriptor editor = PlatformUI.getWorkbench().getEditorRegistry().getDefaultEditor(iFile.getLocation().toOSString(), iFile.getContentDescription().getContentType());
- if (editor != null) {
- editorId = editor.getId();
- }
- workbenchWindow.getActivePage().openEditor(new FileEditorInput(iFile), editorId);
+ workbenchWindow.getActivePage().openEditor(new FileEditorInput(iFile), "org.eclipse.wst.wsdl.ui.internal.WSDLEditor");
}
catch (PartInitException ex) {
// B2BGUIPlugin.getPlugin().getMsgLogger().write("Exception
// encountered when attempting to open file: " + iFile
// + "\n\n" + ex);
}
- catch (CoreException ex) {
- }
}
});
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.wsdl.validation/META-INF/MANIFEST.MF
index 44ba916..ff54804 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.wsdl.validation/META-INF/MANIFEST.MF
@@ -2,11 +2,12 @@
Bundle-ManifestVersion: 2
Bundle-Name: %_PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.wsdl.validation; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.1.qualifier
Bundle-Activator: org.eclipse.wst.wsdl.validation.internal.eclipse.ValidateWSDLPlugin
Bundle-Vendor: %_PROVIDER_NAME
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.wsdl.validation.internal,
+Export-Package: .,
+ org.eclipse.wst.wsdl.validation.internal,
org.eclipse.wst.wsdl.validation.internal.eclipse,
org.eclipse.wst.wsdl.validation.internal.exception,
org.eclipse.wst.wsdl.validation.internal.resolver,
@@ -27,4 +28,4 @@
org.wsdl4j,
org.apache.xerces;visibility:=reexport,
org.eclipse.core.runtime
-Eclipse-LazyStart: true
+Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.wst.wsdl.validation/exsd/extvalidator.exsd b/bundles/org.eclipse.wst.wsdl.validation/exsd/extvalidator.exsd
index d7ca02a..13ab558 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/exsd/extvalidator.exsd
+++ b/bundles/org.eclipse.wst.wsdl.validation/exsd/extvalidator.exsd
@@ -55,6 +55,13 @@
</documentation>
</annotation>
</attribute>
+ <attribute name="resourcebundle" type="string">
+ <annotation>
+ <documentation>
+ An optional resource bundle that contains messages to be used by the extension validator.
+ </documentation>
+ </annotation>
+ </attribute>
</complexType>
</element>
@@ -80,7 +87,8 @@
point="org.eclipse.wst.wsdl.validation.extvalidator">
<extvalidator
namespace="http://schemas.xmlsoap.org/wsdl/"
- class="org.eclipse.wst.wsi.internal.validate.wsdl.WSDLValidator">
+ class="org.eclipse.wst.wsi.internal.validate.wsdl.WSDLValidator"
+ resourcebundle="wsivalidate">
</extvalidator>
</extension>
</pre>
@@ -113,7 +121,7 @@
<meta.section type="copyright"/>
</appInfo>
<documentation>
- Copyright (c) 2000, 2006 IBM Corporation and others.<br>
+ Copyright (c) 2000, 2005 IBM Corporation and others.<br>
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 <a
diff --git a/bundles/org.eclipse.wst.wsdl.validation/exsd/wsdl11validator.exsd b/bundles/org.eclipse.wst.wsdl.validation/exsd/wsdl11validator.exsd
index e852048..14ed921 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/exsd/wsdl11validator.exsd
+++ b/bundles/org.eclipse.wst.wsdl.validation/exsd/wsdl11validator.exsd
@@ -55,6 +55,13 @@
</documentation>
</annotation>
</attribute>
+ <attribute name="resourcebundle" type="string">
+ <annotation>
+ <documentation>
+ An optional resource bundle that contains messages to be used by the extension validator.
+ </documentation>
+ </annotation>
+ </attribute>
</complexType>
</element>
@@ -78,7 +85,8 @@
point="org.eclipse.wst.wsdl.validation.wsdl11validator">
<validator
class="org.eclipse.wst.wsdl.validation.internal.wsdl11.http.HTTPValidator"
- namespace="http://schemas.xmlsoap.org/wsdl/http/"/>
+ namespace="http://schemas.xmlsoap.org/wsdl/http/"
+ resourcebundle="validatewsdlhttp"/>
</extension>
</pre>
</documentation>
@@ -118,7 +126,7 @@
<meta.section type="copyright"/>
</appInfo>
<documentation>
- Copyright (c) 2000, 2006 IBM Corporation and others.<br>
+ Copyright (c) 2000, 2005 IBM Corporation and others.<br>
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 <a
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ClassloaderWSDLValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ClassloaderWSDLValidatorDelegate.java
deleted file mode 100644
index 3d0fe50..0000000
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ClassloaderWSDLValidatorDelegate.java
+++ /dev/null
@@ -1,84 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2006 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.wsdl.validation.internal;
-
-
-
-/**
- * A delegate holds a validator's information and can instantiate it
- * when requested to.
- */
-public class ClassloaderWSDLValidatorDelegate extends WSDLValidatorDelegate
-{
- private String validatorClassname = null;
- private ClassLoader classLoader = null;
-
- /**
- * Create a delegate for a validator by its class name.
- *
- * @param validatorClassname The name of the validator class.
- */
- public ClassloaderWSDLValidatorDelegate(String validatorClassname)
- {
- this.validatorClassname = validatorClassname;
- }
-
- /**
- * Create a delegate for a validator by its class name and
- * a class loader to load the validator.
- *
- * @param validatorClassname The name of the validator class.
- * @param classLoader The class loader to use to load the validator.
- */
- public ClassloaderWSDLValidatorDelegate(String validatorClassname, ClassLoader classLoader)
- {
- this(validatorClassname);
- this.classLoader = classLoader;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate#loadValidator()
- */
- protected IWSDLValidator loadValidator()
- {
- IWSDLValidator validator = null;
- if(classLoader == null)
- {
- classLoader = getClass().getClassLoader();
- }
- try
- {
- Class validatorClass =
- classLoader != null ? classLoader.loadClass(validatorClassname) : Class.forName(validatorClassname);
-
- validator = (IWSDLValidator)validatorClass.newInstance();
- }
- catch (Exception e)
- {
- // TODO: add logging
- System.err.println(e);
- }
- catch(Throwable t)
- {
- System.err.println(t);
- }
- return validator;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate#getValidatorName()
- */
- public String getValidatorName()
- {
- return validatorClassname;
- }
-}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/IWSDLValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/IWSDLValidator.java
index cac0de3..3278e9d 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/IWSDLValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/IWSDLValidator.java
@@ -11,6 +11,8 @@
package org.eclipse.wst.wsdl.validation.internal;
+import java.util.ResourceBundle;
+
import org.eclipse.wst.wsdl.validation.internal.exception.ValidateWSDLException;
import org.w3c.dom.Document;
@@ -28,4 +30,14 @@
* @throws ValidateWSDLException
*/
public void validate(Document domModel, IValidationInfo valInfo) throws ValidateWSDLException;
+
+ /**
+ * setResourceBundle
+ * Set the ResourceBundle for this validator. Allows the use of difference
+ * ResourceBundles for different validators.
+ *
+ * @param rb The resource bundle to set.
+ */
+ public void setResourceBundle(ResourceBundle rb);
+
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ValidationController.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ValidationController.java
index 1c7250e..13113bd 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ValidationController.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ValidationController.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -273,7 +273,7 @@
}
catch(Throwable t)
{
- valInfo.addWarning(messagegenerator.getString(_ERROR_PROBLEM_EXT_VALIDATOR, extvaldel.getValidatorName(), wsdlNamespace), 1, 1, valInfo.getFileURI());
+ valInfo.addWarning(messagegenerator.getString(_ERROR_PROBLEM_EXT_VALIDATOR, extvaldel.getValidatorClassName(), wsdlNamespace), 1, 1, valInfo.getFileURI());
// This error should be logged and not displayed to the user.
}
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidator.java
index dfb3521..c42e008 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -17,7 +17,6 @@
import org.eclipse.wst.wsdl.validation.internal.resolver.IExtensibleURIResolver;
import org.eclipse.wst.wsdl.validation.internal.resolver.URIResolver;
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.ClassloaderWSDL11ValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11BasicValidator;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorController;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate;
@@ -33,6 +32,9 @@
public class WSDLValidator
{
private static String VALIDATOR_RESOURCE_BUNDLE = "validatewsdl";
+ private static String VALIDATOR_HTTP_RESOURCE_BUNDLE = "validatewsdlhttp";
+ private static String VALIDATOR_SOAP_RESOURCE_BUNDLE = "validatewsdlsoap";
+ private static String VALIDATOR_MIME_RESOURCE_BUNDLE = "validatewsdlmime";
private ValidationController validationController;
private URIResolver uriResolver;
private Hashtable attributes = new Hashtable();
@@ -49,15 +51,15 @@
//Register the default validators.
ValidatorRegistry registry = ValidatorRegistry.getInstance();
// Register the WSDL 1.1 validator controller and validators.
- WSDLValidatorDelegate delegate = new ClassloaderWSDLValidatorDelegate(WSDL11ValidatorController.class.getName(), getClass().getClassLoader());
+ WSDLValidatorDelegate delegate = new WSDLValidatorDelegate(WSDL11ValidatorController.class.getName(), VALIDATOR_RESOURCE_BUNDLE, getClass().getClassLoader());
registry.registerValidator(Constants.NS_URI_WSDL, delegate, ValidatorRegistry.WSDL_VALIDATOR);
- WSDL11ValidatorDelegate delegate1 = new ClassloaderWSDL11ValidatorDelegate(WSDL11BasicValidator.class.getName(), getClass().getClassLoader());
+ WSDL11ValidatorDelegate delegate1 = new WSDL11ValidatorDelegate(WSDL11BasicValidator.class.getName(), VALIDATOR_RESOURCE_BUNDLE, getClass().getClassLoader());
registerWSDL11Validator(Constants.NS_URI_WSDL, delegate1);
- delegate1 = new ClassloaderWSDL11ValidatorDelegate(HTTPValidator.class.getName(), getClass().getClassLoader());
+ delegate1 = new WSDL11ValidatorDelegate(HTTPValidator.class.getName(), VALIDATOR_HTTP_RESOURCE_BUNDLE, getClass().getClassLoader());
registerWSDL11Validator(org.eclipse.wst.wsdl.validation.internal.Constants.NS_HTTP, delegate1);
- delegate1 = new ClassloaderWSDL11ValidatorDelegate(SOAPValidator.class.getName(), getClass().getClassLoader());
+ delegate1 = new WSDL11ValidatorDelegate(SOAPValidator.class.getName(), VALIDATOR_SOAP_RESOURCE_BUNDLE, getClass().getClassLoader());
registerWSDL11Validator(org.eclipse.wst.wsdl.validation.internal.Constants.NS_SOAP11, delegate1);
- delegate1 = new ClassloaderWSDL11ValidatorDelegate(MIMEValidator.class.getName(), getClass().getClassLoader());
+ delegate1 = new WSDL11ValidatorDelegate(MIMEValidator.class.getName(), VALIDATOR_MIME_RESOURCE_BUNDLE, getClass().getClassLoader());
registerWSDL11Validator(org.eclipse.wst.wsdl.validation.internal.Constants.NS_MIME, delegate1);
// The WSDL 1.1 schema validator is a special case as it is registered for three namespaces.
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidatorDelegate.java
index 82ae025..ab4075f 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidatorDelegate.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/WSDLValidatorDelegate.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -11,14 +11,47 @@
package org.eclipse.wst.wsdl.validation.internal;
+import java.util.Locale;
+import java.util.ResourceBundle;
+
+
/**
- * A WSDLValidatorDelegate holds a reference to a WSDL validator.
- * A delegate is used to lazy load extension validators.
+ * A delegate holds a validator's information and can instantiate it
+ * when requested to.
*/
-public abstract class WSDLValidatorDelegate
+public class WSDLValidatorDelegate
{
+ private String validatorClassname = null;
+ private String resourceBundle = null;
+ private ClassLoader classLoader = null;
private IWSDLValidator validator = null;
-
+
+ /**
+ * Create a delegate for a validator by its class name and resource bundle name.
+ *
+ * @param validatorClassname The name of the validator class.
+ * @param resourceBundle The name of the validator base resource bundle.
+ */
+ public WSDLValidatorDelegate(String validatorClassname, String resourceBundle)
+ {
+ this.validatorClassname = validatorClassname;
+ this.resourceBundle = resourceBundle;
+ }
+
+ /**
+ * Create a delegate for a validator by its class name, resource bundle name and
+ * a class loader to load the validator and bundle.
+ *
+ * @param validatorClassname The name of the validator class.
+ * @param resourceBundle The name of the validator base resource bundle.
+ * @param classLoader The class loader to use to load the validator and bundle.
+ */
+ public WSDLValidatorDelegate(String validatorClassname, String resourceBundle, ClassLoader classLoader)
+ {
+ this(validatorClassname, resourceBundle);
+ this.classLoader = classLoader;
+ }
+
/**
* Get the validator specified in this delegate.
*
@@ -27,23 +60,43 @@
public IWSDLValidator getValidator()
{
if (validator == null)
- {
- validator = loadValidator();
+ {
+ if(classLoader == null)
+ {
+ classLoader = getClass().getClassLoader();
+ }
+ try
+ {
+ Class validatorClass =
+ classLoader != null ? classLoader.loadClass(validatorClassname) : Class.forName(validatorClassname);
+
+ validator = (IWSDLValidator)validatorClass.newInstance();
+
+ if (resourceBundle != null)
+ {
+ ResourceBundle validatorBundle = ResourceBundle.getBundle(resourceBundle, Locale.getDefault(), classLoader);
+ validator.setResourceBundle(validatorBundle);
+ }
+ }
+ catch (Exception e)
+ {
+ // TODO: add logging
+ System.err.println(e);
+ }
+ catch(Throwable t)
+ {
+ System.err.println(t);
+ }
}
return validator;
}
/**
- * Load the validator specified in this delegate.
- *
- * @return The WSDL validator specified by this delegate.
+ * Return the validator class name.
+ * @return The validator class name.
*/
- protected abstract IWSDLValidator loadValidator();
-
- /**
- * Return the name of the validator.
- *
- * @return The validator name.
- */
- public abstract String getValidatorName();
+ public String getValidatorClassName()
+ {
+ return validatorClassname;
+ }
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDL11ValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDL11ValidatorDelegate.java
deleted file mode 100644
index 7e7ccc9..0000000
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDL11ValidatorDelegate.java
+++ /dev/null
@@ -1,59 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2006 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.wsdl.validation.internal.eclipse;
-
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator;
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate;
-import org.osgi.framework.Bundle;
-
-public class EclipseWSDL11ValidatorDelegate extends WSDL11ValidatorDelegate
-{
- private String validatorClassname = null;
- private Bundle bundle = null;
-
- /**
- * Create a delegate for a validator by its class name and
- * a class loader to load the validator.
- *
- * @param validatorClassname The name of the validator class.
- * @param bundle The bundle to use to load the validator.
- */
- public EclipseWSDL11ValidatorDelegate(String validatorClassname, Bundle bundle)
- {
- this.validatorClassname = validatorClassname;
- this.bundle = bundle;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate#loadValidator()
- */
- protected IWSDL11Validator loadValidator()
- {
- IWSDL11Validator validator = null;
- if(bundle != null)
- {
- try
- {
- Class validatorClass = bundle.loadClass(validatorClassname);
-
- validator = (IWSDL11Validator)validatorClass.newInstance();
-
- }
- catch (Throwable t)
- {
- // TODO: add logging
- System.err.println(t);
- }
- }
- return validator;
- }
-}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDLValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDLValidatorDelegate.java
deleted file mode 100644
index 109d366..0000000
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/EclipseWSDLValidatorDelegate.java
+++ /dev/null
@@ -1,71 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2006 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.wsdl.validation.internal.eclipse;
-
-import org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate;
-import org.eclipse.wst.wsdl.validation.internal.IWSDLValidator;
-import org.osgi.framework.Bundle;
-
-
-/**
- * A delegate holds a validator's information and can instantiate it
- * when requested to.
- */
-public class EclipseWSDLValidatorDelegate extends WSDLValidatorDelegate
-{
- private String validatorClassname = null;
- private Bundle bundle = null;
-
- /**
- * Create a delegate for a validator by its class name and
- * an OSGI bundle to load the validator.
- *
- * @param validatorClassname The name of the validator class.
- * @param bundle The OSGI bundle to use to load the validator.
- */
- public EclipseWSDLValidatorDelegate(String validatorClassname, Bundle bundle)
- {
- this.validatorClassname = validatorClassname;
- this.bundle = bundle;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.AbstractWSDLValidatorDelegate#loadValidator()
- */
- protected IWSDLValidator loadValidator()
- {
- IWSDLValidator validator = null;
- if(bundle != null)
- {
- try
- {
- Class validatorClass = bundle.loadClass(validatorClassname);
-
- validator = (IWSDLValidator)validatorClass.newInstance();
- }
- catch(Throwable t)
- {
- // TODO: add logging
- System.err.println(t);
- }
- }
- return validator;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.AbstractWSDLValidatorDelegate#getValidatorName()
- */
- public String getValidatorName()
- {
- return validatorClassname;
- }
-}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/ValidateWSDLPlugin.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/ValidateWSDLPlugin.java
index 7486b14..c170ad1 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/ValidateWSDLPlugin.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/eclipse/ValidateWSDLPlugin.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -14,16 +14,15 @@
import java.io.IOException;
import java.util.ResourceBundle;
-import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionPoint;
import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.Platform;
import org.eclipse.core.runtime.Plugin;
import org.eclipse.wst.wsdl.validation.internal.Constants;
+import org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.xml.XMLCatalog;
-import org.osgi.framework.Bundle;
import org.osgi.framework.BundleContext;
/**
@@ -91,7 +90,7 @@
{
try
{
- return FileLocator.resolve(getBundle().getEntry("/")).getFile();
+ return Platform.resolve(getBundle().getEntry("/")).getFile();
}
catch (IOException e)
{
@@ -143,6 +142,7 @@
protected static final String PLUGIN_ID = "org.eclipse.wst.wsdl.validation";
protected static final String ATT_CLASS = "class";
protected static final String ATT_NAMESPACE = "namespace";
+ protected static final String ATT_RESOURCEBUNDLE = "resourcebundle";
protected static final int WSDL_VALIDATOR = 0;
protected static final int EXT_VALIDATOR = 1;
protected String extensionPointId;
@@ -194,6 +194,7 @@
{
String validatorClass = element.getAttribute(ATT_CLASS);
String namespace = element.getAttribute(ATT_NAMESPACE);
+ String resourceBundle = element.getAttribute(ATT_RESOURCEBUNDLE);
if (validatorClass != null)
{
@@ -203,13 +204,23 @@
// element.getDeclaringExtension().getDeclaringPluginDescriptor().getPlugin().getClass().getClassLoader();
// modified to resolve certain situations where the plugin has not been initialized
- Bundle pluginBundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
+ ClassLoader pluginLoader =
+ element.getDeclaringExtension().getDeclaringPluginDescriptor().getPluginClassLoader();
+// if (validatorType == WSDL_VALIDATOR)
+// {
+// WSDL11ValidatorDelegate delegate = new WSDL11ValidatorDelegate(validatorClass, resourceBundle, pluginLoader);
+// WSDLValidator.getInstance().registerWSDL11Validator(namespace, delegate);
+// }
if (validatorType == EXT_VALIDATOR)
{
- EclipseWSDLValidatorDelegate delegate = new EclipseWSDLValidatorDelegate(validatorClass, pluginBundle);
+ WSDLValidatorDelegate delegate = new WSDLValidatorDelegate(validatorClass, resourceBundle, pluginLoader);
WSDLValidator.getInstance().registerWSDLExtensionValidator(namespace, delegate);
}
+// registerWSDLValidatorPluginExtensionWithClassName(
+// pluginLoader,
+// WSDLValidatorExtensionClass,
+// WSDLValidatorExtensionNamespace);
}
catch (Exception e)
{
@@ -217,6 +228,54 @@
}
}
}
+
+ /**
+ * Register the extension validator with the given class name and namespaces.
+ *
+ * @param classLoader - the class loader to create the validator
+ * @param className - the name of the extension validator
+ * @param namespace - the namespace of the extension validator
+ * @throws Exception
+ */
+// protected void registerWSDLValidatorPluginExtensionWithClassName(
+// ClassLoader classLoader,
+// String className,
+// String namespace)
+// throws Exception
+// {
+// try
+// {
+// Class validatorExtensionClass = classLoader != null ? classLoader.loadClass(className) : Class.forName(className);
+//
+//
+// //IValidatorExtensionPlugin validatorHandler = (IValidatorExtensionPlugin)validatorExtensionClass.newInstance();
+// //add(namespace, validatorHandler.getValidator());
+// }
+// catch (Exception e)
+// {
+// //System.out.println(e.getMessage());
+// //TODO: write the error message to the log file - use custom log writer class
+// //ValidateWSDLPlugin.getInstance().getMsgLogger().write("WSDL Validator could not register the extension validator." + e.getMessage());
+// }
+// }
+
+ /**
+ * Register the loaded validator.
+ *
+ * @param namespace - the namespace of the validator
+ * @param validatorExtension - the extension validator
+ */
+// protected void add(String namespace, IWSDLValidator validatorExtension)
+// {
+// if (validatorType == WSDL_VALIDATOR)
+// {
+// WSDLConfigurator.registerWSDLValidator(namespace, validatorExtension);
+// }
+// else if (validatorType == WSI_VALIDATOR)
+// {
+// WSDLConfigurator.registerWSIValidator(namespace, validatorExtension);
+// }
+// }
}
/**
@@ -238,6 +297,7 @@
protected static final String PLUGIN_ID = "org.eclipse.wst.wsdl.validation";
protected static final String ATT_CLASS = "class";
protected static final String ATT_NAMESPACE = "namespace";
+ protected static final String ATT_RESOURCEBUNDLE = "resourcebundle";
protected String extensionPointId;
protected String tagName;
@@ -282,13 +342,15 @@
{
String validatorClass = element.getAttribute(ATT_CLASS);
String namespace = element.getAttribute(ATT_NAMESPACE);
+ String resourceBundle = element.getAttribute(ATT_RESOURCEBUNDLE);
if (validatorClass != null && namespace != null)
{
try
{
- Bundle pluginBundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
- WSDL11ValidatorDelegate delegate = new EclipseWSDL11ValidatorDelegate(validatorClass, pluginBundle);
+ ClassLoader pluginLoader =
+ element.getDeclaringExtension().getDeclaringPluginDescriptor().getPluginClassLoader();
+ WSDL11ValidatorDelegate delegate = new WSDL11ValidatorDelegate(validatorClass, resourceBundle, pluginLoader);
WSDLValidator.getInstance().registerWSDL11Validator(namespace, delegate);
}
catch (Exception e)
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/ExtensionValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/ExtensionValidator.java
index 3f49448..6b9aa20 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/ExtensionValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/ExtensionValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -18,6 +18,7 @@
{
private String classname = null;
private String namespace = null;
+ private String resourcebundle = null;
public void setClass(String classname)
{
@@ -38,4 +39,14 @@
{
return this.namespace;
}
+
+ public void setResourceBundle(String resourcebundle)
+ {
+ this.resourcebundle = resourcebundle;
+ }
+
+ public String getResourceBundle()
+ {
+ return this.resourcebundle;
+ }
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/WSDLValidate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/WSDLValidate.java
index 4450a90..5ad53d9 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/WSDLValidate.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/ant/WSDLValidate.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -12,6 +12,7 @@
package org.eclipse.wst.wsdl.validation.internal.ui.ant;
import java.io.File;
+
import java.net.URL;
import java.util.ArrayList;
import java.util.Iterator;
@@ -26,13 +27,12 @@
import org.apache.tools.ant.types.FileSet;
import org.apache.tools.ant.types.Path;
import org.apache.tools.ant.types.XMLCatalog;
-import org.eclipse.wst.wsdl.validation.internal.ClassloaderWSDLValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.IValidationMessage;
import org.eclipse.wst.wsdl.validation.internal.IValidationReport;
import org.eclipse.wst.wsdl.validation.internal.WSDLValidator;
+import org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.resolver.URIResolverDelegate;
import org.eclipse.wst.wsdl.validation.internal.util.MessageGenerator;
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.ClassloaderWSDL11ValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate;
/**
@@ -293,7 +293,7 @@
while(wsdl11extIter.hasNext())
{
ExtensionValidator extVal = (ExtensionValidator)wsdl11extIter.next();
- WSDL11ValidatorDelegate delegate = new ClassloaderWSDL11ValidatorDelegate(extVal.getClassName());
+ WSDL11ValidatorDelegate delegate = new WSDL11ValidatorDelegate(extVal.getClassName(), extVal.getResourceBundle());
wsdlValidator.registerWSDL11Validator(extVal.getNamespace(), delegate);
}
@@ -302,7 +302,7 @@
while(extIter.hasNext())
{
ExtensionValidator extVal = (ExtensionValidator)extIter.next();
- ClassloaderWSDLValidatorDelegate delegate = new ClassloaderWSDLValidatorDelegate(extVal.getClassName());
+ WSDLValidatorDelegate delegate = new WSDLValidatorDelegate(extVal.getClassName(), extVal.getResourceBundle());
wsdlValidator.registerWSDLExtensionValidator(extVal.getNamespace(), delegate);
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/text/WSDLValidate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/text/WSDLValidate.java
index e706799..5daa05e 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/text/WSDLValidate.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/ui/text/WSDLValidate.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -19,14 +19,13 @@
import java.util.ResourceBundle;
import java.util.Vector;
-import org.eclipse.wst.wsdl.validation.internal.ClassloaderWSDLValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.IValidationMessage;
import org.eclipse.wst.wsdl.validation.internal.IValidationReport;
import org.eclipse.wst.wsdl.validation.internal.WSDLValidator;
+import org.eclipse.wst.wsdl.validation.internal.WSDLValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.resolver.IExtensibleURIResolver;
import org.eclipse.wst.wsdl.validation.internal.resolver.URIResolverDelegate;
import org.eclipse.wst.wsdl.validation.internal.util.MessageGenerator;
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.ClassloaderWSDL11ValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate;
import org.eclipse.wst.wsdl.validation.internal.xml.XMLCatalog;
import org.eclipse.wst.wsdl.validation.internal.xml.XMLCatalogEntityHolder;
@@ -211,14 +210,20 @@
if (!namespace.startsWith(WSDLValidate.STRING_DASH))
{
+ String propertiesFile = args[++i];
+ if (propertiesFile.startsWith(WSDLValidate.STRING_DASH))
+ {
+ propertiesFile = null;
+ i--;
+ }
if(param.equalsIgnoreCase(WSDLValidate.PARAM_WSDL11VAL))
{
- WSDL11ValidatorDelegate delegate = new ClassloaderWSDL11ValidatorDelegate(validatorClass);
+ WSDL11ValidatorDelegate delegate = new WSDL11ValidatorDelegate(validatorClass, propertiesFile);
wsdlValidator.wsdlValidator.registerWSDL11Validator(namespace, delegate);
}
else if(param.equalsIgnoreCase(WSDLValidate.PARAM_EXTVAL))
{
- ClassloaderWSDLValidatorDelegate delegate = new ClassloaderWSDLValidatorDelegate(validatorClass);
+ WSDLValidatorDelegate delegate = new WSDLValidatorDelegate(validatorClass, propertiesFile);
wsdlValidator.wsdlValidator.registerWSDLExtensionValidator(namespace, delegate);
}
}
@@ -299,4 +304,73 @@
}
}
}
+
+ /**
+ * Load a validator into the wsdl validation framework registry.
+ *
+ * @param namespace - the namespace the validator checks
+ * @param validatorClass - the name of the class the implements IWSDLValidator
+ * @param propertiesFile - the name of the properties file for the validator
+ * @param type - the type of validator - WSDL or WS-I
+ * @param messGen - a MessageGenerator for producing error messages
+ */
+// protected static void loadExtensionValidator(
+// String namespace,
+// String validatorClass,
+// String propertiesFile,
+// Integer type,
+// MessageGenerator messGen)
+// {
+// try
+// {
+// ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
+// IWSDLValidator validator = (IWSDLValidator)classLoader.loadClass(validatorClass).newInstance();
+// // if no properties file is specified we can still load the validator
+// if (propertiesFile != null && !propertiesFile.equals(""))
+// {
+// ResourceBundle rb = ResourceBundle.getBundle(propertiesFile);
+// validator.setResourceBundle(rb);
+// }
+// else
+// {
+// propertiesFile = null;
+// }
+//
+// ValidatorRegistry.getInstance().registerValidator(namespace, validator, type);
+// }
+// catch (Exception e)
+// {
+// System.out.println(messGen.getString(_ERROR_UNABLE_TO_LOAD_EXT_VALIDATOR, namespace, e));
+// }
+//
+// }
+ // /**
+ // * loadWSDL11ExtensionValidator
+ // * Load an extension validator into the WSDL 1.1 validator
+ // * @param namespace
+ // * @param validatorClass
+ // * @param propertiesFile
+ // * @param type
+ // * @param classLoader
+ // */
+ // protected static void loadWSDL11ExtensionValidator(
+ // String namespace,
+ // String validatorClass,
+ // String resourceBundle,
+ // ClassLoader classLoader)
+ // {
+ // try
+ // {
+ // Class valclass = classLoader.loadClass(validatorClass);
+ // IWSDL11Validator validator = (IWSDL11Validator)valclass.newInstance();
+ // validator.setResourceBundle(ResourceBundle.getBundle(resourceBundle));
+ // WSDLConfigurator.registerWSDL11Validator(namespace,validator);
+ // }
+ // catch(Exception e)
+ // {
+ // System.out.println("Unable to load the WSDL 1.1 validator for namespace "
+ // + namespace + e);
+ // }
+ //
+ // }
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/ClassloaderWSDL11ValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/ClassloaderWSDL11ValidatorDelegate.java
deleted file mode 100644
index 955f352..0000000
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/ClassloaderWSDL11ValidatorDelegate.java
+++ /dev/null
@@ -1,66 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2001, 2006 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.wsdl.validation.internal.wsdl11;
-
-public class ClassloaderWSDL11ValidatorDelegate extends WSDL11ValidatorDelegate
-{
- private String validatorClassname = null;
- private ClassLoader classLoader = null;
-
- /**
- * Create a delegate for a validator by its class name.
- *
- * @param validatorClassname The name of the validator class.
- */
- public ClassloaderWSDL11ValidatorDelegate(String validatorClassname)
- {
- this.validatorClassname = validatorClassname;
- }
-
- /**
- * Create a delegate for a validator by its class name and
- * a class loader to load the validator.
- *
- * @param validatorClassname The name of the validator class.
- * @param classLoader The class loader to use to load the validator.
- */
- public ClassloaderWSDL11ValidatorDelegate(String validatorClassname, ClassLoader classLoader)
- {
- this(validatorClassname);
- this.classLoader = classLoader;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.wsdl11.WSDL11ValidatorDelegate#loadValidator()
- */
- protected IWSDL11Validator loadValidator()
- {
- IWSDL11Validator validator = null;
- if(classLoader == null)
- {
- classLoader = getClass().getClassLoader();
- }
- try
- {
- Class validatorClass =
- classLoader != null ? classLoader.loadClass(validatorClassname) : Class.forName(validatorClassname);
-
- validator = (IWSDL11Validator)validatorClass.newInstance();
- }
- catch (Throwable t)
- {
- // TODO: add logging
- System.err.println(t);
- }
- return validator;
- }
-}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/IWSDL11Validator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/IWSDL11Validator.java
index daabcd6..a6bd2e2 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/IWSDL11Validator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/IWSDL11Validator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -12,6 +12,7 @@
package org.eclipse.wst.wsdl.validation.internal.wsdl11;
import java.util.List;
+import java.util.ResourceBundle;
/**
* Interface for a validator plugged into the WSDL 1.1 validator.
@@ -26,4 +27,12 @@
* @param valInfo The current validation information.
*/
public void validate(Object element, List parents, IWSDL11ValidationInfo valInfo);
+
+ /**
+ * Set the resource bundle of the validator.
+ *
+ * @param rb The resource bundle to set.
+ */
+ public void setResourceBundle(ResourceBundle rb);
+
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11BasicValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11BasicValidator.java
index a77067b..bd7b98a 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11BasicValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11BasicValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -14,7 +14,6 @@
import java.util.Hashtable;
import java.util.Iterator;
import java.util.List;
-import java.util.Locale;
import java.util.Map;
import java.util.ResourceBundle;
import java.util.Vector;
@@ -49,8 +48,6 @@
*/
public class WSDL11BasicValidator implements IWSDL11Validator
{
- private static String VALIDATOR_RESOURCE_BUNDLE_NAME = "validatewsdl";
-
protected final String NAMESPACES_FEATURE_ID = "http://xml.org/sax/features/namespaces";
protected final String VALIDATION_FEATURE_ID = "http://xml.org/sax/features/validation";
protected final String SCHEMA_VALIDATION_FEATURE_ID = "http://apache.org/xml/features/validation/schema";
@@ -90,11 +87,6 @@
//protected WSDL11ValidatorController validatorcontroller;
protected MessageGenerator messagegenerator;
- public WSDL11BasicValidator()
- {
- ResourceBundle rb = ResourceBundle.getBundle(VALIDATOR_RESOURCE_BUNDLE_NAME, Locale.getDefault());
- messagegenerator = new MessageGenerator(rb);
- }
/**
* @see org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator#validate(java.lang.Object, java.util.List, org.eclipse.wsdl.validate.wsdl11.IWSDL11ValidationInfo)
*/
@@ -144,6 +136,29 @@
}
/**
+ * If the resourcebundle hasn't been set, set it to the one registered with the ValidatorController.
+ *
+ * @param validatorcontroller The validator controller to get the resource bundle from.
+ */
+ // protected void setDefaultResourceBundleIfNeeded(WSDL11ValidatorController validatorcontroller)
+ // {
+ // if (messagegenerator == null)
+ // {
+ // setResourceBundle(validatorcontroller.getResourceBundle());
+ // }
+ // }
+
+ /**
+ * Set the resourcebundle to the one specified.
+ *
+ * @param rb The resource bundle to set.
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+
+ /**
* Ensure that the Types element is correct.
*
* @param wsdlDefinition The definitions element from the current document.
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorController.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorController.java
index 089719a..aa46e81 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorController.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorController.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -13,7 +13,6 @@
import java.util.Iterator;
import java.util.List;
-import java.util.Locale;
import java.util.ResourceBundle;
import java.util.Vector;
@@ -34,7 +33,6 @@
*/
public class WSDL11ValidatorController implements IWSDLValidator
{
- private static String VALIDATOR_RESOURCE_BUNDLE_NAME = "validatewsdl";
protected final String _WARN_NO_VALDIATOR = "_WARN_NO_VALDIATOR";
// protected final int ERROR_MESSAGE = 0;
// protected final int WARNING_MESSAGE = 1;
@@ -50,8 +48,6 @@
*/
public WSDL11ValidatorController()
{
- ResourceBundle rb = ResourceBundle.getBundle(VALIDATOR_RESOURCE_BUNDLE_NAME, Locale.getDefault());
- messagegenerator = new MessageGenerator(rb);
}
@@ -114,6 +110,34 @@
}
/**
+ * Validate an imported WSDL document. Allows the calling class to have access to the internal
+ * components of the validation.
+ *
+ * @param wsdlvalinfo The WSDL 1.1 validation info object to use.
+ * @return The definitions element for the import.
+ * @throws ValidateWSDLException
+ */
+// protected Definition validateImport(WSDL11ValidationInfo wsdlvalinfo)
+// {
+// WSDLDocument[] wsdlDocs = null;
+// try
+// {
+// wsdlDocs = readWSDLDocument(null, wsdlvalinfo.getFileURI(), getMessageGenerator(), wsdlvalinfo);
+// }
+// catch(ValidateWSDLException e)
+// {
+// // supress any validation issues with imported documents
+// }
+// // Don't validate an null definitions element. Either the file is emtpy and valid or
+// // had an error when reading.
+// if(wsdlDocs != null)
+// {
+// validateWSDLElement(Constants.NS_URI_WSDL, wsdlDefinition, new Vector(), wsdlvalinfo);
+// }
+// return wsdlDefinition;
+// }
+
+ /**
* Read in the WSDL document and set the model and imported schemas.
*
* @param domModel A DOM model of the document to be read.
@@ -194,6 +218,55 @@
//wsdlvalinfo.addWarning(messagegenerator.getString(_WARN_NO_VALDIATOR, namespace), element);
}
}
+
+ /**
+ * Add a schema to the list of schemas.
+ *
+ * @param xsModel The schema to add.
+ */
+// public void addSchema(XSModel xsModel)
+// {
+// if (xsModel != null)
+// {
+// schemas.add(xsModel);
+// }
+// }
+
+ /**
+ * Return the list containing the schemas.
+ *
+ * @return The list of schemas.
+ */
+// public List getSchemas()
+// {
+// return schemas;
+// }
+
+ /**
+ * Get the ResourceBundle for this ValidatorManager.
+ *
+ * @return The resource bundle registered for this controller.
+ * @see #setResourceBundle
+ */
+// public ResourceBundle getResourceBundle()
+// {
+// return resourcebundle;
+// }
+
+ /**
+ * Set the ResourceBundle for this ValidatorManager.
+ *
+ * @param rb The resource bundle to set.
+ * @see #getResourceBundle
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ if (messagegenerator == null)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+
+ }
/**
* Set the message generator for this controller.
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorDelegate.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorDelegate.java
index 32135e4..e627a78 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorDelegate.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/WSDL11ValidatorDelegate.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -11,14 +11,46 @@
package org.eclipse.wst.wsdl.validation.internal.wsdl11;
+import java.util.Locale;
+import java.util.ResourceBundle;
+
+
/**
* The WSDL 1.1 validator delegate holds a reference to a validator to be instantiated at
* a later point.
*/
-public abstract class WSDL11ValidatorDelegate
+public class WSDL11ValidatorDelegate
{
+ private String validatorClassname = null;
+ private String resourceBundle = null;
+ private ClassLoader classLoader = null;
private IWSDL11Validator validator = null;
+ /**
+ * Create a delegate for a validator by its class name and resource bundle name.
+ *
+ * @param validatorClassname The name of the validator class.
+ * @param resourceBundle The name of the validator base resource bundle.
+ */
+ public WSDL11ValidatorDelegate(String validatorClassname, String resourceBundle)
+ {
+ this.validatorClassname = validatorClassname;
+ this.resourceBundle = resourceBundle;
+ }
+
+ /**
+ * Create a delegate for a validator by its class name, resource bundle name and
+ * a class loader to load the validator and bundle.
+ *
+ * @param validatorClassname The name of the validator class.
+ * @param resourceBundle The name of the validator base resource bundle.
+ * @param classLoader The class loader to use to load the validator and bundle.
+ */
+ public WSDL11ValidatorDelegate(String validatorClassname, String resourceBundle, ClassLoader classLoader)
+ {
+ this(validatorClassname, resourceBundle);
+ this.classLoader = classLoader;
+ }
/**
* Get the validator specified in this delegate.
@@ -29,10 +61,38 @@
{
if (validator == null)
{
- validator = loadValidator();
+ if(classLoader == null)
+ {
+ classLoader = getClass().getClassLoader();
+ }
+ try
+ {
+ Class validatorClass =
+ classLoader != null ? classLoader.loadClass(validatorClassname) : Class.forName(validatorClassname);
+
+ validator = (IWSDL11Validator)validatorClass.newInstance();
+ if (resourceBundle != null)
+ {
+ ResourceBundle validatorBundle = ResourceBundle.getBundle(resourceBundle, Locale.getDefault(), classLoader);
+ validator.setResourceBundle(validatorBundle);
+ }
+ }
+ catch (ClassNotFoundException e)
+ {
+ // TODO: add logging
+ System.err.println(e);
+ }
+ catch (IllegalAccessException e)
+ {
+ // TODO: add logging
+ System.err.println(e);
+ }
+ catch (InstantiationException e)
+ {
+ // TODO: add logging
+ System.err.println(e);
+ }
}
return validator;
}
-
- protected abstract IWSDL11Validator loadValidator();
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/http/HTTPValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/http/HTTPValidator.java
index 5134e33..6780e48 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/http/HTTPValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/http/HTTPValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -13,7 +13,6 @@
import java.util.Iterator;
import java.util.List;
-import java.util.Locale;
import java.util.ResourceBundle;
import javax.wsdl.Binding;
@@ -24,8 +23,8 @@
import javax.wsdl.extensions.http.HTTPOperation;
import org.eclipse.wst.wsdl.validation.internal.util.MessageGenerator;
-import org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11ValidationInfo;
import org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator;
+import org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11ValidationInfo;
import com.ibm.wsdl.BindingImpl;
import com.ibm.wsdl.BindingInputImpl;
@@ -43,8 +42,6 @@
*/
public class HTTPValidator implements IWSDL11Validator
{
- private static String HTTP_RESOURCE_BUNDLE_NAME = "validatewsdlhttp";
-
private final String _ERROR_INVALID_PORT_ELEMENT = "_ERROR_INVALID_PORT_ELEMENT";
private final String _ERROR_INVALID_BINDING_ELEMENT = "_ERROR_INVALID_BINDING_ELEMENT";
private final String _ERROR_INVALID_BINDING_OPERATION_ELEMENT = "_ERROR_INVALID_BINDING_OPERATION_ELEMENT";
@@ -67,15 +64,6 @@
private MessageGenerator messagegenerator;
/**
- * Default constructor.
- */
- public HTTPValidator()
- {
- ResourceBundle rb = ResourceBundle.getBundle(HTTP_RESOURCE_BUNDLE_NAME, Locale.getDefault());
- messagegenerator = new MessageGenerator(rb);
- }
-
- /**
* @see org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator#validate(java.lang.Object, java.util.List, org.eclipse.wsdl.validate.wsdl11.IWSDL11ValidationInfo)
*/
public void validate(Object element, List parents, IWSDL11ValidationInfo valInfo)
@@ -163,6 +151,17 @@
}
/**
+ * @see org.eclipse.wst.wsdl.validation.internal.wsdl11.validator.IWSDL11Validator#setResourceBundle(java.util.ResourceBundle)
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ if (messagegenerator == null)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+ }
+
+ /**
* Ensure that the HTTP address has a value specified for it's uri and that there is a HTTP Binding defined
* for the Binding specified in the port.
*
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/mime/MIMEValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/mime/MIMEValidator.java
index 912a3b4..54fcea8 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/mime/MIMEValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/mime/MIMEValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -12,7 +12,6 @@
package org.eclipse.wst.wsdl.validation.internal.wsdl11.mime;
import java.util.List;
-import java.util.Locale;
import java.util.ResourceBundle;
import org.eclipse.wst.wsdl.validation.internal.util.MessageGenerator;
@@ -25,14 +24,8 @@
*/
public class MIMEValidator implements IWSDL11Validator
{
- private static String MIME_RESOURCE_BUNDLE_NAME = "validatewsdlmime";
protected MessageGenerator messagegenerator;
- public MIMEValidator()
- {
- ResourceBundle rb = ResourceBundle.getBundle(MIME_RESOURCE_BUNDLE_NAME, Locale.getDefault());
- messagegenerator = new MessageGenerator(rb);
- }
/**
* @see org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator#validate(java.lang.Object, java.util.List, org.eclipse.wsdl.validate.wsdl11.IWSDL11ValidationInfo)
*/
@@ -40,4 +33,15 @@
{
}
+
+ /**
+ * @see org.eclipse.wst.wsdl.validation.internal.wsdl11.validator.IWSDL11Validator#setResourceBundle(java.util.ResourceBundle)
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ if (messagegenerator == null)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+ }
}
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/soap/SOAPValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/soap/SOAPValidator.java
index 47f8570..c591425 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/soap/SOAPValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/wsdl11/soap/SOAPValidator.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -13,7 +13,6 @@
import java.util.Iterator;
import java.util.List;
-import java.util.Locale;
import java.util.ResourceBundle;
import javax.wsdl.Binding;
@@ -55,8 +54,6 @@
*/
public class SOAPValidator implements IWSDL11Validator
{
- private static String SOAP_RESOURCE_BUNDLE_NAME = "validatewsdlsoap";
-
private final String _ERROR_INVALID_PORT_ELEMENT = "_ERROR_INVALID_PORT_ELEMENT";
private final String _ERROR_INVALID_BINDING_ELEMENT = "_ERROR_INVALID_BINDING_ELEMENT";
private final String _ERROR_INVALID_BINDING_OPERATION_ELEMENT = "_ERROR_INVALID_BINDING_OPERATION_ELEMENT";
@@ -101,15 +98,6 @@
protected MessageGenerator messagegenerator;
/**
- * Default constructor.
- */
- public SOAPValidator()
- {
- ResourceBundle rb = ResourceBundle.getBundle(SOAP_RESOURCE_BUNDLE_NAME, Locale.getDefault());
- messagegenerator = new MessageGenerator(rb);
- }
-
- /**
* @see org.eclipse.wst.wsdl.validation.internal.wsdl11.IWSDL11Validator#validate(java.lang.Object, java.util.List, org.eclipse.wsdl.validate.wsdl11.IWSDL11ValidationInfo)
*/
public void validate(Object element, List parents, IWSDL11ValidationInfo valInfo)
@@ -210,6 +198,17 @@
}
}
+
+ /**
+ * @see org.eclipse.wst.wsdl.validation.internal.wsdl11.validator.IWSDL11Validator#setResourceBundle(java.util.ResourceBundle)
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ if (messagegenerator == null)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+ }
/**
* Ensure that the SOAP address has a value specified for it's uri and that the binding has a SOAP
diff --git a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java
index ea52dd1..f890942 100644
--- a/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java
+++ b/bundles/org.eclipse.wst.wsdl.validation/src/org/eclipse/wst/wsdl/validation/internal/xml/DefaultXMLValidator.java
@@ -31,9 +31,11 @@
import org.apache.xerces.xni.parser.XMLErrorHandler;
import org.apache.xerces.xni.parser.XMLInputSource;
import org.apache.xerces.xni.parser.XMLParseException;
+import org.eclipse.core.resources.IFile;
import org.eclipse.wst.wsdl.validation.internal.ValidationMessageImpl;
import org.eclipse.wst.wsdl.validation.internal.resolver.IURIResolutionResult;
import org.eclipse.wst.wsdl.validation.internal.resolver.URIResolver;
+import org.eclipse.wst.wsdl.validation.internal.wsdl11.xsd.XSDValidator;
import org.w3c.dom.DOMError;
import org.xml.sax.Attributes;
import org.xml.sax.InputSource;
@@ -75,32 +77,26 @@
ignoredNamespaceList.add(Constants.NS_URI_XSD_2001);
}
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.xml.IXMLValidator#setFile(java.lang.String)
+ /**
+ * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#setFile(IFile)
*/
public void setFile(String uri)
{
this.uri = uri;
}
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.xml.IXMLValidator#setURIResolver(org.eclipse.wst.wsdl.validation.internal.resolver.URIResolver)
- */
public void setURIResolver(URIResolver uriResolver)
{
this.uriResolver = uriResolver;
}
- /**
- * @param grammarPool
- */
public void setGrammarPool(XMLGrammarPool grammarPool)
{
this.grammarPool = grammarPool;
}
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.xml.IXMLValidator#run()
+ /**
+ * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#run()
*/
public void run()
{
@@ -135,6 +131,7 @@
catch (IOException e)
{
// TODO: Log exception.
+ // System.out.println(e);
}
catch (Exception e)
{
@@ -143,10 +140,6 @@
}
}
- /**
- * @param inputStream
- * @return
- */
final String createStringForInputStream(InputStream inputStream)
{
// Here we are reading the file and storing to a stringbuffer.
@@ -171,28 +164,22 @@
return fileString.toString();
}
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.xml.IXMLValidator#hasErrors()
+ /**
+ * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#hasErrors()
*/
public boolean hasErrors()
{
return !errors.isEmpty();
}
- /* (non-Javadoc)
- * @see org.eclipse.wst.wsdl.validation.internal.xml.IXMLValidator#getErrors()
+ /**
+ * @see org.eclipse.validate.wsdl.xmlconformance.IXMLValidatorAction#getErrorList()
*/
public List getErrors()
{
return errors;
}
- /**
- * @param message
- * @param line
- * @param column
- * @param uri
- */
public void addError(String message, int line, int column, String uri)
{
errors.add(new ValidationMessageImpl(message, line, column, ValidationMessageImpl.SEV_WARNING, uri, currentErrorKey, currentMessageArguments));
@@ -547,6 +534,8 @@
return new XMLInputSource(rid);
}
+ boolean nsUsed = false;
+
String ns = rid.getNamespace();
if(ns != null && ignoredNamespaceList.contains(ns))
{
@@ -557,6 +546,7 @@
if(systemId == null)
{
systemId = ns;
+ nsUsed = true;
}
String publicId = rid.getPublicId();
if(publicId == null)
@@ -564,24 +554,44 @@
publicId = systemId;
}
- IURIResolutionResult result = uriResolver.resolve("", publicId, systemId);
- String uri = result.getPhysicalLocation();
- if (uri != null && !uri.equals(""))
+ // Xerces tends to try to resolve locations with no information.
+ // No need to do any processing if we have no information.
+ if(publicId != null || systemId != null)
{
- try
- {
- URL entityURL = new URL(uri);
- XMLInputSource is = new XMLInputSource(rid.getPublicId(), systemId, result.getLogicalLocation());
- is.setByteStream(entityURL.openStream());
- if (is != null)
+ IURIResolutionResult result = uriResolver.resolve("", publicId, systemId);
+ String uri = result.getPhysicalLocation();
+ if (uri != null && !uri.equals(""))
+ {
+ // If the namespace was used to resolve this reference ensure a schema
+ // has been returned. Namespaces tend to point to Web resources that
+ // may or may not be schemas.
+ boolean createEntityResult = true;
+ if(nsUsed)
{
- return is;
+ XSDValidator xsdVal = new XSDValidator();
+ xsdVal.validate(uri, uriResolver, null);
+ if(!xsdVal.isValid())
+ createEntityResult = false;
}
- }
- catch(Exception e)
- {
- // No need to report this error. Simply continue below.
- }
+
+ if(createEntityResult)
+ {
+ try
+ {
+ URL entityURL = new URL(uri);
+ XMLInputSource is = new XMLInputSource(rid.getPublicId(), systemId, result.getLogicalLocation());
+ is.setByteStream(entityURL.openStream());
+ if (is != null)
+ {
+ return is;
+ }
+ }
+ catch(Exception e)
+ {
+ // No need to report this error. Simply continue below.
+ }
+ }
+ }
}
return null;
}
diff --git a/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.core.prefs
index ae9d67c..2407534 100644
--- a/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.core.prefs
+++ b/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.core.prefs
@@ -1,6 +1,6 @@
-#Mon Jan 30 23:40:08 EST 2006
+#Mon Jan 30 18:52:04 EST 2006
eclipse.preferences.version=1
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
+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
@@ -34,7 +34,6 @@
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.rawTypeReference=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
@@ -49,7 +48,6 @@
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
org.eclipse.jdt.core.compiler.problem.unusedImport=error
-org.eclipse.jdt.core.compiler.problem.unusedLabel=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
diff --git a/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.ui.prefs b/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 17c50aa..0000000
--- a/bundles/org.eclipse.wst.wsdl/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Mon Jan 30 23:19:19 EST 2006
-eclipse.preferences.version=1
-internal.default.compliance=default
diff --git a/bundles/org.eclipse.wst.wsdl/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.wsdl/META-INF/MANIFEST.MF
index 8778f37..b9ea33b 100644
--- a/bundles/org.eclipse.wst.wsdl/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.wsdl/META-INF/MANIFEST.MF
@@ -3,33 +3,33 @@
Bundle-Name: %pluginName
Bundle-SymbolicName: org.eclipse.wst.wsdl; singleton:=true
Bundle-Version: 1.0.0.qualifier
-Bundle-Activator: org.eclipse.wst.wsdl.WSDLPluginImplementation
+Bundle-Activator: org.eclipse.core.internal.compatibility.PluginActivator
Bundle-Vendor: %providerName
Bundle-Localization: plugin
Export-Package: model,
org.eclipse.wst.wsdl,
org.eclipse.wst.wsdl.binding.http,
- org.eclipse.wst.wsdl.binding.http.internal.generator;x-internal:=true,
- org.eclipse.wst.wsdl.binding.http.internal.impl;x-internal:=true,
- org.eclipse.wst.wsdl.binding.http.internal.util;x-internal:=true,
+ org.eclipse.wst.wsdl.binding.http.internal.generator,
+ org.eclipse.wst.wsdl.binding.http.internal.impl,
+ org.eclipse.wst.wsdl.binding.http.internal.util,
org.eclipse.wst.wsdl.binding.mime,
- org.eclipse.wst.wsdl.binding.mime.internal.impl;x-internal:=true,
- org.eclipse.wst.wsdl.binding.mime.internal.util;x-internal:=true,
+ org.eclipse.wst.wsdl.binding.mime.internal.impl,
+ org.eclipse.wst.wsdl.binding.mime.internal.util,
org.eclipse.wst.wsdl.binding.soap,
- org.eclipse.wst.wsdl.binding.soap.internal.generator;x-internal:=true,
- org.eclipse.wst.wsdl.binding.soap.internal.impl;x-internal:=true,
- org.eclipse.wst.wsdl.binding.soap.internal.util;x-internal:=true,
- org.eclipse.wst.wsdl.internal.extensibility;x-internal:=true,
- org.eclipse.wst.wsdl.internal.generator;x-internal:=true,
- org.eclipse.wst.wsdl.internal.generator.extension;x-internal:=true,
- org.eclipse.wst.wsdl.internal.impl;x-internal:=true,
- org.eclipse.wst.wsdl.internal.impl.wsdl4j;x-internal:=true,
- org.eclipse.wst.wsdl.internal.util;x-internal:=true,
+ org.eclipse.wst.wsdl.binding.soap.internal.generator,
+ org.eclipse.wst.wsdl.binding.soap.internal.impl,
+ org.eclipse.wst.wsdl.binding.soap.internal.util,
+ org.eclipse.wst.wsdl.internal.extensibility,
+ org.eclipse.wst.wsdl.internal.generator,
+ org.eclipse.wst.wsdl.internal.generator.extension,
+ org.eclipse.wst.wsdl.internal.impl,
+ org.eclipse.wst.wsdl.internal.impl.wsdl4j,
+ org.eclipse.wst.wsdl.internal.util,
org.eclipse.wst.wsdl.util
-Require-Bundle: org.eclipse.emf.ecore,
+Require-Bundle: org.eclipse.core.runtime.compatibility,
+ org.eclipse.emf.ecore,
org.eclipse.xsd,
org.eclipse.core.resources,
- org.wsdl4j,
- org.eclipse.core.runtime,
- org.apache.xerces
-Eclipse-LazyStart: true
+ org.wsdl4j
+Eclipse-AutoStart: true
+Plugin-Class: org.eclipse.wst.wsdl.WSDLPluginImplementation
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/WSDLPluginImplementation.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/WSDLPluginImplementation.java
index 3a02b7c..a07de7a 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/WSDLPluginImplementation.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/WSDLPluginImplementation.java
@@ -10,6 +10,7 @@
*******************************************************************************/
package org.eclipse.wst.wsdl;
+import org.eclipse.core.runtime.IPluginDescriptor;
import org.eclipse.emf.common.EMFPlugin.EclipsePlugin;
/**
@@ -26,10 +27,11 @@
{
/**
* Creates an instance.
+ * @param descriptor the description of the plugin.
*/
- public WSDLPluginImplementation()
+ public WSDLPluginImplementation(IPluginDescriptor descriptor)
{
- super();
+ super(descriptor);
// Remember the static instance.
//
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryDescriptor.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryDescriptor.java
index 64a2fc7..040b799 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryDescriptor.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryDescriptor.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2001, 2006 IBM Corporation and others.
+ * 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
@@ -11,20 +11,19 @@
package org.eclipse.wst.wsdl.internal.extensibility;
import org.eclipse.wst.wsdl.util.ExtensibilityElementFactory;
-import org.osgi.framework.Bundle;
public class ExtensibilityElementFactoryDescriptor
{
private final static String CLASS_LOADING_ERROR = "CLASS_LOADING_ERROR";
- protected Bundle bundle;
+ protected ClassLoader classLoader;
protected String namespace;
protected String className;
protected Object factory;
- public ExtensibilityElementFactoryDescriptor(String className, String namespace, Bundle bundle)
+ public ExtensibilityElementFactoryDescriptor(String className, String namespace, ClassLoader classLoader)
{
- this.bundle = bundle;
+ this.classLoader = classLoader;
this.className = className;
this.namespace = namespace;
}
@@ -35,7 +34,7 @@
{
try
{
- Class theClass = bundle.loadClass(className);
+ Class theClass = classLoader != null ? classLoader.loadClass(className) : Class.forName(className);
factory = (ExtensibilityElementFactory)theClass.newInstance();
}
catch (Exception e)
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryRegistryReader.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryRegistryReader.java
index 57be9ad..ddc5407 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryRegistryReader.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/extensibility/ExtensibilityElementFactoryRegistryReader.java
@@ -11,18 +11,16 @@
package org.eclipse.wst.wsdl.internal.extensibility;
import java.net.URL;
-import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionPoint;
-import org.eclipse.core.runtime.IExtensionRegistry;
+import org.eclipse.core.runtime.IPluginRegistry;
import org.eclipse.core.runtime.Platform;
import org.eclipse.wst.wsdl.WSDLPlugin;
-import org.osgi.framework.Bundle;
public class ExtensibilityElementFactoryRegistryReader
{
- protected static final String PLUGIN_ID = WSDLPlugin.getPlugin().getSymbolicName();
+ protected static final String PLUGIN_ID = WSDLPlugin.getPlugin().getDescriptor().getUniqueIdentifier();
protected static final String EXTENSION_POINT_ID = "extensibilityElementFactories";
protected static final String ELEMENT_NAME = "extensibilityElementFactory";
protected static final String ATT_NAMESPACE = "namespace";
@@ -39,8 +37,8 @@
*/
public void readRegistry()
{
- IExtensionRegistry pluginRegistry = Platform.getExtensionRegistry();
- IExtensionPoint point = pluginRegistry.getExtensionPoint(PLUGIN_ID, EXTENSION_POINT_ID);
+ IPluginRegistry pluginRegistry = Platform.getPluginRegistry();
+ IExtensionPoint point = pluginRegistry.getExtensionPoint(PLUGIN_ID, EXTENSION_POINT_ID);
if (point != null)
{
IConfigurationElement[] elements = point.getConfigurationElements();
@@ -53,7 +51,7 @@
public String resolve(URL platformURL, String relativePath) throws Exception
{
- URL resolvedURL = FileLocator.resolve(platformURL);
+ URL resolvedURL = Platform.resolve(platformURL);
return resolvedURL.toString() + relativePath;
}
@@ -67,9 +65,9 @@
String namespace = childElement.getAttribute(ATT_NAMESPACE);
if (namespace != null)
{
- Bundle pluginBundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
+ ClassLoader pluginClasssLoader = element.getDeclaringExtension().getDeclaringPluginDescriptor().getPluginClassLoader();
String className = childElement.getAttribute(ATT_CLASS);
- ExtensibilityElementFactoryDescriptor descriptor = new ExtensibilityElementFactoryDescriptor(className,namespace,pluginBundle);
+ ExtensibilityElementFactoryDescriptor descriptor = new ExtensibilityElementFactoryDescriptor(className,namespace,pluginClasssLoader);
extensibilityElementFactoryRegistry.put(namespace, descriptor);
}
}
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/BindingGenerator.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/BindingGenerator.java
index 2ba499c..313fab3 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/BindingGenerator.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/BindingGenerator.java
@@ -101,6 +101,10 @@
}
private Binding createEmptyBinding(String localName) {
+ String name = localName;
+ if (localName == null) {
+ name = "";
+ }
Binding newBinding = WSDLFactory.eINSTANCE.createBinding();
newBinding.setQName(new QName(definition.getTargetNamespace(),localName));
newBinding.setEnclosingDefinition(definition);
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/PortGenerator.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/PortGenerator.java
index c16557b..0d3bce0 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/PortGenerator.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/PortGenerator.java
@@ -16,8 +16,6 @@
import java.util.Map;
import org.eclipse.wst.wsdl.Binding;
-import org.eclipse.wst.wsdl.Definition;
-import org.eclipse.wst.wsdl.Import;
import org.eclipse.wst.wsdl.Port;
import org.eclipse.wst.wsdl.Service;
import org.eclipse.wst.wsdl.WSDLFactory;
@@ -25,132 +23,43 @@
public class PortGenerator extends BaseGenerator {
private Service service;
- /**
- * Constructs a port generator given the target service.
- * @param service the target Service, must not be null.
- */
public PortGenerator(Service service) {
this.service = service;
definition = service.getEnclosingDefinition();
}
- /**
- * Generates a service port given it's name and binding name.
- * The port is then added to the service passed in the constructor.
- * @return the Port instance
- */
public Port generatePort() {
- String portName = getName();
- String bindingName = getRefName();
-
- Binding binding = getBinding(bindingName);
-
- Port port = WSDLFactory.eINSTANCE.createPort();
- port.setName(portName);
- port.setEnclosingDefinition(definition);
- port.setBinding(binding);
-
- service.addPort(port);
-
- ContentGenerator contentGenerator = getContentGenerator();
-
- if (contentGenerator != null) {
- contentGenerator.generatePortContent(port);
- }
-
- return port;
+ String name = getName();
+ String bindingName = getRefName();
+
+ Port port = WSDLFactory.eINSTANCE.createPort();
+ port.setName(getName());
+ port.setEnclosingDefinition(service.getEnclosingDefinition());
+ port.setBinding(getBinding(getRefName()));
+ service.addPort(port);
+
+ if (this.getContentGenerator() != null) {
+ this.getContentGenerator().generatePortContent(port);
+ }
+
+ return port;
}
- /**
- * Locates a binding given its prefixed name (someNSPrefix:someBindingName).
- *
- * @param bindingName the qname of the desired binding.
- * @return a Binding with the given name, or null if one is not found.
- */
private Binding getBinding(String bindingName) {
- List allBindings = getAllBindings();
- Iterator bindingIterator = allBindings.iterator();
-
- while (bindingIterator.hasNext()) {
- Binding binding = (Binding)bindingIterator.next();
-
- List prefixedNames = getPrefixedNames(binding);
-
- if (prefixedNames.contains(bindingName)) {
- return binding;
- }
- }
-
- return null;
- }
-
- /**
- * Locates all the bindings available in this definition and all its
- * imported definitions.
- *
- * @return a List with all available bindings.
- */
- public List getAllBindings() {
- List allBindings = new ArrayList();
- List allDefinitions = getAllDefinitions();
-
- Iterator defsIterator = allDefinitions.iterator();
-
- while (defsIterator.hasNext()) {
- Definition definition = (Definition) defsIterator.next();
- Map bindings = definition.getBindings();
-
- // ISSUE A possible problem here if somehow a binding is duplicated in one of the imports?
- // In that case we should iterate over and check them one by one.
-
- allBindings.addAll(bindings.values());
- }
-
- return allBindings;
- }
-
- /**
- * Attempts to locate and add to the list all the definitions imported by the
- * definition passed in. Recursively tries to locate all definitions.
- *
- * @param definition the start Definition. Must not be null.
- * @param list used to collect all the imported definitions. Must not be null.
- */
- private void addDefinition(Definition definition, List list) {
- list.add(definition);
- List imports = definition.getEImports();
- Iterator importsIterator = imports.iterator();
-
- while (importsIterator.hasNext()) {
- Import theImport = (Import)importsIterator.next();
-
- String importLocationURI = theImport.getLocationURI();
- if (importLocationURI != null &&
- // ISSUE This assumption seems a bit weak.
- importLocationURI.endsWith("wsdl")) {
- Definition importedDefinition = theImport.getEDefinition();
-
- if (importedDefinition != null &&
- !list.contains(importedDefinition)) {
- // Recursively try to locate all definitions.
-
- addDefinition(importedDefinition, list);
- }
- }
- }
- }
-
- /**
- * Attempts to locate all definitions imported by the current definition and
- * all their imports in turn.
- *
- * @return a List with all definitions imported by the current definition.
- */
- private List getAllDefinitions()
- {
- List list = new ArrayList();
- addDefinition(definition, list);
- return list;
+ Iterator bindingIt = definition.getEBindings().iterator();
+ while (bindingIt.hasNext()) {
+ Binding binding = (Binding) bindingIt.next();
+ String currentBindingName = binding.getQName().getLocalPart();
+ String currentNamespace = binding.getQName().getNamespaceURI();
+
+ List prefixedNames = getPrefixedNames(binding);
+
+ if (prefixedNames.contains(bindingName)) {
+ return binding;
+ }
+ }
+
+ return null;
}
private List getPrefixedNames(Binding binding) {
@@ -166,7 +75,7 @@
if (currentNamespace.equals(value)) {
// Found a match. Add to our list
- prefixedNames.add(key + ":" + currentBindingName); //$NON-NLS-1$
+ prefixedNames.add(key + ":" + currentBindingName);
}
}
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionDescriptor.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionDescriptor.java
index cd88bdf..c49e99c 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionDescriptor.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionDescriptor.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2000, 2006 IBM Corporation and others.
+ * Copyright (c) 2000, 2005 IBM Corporation and others.
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Common Public License v1.0
* which accompanies this distribution, and is available at
@@ -11,20 +11,19 @@
package org.eclipse.wst.wsdl.internal.generator.extension;
import org.eclipse.wst.wsdl.internal.generator.ContentGenerator;
-import org.osgi.framework.Bundle;
/*
* Class which acts as a container to hold information about the extension.
*/
public class ContentGeneratorExtensionDescriptor {
- protected Bundle bundle;
+ protected ClassLoader classLoader;
protected ContentGenerator contentGenerator;
protected String namespace;
protected String name;
protected String className;
- public ContentGeneratorExtensionDescriptor(Bundle bundle, String classString, String namespace, String name) {
- this.bundle = bundle;
+ public ContentGeneratorExtensionDescriptor(ClassLoader classLoader, String classString, String namespace, String name) {
+ this.classLoader = classLoader;
this.namespace = namespace;
this.name = name;
this.className = classString;
@@ -33,7 +32,7 @@
public Object getContentGenerator() {
try {
- Class theClass = bundle.loadClass(className);
+ Class theClass = classLoader != null ? classLoader.loadClass(className) : Class.forName(className);
contentGenerator = (ContentGenerator) theClass.newInstance();
}
catch (Exception e) {
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionRegistryReader.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionRegistryReader.java
index 79c448d..57075b6 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionRegistryReader.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/internal/generator/extension/ContentGeneratorExtensionRegistryReader.java
@@ -12,16 +12,14 @@
import java.net.URL;
-import org.eclipse.core.runtime.FileLocator;
import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionPoint;
-import org.eclipse.core.runtime.IExtensionRegistry;
+import org.eclipse.core.runtime.IPluginRegistry;
import org.eclipse.core.runtime.Platform;
import org.eclipse.wst.wsdl.WSDLPlugin;
-import org.osgi.framework.Bundle;
public class ContentGeneratorExtensionRegistryReader {
- protected static final String PLUGIN_ID = WSDLPlugin.getPlugin().getSymbolicName();
+ protected static final String PLUGIN_ID = WSDLPlugin.getPlugin().getDescriptor().getUniqueIdentifier();
protected static final String EXTENSION_POINT_ID = "contentGenerators";
protected static final String ELEMENT_NAME = "contentGenerator";
protected static final String ATT_NAMESPACE = "namespace";
@@ -38,8 +36,8 @@
* read from plugin registry and parse it.
*/
public void readRegistry() {
- IExtensionRegistry pluginRegistry = Platform.getExtensionRegistry();
- IExtensionPoint point = pluginRegistry.getExtensionPoint(PLUGIN_ID, EXTENSION_POINT_ID);
+ IPluginRegistry pluginRegistry = Platform.getPluginRegistry();
+ IExtensionPoint point = pluginRegistry.getExtensionPoint(PLUGIN_ID, EXTENSION_POINT_ID);
if (point != null) {
IConfigurationElement[] elements = point.getConfigurationElements();
for (int i = 0; i < elements.length; i++) {
@@ -49,7 +47,7 @@
}
public String resolve(URL platformURL, String relativePath) throws Exception {
- URL resolvedURL = FileLocator.resolve(platformURL);
+ URL resolvedURL = Platform.resolve(platformURL);
return resolvedURL.toString() + relativePath;
}
@@ -61,9 +59,9 @@
String namespace = childElement.getAttribute(ATT_NAMESPACE);
if (namespace != null) {
- Bundle pluginBundle = Platform.getBundle(element.getDeclaringExtension().getContributor().getName());
+ ClassLoader pluginClasssLoader = element.getDeclaringExtension().getDeclaringPluginDescriptor().getPluginClassLoader();
String className = childElement.getAttribute(ATT_CLASS);
- ContentGeneratorExtensionDescriptor descriptor = new ContentGeneratorExtensionDescriptor(pluginBundle, className, namespace, name);
+ ContentGeneratorExtensionDescriptor descriptor = new ContentGeneratorExtensionDescriptor(pluginClasssLoader, className, namespace, name);
contentGeneratorExtensionFactoryRegistry.put(namespace, name, descriptor);
}
}
diff --git a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/util/WSDLResourceImpl.java b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/util/WSDLResourceImpl.java
index c967624..ee5e521 100644
--- a/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/util/WSDLResourceImpl.java
+++ b/bundles/org.eclipse.wst.wsdl/src-wsdl/org/eclipse/wst/wsdl/util/WSDLResourceImpl.java
@@ -260,22 +260,6 @@
documentBuilderFactory.setNamespaceAware(true);
documentBuilderFactory.setValidating(false);
- try
- {
- // Using a deferred DOM document in the WSDL model may cause a
- // performance problem in terms of memory consumption in particular.
- // We're attempting to use the feature which instructs the Xerces parser
- // to not use deferred DOM trees.
- // TODO Convert to use setFeature when it becomes available. The Xerces
- // versions < 2.7.1 do not fully support setFeature, so we have to use
- // setAttribute.
- documentBuilderFactory.setAttribute("http://apache.org/xml/features/dom/defer-node-expansion", Boolean.FALSE); //$NON-NLS-1$
- }
- catch (IllegalArgumentException e)
- {
- // Ignore, as the code will have to run with parsers other than Xerces.
- }
-
DocumentBuilder documentBuilder = documentBuilderFactory.newDocumentBuilder();
// TBD - Revisit
diff --git a/bundles/org.eclipse.wst.wsi.ui/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.wsi.ui/META-INF/MANIFEST.MF
index 41269d5..1818f01 100644
--- a/bundles/org.eclipse.wst.wsi.ui/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.wsi.ui/META-INF/MANIFEST.MF
@@ -6,11 +6,10 @@
Bundle-Activator: org.eclipse.wst.wsi.ui.internal.WSIUIPlugin
Bundle-Vendor: %_PROVIDER_NAME
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.wsi.ui.internal;x-internal:=true,
- org.eclipse.wst.wsi.ui.internal.actions;x-internal:=true,
- org.eclipse.wst.wsi.ui.internal.actions.actionDelegates;x-internal:=true,
- org.eclipse.wst.wsi.ui.internal.actions.icons;x-internal:=true,
- org.eclipse.wst.wsi.ui.internal.wizards;x-internal:=true
+Export-Package: org.eclipse.wst.wsi.ui.internal,
+ org.eclipse.wst.wsi.ui.internal.actions,
+ org.eclipse.wst.wsi.ui.internal.actions.actionDelegates,
+ org.eclipse.wst.wsi.ui.internal.wizards
Require-Bundle: org.eclipse.jface.text,
org.eclipse.core.resources,
org.eclipse.ui,
diff --git a/bundles/org.eclipse.wst.wsi/META-INF/MANIFEST.MF b/bundles/org.eclipse.wst.wsi/META-INF/MANIFEST.MF
index 2b3a315..e356712 100644
--- a/bundles/org.eclipse.wst.wsi/META-INF/MANIFEST.MF
+++ b/bundles/org.eclipse.wst.wsi/META-INF/MANIFEST.MF
@@ -2,47 +2,18 @@
Bundle-ManifestVersion: 2
Bundle-Name: %_PLUGIN_NAME
Bundle-SymbolicName: org.eclipse.wst.wsi; singleton:=true
-Bundle-Version: 1.0.101.qualifier
+Bundle-Version: 1.0.2.qualifier
Bundle-Activator: org.eclipse.wst.wsi.internal.WSITestToolsPlugin
Bundle-Vendor: %_PROVIDER_NAME
Bundle-Localization: plugin
-Export-Package: org.eclipse.wst.wsi.internal;x-internal:=true,
- org.eclipse.wst.wsi.internal.analyzer;x-internal:=true,
- org.eclipse.wst.wsi.internal.core;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.analyzer;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.analyzer.config;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.analyzer.config.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.common;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.common.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.document;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.document.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.log;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.log.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.monitor;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.monitor.config;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.monitor.config.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator.impl.envelope;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator.impl.message;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator.impl.uddi;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.profile.validator.impl.wsdl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.report;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.report.impl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.util;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.wsdl;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.wsdl.traversal;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.wsdl.xsd;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.xml;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.xml.dom;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.xml.jaxp;x-internal:=true,
- org.eclipse.wst.wsi.internal.core.xml.schema;x-internal:=true,
- org.eclipse.wst.wsi.internal.document;x-internal:=true,
- org.eclipse.wst.wsi.internal.report;x-internal:=true,
- org.eclipse.wst.wsi.internal.validate.wsdl;x-internal:=true
-Require-Bundle: org.eclipse.wst.command.env,
+Export-Package: org.eclipse.wst.wsi.internal,
+ org.eclipse.wst.wsi.internal.analyzer,
+ org.eclipse.wst.wsi.internal.core,
+ org.eclipse.wst.wsi.internal.core.log,
+ org.eclipse.wst.wsi.internal.core.wsdl,
+ org.eclipse.wst.wsi.internal.core.xml,
+ org.eclipse.wst.wsi.internal.report
+Require-Bundle: org.eclipse.wst.command.env,
org.eclipse.wst.command.env.core,
org.eclipse.wst.common.uriresolver,
org.eclipse.core.resources,
@@ -51,7 +22,5 @@
org.wsdl4j,
org.uddi4j,
org.eclipse.core.runtime;bundle-version="2.1.0",
- org.apache.axis,
- com.ibm.icu,
- org.apache.xerces
-Eclipse-LazyStart: true
+ org.apache.axis
+Eclipse-AutoStart: true
diff --git a/bundles/org.eclipse.wst.wsi/plugin.xml b/bundles/org.eclipse.wst.wsi/plugin.xml
index 7e80a2b..84a3928 100644
--- a/bundles/org.eclipse.wst.wsi/plugin.xml
+++ b/bundles/org.eclipse.wst.wsi/plugin.xml
@@ -20,7 +20,8 @@
point="org.eclipse.wst.wsdl.validation.extvalidator">
<extvalidator
namespace="http://schemas.xmlsoap.org/wsdl/"
- class="org.eclipse.wst.wsi.internal.validate.wsdl.WSDLValidator">
+ class="org.eclipse.wst.wsi.internal.validate.wsdl.WSDLValidator"
+ resourcebundle="wsivalidate">
</extvalidator>
</extension>
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsEclipseProperties.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsEclipseProperties.java
index b5e509c..debcff7 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsEclipseProperties.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsEclipseProperties.java
@@ -14,6 +14,8 @@
import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.ResourcesPlugin;
import org.eclipse.core.runtime.Path;
+import org.eclipse.wst.common.uriresolver.internal.provisional.URIResolver;
+import org.eclipse.wst.common.uriresolver.internal.provisional.URIResolverPlugin;
import org.eclipse.wst.ws.internal.plugin.WSPlugin;
import org.eclipse.wst.ws.internal.preferences.PersistentWSIContext;
@@ -27,8 +29,10 @@
*/
public static WSIPreferences checkWSIPreferences(String fileuri)
{
+ // Cache the WS-I tads.
+ cacheTADFiles();
+
WSIPreferences preferences = new WSIPreferences();
-
// Remove file: and any slashes from the fileuri.
// Eclipse's resolution mechanism needs to start with the drive.
String uriStr = trimURI(fileuri);
@@ -101,5 +105,38 @@
}
return preferences;
}
+
+ protected static void cacheTADFiles()
+ {
+ String resultAP = cacheFile(AP_ASSERTION_FILE);
+ if(resultAP != null)
+ {
+ AP_ASSERTION_FILE = resultAP;
+ }
+
+ String resultSSBP = cacheFile(SSBP_ASSERTION_FILE);
+ if(resultSSBP != null)
+ {
+ SSBP_ASSERTION_FILE = resultSSBP;
+ }
+ }
+
+ protected static String cacheFile(String uri)
+ {
+ URIResolver resolver = getURIResolver();
+ String resolvedUri = resolver.resolve("", null, uri);
+ return resolver.resolvePhysicalLocation("", null, resolvedUri);
+ }
+
+ /**
+ * Get the URI resolver to use for WS-I validaiton.
+ *
+ * @return
+ * The URI resolver to use for WS-I validation.
+ */
+ public static URIResolver getURIResolver()
+ {
+ return URIResolverPlugin.createResolver();
+ }
}
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsProperties.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsProperties.java
index f18cf04..8e69cdf 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsProperties.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/WSITestToolsProperties.java
@@ -19,8 +19,8 @@
protected static String tadfile = "";
public final static String schemaDir = "common/schemas/";
- public final static String SSBP_ASSERTION_FILE = "http://www.ws-i.org/Testing/Tools/2005/01/SSBP10_BP11_TAD_1-0.xml";
- public final static String AP_ASSERTION_FILE = "http://www.ws-i.org/Testing/Tools/2004/12/AP10_BP11_SSBP10_TAD.xml";
+ public static String SSBP_ASSERTION_FILE = "http://www.ws-i.org/Testing/Tools/2005/01/SSBP10_BP11_TAD_1-0.xml";
+ public static String AP_ASSERTION_FILE = "http://www.ws-i.org/Testing/Tools/2004/12/AP10_BP11_SSBP10_TAD.xml";
public final static String DEFAULT_ASSERTION_FILE = AP_ASSERTION_FILE;
public static final String STOP_NON_WSI = "0";
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/log/LogBuilder.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/log/LogBuilder.java
index b4dfc80..2a80668 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/log/LogBuilder.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/log/LogBuilder.java
@@ -13,16 +13,23 @@
import java.io.PrintWriter;
import java.io.StringReader;
import java.io.StringWriter;
+import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Iterator;
import java.util.List;
+import java.util.TimeZone;
import org.eclipse.core.resources.IFile;
-import org.eclipse.wst.wsi.internal.core.ToolInfo;
import org.eclipse.wst.wsi.internal.core.WSIConstants;
+import org.eclipse.wst.wsi.internal.core.ToolInfo;
import org.eclipse.wst.wsi.internal.core.common.AddStyleSheet;
import org.eclipse.wst.wsi.internal.core.common.impl.AddStyleSheetImpl;
import org.eclipse.wst.wsi.internal.core.document.DocumentFactory;
+import org.eclipse.wst.wsi.internal.core.log.Log;
+import org.eclipse.wst.wsi.internal.core.log.LogWriter;
+import org.eclipse.wst.wsi.internal.core.log.MessageEntry;
+import org.eclipse.wst.wsi.internal.core.log.MimeParts;
+import org.eclipse.wst.wsi.internal.core.log.RequestHandler;
import org.eclipse.wst.wsi.internal.core.log.impl.LogImpl;
import org.eclipse.wst.wsi.internal.core.log.impl.LogWriterImpl;
import org.eclipse.wst.wsi.internal.core.log.impl.MessageEntryImpl;
@@ -33,9 +40,6 @@
import org.eclipse.wst.wsi.internal.core.monitor.config.impl.ManInTheMiddleImpl;
import org.eclipse.wst.wsi.internal.core.util.Utils;
-import com.ibm.icu.text.SimpleDateFormat;
-import com.ibm.icu.util.TimeZone;
-
/**
* Given a list of RequestHandlers, this class builds a
* WS-I compliant Message Log file.
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/profile/impl/ProfileAssertionsReaderImpl.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/profile/impl/ProfileAssertionsReaderImpl.java
index 3b2a9d9..db95949 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/profile/impl/ProfileAssertionsReaderImpl.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/profile/impl/ProfileAssertionsReaderImpl.java
@@ -10,12 +10,17 @@
*******************************************************************************/
package org.eclipse.wst.wsi.internal.core.profile.impl;
+import java.io.IOException;
import java.io.Reader;
+import java.net.URL;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.List;
import java.util.TreeMap;
+import org.eclipse.wst.common.uriresolver.internal.provisional.URIResolver;
+import org.eclipse.wst.wsi.internal.WSITestToolsEclipseProperties;
+import org.eclipse.wst.wsi.internal.WSITestToolsProperties;
import org.eclipse.wst.wsi.internal.core.WSIConstants;
import org.eclipse.wst.wsi.internal.core.WSIException;
import org.eclipse.wst.wsi.internal.core.profile.EntryTypeList;
@@ -27,7 +32,9 @@
import org.eclipse.wst.wsi.internal.core.util.Utils;
import org.eclipse.wst.wsi.internal.core.xml.XMLUtils;
import org.xml.sax.Attributes;
+import org.xml.sax.EntityResolver;
import org.xml.sax.InputSource;
+import org.xml.sax.SAXException;
import org.xml.sax.XMLReader;
import org.xml.sax.helpers.DefaultHandler;
@@ -93,7 +100,32 @@
// Set content handler to inner class
reader.setContentHandler(new ProfileAssertionsHandler());
+
+ if(WSITestToolsProperties.getEclipseContext())
+ {
+ EntityResolver resolver = new EntityResolver(){
+ public InputSource resolveEntity(String publicId, String systemId) throws SAXException, IOException {
+ URIResolver resolver = WSITestToolsEclipseProperties.getURIResolver();
+ String uri = resolver.resolve("", publicId, systemId);
+ String physicalLocation = resolver.resolvePhysicalLocation("", publicId, uri);
+ InputSource is = null;
+ try
+ {
+ URL url = new URL(physicalLocation);
+ is = new InputSource(uri);
+ is.setByteStream(url.openStream());
+ }
+ catch(Exception e)
+ {
+ // Do nothing if opening the stream fails.
+ }
+ return is;
+ }
+
+ };
+ reader.setEntityResolver(resolver);
+ }
// Parse profile definition file
reader.parse(inputSource);
}
@@ -107,15 +139,24 @@
//Check to see if the version of test asssertion document is supported
if (!Utils.isValidProfileTADVersion(profileAssertions))
{
- throw new WSIException(
+ String tadVersion = profileAssertions.getTADVersion();
+ if(tadVersion != null)
+ {
+ String tadName = profileAssertions.getTADName();
+ throw new WSIException(
"\nVersion "
- + profileAssertions.getTADVersion()
+ + tadVersion
+ " of the \""
- + profileAssertions.getTADName()
+ + tadName
+ "\"\n"
+ "document is not compatible with this version of"
+ "\n"
+ "the test tools.");
+ }
+ else
+ {
+ throw new WSIException("WS-I validation was unable to run. Unable to read the test assertion document.");
+ }
}
}
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/HttpHeadersValidator.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/HttpHeadersValidator.java
index f74694f..3c68a88 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/HttpHeadersValidator.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/HttpHeadersValidator.java
@@ -15,13 +15,12 @@
import java.net.MalformedURLException;
import java.net.URL;
import java.text.ParseException;
+import java.text.SimpleDateFormat;
import java.util.Locale;
import java.util.StringTokenizer;
import sun.net.www.MessageHeader;
-import com.ibm.icu.text.SimpleDateFormat;
-
/**
* This class checks HTTP request headers about RFC 2616.
*
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/Utils.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/Utils.java
index 85882d2..4540725 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/Utils.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/core/util/Utils.java
@@ -25,12 +25,14 @@
import java.net.InetAddress;
import java.net.MalformedURLException;
import java.net.URL;
+import java.text.SimpleDateFormat;
import java.util.ArrayList;
import java.util.Collection;
import java.util.Date;
import java.util.Iterator;
import java.util.ResourceBundle;
import java.util.StringTokenizer;
+import java.util.TimeZone;
import java.util.Vector;
import org.eclipse.wst.wsi.internal.core.WSIConstants;
@@ -42,9 +44,6 @@
import org.eclipse.wst.wsi.internal.core.profile.ProfileAssertions;
import org.eclipse.wst.wsi.internal.core.xml.XMLUtils;
-import com.ibm.icu.text.SimpleDateFormat;
-import com.ibm.icu.util.TimeZone;
-
/**
* General set of utilities.
*/
diff --git a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/validate/wsdl/WSDLValidator.java b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/validate/wsdl/WSDLValidator.java
index 997ad20..2c477b7 100644
--- a/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/validate/wsdl/WSDLValidator.java
+++ b/bundles/org.eclipse.wst.wsi/src/org/eclipse/wst/wsi/internal/validate/wsdl/WSDLValidator.java
@@ -9,11 +9,9 @@
* IBM - Initial API and implementation
*******************************************************************************/
package org.eclipse.wst.wsi.internal.validate.wsdl;
-import java.text.MessageFormat;
import java.util.Collection;
import java.util.Iterator;
import java.util.List;
-import java.util.Locale;
import java.util.ResourceBundle;
import javax.wsdl.Binding;
@@ -58,7 +56,7 @@
protected final int ERROR = 2;
protected final int WARNING = 1;
- protected ResourceBundle resourcebundle = null;
+ protected MessageGenerator messagegenerator = null;
protected boolean wsiValid = false;
/**
@@ -66,7 +64,6 @@
*/
public WSDLValidator()
{
- resourcebundle = ResourceBundle.getBundle("wsivalidate", Locale.getDefault());
}
/* (non-Javadoc)
@@ -126,7 +123,7 @@
try
{
//WSDLFactory factory = WSDLFactory.newInstance();
- ValidationInfoImpl vali = new ValidationInfoImpl(valInfo.getFileURI(), new MessageGenerator(resourcebundle));
+ ValidationInfoImpl vali = new ValidationInfoImpl(valInfo.getFileURI(), messagegenerator);
vali.setURIResolver((URIResolver)valInfo.getURIResolver());
WSDLReaderImpl reader = new WSDLReaderImpl(new WSDL11ValidationInfoImpl(vali));
WSDLDocument[] docs = reader.readWSDL(uri, domModel);
@@ -143,7 +140,7 @@
}
catch(WSDLException e)
{
- throw new ValidateWSDLException(MessageFormat.format(resourcebundle.getString(_EXC_UNABLE_TO_VALIDATE_WSI), new Object[] { uri }));
+ throw new ValidateWSDLException(messagegenerator.getString(_EXC_UNABLE_TO_VALIDATE_WSI,uri));
}
if (definition != null && valInfo != null)
@@ -299,7 +296,7 @@
catch (WSIAnalyzerException e)
{
// TODO: Add code to log error
- System.out.println("Unable to run WS-I WSDL conformance check.\n" + e);
+ valInfo.addWarning(WSIConstants.WSI_PREFIX + "A problem occured while running the WS-I WSDL conformance check: " + e, 1, 0, valInfo.getFileURI());
}
}
}
@@ -366,6 +363,14 @@
}
/**
+ * @see org.eclipse.wsdl.validate.controller.IWSDLValidator#setResourceBundle(java.util.ResourceBundle)
+ */
+ public void setResourceBundle(ResourceBundle rb)
+ {
+ messagegenerator = new MessageGenerator(rb);
+ }
+
+ /**
* @see org.eclipse.wsdl.validate.controller.IWSDLValidator#isValid()
*/
public boolean isValid()
@@ -373,11 +378,4 @@
return wsiValid;
}
- public void setResourceBundle(ResourceBundle rb) {
- // Not used.
-
- }
-
-
-
}
diff --git a/docs/org.eclipse.jst.ws.doc.user/ref/rwspref.html b/docs/org.eclipse.jst.ws.doc.user/ref/rwspref.html
index bbdafc3..94e72b5 100644
--- a/docs/org.eclipse.jst.ws.doc.user/ref/rwspref.html
+++ b/docs/org.eclipse.jst.ws.doc.user/ref/rwspref.html
@@ -22,7 +22,7 @@
<h1 class="topictitle1">Web services preferences</h1>
<div><div class="section"><div class="p">To set any of the Web services preferences, follow these steps:<ol><li>Click <span class="uicontrol">Window > Preferences</span> to open the Preferences
notebook.</li>
-<li>Expand <span class="uicontrol">Web services</span>, and click the preference
+<li>Expand <span class="uicontrol">Web services</span> or <span class="uicontrol">Web and XML</span>, and click the preference
category that you want to set</li>
<li>Select the check boxes that you want to set as the default when creating
your Web service.</li>
@@ -39,6 +39,17 @@
dialogs by selecting "Do not show this dialog again" on the first page of
a Web services wizard, you can undo your change by clearing the check box
beside the dialog that you have chosen to hide.</dd>
+<dt class="dlterm">Profile Compliance and Validation</dt>
+<dd>The Profile Compliance preferences allow you to select your level of compliance
+with the WS-I Simple SOAP Binding Profile (SSBP) and WS-I Attachement Profile
+(AP). Note: if you change the level of WS-I compliance while WS-I incompliances
+are listed in the Task view, the Task view will not be automatically updated.
+The workspace must be revalidated before the warnings will be removed from
+the Task view. For more information on WS-I, refer to: <a href="http://www.ws-i.org/" target="_blank">http://www.ws-i.org/</a>
+<p>For validation preferences, you can choose whether
+or not WSDL files consumed by the Web services wizards are validated, and
+whether or not the WSDL validation must complete before the wizard will move
+to the next step.</p></dd>
<dt class="dlterm">Project Topology</dt>
<dd>The Project Topology preferences allow you to:<ul><li>Select the default client project type that the Web services wizards will
create when generating a Web service client. You can also set the order in
@@ -80,13 +91,6 @@
<dd>When creating a WSDL file in the WSDL editor, you can set the default
target namespace. If you do not select to change the default, your WSDL file
will have http://tempuri.org as its target namespace.</dd>
-<dt class="dlterm">WS-I Compliance</dt>
-<dd>The WS-I Compliance preferences allow you to select your level of compliance
-with the WS-I Simple SOAP Binding Profile (SSBP) and WS-I Attachement Profile
-(AP). Note: if you change the level of WS-I compliance while WS-I incompliances
-are listed in the Task view, the Task view will not be automatically updated.
-The workspace must be revalidated before the warnings will be removed from
-the Task view. For more information on WS-I, refer to: </dd>
</dl>
</div>
</div>
diff --git a/docs/org.eclipse.jst.ws.doc.user/tasks/twsicomply.html b/docs/org.eclipse.jst.ws.doc.user/tasks/twsicomply.html
index 6e4099b..fe21e4d 100644
--- a/docs/org.eclipse.jst.ws.doc.user/tasks/twsicomply.html
+++ b/docs/org.eclipse.jst.ws.doc.user/tasks/twsicomply.html
@@ -50,7 +50,7 @@
<ol><li><span>From the <strong>Window</strong> menu, select <strong>Preferences</strong>.</span></li>
<li><span>Select <strong>Web Services</strong> from the component tree on the left-hand
side of the panel.</span></li>
-<li><span>Under WS-I compliance, select the level of compliance you want
+<li><span>Under Profile Compliance and Validation, select the level of compliance you want
from the drop-down lists.</span></li>
<li><span>Click <strong>Apply</strong>, then click <strong>OK</strong>.</span></li>
</ol>
@@ -60,9 +60,9 @@
<div><div class="section"><p>To set the level of WS-I compliance for a project:</p>
</div>
<ol><li><span>In the Project Navigator, right click and select <strong>Properties</strong>.</span></li>
-<li><span>Select <strong>WS-I Compliance</strong> from the component tree on the left-hand
+<li><span>Select <strong>Profile Compliance and Validation</strong> from the component tree on the left-hand
side of the panel.</span></li>
-<li><span>Under WS-I compliance, select the level of compliance you want
+<li><span>Select the level of compliance you want
from the drop-down lists, or select to have the project share the same level
of WS-I compliance as the workspace</span></li>
<li><span>Click <strong>Apply</strong>, then click <strong>OK</strong>.</span></li>
diff --git a/features/org.eclipse.wst.ws_core.feature/feature.xml b/features/org.eclipse.wst.ws_core.feature/feature.xml
index 9db2df8..95531f6 100644
--- a/features/org.eclipse.wst.ws_core.feature/feature.xml
+++ b/features/org.eclipse.wst.ws_core.feature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_core.feature"
label="WST WS Core Feature"
- version="1.0.100.qualifier"
+ version="1.0.2.qualifier"
provider-name="Eclipse.org">
<description>
@@ -18,12 +18,12 @@
<import feature="org.apache.wsil4j.feature" version="1.0.0" match="greaterOrEqual"/>
<import feature="org.uddi4j.feature" version="2.0.3" match="greaterOrEqual"/>
<import feature="org.wsdl4j.feature" version="1.4.0" match="greaterOrEqual"/>
- <import feature="org.apache.xerces.feature" version="2.8.0" match="greaterOrEqual"/>
- <import feature="org.eclipse.platform" version="3.2" match="equivalent"/>
- <import feature="org.eclipse.emf" version="2.2" match="equivalent"/>
- <import feature="org.eclipse.wst.common_core.feature" version="1.0.0" match="greaterOrEqual"/>
- <import feature="org.eclipse.wst.server_core.feature" version="1.0.0" match="greaterOrEqual"/>
- <import feature="org.eclipse.xsd" version="2.2" match="equivalent"/>
+ <import feature="org.apache.xerces.feature" version="2.7.0" match="greaterOrEqual"/>
+ <import feature="org.eclipse.platform" version="3.1.1" match="equivalent"/>
+ <import feature="org.eclipse.emf" version="2.1.1" match="equivalent"/>
+ <import feature="org.eclipse.wst.common_core.feature" version="1.0.2" match="equivalent"/>
+ <import feature="org.eclipse.wst.server_core.feature" version="1.0.2" match="equivalent"/>
+ <import feature="org.eclipse.xsd" version="2.1.1" match="equivalent"/>
</requires>
<plugin
diff --git a/features/org.eclipse.wst.ws_core.feature/sourceTemplateFeature/feature.xml b/features/org.eclipse.wst.ws_core.feature/sourceTemplateFeature/feature.xml
index 8a1b8c8..b859166 100644
--- a/features/org.eclipse.wst.ws_core.feature/sourceTemplateFeature/feature.xml
+++ b/features/org.eclipse.wst.ws_core.feature/sourceTemplateFeature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_core.feature.source"
label="%featureName"
- version="1.0.1.qualifier"
+ version="1.0.2.qualifier"
provider-name="%providerName">
<description>
diff --git a/features/org.eclipse.wst.ws_sdk.feature/feature.xml b/features/org.eclipse.wst.ws_sdk.feature/feature.xml
index 4cb2290..2b4a1b3 100644
--- a/features/org.eclipse.wst.ws_sdk.feature/feature.xml
+++ b/features/org.eclipse.wst.ws_sdk.feature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_sdk.feature"
label="WST WS SDK Feature"
- version="1.0.100.qualifier"
+ version="1.0.2.qualifier"
provider-name="Eclipse.org">
<description>
diff --git a/features/org.eclipse.wst.ws_ui.feature/feature.xml b/features/org.eclipse.wst.ws_ui.feature/feature.xml
index 4d4ca25..1ff775a 100644
--- a/features/org.eclipse.wst.ws_ui.feature/feature.xml
+++ b/features/org.eclipse.wst.ws_ui.feature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_ui.feature"
label="WST WS UI Feature"
- version="1.0.100.qualifier"
+ version="1.0.2.qualifier"
provider-name="Eclipse.org">
<description>
@@ -22,8 +22,8 @@
version="0.0.0"/>
<requires>
- <import feature="org.eclipse.gef" version="3.2" match="equivalent"/>
- <import feature="org.eclipse.wst.ws_core.feature" version="1.0.0" match="greaterOrEqual"/>
+ <import feature="org.eclipse.gef" version="3.1.1" match="equivalent"/>
+ <import feature="org.eclipse.wst.ws_core.feature" version="1.0.2" match="equivalent"/>
</requires>
<plugin
diff --git a/features/org.eclipse.wst.ws_ui.feature/sourceTemplateFeature/feature.xml b/features/org.eclipse.wst.ws_ui.feature/sourceTemplateFeature/feature.xml
index 14892e6..e2ef151 100644
--- a/features/org.eclipse.wst.ws_ui.feature/sourceTemplateFeature/feature.xml
+++ b/features/org.eclipse.wst.ws_ui.feature/sourceTemplateFeature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_ui.feature.source"
label="Source for WST WS UI Feature"
- version="1.0.1.qualifier"
+ version="1.0.2.qualifier"
provider-name="Eclipse.org">
<description>
diff --git a/features/org.eclipse.wst.ws_userdoc.feature/feature.xml b/features/org.eclipse.wst.ws_userdoc.feature/feature.xml
index 657c962..fc00d92 100644
--- a/features/org.eclipse.wst.ws_userdoc.feature/feature.xml
+++ b/features/org.eclipse.wst.ws_userdoc.feature/feature.xml
@@ -2,7 +2,7 @@
<feature
id="org.eclipse.wst.ws_userdoc.feature"
label="User Documentation for WST WS Feature"
- version="1.0.100.qualifier"
+ version="1.0.2.qualifier"
provider-name="Eclipse.org">
<description>
diff --git a/tests/org.eclipse.jst.ws.tests.performance/META-INF/MANIFEST.MF b/tests/org.eclipse.jst.ws.tests.performance/META-INF/MANIFEST.MF
index 2ceabf2..276b0db 100644
--- a/tests/org.eclipse.jst.ws.tests.performance/META-INF/MANIFEST.MF
+++ b/tests/org.eclipse.jst.ws.tests.performance/META-INF/MANIFEST.MF
@@ -9,8 +9,7 @@
Bundle-Localization: plugin
Export-Package: org.eclipse.jst.ws.tests.axis.tomcat.v50.perfmsr,
org.eclipse.jst.ws.tests.performance,
- org.eclipse.jst.ws.tests.performance.plugin,
- org.eclipse.jst.ws.tests.performance.util
+ org.eclipse.jst.ws.tests.performance.plugin
Require-Bundle: org.eclipse.jst.ws,
org.eclipse.jst.j2ee.core,
org.eclipse.core.runtime,
diff --git a/tests/org.eclipse.wst.ws.tests/META-INF/MANIFEST.MF b/tests/org.eclipse.wst.ws.tests/META-INF/MANIFEST.MF
index fcf2369..1202009 100644
--- a/tests/org.eclipse.wst.ws.tests/META-INF/MANIFEST.MF
+++ b/tests/org.eclipse.wst.ws.tests/META-INF/MANIFEST.MF
@@ -23,8 +23,7 @@
org.eclipse.emf.ecore,
org.eclipse.emf.ecore.xmi
Eclipse-AutoStart: true
-Export-Package: org.eclipse.wst.ws.tests.data,
- org.eclipse.wst.ws.tests.plugin,
+Export-Package: org.eclipse.wst.ws.tests.plugin,
org.eclipse.wst.ws.tests.unittest,
org.eclipse.wst.ws.tests.util
Bundle-ClassPath: tests.jar
diff --git a/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/AllTestCases.java b/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/AllTestCases.java
index 5fee2e1..eadd168 100644
--- a/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/AllTestCases.java
+++ b/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/AllTestCases.java
@@ -33,8 +33,7 @@
{
TestSuite suite = new TestSuite();
- // Bug 123547 - comment out this test for now.
- // suite.addTest(InlineSchemaTest.suite());
+ suite.addTest(InlineSchemaTest.suite());
suite.addTest(LoadAndSerializationTest.suite());
suite.addTest(SemanticTest.suite());
suite.addTest(WSDLGenerationTest.suite());
diff --git a/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/WSDLEMFAPITest.java b/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/WSDLEMFAPITest.java
index ed994b2..1ddb8c4 100644
--- a/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/WSDLEMFAPITest.java
+++ b/tests/org.eclipse.wst.wsdl.tests/src/org/eclipse/wst/wsdl/tests/WSDLEMFAPITest.java
@@ -66,6 +66,7 @@
import org.eclipse.wst.wsdl.tests.util.DefinitionVisitor;
import org.eclipse.wst.wsdl.util.WSDLResourceImpl;
import org.eclipse.xsd.XSDPackage;
+import org.eclipse.xsd.XSDSchema;
import org.eclipse.xsd.util.XSDResourceFactoryImpl;
import org.w3c.dom.Element;
diff --git a/tests/org.eclipse.wst.wsi.tests/META-INF/MANIFEST.MF b/tests/org.eclipse.wst.wsi.tests/META-INF/MANIFEST.MF
index 267ff27..99997d5 100644
--- a/tests/org.eclipse.wst.wsi.tests/META-INF/MANIFEST.MF
+++ b/tests/org.eclipse.wst.wsi.tests/META-INF/MANIFEST.MF
@@ -16,4 +16,4 @@
org.eclipse.wst.command.env,
org.eclipse.wst.command.env.core
Eclipse-AutoStart: true
-Export-Package: org.eclipse.wst.wsi.tests.internal;x-internal:=true
+Export-Package: org.eclipse.wst.wsi.tests.internal