V - 未来返回的价值类型
F - 未来的类型
public class PromiseNotifier<V,F extends Future<V>> extends java.lang.Object implements GenericFutureListener<F>
GenericFutureListener执行其他Promise并完成后通知他们。
| Constructor and Description |
|---|
PromiseNotifier(boolean logNotifyFailure, Promise<? super V>... promises)
创建一个新的实例。
|
PromiseNotifier(Promise<? super V>... promises)
创建一个新的实例。
|
| Modifier and Type | Method and Description |
|---|---|
void |
operationComplete(F future)
当与 Future相关的操作已完成时调用。
|
@SafeVarargs public PromiseNotifier(Promise<? super V>... promises)
promises - Promise通知此GenericFutureListener通知。
@SafeVarargs
public PromiseNotifier(boolean logNotifyFailure,
Promise<? super V>... promises)
logNotifyFailure -
true如果在通知失败的情况下应该进行日志记录。
promises - Promise通知此GenericFutureListener通知。
public void operationComplete(F future) throws java.lang.Exception
GenericFutureListener
Future相关的操作已完成时调用。
operationComplete ,界面
GenericFutureListener<F extends Future<V>>
future - 调用此回调的源Future
java.lang.Exception
Copyright © 2008–2018 The Netty Project. All rights reserved.