public static class BlockingWriteCallback.WriteBlocker extends Object implements WriteCallback, Callback, AutoCloseable
Callback.Completable, Callback.Nested
Invocable.InvocationType
__nonBlocking
Modifier | Constructor and Description |
---|---|
protected |
WriteBlocker(SharedBlockingCallback.Blocker blocker) |
Modifier and Type | Method and Description |
---|---|
void |
block() |
void |
close() |
void |
failed(Throwable x)
Callback invoked when the operation fails.
|
Invocable.InvocationType |
getInvocationType() |
void |
succeeded()
Callback invoked when the operation completes.
|
void |
writeFailed(Throwable x)
Callback invoked when the write fails.
|
void |
writeSuccess()
Callback invoked when the write completes.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
asPreferred, getInvocationType, invokeNonBlocking, invokePreferNonBlocking, invokePreferred, isNonBlockingInvocation
protected WriteBlocker(SharedBlockingCallback.Blocker blocker)
public Invocable.InvocationType getInvocationType()
getInvocationType
in interface Invocable
public void writeFailed(Throwable x)
WriteCallback
Callback invoked when the write fails.
writeFailed
in interface WriteCallback
x
- the reason for the write failurepublic void writeSuccess()
WriteCallback
Callback invoked when the write completes.
writeSuccess
in interface WriteCallback
WriteCallback.writeFailed(Throwable)
public void succeeded()
Callback
Callback invoked when the operation completes.
succeeded
in interface Callback
Callback.failed(Throwable)
public void failed(Throwable x)
Callback
Callback invoked when the operation fails.
public void close()
close
in interface AutoCloseable
public void block() throws IOException
IOException
Copyright © 1995–2017 Webtide. All rights reserved.