geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From shiv...@apache.org
Subject svn commit: r634164 [11/12] - in /geronimo/devtools/eclipse-plugin/trunk: features/org.apache.geronimo.v21.feature/ plugins/ plugins/org.apache.geronimo.deployment.v11.jaxbmodel/ plugins/org.apache.geronimo.deployment.v11.jaxbmodel/META-INF/ plugins/or...
Date Thu, 06 Mar 2008 04:58:35 GMT
Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/internal/EMFEditorContext.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/internal/EMFEditorContext.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/internal/EMFEditorContext.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/internal/EMFEditorContext.java Wed Mar  5 20:58:28 2008
@@ -16,27 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.internal;
 
-import java.util.ArrayList;
-import java.util.List;
-
-import org.apache.geronimo.xml.ns.deployment.provider.DeploymentItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.j2ee.application.client.provider.ClientItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.j2ee.application.provider.ApplicationItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.j2ee.connector.provider.ConnectorItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.j2ee.web.provider.WebItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.naming.provider.NamingItemProviderAdapterFactory;
-import org.apache.geronimo.xml.ns.security.provider.SecurityItemProviderAdapterFactory;
-import org.eclipse.emf.common.notify.impl.AdapterFactoryImpl;
-import org.eclipse.emf.edit.provider.ComposedAdapterFactory;
-import org.openejb.xml.ns.openejb.jar.provider.JarItemProviderAdapterFactory;
-import org.openejb.xml.ns.pkgen.provider.PkgenItemProviderAdapterFactory;
 
 public class EMFEditorContext {
 	
-	private static ComposedAdapterFactory factory;
+//	private static ComposedAdapterFactory factory;
 
 	static {
-		List<AdapterFactoryImpl> factories = new ArrayList<AdapterFactoryImpl>();
+/*		List<AdapterFactoryImpl> factories = new ArrayList<AdapterFactoryImpl>();
 		factories.add(new DeploymentItemProviderAdapterFactory());
 		factories.add(new ClientItemProviderAdapterFactory());
 		factories.add(new ApplicationItemProviderAdapterFactory());
@@ -47,10 +33,11 @@
 		factories.add(new JarItemProviderAdapterFactory());
 		factories.add(new PkgenItemProviderAdapterFactory());
 		factory = new ComposedAdapterFactory(factories);
+*/
 	}
 
-	public static ComposedAdapterFactory getFactory() {
-		return factory;
-	}
+//	public static ComposedAdapterFactory getFactory() {
+//		return factory;
+//	}
 
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/DeploymentPage.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/DeploymentPage.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/DeploymentPage.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/DeploymentPage.java Wed Mar  5 20:58:28 2008
@@ -16,19 +16,22 @@
  */
 package org.apache.geronimo.st.v21.ui.pages;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.pages.AbstractGeronimoFormPage;
+import org.apache.geronimo.st.v21.core.jaxb.JAXBModelUtils;
 import org.apache.geronimo.st.v21.ui.sections.DependencySection;
 import org.apache.geronimo.st.v21.ui.sections.GBeanSection;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.EnvironmentType;
 import org.eclipse.ui.forms.IManagedForm;
 import org.eclipse.ui.forms.editor.FormEditor;
 
 public class DeploymentPage extends AbstractGeronimoFormPage {
 	
-	public EReference environment;
+//	public EnvironmentType environment;
 	
-	public EReference gbeanERef;
+	public JAXBElement gbeanERef;
 
 	public DeploymentPage(FormEditor editor, String id, String title) {
 		super(editor, id, title);
@@ -40,8 +43,8 @@
 	 * @see org.apache.geronimo.ui.pages.AbstractGeronimoFormPage#fillBody(org.eclipse.ui.forms.IManagedForm)
 	 */
 	protected void fillBody(IManagedForm managedForm) {
-		managedForm.addPart(new DependencySection(getDeploymentPlan(), environment, body, toolkit, getStyle()));
-		managedForm.addPart(new GBeanSection(getDeploymentPlan(), gbeanERef, body, toolkit, getStyle()));
+		managedForm.addPart(new DependencySection(getDeploymentPlan(), JAXBModelUtils.getEnvironmentType(getDeploymentPlan()), body, toolkit, getStyle()));
+		managedForm.addPart(new GBeanSection(getDeploymentPlan(), JAXBModelUtils.getServiceOrPersistence(getDeploymentPlan()), body, toolkit, getStyle()));
 	}
 
 	/*

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/NamingFormPage.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/NamingFormPage.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/NamingFormPage.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/NamingFormPage.java Wed Mar  5 20:58:28 2008
@@ -16,7 +16,10 @@
  */
 package org.apache.geronimo.st.v21.ui.pages;
 
+import java.util.List;
+
 import org.apache.geronimo.st.ui.CommonMessages;
+import org.apache.geronimo.st.ui.editors.AbstractGeronimoDeploymentPlanEditor;
 import org.apache.geronimo.st.ui.pages.AbstractGeronimoFormPage;
 import org.apache.geronimo.st.v21.ui.sections.EjbLocalRefSection;
 import org.apache.geronimo.st.v21.ui.sections.EjbRefSection;
@@ -24,26 +27,29 @@
 import org.apache.geronimo.st.v21.ui.sections.ResourceEnvRefSection;
 import org.apache.geronimo.st.v21.ui.sections.ResourceRefSection;
 import org.apache.geronimo.st.v21.ui.sections.ServiceRefSection;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
 import org.eclipse.ui.forms.IManagedForm;
 import org.eclipse.ui.forms.editor.FormEditor;
 
 public class NamingFormPage extends AbstractGeronimoFormPage {
 
-	public EReference resRef;
+	public List resRefs;
 
-	public EReference resEnvRef;
+	public List resEnvRefs;
 
-	public EReference ejbRef;
+	public List ejbRefs;
 
-	public EReference ejbLocalRef;
+	public List ejbLocalRefs;
 
-	public EReference gbeanRef;
+	public List gbeanRefs;
 
-	public EReference serviceRef;
+	public List serviceRefs;
 
 	public NamingFormPage(FormEditor editor, String id, String title) {
 		super(editor, id, title);
+		WebAppType webapp = (WebAppType)((AbstractGeronimoDeploymentPlanEditor) getEditor()).getDeploymentPlan().getValue();
+		resRefs = webapp.getResourceRef();
+		serviceRefs = webapp.getServiceRef();
 	}
 
 	/*
@@ -52,12 +58,12 @@
 	 * @see org.apache.geronimo.ui.pages.AbstractGeronimoFormPage#fillBody(org.eclipse.ui.forms.IManagedForm)
 	 */
 	protected void fillBody(IManagedForm managedForm) {
-		managedForm.addPart(new ResourceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), resRef));
-		managedForm.addPart(new ResourceEnvRefSection(getDeploymentPlan(), body, toolkit, getStyle(), resEnvRef));
-		managedForm.addPart(new EjbRefSection(getDeploymentPlan(), body, toolkit, getStyle(), ejbRef));
-		managedForm.addPart(new EjbLocalRefSection(getDeploymentPlan(), body, toolkit, getStyle(), ejbLocalRef));
-		managedForm.addPart(new GBeanRefSection(getDeploymentPlan(), body, toolkit, getStyle(), gbeanRef));
-		managedForm.addPart(new ServiceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), serviceRef));
+		managedForm.addPart(new ResourceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), resRefs));
+		managedForm.addPart(new ResourceEnvRefSection(getDeploymentPlan(), body, toolkit, getStyle(), resEnvRefs));
+		managedForm.addPart(new EjbRefSection(getDeploymentPlan(), body, toolkit, getStyle(), ejbRefs));
+		managedForm.addPart(new EjbLocalRefSection(getDeploymentPlan(), body, toolkit, getStyle(), ejbLocalRefs));
+		managedForm.addPart(new GBeanRefSection(getDeploymentPlan(), body, toolkit, getStyle(), gbeanRefs));
+		managedForm.addPart(new ServiceRefSection(getDeploymentPlan(), body, toolkit, getStyle(), serviceRefs));
 	}
 
 	/*

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/SecurityPage.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/SecurityPage.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/SecurityPage.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/pages/SecurityPage.java Wed Mar  5 20:58:28 2008
@@ -20,18 +20,18 @@
 import org.apache.geronimo.st.ui.pages.AbstractGeronimoFormPage;
 import org.apache.geronimo.st.v21.ui.sections.SecurityRootSection;
 import org.apache.geronimo.st.v21.ui.sections.SecuritySection;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.security_2.SecurityType;
 import org.eclipse.swt.layout.GridLayout;
 import org.eclipse.ui.forms.IManagedForm;
 import org.eclipse.ui.forms.editor.FormEditor;
 
 public class SecurityPage extends AbstractGeronimoFormPage {
 
-	public EReference securityERef;
+	public SecurityType security;
 
-	public SecurityPage(FormEditor editor, String id, String title, EReference securityERef) {
+	public SecurityPage(FormEditor editor, String id, String title, SecurityType security) {
 		super(editor, id, title);
-		this.securityERef = securityERef;
+		this.security = security;
 	}
 
 	/*
@@ -40,8 +40,8 @@
 	 * @see org.apache.geronimo.ui.pages.AbstractGeronimoFormPage#fillBody(org.eclipse.ui.forms.IManagedForm)
 	 */
 	protected void fillBody(IManagedForm managedForm) {
-		managedForm.addPart(new SecurityRootSection(body, toolkit, getStyle(), getDeploymentPlan(), securityERef));
-		managedForm.addPart(new SecuritySection(getDeploymentPlan(), body, toolkit, getStyle(), securityERef));
+		managedForm.addPart(new SecurityRootSection(body, toolkit, getStyle(), getDeploymentPlan(), security));
+		managedForm.addPart(new SecuritySection(getDeploymentPlan(), body, toolkit, getStyle(), security.getRoleMappings()));
 	}
 
 	/*

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/AppGeneralSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/AppGeneralSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/AppGeneralSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/AppGeneralSection.java Wed Mar  5 20:58:28 2008
@@ -16,10 +16,9 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
-import org.apache.geronimo.xml.ns.j2ee.application.ApplicationPackage;
-import org.apache.geronimo.xml.ns.j2ee.application.ApplicationType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import javax.xml.bind.JAXBElement;
+
+import org.apache.geronimo.xml.ns.j2ee.application_2.ApplicationType;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
@@ -27,9 +26,9 @@
 
 	ApplicationType plan;
 
-	public AppGeneralSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public AppGeneralSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
-		this.plan = (ApplicationType) plan;
+		this.plan = (ApplicationType) plan.getValue();
 		createClient();
 	}
 
@@ -38,7 +37,7 @@
 	 * 
 	 * @see org.apache.geronimo.st.v21.ui.sections.CommonGeneralSection#getEnvironmentEReference()
 	 */
