http_type/http_url/
struct.rs

1use crate::*;
2
3/// Represents the components of a parsed HTTP URL.
4#[derive(Debug, Clone, PartialEq, Eq)]
5pub struct HttpUrlComponents {
6    /// The URL scheme, such as "http" or "https".
7    pub protocol: Protocol,
8    /// The host part of the URL (e.g., "example.com").
9    pub host: OptionString,
10    /// The port number in the URL, if specified.
11    pub port: OptionU16,
12    /// The path in the URL (e.g., "/index.html").
13    pub path: OptionString,
14    /// The query string in the URL (e.g., "?a=1").
15    pub query: OptionString,
16    /// The fragment identifier (e.g., "#section").
17    pub fragment: OptionString,
18}