fn fmt()

in src/ast/query.rs [71:102]


    fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
        if let Some(ref with) = self.with {
            write!(f, "{with} ")?;
        }
        write!(f, "{}", self.body)?;
        if let Some(ref order_by) = self.order_by {
            write!(f, " {order_by}")?;
        }

        if let Some(ref limit_clause) = self.limit_clause {
            limit_clause.fmt(f)?;
        }
        if let Some(ref settings) = self.settings {
            write!(f, " SETTINGS {}", display_comma_separated(settings))?;
        }
        if let Some(ref fetch) = self.fetch {
            write!(f, " {fetch}")?;
        }
        if !self.locks.is_empty() {
            write!(f, " {}", display_separated(&self.locks, " "))?;
        }
        if let Some(ref for_clause) = self.for_clause {
            write!(f, " {}", for_clause)?;
        }
        if let Some(ref format) = self.format_clause {
            write!(f, " {}", format)?;
        }
        for pipe_operator in &self.pipe_operators {
            write!(f, " |> {}", pipe_operator)?;
        }
        Ok(())
    }