javax.enterprise.deploy.spi
Interface DeploymentManager

All Known Implementing Classes:
DeploymentManagerImpl (src)

public interface DeploymentManager

The DeploymentManager object provides the core set of functions a J2EE platform must provide for J2EE application deployment. It provides server related information, such as, a list of deployment targets, and vendor unique runtime configuration information.


Method Summary
 DeploymentConfiguration (src) createConfiguration(DeployableObject (src)  obj)
          Retrieve server specific configuration for a component
 ProgressObject (src) distribute(Target (src) [] targets, java.io.File moduleArchive, java.io.File deploymentPlan)
          Validates the configuration, generates all container specific classes and moves the archive to the targets
 ProgressObject (src) distribute(Target (src) [] targets, java.io.InputStream moduleArchive, java.io.InputStream deploymentPlan)
          Validates the configuration, generates all container specific classes and moves the archive to the targets
 TargetModuleID (src) [] getAvailableModules(ModuleType (src)  moduleType, Target (src) [] targets)
          Get the available modules both running and non running
 java.util.Locale getCurrentLocale()
          Get the current local
 DConfigBeanVersionType (src) getDConfigBeanVersion()
          Get the J2EE platform version
 java.util.Locale getDefaultLocale()
          Get the default locale
 TargetModuleID (src) [] getNonRunningModules(ModuleType (src)  moduleType, Target (src) [] targets)
          Get the non running modules
 TargetModuleID (src) [] getRunningModules(ModuleType (src)  moduleType, Target (src) [] targets)
          Get the running modules
 java.util.Locale[] getSupportedLocales()
          Get the supported locales
 Target (src) [] getTargets()
          Get the available targets
 boolean isDConfigBeanVersionSupported(DConfigBeanVersionType (src)  version)
          Test whether the version is supported
 boolean isLocaleSupported(java.util.Locale locale)
          Is the locale supported
 boolean isRedeploySupported()
          Is redeploy supported
 ProgressObject (src) redeploy(TargetModuleID (src) [] moduleIDList, java.io.File moduleArchive, java.io.File deploymentPlan)
          Redeploys the modules
 ProgressObject (src) redeploy(TargetModuleID (src) [] moduleIDList, java.io.InputStream moduleArchive, java.io.InputStream deploymentPlan)
          Redeploys the modules
 void release()
          Release the deployment manager
 void setDConfigBeanVersion(DConfigBeanVersionType (src)  version)
          Set the J2EE version
 void setLocale(java.util.Locale locale)
          Set the locale
 ProgressObject (src) start(TargetModuleID (src) [] moduleIDList)
          Start the modules
 ProgressObject (src) stop(TargetModuleID (src) [] moduleIDList)
          Stop the modules
 ProgressObject (src) undeploy(TargetModuleID (src) [] moduleIDList)
          Removes the modules
 

Method Detail

getTargets

public Target (src) [] getTargets()
                    throws java.lang.IllegalStateException
Get the available targets

Returns:
the available targets
Throws:
java.lang.IllegalStateException - when the manager is disconnected

getRunningModules

public TargetModuleID (src) [] getRunningModules(ModuleType (src)  moduleType,
                                          Target (src) [] targets)
                                   throws TargetException (src) ,
                                          java.lang.IllegalStateException
Get the running modules

Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
TargetException (src) - an invalid target
java.lang.IllegalStateException - when the manager is disconnected

getNonRunningModules

public TargetModuleID (src) [] getNonRunningModules(ModuleType (src)  moduleType,
                                             Target (src) [] targets)
                                      throws TargetException (src) ,
                                             java.lang.IllegalStateException
Get the non running modules

Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
TargetException (src) - an invalid target
java.lang.IllegalStateException - when the manager is disconnected

getAvailableModules

public TargetModuleID (src) [] getAvailableModules(ModuleType (src)  moduleType,
                                            Target (src) [] targets)
                                     throws TargetException (src) ,
                                            java.lang.IllegalStateException
Get the available modules both running and non running

Parameters:
moduleType - the module type
targets - the targets
Returns:
the target modules
Throws:
TargetException (src) - an invalid target
java.lang.IllegalStateException - when the manager is disconnected

