geronimo-scm mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sppa...@apache.org
Subject svn commit: r321007 - in /geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui: editors/ pages/ sections/ wizards/
Date Fri, 14 Oct 2005 05:15:27 GMT
Author: sppatel
Date: Thu Oct 13 22:15:20 2005
New Revision: 321007

URL: http://svn.apache.org/viewcvs?rev=321007&view=rev
Log:
share sec page

Modified:
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ApplicationPlanEditor.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ConnectorPlanEditor.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/OpenEjbPlanEditor.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/WebEditor.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/pages/SecurityPage.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/sections/SecuritySection.java
    geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/wizards/SecurityRoleWizard.java

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ApplicationPlanEditor.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ApplicationPlanEditor.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ApplicationPlanEditor.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ApplicationPlanEditor.java
Thu Oct 13 22:15:20 2005
@@ -18,6 +18,8 @@
 import org.apache.geronimo.core.internal.GeronimoUtils;
 import org.apache.geronimo.ui.internal.Messages;
 import org.apache.geronimo.ui.pages.AppGeneralPage;
+import org.apache.geronimo.ui.pages.SecurityPage;
+import org.apache.geronimo.xml.ns.j2ee.application.ApplicationPackage;
 import org.eclipse.core.resources.IFile;
 import org.eclipse.emf.ecore.EObject;
 import org.eclipse.ui.PartInitException;
@@ -34,7 +36,9 @@
     public void doAddPages() throws PartInitException {
         addPage(new AppGeneralPage(this, "appgeneralpage",
                 Messages.editorTabGeneral));
-        
+        addPage(new SecurityPage(this, "securitypage",
+                Messages.editorTabSecurity,  ApplicationPackage.eINSTANCE
+                .getApplicationType_Security()));             
         addSourcePage();
     }
 

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ConnectorPlanEditor.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ConnectorPlanEditor.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ConnectorPlanEditor.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/ConnectorPlanEditor.java
Thu Oct 13 22:15:20 2005
@@ -18,6 +18,7 @@
 import org.apache.geronimo.core.internal.GeronimoUtils;
 import org.apache.geronimo.ui.internal.Messages;
 import org.apache.geronimo.ui.pages.ConnectorOverviewPage;
+import org.apache.geronimo.ui.pages.NamingFormPage;
 import org.eclipse.core.resources.IFile;
 import org.eclipse.emf.ecore.EObject;
 import org.eclipse.ui.PartInitException;
@@ -31,6 +32,8 @@
     public void doAddPages() throws PartInitException {
         addPage(new ConnectorOverviewPage(this, "connectoroverview",
                 Messages.editorTabGeneral));
+        
+        addPage(new NamingFormPage(this, "namingpage", Messages.editorTabNaming));
         
         addSourcePage();
     }

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/OpenEjbPlanEditor.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/OpenEjbPlanEditor.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/OpenEjbPlanEditor.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/OpenEjbPlanEditor.java
Thu Oct 13 22:15:20 2005
@@ -18,9 +18,12 @@
 import org.apache.geronimo.core.internal.GeronimoUtils;
 import org.apache.geronimo.ui.internal.Messages;
 import org.apache.geronimo.ui.pages.EjbOverviewPage;
+import org.apache.geronimo.ui.pages.NamingFormPage;
+import org.apache.geronimo.ui.pages.SecurityPage;
 import org.eclipse.core.resources.IFile;
 import org.eclipse.emf.ecore.EObject;
 import org.eclipse.ui.PartInitException;
