[jboss-cvs] JBossAS SVN: r58019 - in projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins: deployers/helpers structure/vfs/explicit structure/vfs/jar structure/vfs/war
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Thu Nov 2 13:57:18 EST 2006
Author: scott.stark at jboss.org
Date: 2006-11-02 13:57:08 -0500 (Thu, 02 Nov 2006)
New Revision: 58019
Modified:
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractClassLoaderDeployer.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractComponentDeployer.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractParsingDeployer.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractRealDeployer.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractSimpleRealDeployer.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/explicit/DeclaredStructure.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WARStructure.java
Log:
Remove all of the hard-coded getRelativeOrder overrides as this prevented use of setRelativeOrder.
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractClassLoaderDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractClassLoaderDeployer.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractClassLoaderDeployer.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -35,9 +35,13 @@
*/
public abstract class AbstractClassLoaderDeployer extends AbstractSimpleDeployer implements ClassLoaderFactory
{
- public int getRelativeOrder()
+ /**
+ * Set the default relative order to CLASSLOADER_DEPLOYER
+ *
+ */
+ public AbstractClassLoaderDeployer()
{
- return CLASSLOADER_DEPLOYER;
+ super.setRelativeOrder(CLASSLOADER_DEPLOYER);
}
public void deploy(DeploymentUnit unit) throws DeploymentException
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractComponentDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractComponentDeployer.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractComponentDeployer.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -42,11 +42,15 @@
/** The component type */
private Class<C> componentType;
- public int getRelativeOrder()
+ /**
+ * Set the default relative order to COMPONENT_DEPLOYER
+ *
+ */
+ public AbstractComponentDeployer()
{
- return COMPONENT_DEPLOYER;
+ setRelativeOrder(COMPONENT_DEPLOYER);
}
-
+
/**
* Set the component visitor
*
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractParsingDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractParsingDeployer.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractParsingDeployer.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -39,7 +39,8 @@
public abstract class AbstractParsingDeployer<T> extends AbstractTypedDeployer<T>
{
/**
- * Create a new AbstractParsingDeployer.
+ * Create a new AbstractParsingDeployer. Sets the default relative order
+ * to PARSER_DEPLOYER.
*
* @param deploymentType the deployment type
* @throws IllegalArgumentException if the deployment type is null
@@ -47,13 +48,10 @@
protected AbstractParsingDeployer(Class<T> deploymentType)
{
super(deploymentType);
+ // Default the relative order to PARSER_DEPLOYER
+ setRelativeOrder(PARSER_DEPLOYER);
}
- public int getRelativeOrder()
- {
- return PARSER_DEPLOYER;
- }
-
/**
* A flag indicating whether createMetaData should execute a parse even if a non-null metadata value exists.
*
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractRealDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractRealDeployer.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractRealDeployer.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -45,9 +45,13 @@
/** Whether the warning has been displayed */
private boolean warned;
- public int getRelativeOrder()
+ /**
+ * Set the default relative order to REAL_DEPLOYER.
+ *
+ */
+ public AbstractRealDeployer()
{
- return REAL_DEPLOYER;
+ setRelativeOrder(REAL_DEPLOYER);
}
/**
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractSimpleRealDeployer.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractSimpleRealDeployer.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/deployers/helpers/AbstractSimpleRealDeployer.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -34,7 +34,8 @@
public abstract class AbstractSimpleRealDeployer<T> extends AbstractTypedDeployer<T>
{
/**
- * Create a new AbstractSimpleRealDeployer.
+ * Create a new AbstractSimpleRealDeployer. Sets the default relative order
+ * to REAL_DEPLOYER.
*
* @param deploymentType the deployment type
* @throws IllegalArgumentException for a null deployment type
@@ -42,13 +43,9 @@
public AbstractSimpleRealDeployer(Class<T> deploymentType)
{
super(deploymentType);
+ setRelativeOrder(REAL_DEPLOYER);
}
- public int getRelativeOrder()
- {
- return REAL_DEPLOYER;
- }
-
public void deploy(DeploymentUnit unit) throws DeploymentException
{
T deployment = unit.getAttachment(getDeploymentType());
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/explicit/DeclaredStructure.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/explicit/DeclaredStructure.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/explicit/DeclaredStructure.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -41,19 +41,14 @@
public class DeclaredStructure extends AbstractStructureDeployer
{
private static ThreadLocal<StructureMetaData> activeMetaData
- = new ThreadLocal<StructureMetaData>();
+ = new ThreadLocal<StructureMetaData>();
- public DeclaredStructure()
- {
- }
-
/**
- * Overriden to be the highest priority deployer
+ * Set the relative order to 0 by default.
*/
- @Override
- public int getRelativeOrder()
+ public DeclaredStructure()
{
- return 0;
+ setRelativeOrder(0);
}
public boolean determineStructure(VirtualFile root, StructureMetaData metaData, StructuredDeployers deployers)
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/jar/JARStructure.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -41,14 +41,20 @@
{
public JARStructure()
{
-
+ this(null);
}
+ /**
+ * Sets the default relative order 10000.
+ *
+ */
public JARStructure(Set<String> suffixes)
{
- JarUtils.setJarSuffixes(suffixes);
+ if( suffixes != null )
+ JarUtils.setJarSuffixes(suffixes);
+ setRelativeOrder(10000);
}
-
+
/**
* Gets the set of suffixes recognised as jars
*
@@ -68,12 +74,6 @@
JarUtils.setJarSuffixes(suffixes);
}
- @Override
- public int getRelativeOrder()
- {
- return 10000;
- }
-
public boolean determineStructure(VirtualFile root, StructureMetaData metaData, StructuredDeployers deployers)
{
String contextPath = null;
Modified: projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WARStructure.java
===================================================================
--- projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WARStructure.java 2006-11-02 18:48:41 UTC (rev 58018)
+++ projects/microcontainer/trunk/deployers/src/main/org/jboss/deployers/plugins/structure/vfs/war/WARStructure.java 2006-11-02 18:57:08 UTC (rev 58019)
@@ -47,11 +47,14 @@
/** The web-inf/lib filter */
private VirtualFileFilter webInfLibFilter = DEFAULT_WEB_INF_LIB_FILTER;
-
- @Override
- public int getRelativeOrder()
+
+ /**
+ * Sets the default relative order 1000.
+ *
+ */
+ public WARStructure()
{
- return 1000;
+ setRelativeOrder(1000);
}
/**
More information about the jboss-cvs-commits
mailing list