[jboss-cvs] JBossAS SVN: r101721 - in projects/jboss-deployers/trunk: deployers-impl/src/test/java/org/jboss/test/deployers/deployer/test and 2 other directories.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Tue Mar 2 11:11:59 EST 2010


Author: adrian at jboss.org
Date: 2010-03-02 11:11:58 -0500 (Tue, 02 Mar 2010)
New Revision: 101721

Modified:
   projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/ModifyComponentRelativeOrderDeployer.java
   projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/TestAttachmentDeployer.java
   projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/test/DynamicRelativeOrderUnitTestCase.java
   projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/AbstractDeploymentContext.java
   projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/ComponentDeploymentContext.java
   projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/explicit/DeclaredStructure.java
Log:
Source code tidyup and remove unnecessary null check

Modified: projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/ModifyComponentRelativeOrderDeployer.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/ModifyComponentRelativeOrderDeployer.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/ModifyComponentRelativeOrderDeployer.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -21,8 +21,6 @@
 */
 package org.jboss.test.deployers.deployer.support;
 
-import java.util.Collection;
-
 import org.jboss.deployers.spi.DeploymentException;
 import org.jboss.deployers.spi.deployer.DeploymentStage;
 import org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer;

Modified: projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/TestAttachmentDeployer.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/TestAttachmentDeployer.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/support/TestAttachmentDeployer.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -21,7 +21,6 @@
 */
 package org.jboss.test.deployers.deployer.support;
 
-import java.util.Collection;
 import java.util.Set;
 
 import org.jboss.deployers.spi.DeploymentException;

Modified: projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/test/DynamicRelativeOrderUnitTestCase.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/test/DynamicRelativeOrderUnitTestCase.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-impl/src/test/java/org/jboss/test/deployers/deployer/test/DynamicRelativeOrderUnitTestCase.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -26,6 +26,9 @@
 import java.util.Collections;
 import java.util.List;
 
+import junit.framework.Test;
+import junit.framework.TestSuite;
+
 import org.jboss.deployers.client.spi.DeployerClient;
 import org.jboss.deployers.client.spi.Deployment;
 import org.jboss.deployers.client.spi.DeploymentFactory;
@@ -34,12 +37,12 @@
 import org.jboss.deployers.spi.deployer.DeploymentStages;
 import org.jboss.deployers.spi.structure.ContextInfo;
 import org.jboss.test.deployers.AbstractDeployerTest;
-import org.jboss.test.deployers.deployer.support.*;
-import org.jboss.test.deployers.main.support.TestAttachment;
+import org.jboss.test.deployers.deployer.support.ModifyComponentRelativeOrderDeployer;
+import org.jboss.test.deployers.deployer.support.ModifyRelativeOrderDeployer;
+import org.jboss.test.deployers.deployer.support.TestAttachmentDeployer;
+import org.jboss.test.deployers.deployer.support.TestSimpleDeployer3;
+import org.jboss.test.deployers.deployer.support.TestSimpleDeployer4;
 
-import junit.framework.Test;
-import junit.framework.TestSuite;
-
 /**
  * Dynamic relative order.
  *

Modified: projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/AbstractDeploymentContext.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/AbstractDeploymentContext.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/AbstractDeploymentContext.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -372,6 +372,7 @@
       setRelativeOrder(relativeOrder);
    }
 
+   @SuppressWarnings("unchecked")
    public synchronized void markDirty(DirtyType type)
    {
       if (dirty instanceof CopyOnWriteArraySet == false)

Modified: projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/ComponentDeploymentContext.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/ComponentDeploymentContext.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-structure-spi/src/main/java/org/jboss/deployers/structure/spi/helpers/ComponentDeploymentContext.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -141,6 +141,7 @@
       setRelativeOrder(relativeOrder);
    }
 
+   @SuppressWarnings("unchecked")
    public synchronized void markDirty(DirtyType type)
    {
       if (dirty instanceof CopyOnWriteArraySet == false)

Modified: projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/explicit/DeclaredStructure.java
===================================================================
--- projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/explicit/DeclaredStructure.java	2010-03-02 16:08:07 UTC (rev 101720)
+++ projects/jboss-deployers/trunk/deployers-vfs/src/main/java/org/jboss/deployers/vfs/plugins/structure/explicit/DeclaredStructure.java	2010-03-02 16:11:58 UTC (rev 101721)
@@ -132,21 +132,17 @@
    {
       final StructureMetaData structureMetaData = structureContext.getMetaData();
       final VirtualFile structureRoot = structureContext.getRoot();
-      if(structureContext != null)
+      for(ContextInfo contextInfo : structureMetaData.getContexts()) 
       {
-         for(ContextInfo contextInfo : structureMetaData.getContexts()) 
+         final String contextPath = contextInfo.getPath(); 
+         if(hasValidSuffix(contextPath))
          {
-            final String contextPath = contextInfo.getPath(); 
-            if(hasValidSuffix(contextPath))
+            final VirtualFile child = structureRoot.getChild(contextPath);
+            if(child.exists() && child.isFile()) 
             {
-               final VirtualFile child = structureRoot.getChild(contextPath);
-               if(child.exists() && child.isFile()) 
-               {
-                  performMount(child);
-               }
+               performMount(child);
             }
          }
       }
-      
    }
 }




More information about the jboss-cvs-commits mailing list