pub trait DeltaExtractor: Send {
// Required methods
fn on_event(&self, data: &[u8], targets: &mut Targets);
fn is_terminator(&self, data: &[u8]) -> bool;
fn synthesize(
&self,
repairs: &[Repair],
targets: &Targets,
terminated: bool,
) -> Vec<u8> ⓘ;
}Expand description
A provider-specific adapter that interprets SSE event payloads, routes JSON
delta fragments into Targets, recognises the stream terminator, and
synthesizes the closing SSE bytes from computed repairs.
Required Methods§
Sourcefn on_event(&self, data: &[u8], targets: &mut Targets)
fn on_event(&self, data: &[u8], targets: &mut Targets)
Interpret one SSE data payload, updating targets.
Sourcefn is_terminator(&self, data: &[u8]) -> bool
fn is_terminator(&self, data: &[u8]) -> bool
True if this payload is the provider’s stream terminator.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".