Class DefaultDeployerFactory

    • Constructor Detail

      • DefaultDeployerFactory

        public DefaultDeployerFactory()
        Register default deployers.
    • Method Detail

      • registerDeployer

        public void registerDeployer​(String containerId,
                                     DeployerType deployerType,
                                     Class<? extends Deployer> deployerClass)
        Registers a Deployer implementation.
        Specified by:
        registerDeployer in interface DeployerFactory
        Parameters:
        containerId - the container attached to this deployerClass
        deployerType - the deployer's type (local, remote, etc)
        deployerClass - the deployer implementation class to register
      • registerDeployer

        public void registerDeployer​(String containerId,
                                     DeployerType deployerType,
                                     String deployerClassName)
        Registers a deployer using a class specified as a String.
        Parameters:
        containerId - Container id.
        deployerType - Deployer type.
        deployerClassName - Deployer implementation class to register as a String
        See Also:
        registerDeployer(String, DeployerType, Class)
      • isDeployerRegistered

        public boolean isDeployerRegistered​(String containerId,
                                            DeployerType deployerType)
        Specified by:
        isDeployerRegistered in interface DeployerFactory
        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

        public Class<? extends Deployer> getDeployerClass​(String containerId,
                                                          DeployerType deployerType)
        Specified by:
        getDeployerClass in interface DeployerFactory
        Parameters:
        containerId - the container attached to this deployer class
        deployerType - the deployer's type
        Returns:
        the deployer implementation class
      • createDeployer

        public Deployer createDeployer​(Container container,
                                       DeployerType deployerType)
        Create a Deployer instance matching the specified container and type.
        Specified by:
        createDeployer in interface DeployerFactory
        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

        public 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.
        Specified by:
        createDeployer in interface DeployerFactory
        Parameters:
        container - the container for which we need to create a deployer instance
        Returns:
        the deployer instance