@ Override public final boolean complete ( Object value ) { for ( ; ; ) { final Object oldState = state ; if ( isDone ( oldState ) ) { warnIfSuspiciousDoubleCompletion ( oldState , value ) ; return false ; } if ( compareAndSetState ( oldState , value ) ) { onComplete ( ) ; unblockAll ( oldState , defaultExecutor ) ; return true ; } } }
Can be called multiple times but only the first answer will lead to the future getting triggered . All subsequent complete calls are ignored .