public class BasicComponentInstance extends Object implements ComponentInstance
Modifier and Type | Field and Description |
---|---|
static Object |
INSTANCE_KEY |
Modifier | Constructor and Description |
---|---|
protected |
BasicComponentInstance(BasicComponent component,
AtomicReference<ManagedReference> instanceReference,
org.jboss.invocation.Interceptor preDestroyInterceptor,
Map<Method,org.jboss.invocation.Interceptor> methodInterceptors)
Construct a new instance.
|
Modifier and Type | Method and Description |
---|---|
Collection<Method> |
allowedMethods()
Get the list of allowed methods for this component instance.
|
void |
destroy()
Destroy this component instance.
|
Component |
getComponent()
Get the component associated with this instance.
|
Object |
getInstance()
Get the actual object instance.
|
protected AtomicReference<ManagedReference> |
getInstanceReference() |
org.jboss.invocation.Interceptor |
getInterceptor(Method method)
Get the instance interceptor (entry point) for the given method.
|
protected void |
preDestroy()
Method that sub classes can use to override destroy logic.
|
protected org.jboss.invocation.InterceptorContext |
prepareInterceptorContext() |
public static final Object INSTANCE_KEY
protected BasicComponentInstance(BasicComponent component, AtomicReference<ManagedReference> instanceReference, org.jboss.invocation.Interceptor preDestroyInterceptor, Map<Method,org.jboss.invocation.Interceptor> methodInterceptors)
component
- the componentpublic Component getComponent()
getComponent
in interface ComponentInstance
public Object getInstance()
getInstance
in interface ComponentInstance
public org.jboss.invocation.Interceptor getInterceptor(Method method) throws IllegalStateException
getInterceptor
in interface ComponentInstance
method
- the methodIllegalStateException
- if the method does not existpublic Collection<Method> allowedMethods()
Method
objects.allowedMethods
in interface ComponentInstance
public final void destroy()
destroy
in interface ComponentInstance
protected void preDestroy()
protected org.jboss.invocation.InterceptorContext prepareInterceptorContext()
protected AtomicReference<ManagedReference> getInstanceReference()
Copyright © 2013 JBoss, a division of Red Hat, Inc.. All Rights Reserved.