pub fn join(&self, other: &IriParsed<'a>) -> IriParsed<'a> {
        let (scheme, authority, query, fragment);
        let mut path;
        if other.scheme.is_some() {
            scheme = other.scheme;
            authority = other.authority;
            path = other.path.clone();
            query = other.query;
        } else {
            scheme = self.scheme;
            if other.authority.is_some() {
                authority = other.authority;
                path = other.path.clone();
                query = other.query;
            } else {
                authority = self.authority;
                if other.path.is_empty() {
                    path = self.path.clone();
                    query = other.query.or(self.query);
                } else {
                    if other.path[0].is_empty() {
                        path = other.path.clone();
                    } else {
                        path = self.merged_path(&other.path);
                    }
                    query = other.query;
                }
            }
        }
        remove_dot_segments(&mut path);
        fragment = other.fragment;
        IriParsed {
            scheme,
            authority,
            path,
            query,
            fragment,
        }
    }
/// Resolve `other` using this IRI reference as the base.
///
/// NB: the resulting `IriParsed` may borrow parts from both parts.
Resolve `other` using this IRI reference as the base.
NB: the resulting `IriParsed` may borrow parts from both parts.
Resolve ` other ` using this IRI reference as the base . NB : the resulting ` IriParsed ` may borrow parts from both parts .
pub fn join(&self, other: &IriParsed<'a>) -> IriParsed<'a> {
        let (scheme, authority, query, fragment);
        let mut path;
        if other.scheme.is_some() {
            scheme = other.scheme;
            authority = other.authority;
            path = other.path.clone();
            query = other.query;
        } else {
            scheme = self.scheme;
            if other.authority.is_some() {
                authority = other.authority;
                path = other.path.clone();
                query = other.query;
            } else {
                authority = self.authority;
                if other.path.is_empty() {
                    path = self.path.clone();
                    query = other.query.or(self.query);
                } else {
                    if other.path[0].is_empty() {
                        path = other.path.clone();
                    } else {
                        path = self.merged_path(&other.path);
                    }
                    query = other.query;
                }
            }
        }
        remove_dot_segments(&mut path);
        fragment = other.fragment;
        IriParsed {
            scheme,
            authority,
            path,
            query,
            fragment,
        }
    }
pub fn join ( & self , other : & IriParsed < ' a > ) -> IriParsed < ' a > { let ( scheme , authority , query , fragment ) ; let mut path ; if other . scheme . is_some ( ) { scheme = other . scheme ; authority = other . authority ; path = other . path . clone ( ) ; query = other . query ; } else { scheme = self . scheme ; if other . authority . is_some ( ) { authority = other . authority ; path = other . path . clone ( ) ; query = other . query ; } else { authority = self . authority ; if other . path . is_empty ( ) { path = self . path . clone ( ) ; query = other . query . or ( self . query ) ; } else { if other . path [ 0 ] . is_empty ( ) { path = other . path . clone ( ) ; } else { path = self . merged_path ( & other . path ) ; } query = other . query ; } } } remove_dot_segments ( & mut path ) ; fragment = other . fragment ; IriParsed { scheme , authority , path , query , fragment , } }
Resolve `other` using this IRI reference as the base.
Resolve ` other ` using this IRI reference as the base .
&self
other
&IriParsed<'a>
&self
other
&IriParsed<'a>