#[non_exhaustive]pub struct BranchSwitchingCost {
pub id: String,
pub open_cost: f64,
pub close_cost: f64,
}Expand description
The cost of changing one branch’s status, in objective units. Only a
change against the initial topology costs anything: opening an initially
closed branch costs open_cost, closing an initially open one
close_cost.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.id: StringThe branch identity.
open_cost: f64The cost of opening the branch.
close_cost: f64The cost of closing the branch.
Implementations§
Trait Implementations§
Source§impl Clone for BranchSwitchingCost
impl Clone for BranchSwitchingCost
Source§impl Debug for BranchSwitchingCost
impl Debug for BranchSwitchingCost
Source§impl PartialEq for BranchSwitchingCost
impl PartialEq for BranchSwitchingCost
impl StructuralPartialEq for BranchSwitchingCost
Auto Trait Implementations§
impl Freeze for BranchSwitchingCost
impl RefUnwindSafe for BranchSwitchingCost
impl Send for BranchSwitchingCost
impl Sync for BranchSwitchingCost
impl Unpin for BranchSwitchingCost
impl UnsafeUnpin for BranchSwitchingCost
impl UnwindSafe for BranchSwitchingCost
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more