java.lang.Thread#interrupt() source,
intended for java.lang.Thread specializations.
| Modifier and Type | Class and Description |
|---|---|
| public static class | InterruptSource.
|
| public static class |
| Modifier and Type | Method and Description |
|---|---|
| public void | |
| public int | getInterruptCounter(final boolean
if true, issues clear)clearInterruptSource()Returns the count of |
| public Throwable | getInterruptSource(final boolean
if true, issues clear)clearInterruptSource()Returns the source of the last |
| clearInterruptSource | back to summary |
|---|---|
| public void clearInterruptSource() Clears source and count of | |
| getInterruptCounter | back to summary |
|---|---|
| public int getInterruptCounter(final boolean clear) Returns the count of
| |
| getInterruptSource | back to summary |
|---|---|
| public Throwable getInterruptSource(final boolean clear) Returns the source of the last
| |
java.lang.Thread specialization implementing InterruptSource
to track java.lang.Thread#interrupt() calls.
| Modifier and Type | Field and Description |
|---|---|
| pack-priv volatile int | |
| pack-priv volatile Throwable | |
| pack-priv final Object |
| Access | Constructor and Description |
|---|---|
| public | |
| public | Thread(final ThreadGroup
explicit tg, final Runnable ThreadGroup, may be nullexplicit target)Runnable, may be nullSee |
| public | Thread(final ThreadGroup
explicit tg, final Runnable ThreadGroup, may be nullexplicit target, final String Runnable, may be nullexplicit name of thread, must not be name)nullSee |
| Modifier and Type | Method and Description |
|---|---|
| public final void | clearInterruptSource()
Implements com. java. calls, if any.
|
| public static InterruptSource. | create(final ThreadGroup
explicit tg, final Runnable ThreadGroup, may be nullexplicit target, final String Runnable, may be nullexplicit name of thread, may be name)nullDepending on whether |
| public final int | getInterruptCounter(final boolean
if true, issues clear)clearInterruptSource()Implements com. java. calls.
|
| public final Throwable | getInterruptSource(final boolean
if true, issues clear)clearInterruptSource()Implements com. interrupt() call.
|
| public final void |
| interruptCounter | back to summary |
|---|---|
| pack-priv volatile int interruptCounter | |
| interruptSource | back to summary |
|---|---|
| pack-priv volatile Throwable interruptSource | |
| sync | back to summary |
|---|---|
| pack-priv final Object sync | |
| Thread | back to summary |
|---|---|
| public Thread() See | |
| Thread | back to summary |
|---|---|
| public Thread(final ThreadGroup tg, final Runnable target) See
| |
| Thread | back to summary |
|---|---|
| public Thread(final ThreadGroup tg, final Runnable target, final String name) See
| |
| clearInterruptSource | back to summary |
|---|---|
| public final void clearInterruptSource() Implements com. Doc from com. Clears source and count of
| |
| create | back to summary |
|---|---|
| public static InterruptSource. Depending on whether
| |
| getInterruptCounter | back to summary |
|---|---|
| public final int getInterruptCounter(final boolean clear) Implements com. Doc from com. Returns the count of
| |
| getInterruptSource | back to summary |
|---|---|
| public final Throwable getInterruptSource(final boolean clear) Implements com. Doc from com. Returns the source of the last
| |
| interrupt | back to summary |
|---|---|
| public final void interrupt() Overrides java. Doc from java. Interrupts this thread. Unless the current thread is interrupting itself, which is
always permitted, the If this thread is blocked in an invocation of the If this thread is blocked in an I/O operation upon an If this thread is blocked in a If none of the previous conditions hold then this thread's interrupt status will be set. Interrupting a thread that is not alive need not have any effect.
| |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public static InterruptSource | currentThread()
Casts current |
| public static InterruptSource | get(final Thread t)
Casts given |
| Util | back to summary |
|---|---|
| public Util() | |
| currentThread | back to summary |
|---|---|
| public static InterruptSource currentThread() Casts current | |
| get | back to summary |
|---|---|
| public static InterruptSource get(final Thread t) Casts given | |