You are viewing a plain text version of this content. The canonical link for it is here.
Posted to scm@geronimo.apache.org by mc...@apache.org on 2007/10/26 06:14:23 UTC

svn commit: r588513 - in /geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core: ./ src/org/apache/geronimo/st/v20/core/ src/org/apache/geronimo/st/v20/core/operations/

Author: mcconne
Date: Thu Oct 25 21:14:23 2007
New Revision: 588513

URL: http://svn.apache.org/viewvc?rev=588513&view=rev
Log:
Use unique action across all wizards

Modified:
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/plugin.xml
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/DeploymentPlanInstallConfig.java
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/GeronimoV20FacetInstallDelegate.java
    geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/V20DeploymentPlanCreationOperation.java

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/plugin.xml
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/plugin.xml?rev=588513&r1=588512&r2=588513&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/plugin.xml (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/plugin.xml Thu Oct 25 21:14:23 2007
@@ -70,8 +70,8 @@
     </extension>
     
     <extension point="org.eclipse.wst.common.project.facet.core.facets">        
-        <project-facet-version facet="org.apache.geronimo.facet" version="1.1">
-            <action type="install" id="geronimo.plan.install">
+        <project-facet-version facet="org.apache.geronimo.facet" version="2.0">
+            <action type="install" id="geronimo.plan.install.v20">
                 <delegate class="org.apache.geronimo.st.v20.core.operations.GeronimoV20FacetInstallDelegate"/>
                 <config-factory class="org.apache.geronimo.st.v20.core.DeploymentPlanInstallConfig$Factory"/>
             </action>

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/DeploymentPlanInstallConfig.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/DeploymentPlanInstallConfig.java?rev=588513&r1=588512&r2=588513&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/DeploymentPlanInstallConfig.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/DeploymentPlanInstallConfig.java Thu Oct 25 21:14:23 2007
@@ -16,8 +16,10 @@
  */
 package org.apache.geronimo.st.v20.core;
 
+import org.apache.geronimo.st.v20.core.internal.Trace;
 import org.eclipse.wst.common.project.facet.core.IActionConfigFactory;
 
+
 /**
  * @version $Rev$ $Date$
  */
@@ -37,6 +39,7 @@
     {
         public Object create()
         {
+        	Trace.trace("Entry/Exit", "DeploymentPlanInstallConfig.create");
             return new DeploymentPlanInstallConfig();
         }
     }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/GeronimoV20FacetInstallDelegate.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/GeronimoV20FacetInstallDelegate.java?rev=588513&r1=588512&r2=588513&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/GeronimoV20FacetInstallDelegate.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/GeronimoV20FacetInstallDelegate.java Thu Oct 25 21:14:23 2007
@@ -17,6 +17,7 @@
 package org.apache.geronimo.st.v20.core.operations;
 
 import org.apache.geronimo.st.core.GeronimoFacetInstallDelegate;
+import org.apache.geronimo.st.v20.core.internal.Trace;
 import org.eclipse.core.resources.IProject;
 import org.eclipse.jst.common.project.facet.JavaProjectFacetCreationDataModelProvider;
 import org.eclipse.wst.common.componentcore.datamodel.properties.IFacetDataModelProperties;
@@ -30,8 +31,12 @@
 public class GeronimoV20FacetInstallDelegate extends GeronimoFacetInstallDelegate {
 
 	public IDataModelOperation createDeploymentPlanCreationOp(IProject project, Object config) {
+		Trace.trace("Entry", "GeronimoV20FacetInstallDelegate.createDeploymentPlanCreationOp", project, config);
+		
 		IDataModel model = DataModelFactory.createDataModel(new JavaProjectFacetCreationDataModelProvider());
 		model.setStringProperty(IFacetDataModelProperties.FACET_PROJECT_NAME, project.getName());
-		return new V20DeploymentPlanCreationOperation(model, config);
+		
+		Trace.trace("Exit", "GeronimoV20FacetInstallDelegate.createDeploymentPlanCreationOp");
+		return new V20DeploymentPlanCreationOperation(model, config);		
 	}
 }

Modified: geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/V20DeploymentPlanCreationOperation.java
URL: http://svn.apache.org/viewvc/geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/V20DeploymentPlanCreationOperation.java?rev=588513&r1=588512&r2=588513&view=diff
==============================================================================
--- geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/V20DeploymentPlanCreationOperation.java (original)
+++ geronimo/devtools/eclipse-plugin/trunk/plugins/org.apache.geronimo.st.v20.core/src/org/apache/geronimo/st/v20/core/operations/V20DeploymentPlanCreationOperation.java Thu Oct 25 21:14:23 2007
@@ -20,6 +20,7 @@
 import org.apache.geronimo.st.core.operations.DeploymentPlanCreationOperation;
 import org.apache.geronimo.st.v20.core.DeploymentPlanInstallConfig;
 import org.apache.geronimo.st.v20.core.GeronimoV20Utils;
+import org.apache.geronimo.st.v20.core.internal.Trace;
 import org.apache.geronimo.xml.ns.deployment.ArtifactType;
 import org.apache.geronimo.xml.ns.deployment.DependenciesType;
 import org.apache.geronimo.xml.ns.deployment.DependencyType;
@@ -63,14 +64,17 @@
 
 	public V20DeploymentPlanCreationOperation(IDataModel model, Object config) {
 		super(model, config);
+  		Trace.trace("Constructor Entry/Exit", "V20DeploymentPlanCreationOperation", model, config);
 	}
-
+	
 	/*
 	 * (non-Javadoc)
 	 * 
 	 * @see org.apache.geronimo.st.core.operations.IDeploymentPlanCreationOp#createGeronimoApplicationDeploymentPlan(org.eclipse.core.resources.IFile)
 	 */
 	public EObject createGeronimoApplicationDeploymentPlan(IFile dpFile) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createGeronimoApplicationDeploymentPlan", dpFile);
+		
 		URI uri = URI.createPlatformResourceURI(dpFile.getFullPath().toString(), false);
 
 		ResourceSet resourceSet = new ResourceSetImpl();
@@ -93,6 +97,7 @@
 
 		save(resource);
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createGeronimoApplicationDeploymentPlan", root);
 		return root;
 	}
 
