Called back when one of the Deferred in the group completes. @param result The result of the deferred.
(final Object result)
| 133 | * @param result The result of the deferred. |
| 134 | */ |
| 135 | private void recordCompletion(final Object result) { |
| 136 | int left; |
| 137 | synchronized (this) { |
| 138 | results.add(result); |
| 139 | left = --nresults; |
| 140 | } |
| 141 | if (left == 0) { |
| 142 | done(); |
| 143 | } |
| 144 | } |
| 145 | |
| 146 | /** |
| 147 | * Called back when one of the {@link Deferred} in the group completes. |