org.objectweb.easybeans.deployer
Class AbsWebContainerDeployer

java.lang.Object
  extended by org.objectweb.easybeans.deployer.AbsDeployer
      extended by org.objectweb.easybeans.deployer.AbsWebContainerDeployer
All Implemented Interfaces:
EZBDeployer
Direct Known Subclasses:
JettyDeployer, TomcatDeployer

public abstract class AbsWebContainerDeployer
extends AbsDeployer

This class manage the deployment of EAR for web container. It extracts EJB3 and send them to EasyBeans while the War are given to the web container.

Author:
Florent Benoit

Field Summary
private static JLog logger
          Logger.
 
Fields inherited from class org.objectweb.easybeans.deployer.AbsDeployer
DEFAULT_FOLDER
 
Constructor Summary
AbsWebContainerDeployer()
           
 
Method Summary
protected  void deployEAR(EARDeployable earDeployable)
          Deploy an EAR (called by the deploy method).
protected abstract  void deployWARs(EARDeployable earDeployable, java.net.URL earURL, java.lang.ClassLoader earClassLoader, java.lang.ClassLoader parentClassLoader)
          Deploy the WAR files present in the given EAR.
 void undeploy(EZBDeployable deployable)
          Undeploy the given deployable.
protected  void undeployEAR(EARDeployable tmpEARDeployable)
          Undeploy an EAR (called by the undeploy method).
protected abstract  void undeployWAR(WARDeployable warDeployable)
          Undeploy an given WAR (called by the undeploy method).
 
Methods inherited from class org.objectweb.easybeans.deployer.AbsDeployer
deployEJB, getClassLoaderForEAR, getEmbedded, getMethod, getPersistenceUnitManager, invoke, loadClass, loadClass, newInstance, newInstance, setEmbedded, undeployEJB3FromEAR, unpackEARDeployable
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.objectweb.easybeans.deployer.api.EZBDeployer
deploy
 

Field Detail

logger

private static JLog logger
Logger.

Constructor Detail

AbsWebContainerDeployer

public AbsWebContainerDeployer()
Method Detail

deployWARs

protected abstract void deployWARs(EARDeployable earDeployable,
                                   java.net.URL earURL,
                                   java.lang.ClassLoader earClassLoader,
                                   java.lang.ClassLoader parentClassLoader)
                            throws EZBDeployerException
Deploy the WAR files present in the given EAR.

Parameters:
earDeployable - the EAR containing the WARs
earURL - the EAR URL
earClassLoader - the EAR classloader
parentClassLoader - the parent classloader (EJB) to use
Throws:
EZBDeployerException - if the wars are not deployed.

deployEAR

protected void deployEAR(EARDeployable earDeployable)
                  throws EZBDeployerException
Deploy an EAR (called by the deploy method).

Parameters:
earDeployable - a given EAR deployable
Throws:
EZBDeployerException - if the deployment is not done.

undeployEAR

protected void undeployEAR(EARDeployable tmpEARDeployable)
                    throws EZBDeployerException
Undeploy an EAR (called by the undeploy method).

Parameters:
tmpEARDeployable - a given EAR deployable
Throws:
EZBDeployerException - if the undeployment is not done.

undeploy

public void undeploy(EZBDeployable deployable)
              throws EZBDeployerException
Undeploy the given deployable. It can be an EJB jar, EAR, WAR, etc.

Parameters:
deployable - a given deployable to undeploy
Throws:
EZBDeployerException - if the undeploy operation fails.

undeployWAR

protected abstract void undeployWAR(WARDeployable warDeployable)
                             throws EZBDeployerException
Undeploy an given WAR (called by the undeploy method).

Parameters:
warDeployable - a given WAR deployable
Throws:
EZBDeployerException - if the undeployment is not done.