public void failure(Throwable t) {
        synchronized (mutex) {
            state = State.FAILURE;
            this.result = t;

            while (!callbacks.isEmpty()) {
                callbacks.poll().onFailure(t);
            }
        }
    }
public void failure(Throwable t) {
        synchronized (mutex) {
            state = State.FAILURE;
            this.result = t;

            while (!callbacks.isEmpty()) {
                callbacks.poll().onFailure(t);
            }
        }
    }
public void failure ( Throwable t ) { synchronized ( mutex ) { state = State . FAILURE ; this . result = t ; while ( ! callbacks . isEmpty ( ) ) { callbacks . poll ( ) . onFailure ( t ) ; } } }
Triggers a {@link ListenableFutureCallback#onFailure(Throwable)} call on all added
callbacks with the given {@code Throwable}.

@param t the exception to trigger the callbacks with
Triggers a { @link ListenableFutureCallback#onFailure ( Throwable ) } call on all added callbacks with the given { @code Throwable } .