doMessages_(messages, callbacks) {
    const self = this;
    for (let i = 0; i < messages.length; i++) {
      const message = messages[i];

      callbacks.forEach(function(callback) {
        try {
          callback(message);
        } catch (ex) {
          self.handleError_('message-callback exception (ignored) ' + ex);
        }
      });
    }
  }
Deliver messages to registered callbacks.

Exceptions are caught and logged (debug), and ignored otherwise.

@param {!Array<!Object>} messages The messages to be delivered
@param {!Array<function(!Object=)>} callbacks The callbacks.
@private