public class SharedBlockingCallback.Blocker extends java.lang.Object implements Callback, java.io.Closeable
Callback.Completable, Callback.Nested
Invocable.InvocationType
__nonBlocking
Modifier | Constructor and Description |
---|---|
protected |
Blocker() |
Modifier and Type | Method and Description |
---|---|
void |
block()
Block until the Callback has succeeded or failed and after the return leave in the state to allow reuse.
|
void |
close()
Check the Callback has succeeded or failed and after the return leave in the state to allow reuse.
|
void |
failed(java.lang.Throwable cause)
Callback invoked when the operation fails.
|
Invocable.InvocationType |
getInvocationType() |
void |
succeeded()
Callback invoked when the operation completes.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
getInvocationType, invokeNonBlocking, isNonBlockingInvocation
public Invocable.InvocationType getInvocationType()
getInvocationType
in interface Invocable
public void succeeded()
Callback
Callback invoked when the operation completes.
succeeded
in interface Callback
Callback.failed(Throwable)
public void failed(java.lang.Throwable cause)
Callback
Callback invoked when the operation fails.
public void block() throws java.io.IOException
java.io.IOException
- if exception was caught during blocking, or callback was cancelledpublic void close()
close
in interface java.io.Closeable
close
in interface java.lang.AutoCloseable
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 1995–2023 Webtide. All rights reserved.