Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkchan2005-11-03 19:19:41 +0000
committerkchan2005-11-03 19:19:41 +0000
commitc2368171eba37b1dc77fa5e355628490f0633661 (patch)
tree1009c53c4e4ef39bcd4862496b0f8c5ac17ecf1c /bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java
parent84a249d3a6c984a641541214872eec2ff97bbd88 (diff)
downloadwebtools.webservices-c2368171eba37b1dc77fa5e355628490f0633661.tar.gz
webtools.webservices-c2368171eba37b1dc77fa5e355628490f0633661.tar.xz
webtools.webservices-c2368171eba37b1dc77fa5e355628490f0633661.zip
[95355] Remove use of internal JavaEMFNature.
Diffstat (limited to 'bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java')
-rw-r--r--bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java18
1 files changed, 9 insertions, 9 deletions
diff --git a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java
index 896e121c2..2a1041df3 100644
--- a/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java
+++ b/bundles/org.eclipse.jst.ws.consumption/src/org/eclipse/jst/ws/internal/consumption/command/common/JavaMofReflectionCommand.java
@@ -20,9 +20,12 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
import org.eclipse.emf.ecore.resource.ResourceSet;
-import org.eclipse.jem.internal.plugin.JavaEMFNature;
+import org.eclipse.jem.java.JavaClass;
import org.eclipse.jem.java.JavaHelpers;
import org.eclipse.jem.java.JavaRefFactory;
+import org.eclipse.jem.util.emf.workbench.nature.EMFNature;
+import org.eclipse.jem.workbench.utility.JemProjectUtilities;
+import org.eclipse.jst.ws.internal.common.JavaMOFUtils;
import org.eclipse.jst.ws.internal.common.ResourceUtils;
import org.eclipse.jst.ws.internal.consumption.plugin.WebServiceConsumptionPlugin;
import org.eclipse.wst.command.internal.env.core.common.StatusUtils;
@@ -93,14 +96,11 @@ public class JavaMofReflectionCommand extends AbstractDataModelOperation
if(clientProject == null || qname == null)
return StatusUtils.warningStatus( WebServiceConsumptionPlugin.getMessage("%MSG_WARN_UNABLE_TO_FIND_PROXY") );
- JavaEMFNature nature = (JavaEMFNature)JavaEMFNature.getRuntime(clientIProject);
- if(nature == null){
- try{
- nature = (JavaEMFNature)JavaEMFNature.createRuntime(clientIProject);
- }catch(CoreException exc){}
- }
- resourceSet = nature.getResourceSet();
- javaClass = JavaRefFactory.eINSTANCE.reflectType(qname,resourceSet);
+ try {
+ EMFNature nature = JemProjectUtilities.getJEM_EMF_Nature(clientIProject, true);
+ javaClass = JavaRefFactory.eINSTANCE.reflectType(qname, nature.getResourceSet());
+ } catch (CoreException e) {
+ }
return status;
}

Back to the top