Trait amqp0_parser_nom::pool::ParserPool [] [src]

pub trait ParserPool {
    fn new_table_hashmap(&mut self,
                         usize)
                         -> HashMap<Cow<'static, str>, Value<'static>>; fn new_table_entries_vec(&mut self,
                             &[u8])
                             -> Vec<(&'static str, Value<'static>)>; fn new_values_vec(&mut self, &[u8]) -> Vec<Value<'static>>; fn return_table_hashmap(&mut self, _: HashMap<&'static str, &'static str>) { ... } fn return_table_entries_vec(&mut self,
                                _: Vec<(&'static str, Value<'static>)>) { ... } fn return_values_vec(&mut self, _: Vec<Value<'static>>) { ... } }

Creates the objects that may be needed for parsing

When parsing AMQP "fields", some values may require dynamic allocation-- at least the ones can't just reference into the byte-string (Table and List rather than &str or &[u8]).

Rather than allocate a new one each time, we let the user decide how to allocate these, based on the needed capacity.

Required Methods

Given a capacity, returns a Table

Given the bytes for a table, returns a Vec to accept table entries Most likely to be used to assemble a table

Given a capacity, returns a vector for Vals Most likely to be used to assemble a List

Provided Methods

Implementors