org.openejb.core
Class ContainerSystem

java.lang.Object
  extended by org.openejb.core.ContainerSystem
All Implemented Interfaces:
ContainerSystem

public class ContainerSystem
extends java.lang.Object
implements ContainerSystem


Constructor Summary
ContainerSystem()
           
 
Method Summary
 void addContainer(java.lang.Object id, Container c)
          Adds a Container to the list of those that are managed by this container system.
 void addDeployment(DeploymentInfo deployment)
          Adds a DeploymentInfo object to the list of those that are registered by this container System.
 Container[] containers()
          Gets all the Containers in this container system.
 DeploymentInfo[] deployments()
          Gets the DeploymentInfo objects for all the beans deployed in all the containers in this container system.
 Container getContainer(java.lang.Object id)
          Returns the Container in this container system with the specified id.
 DeploymentInfo getDeploymentInfo(java.lang.Object id)
          Gets the DeploymentInfo object for the bean with the specified deployment id.
 javax.naming.Context getJNDIContext()
          Returns the global JNDI name space for the OpenEJB container system.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ContainerSystem

public ContainerSystem()
Method Detail

getDeploymentInfo

public DeploymentInfo getDeploymentInfo(java.lang.Object id)
Gets the DeploymentInfo object for the bean with the specified deployment id.

Specified by:
getDeploymentInfo in interface ContainerSystem
Parameters:
id - the deployment id of the deployed bean.
Returns:
the DeploymentInfo object associated with the bean.
See Also:
DeploymentInfo, Container.getDeploymentInfo, DeploymentInfo.getDeploymentID()

deployments

public DeploymentInfo[] deployments()
Gets the DeploymentInfo objects for all the beans deployed in all the containers in this container system.

Specified by:
deployments in interface ContainerSystem
Returns:
an array of DeploymentInfo objects
See Also:
DeploymentInfo, Container.deployments()

getContainer

public Container getContainer(java.lang.Object id)
Returns the Container in this container system with the specified id.

Specified by:
getContainer in interface ContainerSystem
Parameters:
id - the id of the Container
Returns:
the Container associated with the id
See Also:
Container

containers

public Container[] containers()
Gets all the Containers in this container system.

Specified by:
containers in interface ContainerSystem
Returns:
an array of all the Containers
See Also:
Container

addContainer

public void addContainer(java.lang.Object id,
                         Container c)
Adds a Container to the list of those that are managed by this container system. If a Container previously existed with the same id it will be replaced.

Parameters:
id - the id of the Container
c - Container to manage
See Also:
Container

addDeployment

public void addDeployment(DeploymentInfo deployment)
Adds a DeploymentInfo object to the list of those that are registered by this container System. If a DeploymentInfo object previously existed with the same id it will be replaced. Also adds deployment to OpenEJB's global JNDI Name Space under the context java:openejb/ejb/deployment-id The global JNDI name space contains bindings for all enterprise bean EJBHome object deployed in the entire container system. EJBHome objects are bound using their deployment-id under the java:openejb/ejb/ namespace. For example, an enterprise bean with the deployment id = 55555 would be have its EJBHome bound to the name "java:openejb/ejb/55555"

Parameters:
deployment -
See Also:
DeploymentInfo

getJNDIContext

public javax.naming.Context getJNDIContext()
Returns the global JNDI name space for the OpenEJB container system. The global JNDI name space contains bindings for all enterprise bean EJBHome object deployed in the entire container system. EJBHome objects are bound using their deployment-id under the java:openejb/ejb/ namespace. For example, an enterprise bean with the deployment id = 55555 would be have its EJBHome bound to the name "java:openejb/ejb/55555"

Specified by:
getJNDIContext in interface ContainerSystem
Returns:
the global JNDI context


Copyright © 1999-2011 OpenEJB. All Rights Reserved.