code: function encodeQueryMap(map) {
    var params = [];
    for (var key in map) {
      var value = map[key];
      params.push(key + '=' + urlEncode_(value));
    }
    return params.join('&');
  }
docs: Returns a URL-encoded query string from a map of key-value pairs.
  @param {Object} map Map of key-value pairs.
  @return {string} URL-encoded query string.