This crate provides a barebone, zero-allocation parser for HTTP URIs as they appear in a request header.
In general, components are extracted along defined delimiters, but further validation
and processing (such as percent decoding, query decoding, and punycode decoding) is
left to higher layers. In the pursuit of simplicity, this crate also contains no
support for generic and non-http URIs such as file:
and ftp://
– only the reduced
syntax for http://
and
https://
schemes is
implemented.
Example
use ;
let uri = new.unwrap;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
assert_eq!;
let res = new;
assert_eq!;
assert_eq!;
assert_eq!;