@@ -102,6 +107,7 @@
 	 * @see org.apache.geronimo.st.core.operations.IDeploymentPlanCreationOp#createGeronimoWebDeploymentPlan(org.eclipse.core.resources.IFile)
 	 */
 	public EObject createGeronimoWebDeploymentPlan(IFile dpFile) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createGeronimoWebDeploymentPlan", dpFile);
 
 		URI uri = URI.createPlatformResourceURI(dpFile.getFullPath().toString(), false);
 
@@ -129,6 +135,7 @@
 
 		save(resource);
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createGeronimoWebDeploymentPlan", root);
 		return root;
 	}
 
@@ -138,6 +145,8 @@
 	 * @see org.apache.geronimo.st.core.operations.IDeploymentPlanCreationOp#createOpenEjbDeploymentPlan(org.eclipse.core.resources.IFile)
 	 */
 	public EObject createOpenEjbDeploymentPlan(IFile dpFile) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createOpenEjbDeploymentPlan", dpFile);
+		
 		URI uri = URI.createPlatformResourceURI(dpFile.getFullPath().toString(), false);
 
 		ResourceSet resourceSet = new ResourceSetImpl();
@@ -162,6 +171,7 @@
 
 		save(resource);
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createOpenEjbDeploymentPlan", root);
 		return root;
 	}
 
@@ -171,6 +181,8 @@
 	 * @see org.apache.geronimo.st.core.operations.IDeploymentPlanCreationOp#createConnectorDeploymentPlan(org.eclipse.core.resources.IFile)
 	 */
 	public EObject createConnectorDeploymentPlan(IFile dpFile) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createConnectorDeploymentPlan", dpFile);
+		
 		URI uri = URI.createPlatformResourceURI(dpFile.getFullPath().toString(), false);
 
 		ResourceSet resourceSet = new ResourceSetImpl();
@@ -191,10 +203,13 @@
 
 		save(resource);
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createConnectorDeploymentPlan", root);
 		return root;
 	}
 
 	public EObject createServiceDeploymentPlan(IFile dpFile) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createServiceDeploymentPlan", dpFile);
+		
 		URI uri = URI.createPlatformResourceURI(dpFile.getFullPath().toString(), false);
 
 		ResourceSet resourceSet = new ResourceSetImpl();
@@ -213,10 +228,13 @@
 
 		save(resource);
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createServiceDeploymentPlan", root);
 		return root;
 	}
 
 	public EnvironmentType getConfigEnvironment() {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.getConfigEnvironment");
+		
 		if (config != null && config instanceof DeploymentPlanInstallConfig) {
 			cfg = (DeploymentPlanInstallConfig) config;
 		}
@@ -241,10 +259,13 @@
 			env.setDependencies(dt);
 		}
 
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.getConfigEnvironment", env);
 		return env;
 	}
 
 	public static ArtifactType createArtifactType(String groupId, String artifactId, String version, String type) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createArtifactType", groupId, artifactId, version, type);
+						
 		ArtifactType artifact = DeploymentFactory.eINSTANCE.createArtifactType();
 		if (groupId != null)
 			artifact.setGroupId(groupId);
@@ -253,10 +274,14 @@
 		if (version != null)
 			artifact.setVersion(version);
 		artifact.setType(type);
+		
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createArtifactType", artifact);
 		return artifact;
 	}
 
 	public static ArtifactType createDependencyType(String groupId, String artifactId, String version, String type) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.createDependencyType", groupId, artifactId, version, type);
+		
 		DependencyType artifact = DeploymentFactory.eINSTANCE.createDependencyType();
 		if (groupId != null)
 			artifact.setGroupId(groupId);
@@ -265,11 +290,16 @@
 		if (version != null)
 			artifact.setVersion(version);
 		artifact.setType(type);
+		
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.createDependencyType", artifact);
 		return artifact;
 	}
 
 	private static boolean hasValue(String attribute) {
+//		Trace.trace("Entry", "V20DeploymentPlanCreationOperation.hasValue", attribute);
+//		Trace.trace("Exit", "V20DeploymentPlanCreationOperation.hasValue", (attribute != null && attribute.trim().length() != 0) );
+		
 		return attribute != null && attribute.trim().length() != 0;
 	}
 
-}
+}
\ No newline at end of file