public abstract class EJBContextImpl extends Object implements javax.ejb.EJBContext, ComponentContext, Serializable
| Modifier and Type | Class and Description |
|---|---|
static class |
EJBContextImpl.BeanState |
| Modifier and Type | Field and Description |
|---|---|
protected BaseContainer |
container |
protected EJBLocalObjectImpl |
ejbLocalBusinessObjectImpl |
protected EJBLocalObjectImpl |
ejbLocalObjectImpl |
protected EJBObjectImpl |
ejbObjectImpl |
protected EJBObjectImpl |
ejbRemoteBusinessObjectImpl |
protected javax.ejb.EJBObject |
ejbStub |
protected boolean |
inEjbRemove |
protected Context |
initialContext |
protected boolean |
isLocalInterfaceSupported |
protected boolean |
isRemoteInterfaceSupported |
protected JCDIService.JCDIInjectionContext |
jcdiInjectionContext |
protected EJBLocalObjectImpl |
optionalEjbLocalBusinessObjectImpl |
protected EJBContextImpl.BeanState |
state |
protected Transaction |
transaction |
| Modifier | Constructor and Description |
|---|---|
protected |
EJBContextImpl(Object ejb,
BaseContainer container) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
checkAccessToCallerSecurity()
Overridden in containers that allow access to isCallerInRole() and
getCallerPrincipal()
|
protected void |
checkActivatePassivate() |
void |
checkTimerServiceMethodAccess()
The EJB spec makes a distinction between access to the TimerService
object itself (via EJBContext.getTimerService) and access to the
methods on TimerService, Timer, and TimerHandle.
|
void |
decrementConcurrentInvokeCount()
Decrement the number of concurrent invocations on this bean
(could happen with re-entrant bean).
|
protected void |
doGetSetRollbackTxAttrCheck() |
Identity |
getCallerIdentity()
Deprecated.
|
Principal |
getCallerPrincipal() |
int |
getConcurrentInvokeCount()
Get the number of concurrent invocations on this bean
(could happen with re-entrant bean).
|
Container |
getContainer()
Get the Container instance which created this Context.
|
Map<String,Object> |
getContextData() |
Object |
getEJB()
Get the EJB instance associated with this context.
|
javax.ejb.EJBHome |
getEJBHome() |
javax.ejb.EJBLocalHome |
getEJBLocalHome() |
javax.ejb.EJBLocalObject |
getEJBLocalObject()
This is a SessionContext/EntityContext method.
|
javax.ejb.EJBObject |
getEJBObject()
This is a SessionContext/EntityContext method.
|
Properties |
getEnvironment() |
Object[] |
getInterceptorInstances() |
protected Object |
getKey() |
long |
getLastTimeUsed() |
List |
getResourceList()
Get all the resources associated with the context
|
boolean |
getRollbackOnly() |
protected EJBContextImpl.BeanState |
getState() |
Transaction |
getTransaction()
Get the Transaction object associated with this Context.
|
UserTransaction |
getUserTransaction() |
protected boolean |
inActivatePassivate() |
protected boolean |
inActivatePassivate(ComponentInvocation inv) |
void |
incrementConcurrentInvokeCount()
Increment the number of concurrent invocations on this bean
(could happen with re-entrant bean).
|
boolean |
isCallerInRole(Identity identity)
Deprecated.
|
boolean |
isCallerInRole(String roleRef) |
Object |
lookup(String name) |
void |
registerResource(ResourceHandle h)
Register a resource opened by the EJB instance
associated with this Context.
|
void |
setRollbackOnly() |
void |
setTransaction(Transaction tr) |
void |
touch() |
void |
unregisterResource(ResourceHandle h)
Unregister a resource from this Context.
|
protected transient BaseContainer container
protected transient Transaction transaction
protected transient Context initialContext
protected transient javax.ejb.EJBObject ejbStub
protected transient EJBObjectImpl ejbObjectImpl
protected transient EJBObjectImpl ejbRemoteBusinessObjectImpl
protected transient EJBLocalObjectImpl ejbLocalObjectImpl
protected transient EJBLocalObjectImpl ejbLocalBusinessObjectImpl
protected transient EJBLocalObjectImpl optionalEjbLocalBusinessObjectImpl
protected transient EJBContextImpl.BeanState state
protected boolean isRemoteInterfaceSupported
protected boolean isLocalInterfaceSupported
protected transient boolean inEjbRemove
protected transient JCDIService.JCDIInjectionContext jcdiInjectionContext
protected EJBContextImpl(Object ejb, BaseContainer container)
public Transaction getTransaction()
ComponentContextgetTransaction in interface ComponentContextpublic void setTransaction(Transaction tr)
protected EJBContextImpl.BeanState getState()
public long getLastTimeUsed()
public void touch()
public Object getEJB()
ComponentContextgetEJB in interface ComponentContextpublic Container getContainer()
ComponentContextgetContainer in interface ComponentContextpublic void registerResource(ResourceHandle h)
public void unregisterResource(ResourceHandle h)
public List getResourceList()
getResourceList in interface ComponentContextgetResourceList in interface ResourceHandlerpublic int getConcurrentInvokeCount()
public void incrementConcurrentInvokeCount()
public void decrementConcurrentInvokeCount()
public javax.ejb.EJBObject getEJBObject()
throws IllegalStateException
IllegalStateExceptionpublic javax.ejb.EJBLocalObject getEJBLocalObject()
throws IllegalStateException
IllegalStateExceptionpublic javax.ejb.EJBHome getEJBHome()
getEJBHome in interface javax.ejb.EJBContextpublic javax.ejb.EJBLocalHome getEJBLocalHome()
getEJBLocalHome in interface javax.ejb.EJBContextpublic Properties getEnvironment()
getEnvironment in interface javax.ejb.EJBContextpublic Identity getCallerIdentity()
getCallerIdentity in interface javax.ejb.EJBContextpublic Principal getCallerPrincipal()
getCallerPrincipal in interface javax.ejb.EJBContextpublic Map<String,Object> getContextData()
getContextData in interface javax.ejb.EJBContextpublic boolean isCallerInRole(Identity identity)
isCallerInRole in interface javax.ejb.EJBContextpublic boolean isCallerInRole(String roleRef)
isCallerInRole in interface javax.ejb.EJBContextprotected void checkAccessToCallerSecurity()
throws IllegalStateException
IllegalStateExceptionpublic UserTransaction getUserTransaction() throws IllegalStateException
getUserTransaction in interface javax.ejb.EJBContextIllegalStateExceptionpublic void setRollbackOnly()
throws IllegalStateException
setRollbackOnly in interface javax.ejb.EJBContextIllegalStateExceptionpublic boolean getRollbackOnly()
throws IllegalStateException
getRollbackOnly in interface javax.ejb.EJBContextIllegalStateExceptionprotected void doGetSetRollbackTxAttrCheck()
public Object[] getInterceptorInstances()
public void checkTimerServiceMethodAccess()
throws IllegalStateException
checkTimerServiceMethodAccess in interface ComponentContextIllegalStateExceptionprotected void checkActivatePassivate()
throws IllegalStateException
IllegalStateExceptionprotected boolean inActivatePassivate()
protected boolean inActivatePassivate(ComponentInvocation inv)
protected Object getKey()
Copyright © 2017. All rights reserved.