pub struct JsonMessageFactory {
pub json: String,
/* private fields */
}Expand description
Message factory implementation that formats decoded messages as JSON encoded String.
Fields§
§json: StringImplementations§
Trait Implementations§
Source§impl MessageFactory for JsonMessageFactory
impl MessageFactory for JsonMessageFactory
Source§fn start_template(&mut self, _id: u32, name: &str)
fn start_template(&mut self, _id: u32, name: &str)
Called when a <template> processing is started. Read more
Source§fn stop_template(&mut self)
fn stop_template(&mut self)
Called when a <template> processing is finished.
Source§fn set_value(&mut self, _id: u32, name: &str, value: Option<Value>)
fn set_value(&mut self, _id: u32, name: &str, value: Option<Value>)
Called when a field element is processed. Read more
Source§fn start_sequence(&mut self, _id: u32, name: &str, _length: u32)
fn start_sequence(&mut self, _id: u32, name: &str, _length: u32)
Called when a <sequence> element processing is started. Read more
Source§fn start_sequence_item(&mut self, _index: u32)
fn start_sequence_item(&mut self, _index: u32)
Called when a sequence item processing is started. Read more
Source§fn stop_sequence_item(&mut self)
fn stop_sequence_item(&mut self)
Called when a sequence item processing is finished.
Source§fn stop_sequence(&mut self)
fn stop_sequence(&mut self)
Called when a <sequence> processing is finished.
Source§fn start_group(&mut self, name: &str)
fn start_group(&mut self, name: &str)
Called when a <group> element processing is started. Read more
Source§fn stop_group(&mut self)
fn stop_group(&mut self)
Called when a <group> element processing is finished.
Source§fn start_template_ref(&mut self, name: &str, dynamic: bool)
fn start_template_ref(&mut self, name: &str, dynamic: bool)
Called when a template reference (<templateRef>) processing is started. Read more
Source§fn stop_template_ref(&mut self)
fn stop_template_ref(&mut self)
Called when a template reference (<templateRef>) processing is finished.
Auto Trait Implementations§
impl Freeze for JsonMessageFactory
impl RefUnwindSafe for JsonMessageFactory
impl Send for JsonMessageFactory
impl Sync for JsonMessageFactory
impl Unpin for JsonMessageFactory
impl UnwindSafe for JsonMessageFactory
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more