Module url::percent_encoding [-]  [+] [src]

Structs

EncodeSet

Represents a set of characters / bytes that should be percent-encoded.

Statics

pub static DEFAULT_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::DEFAULT }

This encode set is used for path components.

 
pub static FORM_URLENCODED_ENCODE_SET: EncodeSet = [definition]

This encode set is used in application/x-www-form-urlencoded serialization.

 
pub static PASSWORD_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::PASSWORD }

This encode set should be used when setting the password field of a parsed URL.

 
pub static QUERY_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::QUERY }

This encode set is used in the URL parser for query strings.

 
pub static SIMPLE_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::SIMPLE }

This encode set is used for fragment identifier and non-relative scheme data.

 
pub static USERINFO_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::USERINFO }

This encode set is used in the URL parser for usernames and passwords.

 
pub static USERNAME_ENCODE_SET: EncodeSet = EncodeSet { map: &encode_sets::USERNAME }

This encode set should be used when setting the username field of a parsed URL.

 

Functions

from_hex
lossy_utf8_percent_decode

Percent-decode the given bytes, and decode the result as UTF-8.

percent_decode

Percent-decode the given bytes.

percent_decode_to

Percent-decode the given bytes, and push the result to output.

percent_encode

Percent-encode the given bytes.

percent_encode_to

Percent-encode the given bytes, and push the result to output.

utf8_percent_encode

Percent-encode the UTF-8 encoding of the given string.

utf8_percent_encode_to

Percent-encode the UTF-8 encoding of the given string, and push the result to output.