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()
ComponentContext
getTransaction
in interface ComponentContext
public void setTransaction(Transaction tr)
protected EJBContextImpl.BeanState getState()
public long getLastTimeUsed()
public void touch()
public Object getEJB()
ComponentContext
getEJB
in interface ComponentContext
public Container getContainer()
ComponentContext
getContainer
in interface ComponentContext
public void registerResource(ResourceHandle h)
public void unregisterResource(ResourceHandle h)
public List getResourceList()
getResourceList
in interface ComponentContext
getResourceList
in interface ResourceHandler
public int getConcurrentInvokeCount()
public void incrementConcurrentInvokeCount()
public void decrementConcurrentInvokeCount()
public javax.ejb.EJBObject getEJBObject() throws IllegalStateException
IllegalStateException
public javax.ejb.EJBLocalObject getEJBLocalObject() throws IllegalStateException
IllegalStateException
public javax.ejb.EJBHome getEJBHome()
getEJBHome
in interface javax.ejb.EJBContext
public javax.ejb.EJBLocalHome getEJBLocalHome()
getEJBLocalHome
in interface javax.ejb.EJBContext
public Properties getEnvironment()
getEnvironment
in interface javax.ejb.EJBContext
public Identity getCallerIdentity()
getCallerIdentity
in interface javax.ejb.EJBContext
public Principal getCallerPrincipal()
getCallerPrincipal
in interface javax.ejb.EJBContext
public Map<String,Object> getContextData()
getContextData
in interface javax.ejb.EJBContext
public boolean isCallerInRole(Identity identity)
isCallerInRole
in interface javax.ejb.EJBContext
public boolean isCallerInRole(String roleRef)
isCallerInRole
in interface javax.ejb.EJBContext
protected void checkAccessToCallerSecurity() throws IllegalStateException
IllegalStateException
public UserTransaction getUserTransaction() throws IllegalStateException
getUserTransaction
in interface javax.ejb.EJBContext
IllegalStateException
public void setRollbackOnly() throws IllegalStateException
setRollbackOnly
in interface javax.ejb.EJBContext
IllegalStateException
public boolean getRollbackOnly() throws IllegalStateException
getRollbackOnly
in interface javax.ejb.EJBContext
IllegalStateException
protected void doGetSetRollbackTxAttrCheck()
public Object[] getInterceptorInstances()
public void checkTimerServiceMethodAccess() throws IllegalStateException
checkTimerServiceMethodAccess
in interface ComponentContext
IllegalStateException
protected void checkActivatePassivate() throws IllegalStateException
IllegalStateException
protected boolean inActivatePassivate()
protected boolean inActivatePassivate(ComponentInvocation inv)
protected Object getKey()
Copyright © 2020. All rights reserved.