-	protected EReference getEnvironmentEReference() {
-		return ApplicationPackage.eINSTANCE.getApplicationType_Environment();
+	protected JAXBElement getEnvironmentEReference() {
+		return null; //ApplicationPackage.eINSTANCE.getApplicationType_Environment();
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/CommonGeneralSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/CommonGeneralSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/CommonGeneralSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/CommonGeneralSection.java Wed Mar  5 20:58:28 2008
@@ -19,17 +19,16 @@
 import java.util.Iterator;
 import java.util.List;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractSectionPart;
-import org.apache.geronimo.st.v21.core.operations.V21DeploymentPlanCreationOperation;
 import org.apache.geronimo.st.v21.ui.internal.Messages;
-import org.apache.geronimo.xml.ns.deployment.ArtifactType;
-import org.apache.geronimo.xml.ns.deployment.DependenciesType;
-import org.apache.geronimo.xml.ns.deployment.DeploymentFactory;
-import org.apache.geronimo.xml.ns.deployment.DeploymentPackage;
-import org.apache.geronimo.xml.ns.deployment.EnvironmentType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.ArtifactType;
+import org.apache.geronimo.xml.ns.deployment_1.DependenciesType;
+import org.apache.geronimo.xml.ns.deployment_1.DependencyType;
+import org.apache.geronimo.xml.ns.deployment_1.EnvironmentType;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.events.ModifyEvent;
 import org.eclipse.swt.events.ModifyListener;
@@ -61,7 +60,7 @@
 	
 	protected Button sharedLibDepends;
 
-	public CommonGeneralSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public CommonGeneralSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
 	}
 
@@ -193,7 +192,7 @@
 	protected String getGroupId() {
 		ArtifactType moduleId = getModuleId(false);
 		if (moduleId != null
-				&& moduleId.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_GroupId()))
+				&& moduleId.getGroupId() != null)
 			return moduleId.getGroupId();
 		return "";
 	}
@@ -201,7 +200,7 @@
 	protected String getArtifactId() {
 		ArtifactType moduleId = getModuleId(false);
 		if (moduleId != null
-				&& moduleId.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_ArtifactId()))
+				&& moduleId.getArtifactId() != null)
 			return moduleId.getArtifactId();
 		return "";
 	}
@@ -209,7 +208,7 @@
 	protected String getVersion() {
 		ArtifactType moduleId = getModuleId(false);
 		if (moduleId != null
-				&& moduleId.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Version()))
+				&& moduleId.getVersion() != null)
 			return moduleId.getVersion();
 		return "";
 	}
@@ -217,7 +216,7 @@
 	protected String getArtifactType() {
 		ArtifactType moduleId = getModuleId(false);
 		if (moduleId != null
-				&& moduleId.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Type()))
+				&& moduleId.getType() != null)
 			return moduleId.getType();
 		return "";
 	}
@@ -243,11 +242,11 @@
 	protected void setInverseClassloading(boolean enable) {
 		if (enable) {
 			EnvironmentType type = getEnvironmentType(true);
-			type.setInverseClassloading(DeploymentFactory.eINSTANCE.createEmptyType());
+			type.setInverseClassloading(getDeploymentObjectFactory().createEmptyType());
 		} else {
 			EnvironmentType type = getEnvironmentType(false);
 			if (type != null) {
-				type.eUnset(DeploymentPackage.eINSTANCE.getEnvironmentType_InverseClassloading());
+				type.setInverseClassloading(null);
 			}
 		}
 	}
@@ -255,11 +254,11 @@
 	protected void setSuppressDefaultEnvironment(boolean enable) {
 		if (enable) {
 			EnvironmentType type = getEnvironmentType(true);
-			type.setSuppressDefaultEnvironment(DeploymentFactory.eINSTANCE.createEmptyType());
+			type.setSuppressDefaultEnvironment(getDeploymentObjectFactory().createEmptyType());
 		} else {
 			EnvironmentType type = getEnvironmentType(false);
 			if (type != null) {
-				type.eUnset(DeploymentPackage.eINSTANCE.getEnvironmentType_SuppressDefaultEnvironment());
+				type.setSuppressDefaultEnvironment(null);
 			}
 		}
 	}
