pub fn new(base_hash: H, base_number: N, base_node: V) -> Self {
		let mut entries = BTreeMap::new();
		entries.insert(
			base_hash.clone(),
			Entry {
				number: base_number,
				ancestors: Vec::new(),
				descendents: Vec::new(),
				cumulative_vote: base_node,
			},
		);

		let mut heads = BTreeSet::new();
		heads.insert(base_hash.clone());

		VoteGraph { entries, heads, base: base_hash, base_number }
	}
/// Create a new `VoteGraph` with base node as given.
Create a new `VoteGraph` with base node as given.
Create a new ` VoteGraph ` with base node as given .
pub fn new(base_hash: H, base_number: N, base_node: V) -> Self {
		let mut entries = BTreeMap::new();
		entries.insert(
			base_hash.clone(),
			Entry {
				number: base_number,
				ancestors: Vec::new(),
				descendents: Vec::new(),
				cumulative_vote: base_node,
			},
		);
		let mut heads = BTreeSet::new();
		heads.insert(base_hash.clone());
		VoteGraph { entries, heads, base: base_hash, base_number }
	}
pub fn new ( base_hash : H , base_number : N , base_node : V ) -> Self { let mut entries = BTreeMap :: new ( ) ; entries . insert ( base_hash . clone ( ) , Entry { number : base_number , ancestors : Vec :: new ( ) , descendents : Vec :: new ( ) , cumulative_vote : base_node , } , ) ; let mut heads = BTreeSet :: new ( ) ; heads . insert ( base_hash . clone ( ) ) ; VoteGraph { entries , heads , base : base_hash , base_number } }
Create a new `VoteGraph` with base node as given.
Create a new ` VoteGraph ` with base node as given .
base_hash
H
base_number
N
base_node
V
base_hash
H
base_number
N
base_node
V