Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 196954 | Differences between
and this patch

Collapse All | Expand All

(-)src/org/eclipse/jst/ws/internal/axis2/consumption/ui/preferences/Axis2RuntimePreferencePage.java (-3 / +12 lines)
Lines 25-30 Link Here
25
 * 20070827   188732 sandakith@wso2.com - Lahiru Sandakith, Restore defaults for preferences
25
 * 20070827   188732 sandakith@wso2.com - Lahiru Sandakith, Restore defaults for preferences
26
 * 20071030	  207618 zina@ca.ibm.com - Zina Mostafia, Page GUI sequence using tab is not correct ( violates Accessibility)
26
 * 20071030	  207618 zina@ca.ibm.com - Zina Mostafia, Page GUI sequence using tab is not correct ( violates Accessibility)
27
 * 20080522   233154 samindaw@wso2.com - Saminda Wijeratne, UI rendering problem where textboxes used as labels had white background
27
 * 20080522   233154 samindaw@wso2.com - Saminda Wijeratne, UI rendering problem where textboxes used as labels had white background
28
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
28
 *******************************************************************************/
29
 *******************************************************************************/
29
package org.eclipse.jst.ws.internal.axis2.consumption.ui.preferences;
30
package org.eclipse.jst.ws.internal.axis2.consumption.ui.preferences;
30
31
Lines 284-294 Link Here
284
	{
285
	{
285
		Axis2EmitterContext context = WebServiceAxis2CorePlugin.getDefault().getAxisEmitterContext();
286
		Axis2EmitterContext context = WebServiceAxis2CorePlugin.getDefault().getAxisEmitterContext();
286
287
287
		String[] databindingItems = {context.getServiceDatabinding().toUpperCase()};
288
		String[] databindingItems = {Axis2Constants.DATA_BINDING_ADB,Axis2Constants.DATA_BINDING_XMLBEANS};
288
		serviceDatabindingCombo.setItems(databindingItems);
289
		serviceDatabindingCombo.setItems(databindingItems);
289
		serviceDatabindingCombo.select(0);
290
		int selected = serviceDatabindingCombo.indexOf(context.getServiceDatabinding().toUpperCase());
291
		if (selected==-1)
292
			serviceDatabindingCombo.select(0);
293
		else
294
			serviceDatabindingCombo.select(selected);
290
		clientDatabindingCombo.setItems(databindingItems);
295
		clientDatabindingCombo.setItems(databindingItems);
291
		clientDatabindingCombo.select(0);
296
		selected = clientDatabindingCombo.indexOf(context.getClientDatabinding().toUpperCase());
297
		if (selected==-1)
298
			clientDatabindingCombo.select(0);
299
		else
300
			clientDatabindingCombo.select(selected);
292
301
293
		generateServerSideInterfaceCheckBoxButton.setSelection( context.isServiceInterfaceSkeleton());
302
		generateServerSideInterfaceCheckBoxButton.setSelection( context.isServiceInterfaceSkeleton());
294
		generateAllCheckBoxButton.setSelection(context.isServiceGenerateAll());
303
		generateAllCheckBoxButton.setSelection(context.isServiceGenerateAll());
(-)src/org/eclipse/jst/ws/axis2/core/utils/Axis2CoreUtils.java (+28 lines)
Lines 16-21 Link Here
16
 * 20070824   200515 sandakith@wso2.com - Lahiru Sandakith, NON-NLS move to seperate file
16
 * 20070824   200515 sandakith@wso2.com - Lahiru Sandakith, NON-NLS move to seperate file
17
 * 20080625   210817 samindaw@wso2.com - Saminda Wijeratne, Setting the proxyBean and proxyEndPoint values - Refactoring
17
 * 20080625   210817 samindaw@wso2.com - Saminda Wijeratne, Setting the proxyBean and proxyEndPoint values - Refactoring
18
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
18
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
19
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
19
 *******************************************************************************/
20
 *******************************************************************************/
20
package org.eclipse.jst.ws.axis2.core.utils;
21
package org.eclipse.jst.ws.axis2.core.utils;
21
22
Lines 28-38 Link Here
28
import java.net.URL;
29
import java.net.URL;
29
import java.util.ArrayList;
30
import java.util.ArrayList;
30
import java.util.HashMap;
31
import java.util.HashMap;
32
import java.util.LinkedList;
33
import java.util.List;
31
34
32
import javax.xml.parsers.DocumentBuilder;
35
import javax.xml.parsers.DocumentBuilder;
33
import javax.xml.parsers.DocumentBuilderFactory;
36
import javax.xml.parsers.DocumentBuilderFactory;
34
import javax.xml.parsers.ParserConfigurationException;
37
import javax.xml.parsers.ParserConfigurationException;
35
38
39
import org.eclipse.core.resources.IFolder;
36
import org.eclipse.core.resources.IProject;
40
import org.eclipse.core.resources.IProject;
37
import org.eclipse.core.resources.ResourcesPlugin;
41
import org.eclipse.core.resources.ResourcesPlugin;
38
import org.eclipse.core.runtime.CoreException;
42
import org.eclipse.core.runtime.CoreException;
Lines 54-59 Link Here
54
	private static boolean alreadyComputedTempAxis2Directory = false;
58
	private static boolean alreadyComputedTempAxis2Directory = false;
55
	private static String tempAxis2Dir = null;
59
	private static String tempAxis2Dir = null;
56
	
60
	
61
	public static void addResourcesFolderAsClassPath(IProject project){
62
		try {
63
			IJavaProject javaProject = (IJavaProject)project.getNature(JavaCore.NATURE_ID);
64
			IClasspathEntry[] rawClasspath = javaProject.getRawClasspath();
65
			List list = new LinkedList(java.util.Arrays.asList(rawClasspath));
66
				String resourceName = "resources";
67
				IFolder resourcesFolder = project.getFolder(resourceName);
68
				boolean isAlreadyAdded=false;
69
				for(IClasspathEntry cpe:rawClasspath){
70
					isAlreadyAdded=cpe.getPath().toOSString().equals(resourcesFolder.getFullPath().toOSString());
71
					if (isAlreadyAdded) break;
72
				}
73
				if (!isAlreadyAdded){
74
					IClasspathEntry jarEntry = JavaCore.newLibraryEntry(resourcesFolder.getFullPath(),null,null);
75
					list.add(jarEntry);
76
				}
77
			IClasspathEntry[] newClasspath = (IClasspathEntry[])list.toArray(new IClasspathEntry[0]);
78
			javaProject.setRawClasspath(newClasspath,null);
79
		} catch (CoreException e) {
80
			e.printStackTrace();
81
		}
82
83
	}
84
57
	public static String tempAxis2Directory() {
85
	public static String tempAxis2Directory() {
58
		if (!alreadyComputedTempAxis2Directory){
86
		if (!alreadyComputedTempAxis2Directory){
59
			String[] nodes = {Axis2Constants.DIR_DOT_METADATA,
87
			String[] nodes = {Axis2Constants.DIR_DOT_METADATA,
(-)src/org/eclipse/jst/ws/axis2/core/constant/Axis2Constants.java (-1 / +4 lines)
Lines 14-19 Link Here
14
 * 20071029   206967 sandakith@wso2.com - Lahiru Sandakith
14
 * 20071029   206967 sandakith@wso2.com - Lahiru Sandakith
15
 * 20080521   231098 sandakith@wso2.com - Lahiru Sandakith, Fix for Axis2 1.4 dependency chenge
15
 * 20080521   231098 sandakith@wso2.com - Lahiru Sandakith, Fix for Axis2 1.4 dependency chenge
16
 * 20080604   193371 samindaw@wso2.com - Saminda Wijeratne, creating a function to validate services.xml
16
 * 20080604   193371 samindaw@wso2.com - Saminda Wijeratne, creating a function to validate services.xml
17
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
17
 *******************************************************************************/
18
 *******************************************************************************/
18
package org.eclipse.jst.ws.axis2.core.constant;
19
package org.eclipse.jst.ws.axis2.core.constant;
19
20
Lines 61-66 Link Here
61
	public static final String AXIS2_PROJECT="org.eclipse.jst.ws.axis2";		//$NON-NLS-1$
62
	public static final String AXIS2_PROJECT="org.eclipse.jst.ws.axis2";		//$NON-NLS-1$
62
	public static final String CODEGEN_RESULTS="codegen";						//$NON-NLS-1$
63
	public static final String CODEGEN_RESULTS="codegen";						//$NON-NLS-1$
63
	public static final String DATA_BINDING_ADB="ADB";							//$NON-NLS-1$
64
	public static final String DATA_BINDING_ADB="ADB";							//$NON-NLS-1$
65
	public static final String DATA_BINDING_XMLBEANS="XMLBEANS";						//$NON-NLS-1$
64
	public static final String DATA_BINDING_NONE="NONE";						//$NON-NLS-1$
66
	public static final String DATA_BINDING_NONE="NONE";						//$NON-NLS-1$
65
	public static final String SKELETON_SUFFIX="Skeleton.java";					//$NON-NLS-1$
67
	public static final String SKELETON_SUFFIX="Skeleton.java";					//$NON-NLS-1$
66
	public static final String RESOURCE_FOLDER="resources";						//$NON-NLS-1$
68
	public static final String RESOURCE_FOLDER="resources";						//$NON-NLS-1$
Lines 91-97 Link Here
91
        "annogen",
93
        "annogen",
92
        "backport-util",
94
        "backport-util",
93
        "mex-impl",
95
        "mex-impl",
94
        "mail"
96
        "mail",
97
        "xmlbeans"
95
	};
98
	};
96
}	
99
}	
97
	
100
	
(-)src/org/eclipse/jst/ws/axis2/consumption/core/command/Axis2ClientCodegenCommand.java (-2 / +10 lines)
Lines 22-27 Link Here
22
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again 
22
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again 
23
 * 20080616   237363 samindaw@wso2.com - Saminda Wijeratne, get ResourceContext from environment instead of preference
23
 * 20080616   237363 samindaw@wso2.com - Saminda Wijeratne, get ResourceContext from environment instead of preference
24
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
24
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
25
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
25
*******************************************************************************/
26
*******************************************************************************/
26
package org.eclipse.jst.ws.axis2.consumption.core.command;
27
package org.eclipse.jst.ws.axis2.consumption.core.command;
27
28
Lines 31-36 Link Here
31
import java.util.Map;
32
import java.util.Map;
32
33
33
import org.eclipse.core.commands.ExecutionException;
34
import org.eclipse.core.commands.ExecutionException;
35
import org.eclipse.core.resources.IFolder;
36
import org.eclipse.core.resources.IProject;
34
import org.eclipse.core.resources.ResourcesPlugin;
37
import org.eclipse.core.resources.ResourcesPlugin;
35
import org.eclipse.core.runtime.IAdaptable;
38
import org.eclipse.core.runtime.IAdaptable;
36
import org.eclipse.core.runtime.IProgressMonitor;
39
import org.eclipse.core.runtime.IProgressMonitor;
Lines 224-230 Link Here
224
	    							currentDynamicWebProjectDir, 
227
	    							currentDynamicWebProjectDir, 
225
	    							monitor, 
228
	    							monitor, 
226
	    							statusHandler);
229
	    							statusHandler);
227
      
230
	    
231
	    IProject project = FacetContainerUtils.getProjectName(model.getWebProjectName());
232
	    IFolder folder = project.getFolder("resources");
233
	    if (folder.exists()){
234
	    	Axis2CoreUtils.addResourcesFolderAsClassPath(project);
235
	    }
228
	} catch (Exception e) {
236
	} catch (Exception e) {
229
		status = StatusUtils.errorStatus(NLS.bind(
237
		status = StatusUtils.errorStatus(NLS.bind(
230
											Axis2ConsumptionUIMessages.ERROR_CODEGEN_EXCEPTION,
238
											Axis2ConsumptionUIMessages.ERROR_CODEGEN_EXCEPTION,
Lines 244-248 Link Here
244
252
245
		return status;
253
		return status;
246
	}
254
	}
247
255
	
248
}
256
}
(-)src/org/eclipse/jst/ws/axis2/creation/core/command/Axis2WSDL2JavaCommand.java (-2 / +8 lines)
Lines 21-26 Link Here
21
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
21
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
22
 * 20080616   237363 samindaw@wso2.com - Saminda Wijeratne, get ResourceContext from environment instead of preference
22
 * 20080616   237363 samindaw@wso2.com - Saminda Wijeratne, get ResourceContext from environment instead of preference
23
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
23
 * 20080924   247929 samindaw@wso2.com - Saminda Wijeratne, source folder not correctly set
24
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
24
 *******************************************************************************/
25
 *******************************************************************************/
25
package org.eclipse.jst.ws.axis2.creation.core.command;
26
package org.eclipse.jst.ws.axis2.creation.core.command;
26
27
Lines 30-35 Link Here
30
import java.util.Map;
31
import java.util.Map;
31
32
32
import org.eclipse.core.commands.ExecutionException;
33
import org.eclipse.core.commands.ExecutionException;
34
import org.eclipse.core.resources.IFolder;
35
import org.eclipse.core.resources.IProject;
33
import org.eclipse.core.runtime.IAdaptable;
36
import org.eclipse.core.runtime.IAdaptable;
34
import org.eclipse.core.runtime.IProgressMonitor;
37
import org.eclipse.core.runtime.IProgressMonitor;
35
import org.eclipse.core.runtime.IStatus;
38
import org.eclipse.core.runtime.IStatus;
Lines 209-215 Link Here
209
	    							monitor, 
212
	    							monitor, 
210
	    							statusHandler);
213
	    							statusHandler);