@@ -267,7 +266,10 @@
 	protected void setSharedLibDependency(boolean enable) {
 		if (enable) {
 			DependenciesType deptype = getDependenciesType(true);
-			ArtifactType sharedLib = V21DeploymentPlanCreationOperation.createDependencyType("org.apache.geronimo.configs", "sharedlib", null, "car");
+			DependencyType sharedLib = getDeploymentObjectFactory().createDependencyType();
+			sharedLib.setGroupId("org.apache.geronimo.configs");
+			sharedLib.setArtifactId("sharedlib");
+			sharedLib.setType("car");
 			deptype.getDependency().add(sharedLib);
 		} else {
 			DependenciesType deptype = getDependenciesType(false);
@@ -294,10 +296,10 @@
 	}
 
 	private EnvironmentType getEnvironmentType(boolean create) {
-		EnvironmentType type = (EnvironmentType) getPlan().eGet(getEnvironmentEReference());
+		EnvironmentType type = ((WebAppType) getPlan().getValue()).getEnvironment();
 		if (type == null && create) {
-			type = DeploymentFactory.eINSTANCE.createEnvironmentType();
-			getPlan().eSet(getEnvironmentEReference(), type);
+			type = getDeploymentObjectFactory().createEnvironmentType();
+			((WebAppType) getPlan().getValue()).setEnvironment( type );
 		}
 		return type;
 	}
@@ -307,7 +309,7 @@
 		if(env != null) {
 			DependenciesType dep = env.getDependencies();
 			if (dep == null && create) {
-				dep = DeploymentFactory.eINSTANCE.createDependenciesType();
+				dep = getDeploymentObjectFactory().createDependenciesType();
 				env.setDependencies(dep);
 			}
 			return dep;
@@ -320,14 +322,22 @@
 		if (type != null) {
 			ArtifactType moduleId = type.getModuleId();
 			if (moduleId == null && create) {
-				moduleId = DeploymentFactory.eINSTANCE.createArtifactType();
+				moduleId = getDeploymentObjectFactory().createArtifactType();
 				type.setModuleId(moduleId);
 			}
 			return moduleId;
 		}
 		return null;
 	}
+	
+	org.apache.geronimo.xml.ns.deployment_1.ObjectFactory deploymentObjectFacotry = null;
+	private org.apache.geronimo.xml.ns.deployment_1.ObjectFactory getDeploymentObjectFactory() {
+		if ( deploymentObjectFacotry == null ) {
+			deploymentObjectFacotry = new org.apache.geronimo.xml.ns.deployment_1.ObjectFactory();
+		}
+		return deploymentObjectFacotry;
+	}
 
-	protected abstract EReference getEnvironmentEReference();
+	protected abstract JAXBElement getEnvironmentEReference();
 
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ConnectorGeneralSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ConnectorGeneralSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ConnectorGeneralSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ConnectorGeneralSection.java Wed Mar  5 20:58:28 2008
@@ -16,10 +16,9 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
-import org.apache.geronimo.xml.ns.j2ee.connector.ConnectorPackage;
-import org.apache.geronimo.xml.ns.j2ee.connector.ConnectorType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import javax.xml.bind.JAXBElement;
+
+import org.apache.geronimo.xml.ns.j2ee.connector_1.ConnectorType;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
@@ -27,13 +26,13 @@
 
 	ConnectorType plan;
 
-	public ConnectorGeneralSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public ConnectorGeneralSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
-		this.plan = (ConnectorType) plan;
+		this.plan = (ConnectorType) plan.getValue();
 		createClient();
 	}
 
