Struct trillium_http_types::other::SourceMap [−][src]
pub struct SourceMap { /* fields omitted */ }Expand description
Links to a file that maps transformed source to the original source.
Specifications
Examples
use http_types::{Response, Url}; use http_types::other::SourceMap; let source_map = SourceMap::new(Url::parse("https://example.net/")?); let mut res = Response::new(200); res.insert_header(&source_map, &source_map); let base_url = Url::parse("https://example.net/")?; let source_map = SourceMap::from_headers(base_url, res)?.unwrap(); assert_eq!(source_map.location(), &Url::parse("https://example.net/")?);
Implementations
Create a new instance from headers.
Trait Implementations
Access the header’s name.
Access the header’s value.
Auto Trait Implementations
impl RefUnwindSafe for SourceMapimpl UnwindSafe for SourceMap