public interface InterruptibleThreadInfrastructure
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
ITI_LOC
The location in JNDI where this object can be obtained.
|
Modifier and Type | Method and Description |
---|---|
void |
deregister(InterruptObject odi)
Deregisters an
InterruptObject
from the current thread of execution. |
boolean |
isODISupported()
Indicates if the InterruptibleThreadInfrastructure function is supported
within the current runtime environment.
|
void |
register(InterruptObject odi)
Registers an
InterruptObject
with the request running on the current thread of execution. |
static final java.lang.String ITI_LOC
jndi-1.0
needs to be enabled to use JNDI to lookup this object.
This object can also be obtained by resource injection as follows:
@Resource(InterruptibleThreadInfrastructure.ITI_LOC) private InterruptibleThreadInfrastructure _iti;
void register(InterruptObject odi) throws InterruptRegistrationException
InterruptObject
with the request running on the current thread of execution. The
InterruptObject
is placed on a stack, and should be removed by calling
deregister
when the caller has finished processing.odi
- The
InterruptObject
to
register.InterruptRegistrationException
- Thrown if the interrupt object
could not be registered. The cause (if known) will be linked to this
exception.void deregister(InterruptObject odi)
InterruptObject
from the current thread of execution. No errors are generated if the
InterruptObject
is not found in the stack for this thread.odi
- The
InterruptObject
to
deregister.boolean isODISupported()
true
if
InterruptObject
registration is supported on the
current thread, false
if
InterruptObject
registration is not supported
on the current thread.