Serialize URI to its string representation.
@method  toString
@return {String} an URI as a string.
767186
function() {
        return (this.scheme !== null ? this.scheme + "://" : '') +
               (this.host !== null ? this.host : '' ) +
               (this.port !== -1   ? ":" + this.port : '' ) +
               (this.path !== null ? this.path : '' ) +
               (this.qs   !== null ? "?" + this.qs : '' );
    }
460160
function(u){
      var urlObj = url.parse(u)
      return urlObj.protocol + "//" + urlObj.hostname + urlObj.pathname 
    }
1205703
function() {
  var server = this.get("server");
  if (!server)
    return null;
  var address = server.address();
  var scheme = server instanceof https.Server ? 'https' : 'http';
  return util.format("%s://%s:%d", scheme, address.address, address.port);
}
1360748
def serialize_text(self):
        '''
        '''
        if self._uri_to_prefix is None or len(self._uri_to_prefix) == 0:
            return b''
        od = collections.OrderedDict(sorted(self._uri_to_prefix.items()))
        data = []
        for uri in od:
            data.append(uri + ':' + od[uri])
        return ' '.join(data).encode('utf-8')
269220
function() {
      var base =
        _.result(this, 'urlRoot') ||
        _.result(this.collection, 'url') ||
        urlError();
      if (this.isNew()) return base;
      return base.replace(/([^\/])$/, '$1/') + encodeURIComponent(this.id);
    }
656958
function(string) {
            var output = encodeURIComponent(string);
            output = output.replace(/[^A-Za-z0-9_.~\-%]+/g, escape);
            output = output.replace(/[*]/g, function(ch) {
                return "%" + ch.charCodeAt(0).toString(16).toUpperCase();
            });
            return output;
        }
1129638
function parseUri(str) {
    var parser = re.uri_parser;
    var parserKeys = ["source", "protocol", "authority", "userInfo", "user", "password", "host", "port", "isColonUri", "relative", "path", "directory", "file", "query", "anchor"];
    var m = parser.exec(str || '');
    var parts = {};

    parserKeys.forEach(function(key, i) {
      parts[key] = m[i] || '';
    });

    return parts;
  }
607778
function objectToString(o) {
  return '{' + keys(o).map(k => `${k}: ${o[k]}`).join(', ') + '}';
}
1215406
function () {
      var result = '';
      if (this._string) {
        return this._string;
      } else {
        result = this.scheme === undefined ? result : (result + this.scheme + ':');
        result = this.authority === undefined ? result : (result + '//' + this.authority);
        result = result + this.path;
        result = this.query === undefined ? result : (result + '?' + this.query);
        result = this.fragment === undefined ? result : (result + '#' + this.fragment);
        this._string = result;
        return result;
      }
    }
79512
function propsToString() {
    var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
    var defaultProps = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};

    var propStr = '';

    Object.keys(props).map(function (prop) {
        var propVal = props[prop];

        if (prop !== 'children' && propVal !== defaultProps[prop]) {
            propStr += ' ' + prop + '=';

            if (typeof propVal === 'string') {
                propStr += '"' + propVal + '"';
            } else {
                propStr += '{' + JSON.stringify(propVal) + '}';
            }
        }
    });

    return propStr;
}
335405
function jsonToQueryString(json) {
    return '?' +
        Object
        .keys(json)
        .map(function (key) {
            if (json[key] !== null) {
                return encodeURIComponent(key) + '=' +
                    encodeURIComponent(json[key]);
            }
        })
        .join('&');
}
319455
function toQueryString(obj) {
    var parts = [];
    for (var i in obj) {
      if (obj.hasOwnProperty(i)) {
        parts.push(encodeURIComponent(i) + "=" + encodeURIComponent(obj[i]));
      }
    }
    return parts.join("&");
  }
134221
function serialize(pairs) {
					var output = '', first = true;
					pairs.forEach(function (pair) {
						var name = encodeURIComponent(pair.name);
						var value = encodeURIComponent(pair.value);
						if (!first) output += '&';
						output += name + '=' + value;
						first = false;
					});
					return output.replace(/%20/g, '+');
				}
698571
function() {
		var str = this.trim();
		str = this.charAt(0).toUpperCase() + this.slice(1);
		if (!str.match(/[?!\.]$/)) str = str+'.';
		return str;
	}
242687
function stringifyQueryStr(obj) {
      if (!typeOf(obj, 'obj', 'arr')) return '';
      obj = JSON.parse(JSON.stringify(obj));
      var pairs = [];
      forIn(obj, function (key, value) {
        var encode = encodeURIComponent;
        pairs.push(encode(key) + '=' + encode(value));
      });
      return '?' + pairs.join('&');
    }
153362
function dataURItoBlob(dataURI) {
    // convert base64 to raw binary data held in a string
    var byteString = atob(dataURI.split(',')[1]),
        // separate out the mime component
        mimeString = dataURI.split(',')[0].split(':')[1].split(';')[0],
        // write the bytes of the string to an ArrayBuffer
        arrayBuffer = new ArrayBuffer(byteString.length),
        _ia = new Uint8Array(arrayBuffer),
        i, dataView, blob;

    for (i = 0; i < byteString.length; i++) {
        _ia[i] = byteString.charCodeAt(i);
    }

    dataView = new DataView(arrayBuffer);
    blob = new Blob([dataView], { type: mimeString });

    return blob;
}
1080318
function() {
        "use strict";
        var ret = "";
        if (this.json.length > 0) {
            if (this.json.length === 1) {
                ret = JSON.stringify(this.json[0]);
            } else {
                ret = JSON.stringify(this.json);
            }
        }
        return ret;
    }