public class CancellationContext extends Object implements Closeable
| 构造器和说明 |
|---|
CancellationContext() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
addListener(CancellationListener cancellationListener) |
void |
addListener(CancellationListener cancellationListener,
Executor executor) |
void |
addListener(CancellationListener cancellationListener,
Executor executor,
RpcServiceContext context) |
void |
addListener(CancellationListener cancellationListener,
RpcServiceContext context) |
void |
addListenerInternal(ExecutableListener executableListener) |
boolean |
cancel(Throwable cause) |
void |
close() |
Throwable |
getCancellationCause() |
List<ExecutableListener> |
getListeners() |
boolean |
isCancelled() |
public void addListener(CancellationListener cancellationListener, Executor executor)
public void addListener(CancellationListener cancellationListener)
public void addListener(CancellationListener cancellationListener, RpcServiceContext context)
public void addListener(CancellationListener cancellationListener, Executor executor, RpcServiceContext context)
public void addListenerInternal(ExecutableListener executableListener)
public boolean cancel(Throwable cause)
public boolean isCancelled()
public List<ExecutableListener> getListeners()
public Throwable getCancellationCause()
public void close()
throws IOException
close 在接口中 Closeableclose 在接口中 AutoCloseableIOExceptionCopyright © 2011–2020 The Apache Software Foundation. All rights reserved.