pub trait FormatParser {
// Required method
fn parse_str(&self, input: &str) -> Result<Value, BabbelError>;
// Provided method
fn parse_bytes(&self, input: &[u8]) -> Result<Value, BabbelError> { ... }
}Expand description
Abstract parser converting text or byte inputs into a universal Value AST.
Required Methods§
Provided Methods§
Sourcefn parse_bytes(&self, input: &[u8]) -> Result<Value, BabbelError>
fn parse_bytes(&self, input: &[u8]) -> Result<Value, BabbelError>
Parses a raw byte slice into a universal Value.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".