org.codehaus.cargo.generic.deployer
Interface DeployerFactory

All Known Implementing Classes:
DefaultDeployerFactory

public interface DeployerFactory

Create a Deployer knowing the container to which it is attached and the deployer type.

Version:
$Id: DeployerFactory.java 1705 2008-09-02 13:14:55Z adriana $

Method Summary
 Deployer createDeployer(Container container)
          Create a Deployer instance whose type matches the container's type.
 Deployer createDeployer(Container container, DeployerType deployerType)
          Create a Deployer instance matching the specified container and type.
 Class getDeployerClass(String containerId, DeployerType deployerType)
           
 boolean isDeployerRegistered(String containerId, DeployerType deployerType)
           
 void registerDeployer(String containerId, DeployerType deployerType, Class deployerClass)
          Registers a Deployer implementation.
 

Method Detail

registerDeployer

void registerDeployer(String containerId,
                      DeployerType deployerType,
                      Class deployerClass)
Registers a Deployer implementation.

Parameters:
containerId - the container attached to this deployerClass
deployerType - the deployer's type (local, remote, etc)
deployerClass - the deployer implementation class to register

isDeployerRegistered

boolean isDeployerRegistered(String containerId,
                             DeployerType deployerType)
Parameters:
containerId - the container attached to this deployer class
deployerType - the type to differentiate this deployer from others for the specified container
Returns:
true if the specified deployer is already registered or false otherwise

getDeployerClass

Class getDeployerClass(String containerId,
                       DeployerType deployerType)
Parameters:
containerId - the container attached to this deployer class
deployerType - the deployer's type
Returns:
the deployer implementation class

createDeployer

Deployer createDeployer(Container container,
                        DeployerType deployerType)
Create a Deployer instance matching the specified container and type.

Parameters:
container - the container for which we need to create a deployer instance
deployerType - the deployer's type (local, remote, etc)
Returns:
the deployer instance

createDeployer

Deployer createDeployer(Container container)
Create a Deployer instance whose type matches the container's type. For example this creates a local deployer when the container's instance passed is a local container and a remote deployer when the container's instance passed is a remote container.

Parameters:
container - the container for which we need to create a deployer instance
Returns:
the deployer instance


Copyright © 2004-2012 Codehaus. All Rights Reserved.