pub struct PrebuiltCompleteGraph {
pub vertex_num: VertexNum,
pub edges: Vec<BTreeMap<VertexIndex, Weight>>,
pub virtual_boundary_weight: Vec<Option<(VertexIndex, Weight)>>,
}Fields§
§vertex_num: VertexNumnumber of vertices
edges: Vec<BTreeMap<VertexIndex, Weight>>all edge weights, if set to Weight::MAX then this edge does not exist
virtual_boundary_weight: Vec<Option<(VertexIndex, Weight)>>the virtual boundary weight
Implementations§
Source§impl PrebuiltCompleteGraph
impl PrebuiltCompleteGraph
pub fn new_threaded( initializer: &SolverInitializer, thread_pool_size: usize, ) -> Self
pub fn new(initializer: &SolverInitializer) -> Self
pub fn get_edge_weight( &self, vertex_1: VertexIndex, vertex_2: VertexIndex, ) -> Option<Weight>
pub fn get_boundary_weight( &self, vertex_index: VertexIndex, ) -> Option<(VertexIndex, Weight)>
Trait Implementations§
Source§impl Clone for PrebuiltCompleteGraph
impl Clone for PrebuiltCompleteGraph
Source§fn clone(&self) -> PrebuiltCompleteGraph
fn clone(&self) -> PrebuiltCompleteGraph
Returns a duplicate of the value. Read more
1.0.0§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 PrebuiltCompleteGraph
impl RefUnwindSafe for PrebuiltCompleteGraph
impl Send for PrebuiltCompleteGraph
impl Sync for PrebuiltCompleteGraph
impl Unpin for PrebuiltCompleteGraph
impl UnwindSafe for PrebuiltCompleteGraph
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more