PathRanking

Trait PathRanking 

Source
pub trait PathRanking:
    'static
    + Send
    + Sync {
    // Required method
    fn rank_order(
        &self,
        this: &PathManagerPath,
        other: &PathManagerPath,
    ) -> Ordering;
}
Expand description

Scion path ranking allows expressing preferences between paths.

Required Methods§

Source

fn rank_order( &self, this: &PathManagerPath, other: &PathManagerPath, ) -> Ordering

Ranks the order of two paths based on preference.

§Return

Returns the preference ordering between two paths.

  • Ordering::Less if this is preferred over other
  • Ordering::Greater if other is preferred over this
  • Ordering::Equal if both paths are equally preferred

Implementors§