azalea_brigadier/
parse_results.rs

1use std::{collections::HashMap, fmt::Debug, rc::Rc};
2
3use crate::{
4    context::CommandContextBuilder, exceptions::CommandSyntaxException,
5    string_reader::StringReader, tree::CommandNode,
6};
7
8pub struct ParseResults<'a, S> {
9    pub context: CommandContextBuilder<'a, S>,
10    pub reader: StringReader,
11    pub exceptions: HashMap<Rc<CommandNode<S>>, CommandSyntaxException>,
12}
13
14impl<S> Debug for ParseResults<'_, S> {
15    fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
16        f.debug_struct("ParseResults")
17            .field("context", &self.context)
18            // .field("reader", &self.reader)
19            .field("exceptions", &self.exceptions)
20            .finish()
21    }
22}