class DefaultPromise extends AbstractFuture<V> implements Promise<V> {

    @Override
    public boolean cancel(boolean mayInterruptIfRunning) {
        // 尝试将结果从初始状态(null)变为取消完成状态
        if (RESULT_UPDATER.compareAndSet(this, null, CANCELLATION_CAUSE_HOLDER)) {
            // 取消成功，则坚持是否需要通知监听器，并进行相应的通知
            if (checkNotifyWaiters()) {
                notifyListeners();
            }
            return true;
        }
        return false;
    }

    public  DefaultPromise(EventExecutor executor);
    protected  DefaultPromise();

}