Package org.glassfish.api.invocation
Class ComponentInvocation
- java.lang.Object
-
- org.glassfish.api.invocation.ComponentInvocation
-
- All Implemented Interfaces:
Cloneable
- Direct Known Subclasses:
EjbInvocation
,WebComponentInvocation
@PerLookup @Service public class ComponentInvocation extends Object implements Cloneable
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
ComponentInvocation.ComponentInvocationType
-
Field Summary
Fields Modifier and Type Field Description protected String
appName
String
componentId
Object
container
ServletContext for servlet, Container for EJBObject
instance
The component instance, type Servlet, Filter or EnterpriseBeanObject
jndiEnvironment
protected String
moduleName
Object
oldSecurityContext
security context coming in a call security context changes on a runas call - on a run as call the old logged in security context is stored in here.protected String
registrationName
Object
transaction
-
Constructor Summary
Constructors Constructor Description ComponentInvocation()
ComponentInvocation(String componentId, ComponentInvocation.ComponentInvocationType invocationType, Object instance, Object container, Object transaction)
ComponentInvocation(String componentId, ComponentInvocation.ComponentInvocationType invocationType, Object container, String appName, String moduleName, String registrationName)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearRegistry()
ComponentInvocation
clone()
String
getAppName()
Returns the appName for the current invocation, equivalent to the value bound to java:app/AppName, without the cost of lookup.Boolean
getAuth()
String
getComponentId()
Object
getContainer()
Object
getContainerContext()
Object
getInstance()
String
getInstanceName()
ComponentInvocation.ComponentInvocationType
getInvocationType()
Object
getJndiEnvironment()
Object
getJNDIEnvironment()
String
getModuleName()
Returns the moduleName for the current invocation, equivalent to the value bound to java:module/ModuleName, without the cost of lookup.Object
getOldSecurityContext()
Gets the security context of the call that came in before a new context for runas is madeString
getRegistrationName()
Returns the unique registration name of application.Map<Class<?>,Object>
getRegistry()
<T> T
getRegistryFor(Class<T> key)
ResourceHandler
getResourceHandler()
Object
getResourceTableKey()
Object
getTransaction()
Object
getTransactionOperationsManager()
boolean
isPreInvokeDone()
boolean
isPreInvokeDoneStatus()
boolean
isTransactionCompleting()
void
setAppName(String appName)
void
setAuth(boolean value)
void
setAuth(Boolean auth)
void
setComponentId(String componentId)
void
setComponentInvocationType(ComponentInvocation.ComponentInvocationType t)
void
setContainer(Object container)
void
setInstance(Object instance)
void
setInstanceName(String instanceName)
void
setInvocationType(ComponentInvocation.ComponentInvocationType invocationType)
void
setJndiEnvironment(Object jndiEnvironment)
void
setJNDIEnvironment(Object val)
void
setModuleName(String moduleName)
void
setOldSecurityContext(Object sc)
Sets the security context of the call coming invoid
setPreInvokeDone(boolean value)
void
setPreInvokeDoneStatus(boolean preInvokeDoneStatus)
void
setRegistrationName(String registrationName)
void
setRegistry(Map<Class<?>,Object> registry)
<T> void
setRegistryFor(Class<T> key, T payLoad)
Associate givenregistry with given
key
for this invocationvoid
setResourceHandler(ResourceHandler h)
void
setResourceTableKey(Object key)
void
setTransaction(Object t)
void
setTransactionCompeting(boolean value)
void
setTransactionCompleting(boolean transactionCompleting)
void
setTransactionOperationsManager(Object transactionOperationsManager)
String
toString()
-
-
-
Field Detail
-
instance
public Object instance
The component instance, type Servlet, Filter or EnterpriseBean
-
container
public Object container
ServletContext for servlet, Container for EJB
-
jndiEnvironment
public Object jndiEnvironment
-
componentId
public String componentId
-
transaction
public Object transaction
-
oldSecurityContext
public Object oldSecurityContext
security context coming in a call security context changes on a runas call - on a run as call the old logged in security context is stored in here.
-
appName
protected String appName
-
moduleName
protected String moduleName
-
registrationName
protected String registrationName
-
-
Constructor Detail
-
ComponentInvocation
public ComponentInvocation()
-
ComponentInvocation
public ComponentInvocation(String componentId, ComponentInvocation.ComponentInvocationType invocationType, Object container, String appName, String moduleName, String registrationName)
-
ComponentInvocation
public ComponentInvocation(String componentId, ComponentInvocation.ComponentInvocationType invocationType, Object instance, Object container, Object transaction)
-
-
Method Detail
-
getInvocationType
public ComponentInvocation.ComponentInvocationType getInvocationType()
-
setInvocationType
public void setInvocationType(ComponentInvocation.ComponentInvocationType invocationType)
-
setComponentInvocationType
public void setComponentInvocationType(ComponentInvocation.ComponentInvocationType t)
-
isPreInvokeDone
public boolean isPreInvokeDone()
-
setPreInvokeDone
public void setPreInvokeDone(boolean value)
-
getAuth
public Boolean getAuth()
-
setAuth
public void setAuth(Boolean auth)
-
setAuth
public void setAuth(boolean value)
-
isPreInvokeDoneStatus
public boolean isPreInvokeDoneStatus()
-
setPreInvokeDoneStatus
public void setPreInvokeDoneStatus(boolean preInvokeDoneStatus)
-
getInstance
public Object getInstance()
-
setInstance
public void setInstance(Object instance)
-
getInstanceName
public String getInstanceName()
-
setInstanceName
public void setInstanceName(String instanceName)
-
getComponentId
public String getComponentId()
-
setComponentId
public void setComponentId(String componentId)
-
getJndiEnvironment
public Object getJndiEnvironment()
-
setJndiEnvironment
public void setJndiEnvironment(Object jndiEnvironment)
-
setJNDIEnvironment
public void setJNDIEnvironment(Object val)
-
getJNDIEnvironment
public Object getJNDIEnvironment()
-
getContainer
public Object getContainer()
-
setContainer
public void setContainer(Object container)
-
getContainerContext
public Object getContainerContext()
-
getTransaction
public Object getTransaction()
-
setTransaction
public void setTransaction(Object t)
-
setTransactionCompleting
public void setTransactionCompleting(boolean transactionCompleting)
-
getAppName
public String getAppName()
Returns the appName for the current invocation, equivalent to the value bound to java:app/AppName, without the cost of lookup. For standalone modules, returns the same value as getModuleName(). For invocations that are not on Java EE components, returns null.
-
setAppName
public void setAppName(String appName)
-
getModuleName
public String getModuleName()
Returns the moduleName for the current invocation, equivalent to the value bound to java:module/ModuleName, without the cost of lookup. For invocations that are not on Java EE components, returns null.
-
setModuleName
public void setModuleName(String moduleName)
-
getRegistrationName
public String getRegistrationName()
Returns the unique registration name of application.- Returns:
-
setRegistrationName
public void setRegistrationName(String registrationName)
-
setTransactionOperationsManager
public void setTransactionOperationsManager(Object transactionOperationsManager)
-
getTransactionOperationsManager
public Object getTransactionOperationsManager()
-
setOldSecurityContext
public void setOldSecurityContext(Object sc)
Sets the security context of the call coming in
-
getOldSecurityContext
public Object getOldSecurityContext()
Gets the security context of the call that came in before a new context for runas is made
-
isTransactionCompleting
public boolean isTransactionCompleting()
-
setTransactionCompeting
public void setTransactionCompeting(boolean value)
-
setResourceTableKey
public void setResourceTableKey(Object key)
-
getResourceTableKey
public Object getResourceTableKey()
-
setResourceHandler
public void setResourceHandler(ResourceHandler h)
-
getResourceHandler
public ResourceHandler getResourceHandler()
-
getRegistryFor
public <T> T getRegistryFor(Class<T> key)
- Returns:
- Registry associated with this invocation for the given
key
-
setRegistryFor
public <T> void setRegistryFor(Class<T> key, T payLoad)
Associate givenregistry with given
key
for this invocation
-
clearRegistry
public void clearRegistry()
-
clone
public ComponentInvocation clone()
-
-