code: private void updateNetwork(final NetworkContext context, final Handler<AsyncResult<Void>> doneHandler) {
      final CountingCompletionHandler<Void> complete = new CountingCompletionHandler<Void>(context.components().size());
      complete.setHandler(new Handler<AsyncResult<Void>>() {
        @Override
        public void handle(AsyncResult<Void> result) {
          if (result.failed()) {
            new DefaultFutureResult<Void>(result.cause()).setHandler(doneHandler);
          } else {
            new DefaultFutureResult<Void>((Void) null).setHandler(doneHandler);
          }
        }
      });
      updateComponents(context.components(), complete);
    }
docs: Updates a network.