-	protected EReference getEnvironmentEReference() {
-		return ConnectorPackage.eINSTANCE.getConnectorType_Environment();
+	protected JAXBElement getEnvironmentEReference() {
+		return null; //ConnectorPackage.eINSTANCE.getConnectorType_Environment();
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/DependencySection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/DependencySection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/DependencySection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/DependencySection.java Wed Mar  5 20:58:28 2008
@@ -16,17 +16,20 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import java.util.List;
+
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
+import org.apache.geronimo.st.ui.providers.AdapterFactory;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.DependencyWizard;
-import org.apache.geronimo.xml.ns.deployment.DeploymentPackage;
-import org.apache.geronimo.xml.ns.deployment.EnvironmentType;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.DependenciesType;
+import org.apache.geronimo.xml.ns.deployment_1.DependencyType;
+import org.apache.geronimo.xml.ns.deployment_1.EnvironmentType;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
+import org.apache.geronimo.xml.ns.naming_1.ResourceRefType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
@@ -34,7 +37,7 @@
 
 public class DependencySection extends AbstractTableSection {
 
-	private EReference environmentERef;
+	private EnvironmentType environment;
 
 	/**
 	 * @param plan
@@ -42,9 +45,9 @@
 	 * @param toolkit
 	 * @param style
 	 */
-	public DependencySection(EObject plan, EReference environment, Composite parent, FormToolkit toolkit, int style) {
+	public DependencySection(JAXBElement plan, EnvironmentType environment, Composite parent, FormToolkit toolkit, int style) {
 		super(plan, parent, toolkit, style);
-		this.environmentERef = environment;
+		this.environment = environment;
 		createClient();
 	}
 
@@ -66,13 +69,8 @@
 		return CommonMessages.editorSectionDependenciesDescription;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return environmentERef;
+	public List getObjectContainer() {
+		return environment.getDependencies().getDependency();
 	}
 
 	/*
@@ -102,24 +100,37 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return DeploymentPackage.eINSTANCE.getDependencyType();
+	public Class getTableEntryObjectType() {
+		return DependencyType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
 	
 	public Object getInput() {
-		EnvironmentType envType = (EnvironmentType) getPlan().eGet(getEReference());
-		if (envType != null) {
-			return envType.getDependencies();
+		if (environment != null) {
+			return environment.getDependencies();
 		}
 		return super.getInput();
+	}
+	
+	public AdapterFactory getAdapterFactory() {
+		return new AdapterFactory() {
+			public Object[] getElements(Object inputElement) {
+				if (!DependenciesType.class.isInstance(inputElement)) {
+					return new String[] { "" };
+				}
+				DependenciesType plan = (DependenciesType)inputElement;
+				return plan.getDependency().toArray();
+			}
+			public String getColumnText(Object element, int columnIndex) {
+				if (DependencyType.class.isInstance(element)) {
+					DependencyType dependency = (DependencyType)element;
+					switch (columnIndex) {
+					case 0: return dependency.getGroupId();
+					case 1: return dependency.getArtifactId();
+					}
+				}
+				return null;
+			}
+		};
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbLocalRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbLocalRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbLocalRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbLocalRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,16 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.EjbLocalRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.naming_1.EjbLocalRefType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
@@ -33,13 +30,13 @@
 
 public class EjbLocalRefSection extends AbstractTableSection {
 
-	EReference ejbLocalRefERef;
+	Object ejbLocalRefERef;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.name,
 			CommonMessages.editorEjbRefEjbLink };
 
-	public EjbLocalRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference ejbLocalRefERef) {
+	public EjbLocalRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, Object ejbLocalRefERef) {
 		super(plan, parent, toolkit, style);
 		this.ejbLocalRefERef = ejbLocalRefERef;
 		createClient();
@@ -72,14 +69,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return ejbLocalRefERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return ejbLocalRefERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -99,16 +96,16 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getEjbLocalRefType();
+	public Class getTableEntryObjectType() {
+		return EjbLocalRefType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
+//	 */
+//	public AdapterFactory getAdapterFactory() {
+//		return EMFEditorContext.getFactory();
+//	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/EjbRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,16 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.EjbRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.naming_1.EjbRefType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
@@ -33,7 +30,7 @@
 
 public class EjbRefSection extends AbstractTableSection {
 
-	EReference ejbRefERef;
+	Object ejbRefERef;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.name,
@@ -45,7 +42,7 @@
 	 * @param toolkit
 	 * @param style
 	 */
-	public EjbRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference ejbRefERef) {
+	public EjbRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, Object ejbRefERef) {
 		super(plan, parent, toolkit, style);
 		this.ejbRefERef = ejbRefERef;
 		createClient();
@@ -78,14 +75,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return ejbRefERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return ejbRefERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -105,16 +102,16 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getEjbRefType();
+	public Class getTableEntryObjectType() {
+		return EjbRefType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
+//	 */
+//	public AdapterFactory getAdapterFactory() {
+//		return EMFEditorContext.getFactory();
+//	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,28 +16,25 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.GBeanRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.GbeanType;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
 public class GBeanRefSection extends AbstractTableSection {
 
-	EReference gbeanERef;
+	Object gbeanERef;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.editorGBeanRefName,
 			CommonMessages.editorGBeanRefType};
 
-	public GBeanRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference gbeanERef) {
+	public GBeanRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, Object gbeanERef) {
 		super(plan, parent, toolkit, style);
 		this.gbeanERef = gbeanERef;
 		createClient();
@@ -70,14 +67,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return gbeanERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return gbeanERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -93,16 +90,16 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getGbeanRefType();
+	public Class getTableEntryObjectType() {
+		return GbeanType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
+//	 */
+//	public AdapterFactory getAdapterFactory() {
+//		return EMFEditorContext.getFactory();
+//	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/GBeanSection.java Wed Mar  5 20:58:28 2008
@@ -16,22 +16,24 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import java.util.List;
+
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
+import org.apache.geronimo.st.ui.providers.AdapterFactory;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.GBeanWizard;
-import org.apache.geronimo.xml.ns.deployment.DeploymentPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.GbeanType;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
+import org.apache.geronimo.xml.ns.naming_1.ResourceRefType;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
 public class GBeanSection extends AbstractTableSection {
 
-	private EReference gBeanERef;
+	private List gbeans;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.name, CommonMessages.className };
@@ -42,9 +44,9 @@
 	 * @param toolkit
 	 * @param style
 	 */
-	public GBeanSection(EObject plan, EReference gBeanERef, Composite parent, FormToolkit toolkit, int style) {
+	public GBeanSection(JAXBElement plan, List gbeans, Composite parent, FormToolkit toolkit, int style) {
 		super(plan, parent, toolkit, style);
-		this.gBeanERef = gBeanERef;
+		this.gbeans = gbeans;
 		createClient();
 	}
 
@@ -75,15 +77,10 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return gBeanERef;
+	public List getObjectContainer() {
+		return gbeans;
 	}
-
+	
 	/*
 	 * (non-Javadoc)
 	 * 
@@ -98,8 +95,8 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return DeploymentPackage.eINSTANCE.getGbeanType();
+	public Class getTableEntryObjectType() {
+		return GbeanType.class;
 	}
 
 	/*
@@ -108,6 +105,27 @@
 	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
 	 */
 	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
+		return new AdapterFactory() {
+			public Object[] getElements(Object inputElement) {
+				if (!JAXBElement.class.isInstance(inputElement)) {
+					return new String[] { "" };
+				}
+				JAXBElement plan = (JAXBElement)inputElement;
+				if (plan.getDeclaredType().equals(WebAppType.class)) {
+					return ((WebAppType)plan.getValue()).getResourceRef().toArray();
+				}
+				return new String[] { "" };
+			}
+			public String getColumnText(Object element, int columnIndex) {
+				if (ResourceRefType.class.isInstance(element)) {
+					ResourceRefType resourceRef = (ResourceRefType)element;
+					switch (columnIndex) {
+					case 0: return resourceRef.getRefName();
+					case 1: return resourceRef.getResourceLink();
+					}
+				}
+				return null;
+			}
+		};
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ImportSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ImportSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ImportSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ImportSection.java Wed Mar  5 20:58:28 2008
@@ -16,18 +16,19 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.v21.ui.wizards.ImportWizard;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.deployment_1.EnvironmentType;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
 public class ImportSection extends DependencySection {
 
-	public ImportSection(EObject plan, EReference dependenciesERef, Composite parent, FormToolkit toolkit, int style) {
-		super(plan, dependenciesERef, parent, toolkit, style);
+	public ImportSection(JAXBElement plan, EnvironmentType environment, Composite parent, FormToolkit toolkit, int style) {
+		super(plan, environment, parent, toolkit, style);
 	}
 
 	/*

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/OpenEjbJarGeneralSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/OpenEjbJarGeneralSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/OpenEjbJarGeneralSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/OpenEjbJarGeneralSection.java Wed Mar  5 20:58:28 2008
@@ -16,20 +16,19 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import javax.xml.bind.JAXBElement;
+
+import org.apache.geronimo.xml.ns.j2ee.ejb.openejb_2.OpenejbJarType;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
-import org.openejb.xml.ns.openejb.jar.JarPackage;
-import org.openejb.xml.ns.openejb.jar.OpenejbJarType;
 
 public class OpenEjbJarGeneralSection extends CommonGeneralSection {
 
 	OpenejbJarType plan;
 
-	public OpenEjbJarGeneralSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public OpenEjbJarGeneralSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
-		this.plan = (OpenejbJarType) plan;
+		this.plan = (OpenejbJarType) plan.getValue();
 		createClient();
 	}
 
@@ -38,7 +37,7 @@
 	 * 
 	 * @see org.apache.geronimo.st.v21.ui.sections.CommonGeneralSection#getEnvironmentEReference()
 	 */
-	protected EReference getEnvironmentEReference() {
-		return JarPackage.eINSTANCE.getOpenejbJarType_Environment();
+	protected JAXBElement getEnvironmentEReference() {
+		return null; //JarPackage.eINSTANCE.getOpenejbJarType_Environment();
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceEnvRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceEnvRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceEnvRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceEnvRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,16 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.ResourceEnvRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.naming_1.ResourceEnvRefType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
@@ -33,13 +30,13 @@
 
 public class ResourceEnvRefSection extends AbstractTableSection {
 
-	EReference resourceEnvRefERef;
+	Object resourceEnvRefERef;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.editorResEnvRefNameTitle,
 			CommonMessages.editorResEnvRefMsgDestTitle };
 
-	public ResourceEnvRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference resourceEnvRefERef) {
+	public ResourceEnvRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, Object resourceEnvRefERef) {
 		super(plan, parent, toolkit, style);
 		this.resourceEnvRefERef = resourceEnvRefERef;
 		createClient();
@@ -72,14 +69,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return resourceEnvRefERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return resourceEnvRefERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -99,16 +96,16 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getResourceEnvRefType();
+	public Class getTableEntryObjectType() {
+		return ResourceEnvRefType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
+//	 */
+//	public AdapterFactory getAdapterFactory() {
+//		return EMFEditorContext.getFactory();
+//	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ResourceRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,16 +16,18 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import java.util.ArrayList;
+import java.util.List;
+
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
+import org.apache.geronimo.st.ui.providers.AdapterFactory;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.ResourceRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
+import org.apache.geronimo.xml.ns.naming_1.ResourceRefType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
@@ -33,15 +35,15 @@
 
 public class ResourceRefSection extends AbstractTableSection {
 
-	EReference resourceRefERef;
+	List resourceRefERefs;
 
 	private static final String[] COLUMN_NAMES = new String[] {
 			CommonMessages.editorResRefNameTitle,
 			CommonMessages.editorResRefLinkTitle};
 
-	public ResourceRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference resourceRefERef) {
+	public ResourceRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, List resourceRefERefs) {
 		super(plan, parent, toolkit, style);
-		this.resourceRefERef = resourceRefERef;
+		this.resourceRefERefs = resourceRefERefs;
 		createClient();
 	}
 
@@ -72,14 +74,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return resourceRefERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return resourceRefERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -99,8 +101,12 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getResourceRefType();
+	public Class getTableEntryObjectType() {
+		return ResourceRefType.class;
+	}
+	
+	public List getObjectContainer() {
+		return resourceRefERefs;
 	}
 
 	/*
@@ -109,6 +115,27 @@
 	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
 	 */
 	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
+		return new AdapterFactory() {
+			public Object[] getElements(Object inputElement) {
+				if (!JAXBElement.class.isInstance(inputElement)) {
+					return new String[] { "" };
+				}
+				JAXBElement plan = (JAXBElement)inputElement;
+				if (plan.getDeclaredType().equals(WebAppType.class)) {
+					return ((WebAppType)plan.getValue()).getResourceRef().toArray();
+				}
+				return new String[] { "" };
+			}
+			public String getColumnText(Object element, int columnIndex) {
+				if (ResourceRefType.class.isInstance(element)) {
+					ResourceRefType resourceRef = (ResourceRefType)element;
+					switch (columnIndex) {
+					case 0: return resourceRef.getRefName();
+					case 1: return resourceRef.getResourceLink();
+					}
+				}
+				return null;
+			}
+		};
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecurityRootSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecurityRootSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecurityRootSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecurityRootSection.java Wed Mar  5 20:58:28 2008
@@ -16,13 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractSectionPart;
-import org.apache.geronimo.xml.ns.security.SecurityFactory;
-import org.apache.geronimo.xml.ns.security.SecurityPackage;
-import org.apache.geronimo.xml.ns.security.SecurityType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.st.v21.core.jaxb.JAXBModelUtils;
+import org.apache.geronimo.st.v21.core.jaxb.JAXBObjectFactoryImpl;
+import org.apache.geronimo.xml.ns.security_2.SecurityType;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.events.ModifyEvent;
 import org.eclipse.swt.events.ModifyListener;
@@ -40,7 +40,7 @@
 
 public class SecurityRootSection extends AbstractSectionPart {
 
-	EReference secERef;
+	SecurityType secERef;
 
 	Text defaultRole;
 
@@ -60,7 +60,7 @@
 	 * @param toolkit
 	 * @param style
 	 */
-	public SecurityRootSection(Composite parent, FormToolkit toolkit, int style, EObject plan, EReference secERef) {
+	public SecurityRootSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan, SecurityType secERef) {
 		super(parent, toolkit, style, plan);
 		this.secERef = secERef;
 		createClient();
@@ -107,6 +107,7 @@
 				markDirty();
 			}
 		});
+		doas.setSelection(getSecurityType().isDoasCurrentCaller());
 
 		useCtxHdl = toolkit.createButton(composite, CommonMessages.useContextHandler, SWT.CHECK);
 		useCtxHdl.setLayoutData(createGridData());
@@ -119,6 +120,7 @@
 				markDirty();
 			}
 		});
+		useCtxHdl.setSelection(getSecurityType().isUseContextHandler());
 
 	}
 
@@ -136,19 +138,19 @@
 	}
 
 	private String getDefaultRole() {
-		SecurityType secType = (SecurityType) getPlan().eGet(secERef);
+		SecurityType secType = JAXBModelUtils.getSecurityType(getPlan());
 		if (secType != null
-				&& secType.eIsSet(SecurityPackage.eINSTANCE.getSecurityType_DefaultRole())) {
+				&& secType.getDefaultRole() != null ) {
 			return secType.getDefaultRole();
 		}
 		return "";
 	}
 
 	private SecurityType getSecurityType() {
-		SecurityType secType = (SecurityType) getPlan().eGet(secERef);
+		SecurityType secType = JAXBModelUtils.getSecurityType(getPlan());
 		if (secType == null) {
-			secType = SecurityFactory.eINSTANCE.createSecurityType();
-			getPlan().eSet(secERef, secType);
+			secType = (SecurityType)JAXBObjectFactoryImpl.getInstance().create( SecurityType.class );
+			JAXBModelUtils.setSecurityType(getPlan(),secType);
 		}
 		return secType;
 	}

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecuritySection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecuritySection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecuritySection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/SecuritySection.java Wed Mar  5 20:58:28 2008
@@ -16,19 +16,22 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import java.util.List;
+
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
+import org.apache.geronimo.st.ui.providers.AdapterFactory;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
+import org.apache.geronimo.st.v21.core.jaxb.JAXBModelUtils;
 import org.apache.geronimo.st.v21.ui.Activator;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.SecurityRoleWizard;
-import org.apache.geronimo.xml.ns.security.DescriptionType;
-import org.apache.geronimo.xml.ns.security.RoleType;
-import org.apache.geronimo.xml.ns.security.SecurityPackage;
-import org.apache.geronimo.xml.ns.security.SecurityType;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
+import org.apache.geronimo.xml.ns.naming_1.ResourceRefType;
+import org.apache.geronimo.xml.ns.security_2.DescriptionType;
+import org.apache.geronimo.xml.ns.security_2.RoleMappingsType;
+import org.apache.geronimo.xml.ns.security_2.RoleType;
+import org.apache.geronimo.xml.ns.security_2.SecurityType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.SWT;
@@ -45,7 +48,7 @@
 
 public class SecuritySection extends AbstractTableSection {
 
-	public EReference securityERef;
+	public RoleMappingsType roleMappings;
 
 	Text roleNameText;
 
@@ -59,9 +62,9 @@
 	 * @param toolkit
 	 * @param style
 	 */
-	public SecuritySection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference securityERef) {
+	public SecuritySection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, RoleMappingsType roleMappings) {
 		super(plan, parent, toolkit, style);
-		this.securityERef = securityERef;
+		this.roleMappings = roleMappings;
 		createClient();
 	}
 
@@ -92,13 +95,8 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return SecurityPackage.eINSTANCE.getRoleMappingsType_Role();
+	public List getObjectContainer() {
+		return roleMappings.getRole();
 	}
 
 	/*
@@ -115,8 +113,8 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return SecurityPackage.eINSTANCE.getRoleType();
+	public Class getTableEntryObjectType() {
+		return RoleType.class;
 	}
 
 	/*
@@ -183,7 +181,7 @@
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getInput()
 	 */
 	public Object getInput() {
-		SecurityType secType = (SecurityType) getPlan().eGet(securityERef);
+		SecurityType secType = JAXBModelUtils.getSecurityType(getPlan());//.eGet(securityERef);
 		if (secType != null) {
 			return secType.getRoleMappings();
 		}
@@ -214,12 +212,24 @@
 
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
 	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
+		return new AdapterFactory() {
+			public Object[] getElements(Object inputElement) {
+				if (!RoleMappingsType.class.isInstance(inputElement)) {
+					return new String[] { "" };
+				}
+				RoleMappingsType plan = (RoleMappingsType)inputElement;
+				return plan.getRole().toArray();
+			}
+			public String getColumnText(Object element, int columnIndex) {
+				if (RoleType.class.isInstance(element)) {
+					RoleType role = (RoleType)element;
+					switch (columnIndex) {
+					case 0: return role.getRoleName();
+					}
+				}
+				return null;
+			}
+		};
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ServiceRefSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ServiceRefSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ServiceRefSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/ServiceRefSection.java Wed Mar  5 20:58:28 2008
@@ -16,26 +16,25 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import java.util.List;
+
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
-import org.apache.geronimo.st.v21.ui.internal.EMFEditorContext;
 import org.apache.geronimo.st.v21.ui.wizards.ServiceRefWizard;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.common.notify.AdapterFactory;
-import org.eclipse.emf.ecore.EClass;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.naming_1.ServiceRefType;
 import org.eclipse.jface.wizard.Wizard;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.widgets.FormToolkit;
 
 public class ServiceRefSection extends AbstractTableSection {
 
-	EReference serviceRefERef;
+	List serviceRefERef;
 
 	private static final String[] COLUMN_NAMES = new String[] { CommonMessages.editorServiceRefName };
 
-	public ServiceRefSection(EObject plan, Composite parent, FormToolkit toolkit, int style, EReference serviceRefERef) {
+	public ServiceRefSection(JAXBElement plan, Composite parent, FormToolkit toolkit, int style, List serviceRefERef) {
 		super(plan, parent, toolkit, style);
 		this.serviceRefERef = serviceRefERef;
 		createClient();
@@ -68,14 +67,14 @@
 		return COLUMN_NAMES;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
-	 */
-	public EReference getEReference() {
-		return serviceRefERef;
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getEReference()
+//	 */
+//	public JAXBElement getEReference() {
+//		return serviceRefERef;
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -91,16 +90,16 @@
 	 * 
 	 * @see org.apache.geronimo.ui.sections.AbstractTableSection#getTableEntryObjectType()
 	 */
-	public EClass getTableEntryObjectType() {
-		return NamingPackage.eINSTANCE.getServiceRefType();
+	public Class getTableEntryObjectType() {
+		return ServiceRefType.class;
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
-	 */
-	public AdapterFactory getAdapterFactory() {
-		return EMFEditorContext.getFactory();
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.st.ui.sections.AbstractTableSection#getAdapterFactory()
+//	 */
+//	public AdapterFactory getAdapterFactory() {
+//		return EMFEditorContext.getFactory();
+//	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebContainerSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebContainerSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebContainerSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebContainerSection.java Wed Mar  5 20:58:28 2008
@@ -16,15 +16,13 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.sections.AbstractSectionPart;
 import org.apache.geronimo.st.v21.ui.internal.Messages;
-import org.apache.geronimo.xml.ns.j2ee.web.WebAppType;
-import org.apache.geronimo.xml.ns.naming.GbeanLocatorType;
-import org.apache.geronimo.xml.ns.naming.NamingFactory;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.apache.geronimo.xml.ns.naming.PatternType;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EStructuralFeature;
+import org.apache.geronimo.xml.ns.deployment_1.PatternType;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
+import org.apache.geronimo.xml.ns.naming_1.GbeanLocatorType;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.events.ModifyEvent;
 import org.eclipse.swt.events.ModifyListener;
@@ -66,9 +64,9 @@
 	 * @param style
 	 * @param plan
 	 */
-	public WebContainerSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public WebContainerSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
-		this.plan = (WebAppType) plan;
+		this.plan = (WebAppType) plan.getValue();
 		createClient();
 	}
 
@@ -118,7 +116,7 @@
 		group.setLayoutData(createTextFieldGridData());
 		group.addModifyListener(new ModifyListener() {
 			public void modifyText(ModifyEvent e) {
-				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_GroupId(), group.getText());
+//				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_GroupId(), group.getText());
 				markDirty();
 			}
 		});
@@ -130,7 +128,7 @@
 		artifact.setLayoutData(createTextFieldGridData());
 		artifact.addModifyListener(new ModifyListener() {
 			public void modifyText(ModifyEvent e) {
-				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_ArtifactId(), artifact.getText());
+//				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_ArtifactId(), artifact.getText());
 				markDirty();
 			}
 		});
@@ -142,7 +140,7 @@
 		module.setLayoutData(createTextFieldGridData());
 		module.addModifyListener(new ModifyListener() {
 			public void modifyText(ModifyEvent e) {
-				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Module(), module.getText());
+//				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Module(), module.getText());
 				markDirty();
 			}
 		});
@@ -154,7 +152,7 @@
 		name.setLayoutData(createTextFieldGridData());
 		name.addModifyListener(new ModifyListener() {
 			public void modifyText(ModifyEvent e) {
-				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Name(), name.getText());
+//				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Name(), name.getText());
 				markDirty();
 			}
 		});
@@ -166,7 +164,7 @@
 		version.setLayoutData(createTextFieldGridData());
 		version.addModifyListener(new ModifyListener() {
 			public void modifyText(ModifyEvent e) {
-				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Version(), version.getText());
+//				setPatternTypeAttribute(NamingPackage.eINSTANCE.getPatternType_Version(), version.getText());
 				markDirty();
 			}
 		});
@@ -174,11 +172,11 @@
 		specifyAsLink.addSelectionListener(new SelectionAdapter() {
 			public void widgetSelected(SelectionEvent e) {
 				if (specifyAsLink.getSelection()) {
-					if (plan.getWebContainer() != null
-							&& plan.getWebContainer().eIsSet(NamingPackage.eINSTANCE.getGbeanLocatorType_Pattern())) {
-						plan.getWebContainer().eUnset(NamingPackage.eINSTANCE.getGbeanLocatorType_Pattern());
-						markDirty();
-					}
+//					if (plan.getWebContainer() != null
+//							&& plan.getWebContainer().eIsSet(NamingPackage.eINSTANCE.getGbeanLocatorType_Pattern())) {
+//						plan.getWebContainer().eUnset(NamingPackage.eINSTANCE.getGbeanLocatorType_Pattern());
+//						markDirty();
+//					}
 					if (gBeanLink.getText().length() > 0) {
 						plan.getWebContainer().setGbeanLink(gBeanLink.getText());
 						markDirty();
@@ -191,11 +189,11 @@
 		specifyAsPattern.addSelectionListener(new SelectionAdapter() {
 			public void widgetSelected(SelectionEvent e) {
 				if (specifyAsPattern.getSelection()) {
-					if (plan.getWebContainer() != null
-							&& plan.getWebContainer().eIsSet(NamingPackage.eINSTANCE.getGbeanLocatorType_GbeanLink())) {
-						plan.getWebContainer().eUnset(NamingPackage.eINSTANCE.getGbeanLocatorType_GbeanLink());
-						markDirty();
-					}
+//					if (plan.getWebContainer() != null
+//							&& plan.getWebContainer().eIsSet(NamingPackage.eINSTANCE.getGbeanLocatorType_GbeanLink())) {
+//						plan.getWebContainer().eUnset(NamingPackage.eINSTANCE.getGbeanLocatorType_GbeanLink());
+//						markDirty();
+//					}
 					if (group.getText().length() > 0) {
 						getPatternType().setGroupId(group.getText());
 						markDirty();
@@ -209,8 +207,8 @@
 						markDirty();
 					}
 					if (name.getText().length() > 0) {
-						getPatternType().setName(name.getText());
-						markDirty();
+//						getPatternType().setName(name.getText());
+//						markDirty();
 					}
 					if (version.getText().length() > 0) {
 						getPatternType().setVersion(version.getText());
@@ -245,7 +243,7 @@
 	private GbeanLocatorType getGBeanLocator() {
 		GbeanLocatorType wc = plan.getWebContainer();
 		if (wc == null) {
-			wc = NamingFactory.eINSTANCE.createGbeanLocatorType();
+//			wc = NamingFactory.eINSTANCE.createGbeanLocatorType();
 			plan.setWebContainer(wc);
 		}
 		return wc;
@@ -256,21 +254,21 @@
 	 */
 	private PatternType getPatternType() {
 		GbeanLocatorType locator = getGBeanLocator();
-		PatternType pattern = locator.getPattern();
-		if (pattern == null) {
-			pattern = NamingFactory.eINSTANCE.createPatternType();
-			locator.setPattern(pattern);
-		}
-		return pattern;
+//		PatternType pattern = locator.getPattern();
+//		if (pattern == null) {
+//			pattern = NamingFactory.eINSTANCE.createPatternType();
+//			locator.setPattern(pattern);
+//		}
+		return null;//pattern;
 	}
 
-	/**
-	 * @param feature
-	 * @param value
-	 */
-	private void setPatternTypeAttribute(EStructuralFeature feature, String value) {
-		getPatternType().eSet(feature, value);
-	}
+//	/**
+//	 * @param feature
+//	 * @param value
+//	 */
+//	private void setPatternTypeAttribute(EStructuralFeature feature, String value) {
+//		getPatternType().eSet(feature, value);
+//	}
 
 	protected Label createLabel(Composite parent, String text) {
 		Label label = toolkit.createLabel(parent, text);

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebGeneralSection.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebGeneralSection.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebGeneralSection.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/sections/WebGeneralSection.java Wed Mar  5 20:58:28 2008
@@ -16,11 +16,10 @@
  */
 package org.apache.geronimo.st.v21.ui.sections;
 
+import javax.xml.bind.JAXBElement;
+
 import org.apache.geronimo.st.ui.CommonMessages;
-import org.apache.geronimo.xml.ns.j2ee.web.WebAppType;
-import org.apache.geronimo.xml.ns.j2ee.web.WebPackage;
-import org.eclipse.emf.ecore.EObject;
-import org.eclipse.emf.ecore.EReference;
+import org.apache.geronimo.xml.ns.j2ee.web_2_0.WebAppType;
 import org.eclipse.swt.SWT;
 import org.eclipse.swt.events.ModifyEvent;
 import org.eclipse.swt.events.ModifyListener;
@@ -35,9 +34,9 @@
 
 	WebAppType plan;
 
-	public WebGeneralSection(Composite parent, FormToolkit toolkit, int style, EObject plan) {
+	public WebGeneralSection(Composite parent, FormToolkit toolkit, int style, JAXBElement plan) {
 		super(parent, toolkit, style, plan);
-		this.plan = (WebAppType) plan;
+		this.plan = (WebAppType) plan.getValue();
 		createClient();
 	}
 
@@ -62,7 +61,7 @@
 	 * 
 	 * @see org.apache.geronimo.st.v21.ui.sections.CommonGeneralSection#getEnvironmentEReference()
 	 */
-	protected EReference getEnvironmentEReference() {
-		return WebPackage.eINSTANCE.getWebAppType_Environment();
+	protected JAXBElement getEnvironmentEReference() {
+		return null; //WebPackage.eINSTANCE.getWebAppType_Environment();
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/DependencyWizard.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/DependencyWizard.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/DependencyWizard.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/DependencyWizard.java Wed Mar  5 20:58:28 2008
@@ -16,18 +16,15 @@
  */
 package org.apache.geronimo.st.v21.ui.wizards;
 
+import javax.enterprise.deploy.spi.factories.DeploymentFactory;
+
 import org.apache.geronimo.st.ui.CommonMessages;
-import org.apache.geronimo.st.v21.ui.internal.Trace;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.ui.wizards.AbstractTableWizard;
-import org.apache.geronimo.xml.ns.deployment.ArtifactType;
-import org.apache.geronimo.xml.ns.deployment.DependenciesType;
-import org.apache.geronimo.xml.ns.deployment.DeploymentFactory;
-import org.apache.geronimo.xml.ns.deployment.DeploymentPackage;
-import org.apache.geronimo.xml.ns.deployment.EnvironmentType;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EFactory;
-import org.eclipse.emf.ecore.EObject;
+import org.apache.geronimo.st.v21.ui.internal.Trace;
+import org.apache.geronimo.xml.ns.deployment_1.ArtifactType;
+import org.apache.geronimo.xml.ns.deployment_1.DependenciesType;
+import org.apache.geronimo.xml.ns.deployment_1.EnvironmentType;
 import org.eclipse.jface.resource.ImageDescriptor;
 import org.eclipse.jface.wizard.IWizardPage;
 import org.eclipse.jface.wizard.WizardPage;
@@ -72,23 +69,23 @@
         Trace.trace("Constructor Entry/Exit", "DependencyWizard");
 	}
 
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.wizards.DynamicAddEditWizard#getEFactory()
-	 */
-	public EFactory getEFactory() {
-		return DeploymentFactory.eINSTANCE;
-	}
-
-	/*
-	 * (non-Javadoc)
-	 * 
-	 * @see org.apache.geronimo.ui.wizards.DynamicAddEditWizard#getTableColumnEAttributes()
-	 */
-	public EAttribute[] getTableColumnEAttributes() {
-		return new EAttribute[] {};
-	}
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.wizards.DynamicAddEditWizard#getEFactory()
+//	 */
+//	public EFactory getEFactory() {
+//		return DeploymentFactory.eINSTANCE;
+//	}
+
+//	/*
+//	 * (non-Javadoc)
+//	 * 
+//	 * @see org.apache.geronimo.ui.wizards.DynamicAddEditWizard#getTableColumnEAttributes()
+//	 */
+//	public EAttribute[] getTableColumnEAttributes() {
+//		return new EAttribute[] {};
+//	}
 
 	/*
 	 * (non-Javadoc)
@@ -218,18 +215,18 @@
 			typeText.setLayoutData(new GridData(GridData.FILL_HORIZONTAL));
 
 			if (eObject != null) {
-				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_ArtifactId())) {
-					artifactIdText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_ArtifactId()).toString());
-				}
-				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_GroupId())) {
-					groupIdText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_GroupId()).toString());
-				}
-				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Version())) {
-					versionText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_Version()).toString());
-				}
-				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Type())) {
-					typeText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_Type()).toString());
-				}
+//				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_ArtifactId())) {
+//					artifactIdText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_ArtifactId()).toString());
+//				}
+//				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_GroupId())) {
+//					groupIdText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_GroupId()).toString());
+//				}
+//				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Version())) {
+//					versionText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_Version()).toString());
+//				}
+//				if (eObject.eIsSet(DeploymentPackage.eINSTANCE.getArtifactType_Type())) {
+//					typeText.setText(eObject.eGet(DeploymentPackage.eINSTANCE.getArtifactType_Type()).toString());
+//				}
 			}
 
 			setControl(composite);
@@ -252,14 +249,14 @@
 //		Trace.trace("Entry", "DependencyWizard.performFinish");
 		
 		if (eObject == null) {
-			eObject = getEFactory().create(section.getTableEntryObjectType());
-			EObject plan = section.getPlan();
-			DependenciesType dependenciesType = ((EnvironmentType) plan.eGet(section.getEReference())).getDependencies();
-			if(dependenciesType == null) {
-				dependenciesType = DeploymentFactory.eINSTANCE.createDependenciesType();
-				((EnvironmentType) plan.eGet(section.getEReference())).setDependencies(dependenciesType);
-			}
-			dependenciesType.getDependency().add(eObject);
+//			eObject = getEFactory().create(section.getTableEntryObjectType());
+//			EObject plan = section.getPlan();
+//			DependenciesType dependenciesType = ((EnvironmentType) plan.eGet(section.getEReference())).getDependencies();
+//			if(dependenciesType == null) {
+//				dependenciesType = DeploymentFactory.eINSTANCE.createDependenciesType();
+//				((EnvironmentType) plan.eGet(section.getEReference())).setDependencies(dependenciesType);
+//			}
+//			dependenciesType.getDependency().add(eObject);
 		}
 
 		processEAttributes(getPages()[0]);

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbLocalRefWizard.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbLocalRefWizard.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbLocalRefWizard.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbLocalRefWizard.java Wed Mar  5 20:58:28 2008
@@ -19,10 +19,6 @@
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.ui.wizards.AbstractTableWizard;
-import org.apache.geronimo.xml.ns.naming.NamingFactory;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EFactory;
 
 public class EjbLocalRefWizard extends AbstractTableWizard {
 
@@ -39,15 +35,15 @@
 		return CommonMessages.wizardNewTitle_EjbLocalRef;
 	}
 
-	public EFactory getEFactory() {
-		return NamingFactory.eINSTANCE;
-	}
-
-	public EAttribute[] getTableColumnEAttributes() {
-		return new EAttribute[] {
-				NamingPackage.eINSTANCE.getEjbLocalRefType_RefName(),
-				NamingPackage.eINSTANCE.getEjbLocalRefType_EjbLink() };
-	}
+//	public EFactory getEFactory() {
+//		return NamingFactory.eINSTANCE;
+//	}
+//
+//	public EAttribute[] getTableColumnEAttributes() {
+//		return new EAttribute[] {
+//				NamingPackage.eINSTANCE.getEjbLocalRefType_RefName(),
+//				NamingPackage.eINSTANCE.getEjbLocalRefType_EjbLink() };
+//	}
 
 	/*
 	 * (non-Javadoc)

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbRefWizard.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbRefWizard.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbRefWizard.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/EjbRefWizard.java Wed Mar  5 20:58:28 2008
@@ -19,10 +19,6 @@
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.ui.wizards.AbstractTableWizard;
-import org.apache.geronimo.xml.ns.naming.NamingFactory;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EFactory;
 
 public class EjbRefWizard extends AbstractTableWizard {
 
@@ -30,15 +26,15 @@
 		super(section);
 	}
 
-	public EFactory getEFactory() {
-		return NamingFactory.eINSTANCE;
-	}
-
-	public EAttribute[] getTableColumnEAttributes() {
-		return new EAttribute[] {
-				NamingPackage.eINSTANCE.getEjbRefType_RefName(),
-				NamingPackage.eINSTANCE.getEjbRefType_EjbLink() };
-	}
+//	public EFactory getEFactory() {
+//		return NamingFactory.eINSTANCE;
+//	}
+//
+//	public EAttribute[] getTableColumnEAttributes() {
+//		return new EAttribute[] {
+//				NamingPackage.eINSTANCE.getEjbRefType_RefName(),
+//				NamingPackage.eINSTANCE.getEjbRefType_EjbLink() };
+//	}
 
 	/*
 	 * (non-Javadoc)

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanRefWizard.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanRefWizard.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanRefWizard.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanRefWizard.java Wed Mar  5 20:58:28 2008
@@ -19,10 +19,6 @@
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.ui.wizards.AbstractTableWizard;
-import org.apache.geronimo.xml.ns.naming.NamingFactory;
-import org.apache.geronimo.xml.ns.naming.NamingPackage;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EFactory;
 
 public class GBeanRefWizard extends AbstractTableWizard {
 
@@ -30,15 +26,15 @@
 		super(section);
 	}
 
-	public EFactory getEFactory() {
-		return NamingFactory.eINSTANCE;
-	}
-
-	public EAttribute[] getTableColumnEAttributes() {
-		return new EAttribute[] {
-				NamingPackage.eINSTANCE.getGbeanRefType_RefName(),
-				NamingPackage.eINSTANCE.getGbeanRefType_RefType()};
-	}
+//	public EFactory getEFactory() {
+//		return NamingFactory.eINSTANCE;
+//	}
+//
+//	public EAttribute[] getTableColumnEAttributes() {
+//		return new EAttribute[] {
+//				NamingPackage.eINSTANCE.getGbeanRefType_RefName(),
+//				NamingPackage.eINSTANCE.getGbeanRefType_RefType()};
+//	}
 
 	/*
 	 * (non-Javadoc)

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanWizard.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanWizard.java?rev=634164&r1=634163&r2=634164&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanWizard.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v21.ui/src/org/apache/geronimo/st/v21/ui/wizards/GBeanWizard.java Wed Mar  5 20:58:28 2008
@@ -16,13 +16,11 @@
  */
 package org.apache.geronimo.st.v21.ui.wizards;
 
+import org.apache.geronimo.st.core.jaxb.JAXBObjectFactory;
 import org.apache.geronimo.st.ui.CommonMessages;
 import org.apache.geronimo.st.ui.sections.AbstractTableSection;
 import org.apache.geronimo.st.ui.wizards.AbstractTableWizard;
-import org.apache.geronimo.xml.ns.deployment.DeploymentFactory;
-import org.apache.geronimo.xml.ns.deployment.DeploymentPackage;
-import org.eclipse.emf.ecore.EAttribute;
-import org.eclipse.emf.ecore.EFactory;
+import org.apache.geronimo.st.v21.core.jaxb.JAXBObjectFactoryImpl;
 
 public class GBeanWizard extends AbstractTableWizard {
 
@@ -33,14 +31,12 @@
 		super(section);
 	}
 
-	public EFactory getEFactory() {
-		return DeploymentFactory.eINSTANCE;
+	public JAXBObjectFactory getEFactory() {
+		return JAXBObjectFactoryImpl.getInstance();
 	}
-
-	public EAttribute[] getTableColumnEAttributes() {
-		return new EAttribute[] {
-				DeploymentPackage.eINSTANCE.getGbeanType_Name(),
-				DeploymentPackage.eINSTANCE.getGbeanType_Class() };
+	
+	public String[] getTableColumnEAttributes() {
+		return new String[] { "Name", "Clazz" };
 	}
 
 	/*



Mime
View raw message