Skip to main content

WeightedGraph

Type Alias WeightedGraph 

Source
pub type WeightedGraph<W> = Vec<Vec<(usize, W)>>;
Expand description

重みありグラフ

Aliased Type§

pub struct WeightedGraph<W> { /* private fields */ }

Trait Implementations§

Source§

impl<'a, W> Graph<'a> for WeightedGraph<W>
where W: Copy + Clone + 'a,

Source§

type NodeId = (usize, W)

Source§

type Iter = Cloned<Iter<'a, <Vec<Vec<(usize, W)>> as Graph<'a>>::NodeId>>

Source§

fn len(&self) -> usize

Source§

fn is_empty(&self) -> bool

Source§

fn index(&self, a: Self::NodeId) -> usize

Source§

fn neighbors(&'a self, a: Self::NodeId) -> Self::Iter