pub fn field_name(&self) -> &str {
        std::iter::once(self)
            .chain(self.parents())
            .find_map(|node| match node.segment {
                QueryPathSegment::Name(name) => Some(name),
                QueryPathSegment::Index(_) => None,
            })
            .unwrap()
    }
/// Get the current field name.
///
/// This traverses all the parents of the node until it finds one that is a field name.
Get the current field name.
This traverses all the parents of the node until it finds one that is a field name.
Get the current field name . This traverses all the parents of the node until it finds one that is a field name .
pub fn field_name(&self) -> &str {
        std::iter::once(self)
            .chain(self.parents())
            .find_map(|node| match node.segment {
                QueryPathSegment::Name(name) => Some(name),
                QueryPathSegment::Index(_) => None,
            })
            .unwrap()
    }
pub fn field_name ( & self ) -> & str { std :: iter :: once ( self ) . chain ( self . parents ( ) ) . find_map ( | node | match node . segment { QueryPathSegment :: Name ( name ) => Some ( name ) , QueryPathSegment :: Index ( _ ) => None , } ) . unwrap ( ) }
Get the current field name.
Get the current field name .
&self
&self