Package org.glassfish.deployment.common
Class SimpleDeployer<T extends Container,U extends ApplicationContainer>
- java.lang.Object
-
- org.glassfish.deployment.common.SimpleDeployer<T,U>
-
- All Implemented Interfaces:
Deployer<T,U>
- Direct Known Subclasses:
JPADeployer,MetroDeployer,SecurityDeployer,WeldDeployer
public abstract class SimpleDeployer<T extends Container,U extends ApplicationContainer> extends Object implements Deployer<T,U>
Convenient superclass for Deployers which only do prepare and clean up and do not actually load/unload application
-
-
Constructor Summary
Constructors Constructor Description SimpleDeployer()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description voidclean(DeploymentContext context)Clean any files and artifacts that were created during the execution of the prepare method.protected abstract voidcleanArtifacts(DeploymentContext dc)protected abstract voidgenerateArtifacts(DeploymentContext dc)MetaDatagetMetaData()Returns the meta data assocated with this DeployerUload(T container, DeploymentContext context)No-op<V> VloadMetaData(Class<V> type, DeploymentContext context)Loads the meta date associated with the application.booleanprepare(DeploymentContext dc)Prepares the application bits for running in the application server.voidunload(U appContainer, DeploymentContext context)No-op
-
-
-
Method Detail
-
loadMetaData
public <V> V loadMetaData(Class<V> type, DeploymentContext context)
Loads the meta date associated with the application.- Specified by:
loadMetaDatain interfaceDeployer<T extends Container,U extends ApplicationContainer>- Parameters:
type- type of meta-data that this deployer has declared providing.- Returns:
- the meta-data of type V
-
prepare
public boolean prepare(DeploymentContext dc)
Prepares the application bits for running in the application server. For certain cases, this is generating non portable artifacts and other application specific tasks. Failure to prepare should throw an exception which will cause the overall deployment to fail.
-
load
public U load(T container, DeploymentContext context)
No-op
-
unload
public void unload(U appContainer, DeploymentContext context)
No-op
-
clean
public void clean(DeploymentContext context)
Clean any files and artifacts that were created during the execution of the prepare method.
-
getMetaData
public MetaData getMetaData()
Returns the meta data assocated with this Deployer- Specified by:
getMetaDatain interfaceDeployer<T extends Container,U extends ApplicationContainer>- Returns:
- the meta data for this Deployer
-
generateArtifacts
protected abstract void generateArtifacts(DeploymentContext dc) throws DeploymentException
- Throws:
DeploymentException
-
cleanArtifacts
protected abstract void cleanArtifacts(DeploymentContext dc) throws DeploymentException
- Throws:
DeploymentException
-
-