211
214
212
        
215
	    IProject project = FacetContainerUtils.getProjectName(model.getWebProjectName());
216
	    IFolder folder = project.getFolder("resources");
217
	    if (folder.exists()){
218
	    	Axis2CoreUtils.addResourcesFolderAsClassPath(project);
219
	    }
213
	} catch (Exception e) {
220
	} catch (Exception e) {
214
		status = StatusUtils.errorStatus(NLS.bind(
221
		status = StatusUtils.errorStatus(NLS.bind(
215
											Axis2CreationUIMessages.ERROR_CODEGEN_EXCEPTION,
222
											Axis2CreationUIMessages.ERROR_CODEGEN_EXCEPTION,
Lines 230-234 Link Here
230
		
237
		
231
		return status;
238
		return status;
232
	}
239
	}
233
234
}
240
}
(-)src/org/eclipse/jst/ws/internal/axis2/consumption/ui/widgets/Axis2ProxyWidget.java (-2 / +7 lines)
Lines 20-25 Link Here
20
 * 20071030	  207618 zina@ca.ibm.com - Zina Mostafia, Page GUI sequence using tab is not correct ( violates Accessibility)
20
 * 20071030	  207618 zina@ca.ibm.com - Zina Mostafia, Page GUI sequence using tab is not correct ( violates Accessibility)
21
 * 20080319   207616 makandre@ca.ibm.com - Andrew Mak, Table in Axis2 Web Service Skeleton Java Bean Configuration Page not Accessible
21
 * 20080319   207616 makandre@ca.ibm.com - Andrew Mak, Table in Axis2 Web Service Skeleton Java Bean Configuration Page not Accessible
22
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
22
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
23
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
23
 *******************************************************************************/
24
 *******************************************************************************/
24
package org.eclipse.jst.ws.internal.axis2.consumption.ui.widgets;
25
package org.eclipse.jst.ws.internal.axis2.consumption.ui.widgets;
25
26
Lines 136-142 Link Here
136
		// Databinding
137
		// Databinding
137
		databindingTypeCombo = uiUtils.createCombo(topComp, Axis2ConsumptionUIMessages.LABEL_DATABINDING_CAPTION, null, null, SWT.READ_ONLY);
138
		databindingTypeCombo = uiUtils.createCombo(topComp, Axis2ConsumptionUIMessages.LABEL_DATABINDING_CAPTION, null, null, SWT.READ_ONLY);
138
		fillDatabinderCombo();
139
		fillDatabinderCombo();
139
		databindingTypeCombo.select(0);
140
		databindingTypeCombo.addSelectionListener(new SelectionListener() {
140
		databindingTypeCombo.addSelectionListener(new SelectionListener() {
141
			public void widgetSelected(SelectionEvent e) {
141
			public void widgetSelected(SelectionEvent e) {
142
				model.setDatabindingType(databindingTypeCombo.getText());
142
				model.setDatabindingType(databindingTypeCombo.getText());
Lines 389-396 Link Here
389
	 */
389
	 */
390
	private void fillDatabinderCombo() {
390
	private void fillDatabinderCombo() {
391
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_ADB);
391
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_ADB);
392
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_XMLBEANS);
392
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_NONE);
393
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_NONE);
393
		databindingTypeCombo.select(0);
394
		int selected = databindingTypeCombo.indexOf(context.getClientDatabinding().toUpperCase());
395
		if (selected==-1)
396
			databindingTypeCombo.select(0);
397
		else
398
			databindingTypeCombo.select(selected);
394
	}
399
	}
395
	
400
	
396
	private void populateModel() {
401
	private void populateModel() {
(-)src/org/eclipse/jst/ws/internal/axis2/creation/ui/widgets/skeleton/WSDL2JAVASkelConfigWidget.java (-2 / +7 lines)
Lines 18-23 Link Here
18
 * 20070824   200515 sandakith@wso2.com - Lahiru Sandakith, NON-NLS move to seperate file
18
 * 20070824   200515 sandakith@wso2.com - Lahiru Sandakith, NON-NLS move to seperate file
19
 * 20080319   207616 makandre@ca.ibm.com - Andrew Mak, Table in Axis2 Web Service Skeleton Java Bean Configuration Page not Accessible
19
 * 20080319   207616 makandre@ca.ibm.com - Andrew Mak, Table in Axis2 Web Service Skeleton Java Bean Configuration Page not Accessible
20
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
20
 * 20080621   200069 samindaw@wso2.com - Saminda Wijeratne, saving the retrieved WSDL so no need to retrieve it again
21
 * 20090307   196954 samindaw@wso2.com - Saminda Wijeratne, Support XMLBeans data binding
21
 *******************************************************************************/
22
 *******************************************************************************/
22
package org.eclipse.jst.ws.internal.axis2.creation.ui.widgets.skeleton;
23
package org.eclipse.jst.ws.internal.axis2.creation.ui.widgets.skeleton;
23
24
Lines 148-154 Link Here
148
		databindingTypeCombo = new Combo(mainComp, SWT.DROP_DOWN | SWT.BORDER | SWT.READ_ONLY);
149
		databindingTypeCombo = new Combo(mainComp, SWT.DROP_DOWN | SWT.BORDER | SWT.READ_ONLY);
149
		databindingTypeCombo.setLayoutData(gd);
150
		databindingTypeCombo.setLayoutData(gd);
150
		fillDatabinderCombo();
151
		fillDatabinderCombo();
151
		databindingTypeCombo.select(0);
152
		databindingTypeCombo.addSelectionListener(new SelectionListener() {
152
		databindingTypeCombo.addSelectionListener(new SelectionListener() {
153
			public void widgetSelected(SelectionEvent e) {
153
			public void widgetSelected(SelectionEvent e) {
154
				model.setDatabindingType(databindingTypeCombo.getText());
154
				model.setDatabindingType(databindingTypeCombo.getText());
Lines 457-464 Link Here
457
	 */
457
	 */
458
	private void fillDatabinderCombo() {
458
	private void fillDatabinderCombo() {
459
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_ADB);
459
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_ADB);
460
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_XMLBEANS);
460
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_NONE);
461
		databindingTypeCombo.add(Axis2Constants.DATA_BINDING_NONE);
461
		databindingTypeCombo.select(0);
462
		int selected = databindingTypeCombo.indexOf(context.getServiceDatabinding().toUpperCase());
463
		if (selected==-1)
464
			databindingTypeCombo.select(0);
465
		else
466
			databindingTypeCombo.select(selected);
462
	}
467
	}
463
	
468
	
464
	
469
	

Return to bug 196954