params2Query method

String params2Query()

Convert params map to query for using in requests with Method.GET method

Returns query format of _params something like this ?firstKey=firstValue&secondKey=secondValue

Implementation

String params2Query() {
  String q = "?";
  _params.forEach((key, value) {
    q += key + "=" + value.toString() + "&";
  });
  return q;
}