#[non_exhaustive]pub enum ClosedSwitchPolicy {
Merge,
Refuse,
Keep,
}Expand description
What normalization does with a closed switch that joins two buses.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Merge
Merge the buses closed switches join before the pass, with
BusMergeRule::closed_switches, and report the merge under
CANONICALIZE.MERGE. The matrix builders and solver preparations
stamp branches only, so a normalized network carries no closed switch
for them to leave apart. A closed switch on an isolated or undeclared
bus is left to the filters that drop that bus. Returns
Error::ClosedSwitch if a requested merge is refused, for example
when it would join two windings of one three winding transformer.
Refuse
Refuse a network with such a switch with Error::ClosedSwitch
(BUILD.SWITCH.CLOSED).
Keep
Keep closed switches as data, as normalization did before it merged them, for a consumer that models switches itself.
Trait Implementations§
Source§impl Clone for ClosedSwitchPolicy
impl Clone for ClosedSwitchPolicy
Source§fn clone(&self) -> ClosedSwitchPolicy
fn clone(&self) -> ClosedSwitchPolicy
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreimpl Copy for ClosedSwitchPolicy
Source§impl Debug for ClosedSwitchPolicy
impl Debug for ClosedSwitchPolicy
Source§impl Default for ClosedSwitchPolicy
impl Default for ClosedSwitchPolicy
Source§fn default() -> ClosedSwitchPolicy
fn default() -> ClosedSwitchPolicy
impl Eq for ClosedSwitchPolicy
Source§impl PartialEq for ClosedSwitchPolicy
impl PartialEq for ClosedSwitchPolicy
impl StructuralPartialEq for ClosedSwitchPolicy
Auto Trait Implementations§
impl Freeze for ClosedSwitchPolicy
impl RefUnwindSafe for ClosedSwitchPolicy
impl Send for ClosedSwitchPolicy
impl Sync for ClosedSwitchPolicy
impl Unpin for ClosedSwitchPolicy
impl UnsafeUnpin for ClosedSwitchPolicy
impl UnwindSafe for ClosedSwitchPolicy
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key and return true if they are equal.