Add doc comment for extra::url::query_to_str
This commit is contained in:
parent
5208332a1a
commit
48f76a0577
@ -364,6 +364,16 @@ fn query_from_str(rawquery: &str) -> Query {
|
||||
return query;
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts an instance of a URI `Query` type to a string.
|
||||
*
|
||||
* # Example
|
||||
*
|
||||
* ```rust
|
||||
* let query = ~[(~"title", ~"The Village"), (~"north", ~"52.91"), (~"west", ~"4.10")];
|
||||
* println(query_to_str(&query)); // title=The%20Village&north=52.91&west=4.10
|
||||
* ```
|
||||
*/
|
||||
pub fn query_to_str(query: &Query) -> ~str {
|
||||
let mut strvec = ~[];
|
||||
for kv in query.iter() {
|
||||
|
Loading…
Reference in New Issue
Block a user