constructor(channel, serviceName, channelName) {
    super();

    /**
     * The channel that is sending the log messages.
     * @type {!MessageChannel}
     * @private
     */
    this.channel_ = channel;

    /**
     * The name of the logging service to listen for.
     * @type {string}
     * @private
     */
    this.serviceName_ = serviceName;

    /**
     * The name of the channel.
     * @type {string}
     * @private
     */
    this.channelName_ = channelName || 'remote logger';

    this.channel_.registerService(
        this.serviceName_, this.log_.bind(this), true /* opt_json */);
  }
Creates a LoggerServer instance.

@param {!MessageChannel} channel The channel that is sending
    the log messages.
@param {string} serviceName The name of the logging service to listen for.
@param {string=} channelName The name of this channel. Used to help
    distinguish this client's messages.