Function ::urlencoded::encode

Overview
fn encode(obj: Object) -> String

Encode a String object into an url encoded String. Consumes the given object.

let map = #{};
map["a"] = "1";
map["b"] = "2";
map["c"] = "3";
map["c"] = "4";
map["key_without_value"] = "";
map[""] = "value_without_key";
let result = urlencoded::decode(urlencoded::encode(map));
let map = #{};
map["a"] = "1";
map["b"] = "2";
map["c"] = "3";
map["c"] = "4";
map["key_without_value"] = "";
map[""] = "value_without_key";
assert_eq!(result, map);