+import org.openejb.xml.ns.openejb.jar.JarPackage;
 /**
  * 
  * 
@@ -36,8 +39,11 @@
 
     public void doAddPages() throws PartInitException {
         addPage(new EjbOverviewPage(this, "ejboverview",
-                Messages.editorTabGeneral));
-        
+                Messages.editorTabGeneral));        
+        addPage(new NamingFormPage(this, "namingpage", Messages.editorTabNaming));
+        addPage(new SecurityPage(this, "securitypage",
+                Messages.editorTabSecurity,  JarPackage.eINSTANCE
+                .getOpenejbJarType_Security()));        
         addSourcePage();
     }
 

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/WebEditor.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/WebEditor.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/WebEditor.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/editors/WebEditor.java
Thu Oct 13 22:15:20 2005
@@ -20,6 +20,7 @@
 import org.apache.geronimo.ui.pages.NamingFormPage;
 import org.apache.geronimo.ui.pages.SecurityPage;
 import org.apache.geronimo.ui.pages.WebGeneralPage;
+import org.apache.geronimo.xml.ns.web.impl.WebPackageImpl;
 import org.eclipse.core.resources.IFile;
 import org.eclipse.emf.ecore.EObject;
 import org.eclipse.ui.PartInitException;
@@ -36,7 +37,8 @@
                 Messages.editorTabGeneral));
         addPage(new NamingFormPage(this, "namingpage", Messages.editorTabNaming));
         addPage(new SecurityPage(this, "securitypage",
-                Messages.editorTabSecurity));
+                Messages.editorTabSecurity,  WebPackageImpl.eINSTANCE
+                .getWebAppType_Security()));
 
         addSourcePage();
     }

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/pages/SecurityPage.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/pages/SecurityPage.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/pages/SecurityPage.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/pages/SecurityPage.java
Thu Oct 13 22:15:20 2005
@@ -1,8 +1,9 @@
 package org.apache.geronimo.ui.pages;
 
-import org.apache.geronimo.ui.editors.WebEditor;
+import org.apache.geronimo.ui.editors.AbstractGeronimoDeploymentPlanEditor;
 import org.apache.geronimo.ui.sections.SecuritySection;
-import org.apache.geronimo.xml.ns.web.WebAppType;
+import org.eclipse.emf.ecore.EObject;
+import org.eclipse.emf.ecore.EReference;
 import org.eclipse.swt.layout.GridLayout;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.ui.forms.IManagedForm;
@@ -14,16 +15,18 @@
 
 public class SecurityPage extends FormPage {
 
-    public SecurityPage(FormEditor editor, String id, String title) {
+    public EReference securityERef;
+
+    public SecurityPage(FormEditor editor, String id, String title,
+            EReference securityERef) {
         super(editor, id, title);
-        // TODO Auto-generated constructor stub
+        this.securityERef = securityERef;
     }
 
     public SecurityPage(String id, String title) {
         super(id, title);
-        // TODO Auto-generated constructor stub
     }
-    
+
     /*
      * (non-Javadoc)
      * 
@@ -47,7 +50,8 @@
 
     private void fillBody(IManagedForm managedForm) {
 
-        WebAppType plan = (WebAppType) ((WebEditor) getEditor()).getDeploymentPlan();
+        EObject plan = ((AbstractGeronimoDeploymentPlanEditor) getEditor())
+                .getDeploymentPlan();
 
         Composite body = managedForm.getForm().getBody();
 
@@ -56,7 +60,7 @@
                 | ExpandableComposite.FOCUS_TITLE;
 
         managedForm.addPart(new SecuritySection(plan, body, managedForm
-                .getToolkit(), style));
+                .getToolkit(), style, securityERef));
     }
 
 }

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/sections/SecuritySection.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/sections/SecuritySection.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/sections/SecuritySection.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/sections/SecuritySection.java
Thu Oct 13 22:15:20 2005
@@ -23,8 +23,6 @@
 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.apache.geronimo.xml.ns.web.WebAppType;
-import org.apache.geronimo.xml.ns.web.impl.WebPackageImpl;
 import org.eclipse.emf.common.util.EList;
 import org.eclipse.emf.ecore.EAttribute;
 import org.eclipse.emf.ecore.EFactory;
@@ -50,8 +48,7 @@
  */
 public class SecuritySection extends DynamicTableSection {
 
-    public static EReference securityERef = WebPackageImpl.eINSTANCE
-            .getWebAppType_Security();
+    public EReference securityERef;
 
     /**
      * @param plan
@@ -59,9 +56,10 @@
      * @param toolkit
      * @param style
      */
-    public SecuritySection(WebAppType plan, Composite parent,
-            FormToolkit toolkit, int style) {
+    public SecuritySection(EObject plan, Composite parent,
+            FormToolkit toolkit, int style, EReference securityERef) {
         super(plan, parent, toolkit, style);
+        this.securityERef = securityERef;
         create();
     }
 

Modified: geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/wizards/SecurityRoleWizard.java
URL: http://svn.apache.org/viewcvs/geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/wizards/SecurityRoleWizard.java?rev=321007&r1=321006&r2=321007&view=diff
==============================================================================
--- geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/wizards/SecurityRoleWizard.java
(original)
+++ geronimo/devtools/trunk/modules/eclipse-plugin/plugins/org.apache.geronimo.ui/src/org/apache/geronimo/ui/wizards/SecurityRoleWizard.java
Thu Oct 13 22:15:20 2005
@@ -63,10 +63,10 @@
             EObject plan = section.getPlan();
 
             SecurityType securityType = (SecurityType) plan
-                    .eGet(SecuritySection.securityERef);
+                    .eGet(((SecuritySection) section).securityERef);
             if (securityType == null) {
                 securityType = SecurityFactory.eINSTANCE.createSecurityType();
-                plan.eSet(SecuritySection.securityERef, securityType);
+                plan.eSet(((SecuritySection) section).securityERef, securityType);
             }
 
             RoleMappingsType roleMappingsType = securityType.getRoleMappings();



Mime
View raw message