|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.deployers.structure.spi.helpers.ComponentDeploymentContext
public class ComponentDeploymentContext
AbstractDeploymentContext.
Field Summary | |
---|---|
protected org.jboss.logging.Logger |
log
The log |
Constructor Summary | |
---|---|
ComponentDeploymentContext()
For serialization |
|
ComponentDeploymentContext(String name,
DeploymentContext parent)
Create a new ComponentDeploymentContext. |
Method Summary | |
---|---|
void |
addChild(DeploymentContext child)
Add a child |
void |
addComponent(DeploymentContext component)
Add a component |
void |
addControllerContextName(Object name)
Add controller context name. |
void |
cleanup()
Cleanup the deployment context |
boolean |
createClassLoader(ClassLoaderFactory factory)
Create a classloader |
void |
deployed()
Touch the context to say it is deployed |
List<ObjectName> |
getChildNames()
The children |
List<DeploymentContext> |
getChildren()
The children |
ClassLoader |
getClassLoader()
Gets the classloader for this deployment unit |
ObjectName |
getClassLoaderName()
Gets the classloader for this deployment unit |
Comparator<DeploymentContext> |
getComparator()
Get the comparator. |
List<ObjectName> |
getComponentNames()
The components |
List<DeploymentContext> |
getComponents()
The components |
Object |
getControllerContextName()
Get underlying controller context name. |
Set<Object> |
getControllerContextNames()
Get the controller context names. |
org.jboss.dependency.spi.DependencyInfo |
getDependencyInfo()
Get the dependency info |
Deployment |
getDeployment()
Get the deployment (if this is a top level context) |
DeploymentUnit |
getDeploymentUnit()
Get the deployment unit |
org.jboss.metadata.spi.MetaData |
getMetaData()
Get the metadata for this deployment context |
org.jboss.metadata.spi.MutableMetaData |
getMutableMetaData()
Get the mutable metadata for this deployment context |
org.jboss.metadata.spi.scope.ScopeKey |
getMutableScope()
Get the mutable scope |
String |
getName()
Get the deployment name |
ObjectName |
getObjectName()
Get the object name |
DeploymentContext |
getParent()
The parent |
ObjectName |
getParentName()
The parent |
Attachments |
getPredeterminedManagedObjects()
Get the predetermined managed objects |
Throwable |
getProblem()
Get the problem for this context |
int |
getRelativeOrder()
Get the relative order |
String |
getRelativePath()
Get the path of this deployment relative to the top of the deployment vfs path ------------------- relative path deploy/some.ear "" deploy/some.ear/x.ejb "/x.ejb" deploy/some.ear/y.sar "/y.sar" deploy/some.ear/y.sar/z.rar "/y.sar/z.rar" |
ClassLoader |
getResourceClassLoader()
Get a resource classloader |
DeploymentResourceLoader |
getResourceLoader()
Get a resource loader |
org.jboss.metadata.spi.scope.ScopeKey |
getScope()
Get the scope |
String |
getSimpleName()
Get the simple vfs name of the deployment unit. |
DeploymentState |
getState()
Get the deployment state |
DeploymentContext |
getTopLevel()
Get the top level deployment |
ObjectName |
getTopLevelName()
Get the top level deployment |
MutableAttachments |
getTransientAttachments()
Get the transient attachments |
MutableAttachments |
getTransientManagedObjects()
Get the transient managed objects |
boolean |
isComponent()
Whether this is a component |
boolean |
isDeployed()
Whether the deployment was processed |
boolean |
isTopLevel()
Whether this is a top level deployment |
String |
listAttachments(boolean detail)
List the attachments as an html table |
protected static void |
listAttachments(StringBuilder builder,
Attachments attachments,
boolean detail,
Set<String> processed)
|
void |
postDeregister()
|
void |
postRegister(Boolean registrationDone)
|
void |
preDeregister()
|
ObjectName |
preRegister(MBeanServer server,
ObjectName name)
|
protected void |
registerMBeans(DeploymentContext context,
boolean registerContext,
boolean registerSubDeployments)
Register mbeans |
boolean |
removeChild(DeploymentContext child)
Remove a child |
void |
removeClassLoader()
Remove the classloader created by the factory |
void |
removeClassLoader(ClassLoaderFactory factory)
Remove the classloader |
boolean |
removeComponent(DeploymentContext component)
Remove a component |
void |
removeControllerContextName(Object name)
Remove controller context name. |
void |
setClassLoader(ClassLoader classLoader)
Set the class loader |
void |
setComparator(Comparator<DeploymentContext> comparator)
Set the comparator. |
void |
setDeployment(Deployment deployment)
Set the deployment |
void |
setDeploymentUnit(DeploymentUnit unit)
Set the deployment unit |
void |
setMetaDataPath(String path)
|
void |
setMutableScope(org.jboss.metadata.spi.scope.ScopeKey mutableScope)
Set the mutable scope |
void |
setParent(DeploymentContext parent)
Set the parent |
void |
setPredeterminedManagedObjects(Attachments objects)
Set the predetermined managed objects |
void |
setProblem(Throwable problem)
Set the problem for this context |
void |
setRelativeOrder(int relativeOrder)
Set the relative order |
void |
setRequiredStage(DeploymentStage stage)
Set the required stage. |
void |
setScope(org.jboss.metadata.spi.scope.ScopeKey scope)
Set the scope |
void |
setState(DeploymentState state)
Set the deployment state |
String |
toString()
|
protected void |
unregisterMBeans(DeploymentContext context,
boolean unregisterContext,
boolean unregisterSubDeployments)
Unregister mbeans |
void |
visit(DeploymentContextVisitor visitor)
Visit the context and the children |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected org.jboss.logging.Logger log
Constructor Detail |
---|
public ComponentDeploymentContext()
public ComponentDeploymentContext(String name, DeploymentContext parent)
name
- the nameparent
- the parent
IllegalArgumentException
- if the name or parent is nullMethod Detail |
---|
public String getName()
DeploymentContext
getName
in interface DeploymentContext
getName
in interface DeploymentMBean
public ObjectName getObjectName()
DeploymentMBean
getObjectName
in interface DeploymentMBean
public Set<Object> getControllerContextNames()
DeploymentContext
getControllerContextNames
in interface DeploymentContext
getControllerContextNames
in interface DeploymentMBean
public void addControllerContextName(Object name)
DeploymentContext
addControllerContextName
in interface DeploymentContext
name
- the controller context namepublic void removeControllerContextName(Object name)
DeploymentContext
removeControllerContextName
in interface DeploymentContext
name
- the controller context namepublic String getSimpleName()
DeploymentContext
getSimpleName
in interface DeploymentContext
getSimpleName
in interface DeploymentMBean
public String getRelativePath()
DeploymentContext
getRelativePath
in interface DeploymentContext
getRelativePath
in interface DeploymentMBean
public int getRelativeOrder()
DeploymentContext
getRelativeOrder
in interface DeploymentContext
getRelativeOrder
in interface DeploymentMBean
public void setRelativeOrder(int relativeOrder)
DeploymentContext
setRelativeOrder
in interface DeploymentContext
relativeOrder
- the relativeOrderpublic Comparator<DeploymentContext> getComparator()
DeploymentContext
getComparator
in interface DeploymentContext
getComparator
in interface DeploymentMBean
public void setComparator(Comparator<DeploymentContext> comparator)
DeploymentContext
setComparator
in interface DeploymentContext
comparator
- the comparator.public org.jboss.metadata.spi.scope.ScopeKey getScope()
DeploymentContext
getScope
in interface DeploymentContext
getScope
in interface DeploymentMBean
public void setScope(org.jboss.metadata.spi.scope.ScopeKey scope)
DeploymentContext
setScope
in interface DeploymentContext
scope
- the scope keypublic org.jboss.metadata.spi.scope.ScopeKey getMutableScope()
DeploymentContext
getMutableScope
in interface DeploymentContext
getMutableScope
in interface DeploymentMBean
public void setMutableScope(org.jboss.metadata.spi.scope.ScopeKey mutableScope)
DeploymentContext
setMutableScope
in interface DeploymentContext
mutableScope
- the mutable scope keypublic org.jboss.metadata.spi.MetaData getMetaData()
DeploymentContext
getMetaData
in interface DeploymentContext
public org.jboss.metadata.spi.MutableMetaData getMutableMetaData()
DeploymentContext
getMutableMetaData
in interface DeploymentContext
public DeploymentState getState()
DeploymentContext
getState
in interface DeploymentContext
getState
in interface DeploymentMBean
public void setState(DeploymentState state)
DeploymentContext
setState
in interface DeploymentContext
state
- the statepublic DeploymentUnit getDeploymentUnit()
DeploymentContext
getDeploymentUnit
in interface DeploymentContext
public void setDeploymentUnit(DeploymentUnit unit)
DeploymentContext
setDeploymentUnit
in interface DeploymentContext
unit
- the deployment unitpublic void setMetaDataPath(String path)
public ClassLoader getClassLoader()
DeploymentContext
getClassLoader
in interface DeploymentContext
public ObjectName getClassLoaderName()
DeploymentMBean
getClassLoaderName
in interface DeploymentMBean
public void setClassLoader(ClassLoader classLoader)
DeploymentContext
setClassLoader
in interface DeploymentContext
classLoader
- the new classloaderpublic boolean createClassLoader(ClassLoaderFactory factory) throws DeploymentException
DeploymentContext
createClassLoader
in interface DeploymentContext
factory
- the factory
DeploymentException
- for any errorpublic void removeClassLoader()
DeploymentContext
removeClassLoader
in interface DeploymentContext
public void removeClassLoader(ClassLoaderFactory factory)
DeploymentContext
removeClassLoader
in interface DeploymentContext
factory
- the original factory used to create the classloaderpublic boolean isTopLevel()
DeploymentContext
isTopLevel
in interface DeploymentContext
isTopLevel
in interface DeploymentMBean
public DeploymentContext getTopLevel()
DeploymentContext
getTopLevel
in interface DeploymentContext
public ObjectName getTopLevelName()
DeploymentMBean
getTopLevelName
in interface DeploymentMBean
public DeploymentContext getParent()
DeploymentContext
getParent
in interface DeploymentContext
public ObjectName getParentName()
DeploymentMBean
getParentName
in interface DeploymentMBean
public void setParent(DeploymentContext parent)
DeploymentContext
setParent
in interface DeploymentContext
parent
- the parentpublic List<DeploymentContext> getChildren()
DeploymentContext
getChildren
in interface DeploymentContext
public List<ObjectName> getChildNames()
DeploymentMBean
getChildNames
in interface DeploymentMBean
public void addChild(DeploymentContext child)
DeploymentContext
addChild
in interface DeploymentContext
child
- the child to addpublic boolean removeChild(DeploymentContext child)
DeploymentContext
removeChild
in interface DeploymentContext
child
- the child to remove
public Deployment getDeployment()
DeploymentContext
getDeployment
in interface DeploymentContext
public void setDeployment(Deployment deployment)
DeploymentContext
setDeployment
in interface DeploymentContext
deployment
- the deploymentpublic boolean isComponent()
DeploymentContext
isComponent
in interface DeploymentContext
isComponent
in interface DeploymentMBean
public List<DeploymentContext> getComponents()
DeploymentContext
getComponents
in interface DeploymentContext
public List<ObjectName> getComponentNames()
DeploymentMBean
getComponentNames
in interface DeploymentMBean
public void addComponent(DeploymentContext component)
DeploymentContext
addComponent
in interface DeploymentContext
component
- the componnet to addpublic boolean removeComponent(DeploymentContext component)
DeploymentContext
removeComponent
in interface DeploymentContext
component
- the component to remove
public ClassLoader getResourceClassLoader()
DeploymentContext
getResourceClassLoader
in interface DeploymentContext
public DeploymentResourceLoader getResourceLoader()
DeploymentContext
getResourceLoader
in interface DeploymentContext
public Object getControllerContextName()
DeploymentContext
getControllerContextName
in interface DeploymentContext
public void setRequiredStage(DeploymentStage stage)
DeploymentContext
setRequiredStage
in interface DeploymentContext
stage
- the required stagepublic org.jboss.dependency.spi.DependencyInfo getDependencyInfo()
DeploymentContext
getDependencyInfo
in interface DeploymentContext
getDependencyInfo
in interface DeploymentMBean
public String listAttachments(boolean detail)
ComponentDeploymentContextMBean
listAttachments
in interface ComponentDeploymentContextMBean
detail
- whether to show the attachment
protected static void listAttachments(StringBuilder builder, Attachments attachments, boolean detail, Set<String> processed)
public void visit(DeploymentContextVisitor visitor) throws DeploymentException
DeploymentContext
visit
in interface DeploymentContext
visitor
- the visitor
DeploymentException
- for any error in the visitorpublic Attachments getPredeterminedManagedObjects()
PredeterminedManagedObjectAttachments
getPredeterminedManagedObjects
in interface PredeterminedManagedObjectAttachments
public void setPredeterminedManagedObjects(Attachments objects)
PredeterminedManagedObjectAttachments
setPredeterminedManagedObjects
in interface PredeterminedManagedObjectAttachments
objects
- the predetermined managed objectspublic MutableAttachments getTransientManagedObjects()
ManagedObjectAttachments
getTransientManagedObjects
in interface ManagedObjectAttachments
public MutableAttachments getTransientAttachments()
ManagedObjectsWithTransientAttachments
getTransientAttachments
in interface ManagedObjectsWithTransientAttachments
public Throwable getProblem()
DeploymentContext
getProblem
in interface DeploymentContext
getProblem
in interface DeploymentMBean
public void setProblem(Throwable problem)
DeploymentContext
setProblem
in interface DeploymentContext
problem
- the problempublic void deployed()
DeploymentContext
deployed
in interface DeploymentContext
public boolean isDeployed()
DeploymentContext
isDeployed
in interface DeploymentContext
isDeployed
in interface DeploymentMBean
public void cleanup()
DeploymentContext
cleanup
in interface DeploymentContext
public ObjectName preRegister(MBeanServer server, ObjectName name) throws Exception
preRegister
in interface MBeanRegistration
Exception
public void postRegister(Boolean registrationDone)
postRegister
in interface MBeanRegistration
public void preDeregister() throws Exception
preDeregister
in interface MBeanRegistration
Exception
public void postDeregister()
postDeregister
in interface MBeanRegistration
protected void registerMBeans(DeploymentContext context, boolean registerContext, boolean registerSubDeployments)
context
- the contextregisterContext
- whether to register the context or just its children and componentsregisterSubDeployments
- whether to register subdeploymentsprotected void unregisterMBeans(DeploymentContext context, boolean unregisterContext, boolean unregisterSubDeployments)
context
- the contextunregisterContext
- whether to unregister the context or just its children and componentsunregisterSubDeployments
- whether to unregister subdeploymentspublic String toString()
toString
in class Object
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |