Skip to main content

OrderValidator

Trait OrderValidator 

Source
pub trait OrderValidator {
    // Required methods
    fn try_accept(&mut self, directory: &Directory) -> Result<(), OrderingError>;
    fn finalize(self) -> Result<(), OrderingError>;
}
Expand description

Common trait implemented by both RootToLeaves and LeavesToRoot.

Required Methods§

Source

fn try_accept(&mut self, directory: &Directory) -> Result<(), OrderingError>

Succeeds if the directory is acceptable with the chosen insertion order.

Source

fn finalize(self) -> Result<(), OrderingError>

Succeeds if the accepted directories are a full closure.

Implementors§