pub trait DiffSource {
// Required methods
fn raw_records(
&self,
base: &str,
head: &str,
) -> Result<Vec<u8>, EngineError>;
fn canonical_patch(
&self,
base: &str,
head: &str,
) -> Result<Vec<u8>, EngineError>;
fn rename_records(
&self,
base: &str,
head: &str,
) -> Result<Vec<u8>, EngineError>;
}Expand description
Canonical enumeration (ADR 0005: total, no exclusions, ever).
FROZEN ARGV. The byte format each method returns is what parse.rs,
rename_view.rs and ultimately the frozen normaliser were validated
against; changing a flag changes shape hashes and breaks real-corpus
parity. Add a method, never edit one.
Required Methods§
Sourcefn raw_records(&self, base: &str, head: &str) -> Result<Vec<u8>, EngineError>
fn raw_records(&self, base: &str, head: &str) -> Result<Vec<u8>, EngineError>
diff-tree -r -z --raw --full-index --no-renames: authoritative modes,
full oids, dispositions.
Sourcefn canonical_patch(
&self,
base: &str,
head: &str,
) -> Result<Vec<u8>, EngineError>
fn canonical_patch( &self, base: &str, head: &str, ) -> Result<Vec<u8>, EngineError>
diff-tree -r -U0 --no-renames --no-color --no-ext-diff: the canonical
patch. Every hunk in the system comes from here.
Sourcefn rename_records(&self, base: &str, head: &str) -> Result<Vec<u8>, EngineError>
fn rename_records(&self, base: &str, head: &str) -> Result<Vec<u8>, EngineError>
diff-tree -r -M -z --name-status: rename-detected annotations
only (ADR 0003). Never affects what exists.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".