pub fn param(&self, name: impl Into<ParamName>) -> Option<&ParamValue> {
        let name: ParamName = name.into();
        self.params
            .as_ref()
            .map(|inner| match inner {
                ParamKind::Map(hm) => hm.get(&name),
                ParamKind::Utf8 => match name {
                    ParamName(Cow::Borrowed("charset")) => Some(&ParamValue(Cow::Borrowed("utf8"))),
                    _ => None,
                },
            })
            .flatten()
    }
/// Get a reference to a param.
Get a reference to a param.
Get a reference to a param .
pub fn param(&self, name: impl Into<ParamName>) -> Option<&ParamValue> {
        let name: ParamName = name.into();
        self.params
            .as_ref()
            .map(|inner| match inner {
                ParamKind::Map(hm) => hm.get(&name),
                ParamKind::Utf8 => match name {
                    ParamName(Cow::Borrowed("charset")) => Some(&ParamValue(Cow::Borrowed("utf8"))),
                    _ => None,
                },
            })
            .flatten()
    }
pub fn param ( & self , name : impl Into < ParamName > ) -> Option < & ParamValue > { let name : ParamName = name . into ( ) ; self . params . as_ref ( ) . map ( | inner | match inner { ParamKind :: Map ( hm ) => hm . get ( & name ) , ParamKind :: Utf8 => match name { ParamName ( Cow :: Borrowed ( " " ) ) => Some ( & ParamValue ( Cow :: Borrowed ( " " ) ) ) , _ => None , } , } ) . flatten ( ) }
Get a reference to a param.
Get a reference to a param .
&self
name
impl Into<ParamName>
&self
name
impl Into<ParamName>