createConfiguration

public DeploymentConfiguration (src)  createConfiguration(DeployableObject (src)  obj)
                                            throws InvalidModuleException (src) 
Retrieve server specific configuration for a component

Parameters:
obj - the deployable component
Returns:
the configuration
Throws:
InvalidModuleException (src) - when the module does not exist or is not supported

distribute

public ProgressObject (src)  distribute(Target (src) [] targets,
                                 java.io.File moduleArchive,
                                 java.io.File deploymentPlan)
                          throws java.lang.IllegalStateException
Validates the configuration, generates all container specific classes and moves the archive to the targets

Parameters:
targets - the targets
moduleArchive - the module archive
deploymentPlan - the runtime configuration
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected

distribute

public ProgressObject (src)  distribute(Target (src) [] targets,
                                 java.io.InputStream moduleArchive,
                                 java.io.InputStream deploymentPlan)
                          throws java.lang.IllegalStateException
Validates the configuration, generates all container specific classes and moves the archive to the targets

Parameters:
targets - the targets
moduleArchive - the module archive
deploymentPlan - the runtime configuration
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected

start

public ProgressObject (src)  start(TargetModuleID (src) [] moduleIDList)
                     throws java.lang.IllegalStateException
Start the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected

stop

public ProgressObject (src)  stop(TargetModuleID (src) [] moduleIDList)
                    throws java.lang.IllegalStateException
Stop the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected

undeploy

public ProgressObject (src)  undeploy(TargetModuleID (src) [] moduleIDList)
                        throws java.lang.IllegalStateException
Removes the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected

isRedeploySupported

public boolean isRedeploySupported()
Is redeploy supported

Returns:
true when redeploy is supported, false otherwise

redeploy

public ProgressObject (src)  redeploy(TargetModuleID (src) [] moduleIDList,
                               java.io.File moduleArchive,
                               java.io.File deploymentPlan)
                        throws java.lang.UnsupportedOperationException,
                               java.lang.IllegalStateException
Redeploys the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected
java.lang.UnsupportedOperationException - when redeploy is not supported

redeploy

public ProgressObject (src)  redeploy(TargetModuleID (src) [] moduleIDList,
                               java.io.InputStream moduleArchive,
                               java.io.InputStream deploymentPlan)
                        throws java.lang.UnsupportedOperationException,
                               java.lang.IllegalStateException
Redeploys the modules

Parameters:
moduleIDList - the list of modules
Returns:
the progress object
Throws:
java.lang.IllegalStateException - when the manager is disconnected
java.lang.UnsupportedOperationException - when redeploy is not supported

release

public void release()
Release the deployment manager


getDefaultLocale

public java.util.Locale getDefaultLocale()
Get the default locale

Returns:
the default locale

getCurrentLocale

public java.util.Locale getCurrentLocale()
Get the current local

Returns:
the current locale

setLocale

public void setLocale(java.util.Locale locale)
               throws java.lang.UnsupportedOperationException
Set the locale

Parameters:
locale - the new local
Throws:
java.lang.UnsupportedOperationException - when the locale is not supported

getSupportedLocales

public java.util.Locale[] getSupportedLocales()
Get the supported locales

Returns:
the supported locales

isLocaleSupported

public boolean isLocaleSupported(java.util.Locale locale)
Is the locale supported

Parameters:
locale - the locale
Returns:
true when supported, false otherwise

getDConfigBeanVersion

public DConfigBeanVersionType (src)  getDConfigBeanVersion()
Get the J2EE platform version

Returns:
the version

isDConfigBeanVersionSupported

public boolean isDConfigBeanVersionSupported(DConfigBeanVersionType (src)  version)
Test whether the version is supported

Parameters:
version - the version
Returns:
true when supported, false otherwise

setDConfigBeanVersion

public void setDConfigBeanVersion(DConfigBeanVersionType (src)  version)
                           throws DConfigBeanVersionUnsupportedException (src) 
Set the J2EE version

Parameters:
version - the version
Throws:
java.lang.UnsupportedOperationException - when the version is not supported
DConfigBeanVersionUnsupportedException (src)