pub struct DocumentChainResult {
pub chain_id: String,
pub is_complete: bool,
pub missing_steps: Vec<String>,
pub expected_steps: usize,
pub actual_steps: usize,
}Expand description
Document chain validation result.
Fields§
§chain_id: StringChain identifier
is_complete: boolWhether chain is complete
missing_steps: Vec<String>Missing steps (if any)
expected_steps: usizeTotal steps expected
actual_steps: usizeActual steps found
Implementations§
Source§impl DocumentChainResult
impl DocumentChainResult
Sourcepub fn new(chain_id: &str, expected_steps: usize, actual_steps: usize) -> Self
pub fn new(chain_id: &str, expected_steps: usize, actual_steps: usize) -> Self
Create a new chain result.
Sourcepub fn incomplete(
chain_id: &str,
expected: usize,
actual: usize,
missing: Vec<String>,
) -> Self
pub fn incomplete( chain_id: &str, expected: usize, actual: usize, missing: Vec<String>, ) -> Self
Create an incomplete chain result.
Sourcepub fn completion_rate(&self) -> f64
pub fn completion_rate(&self) -> f64
Get completion rate.
Trait Implementations§
Source§impl Clone for DocumentChainResult
impl Clone for DocumentChainResult
Source§fn clone(&self) -> DocumentChainResult
fn clone(&self) -> DocumentChainResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for DocumentChainResult
impl RefUnwindSafe for DocumentChainResult
impl Send for DocumentChainResult
impl Sync for DocumentChainResult
impl Unpin for DocumentChainResult
impl UnwindSafe for DocumentChainResult
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