#[non_exhaustive]pub struct NeutralKronOptions {
pub neutral_terminals: BTreeMap<String, String>,
pub allow_forced_ideal_ground: bool,
}Expand description
Options controlling explicit-neutral identification and grounding.
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.neutral_terminals: BTreeMap<String, String>Per-bus neutral terminal overrides. Bus identity is case insensitive; terminal identity remains case sensitive.
allow_forced_ideal_ground: boolPermit an identified neutral that is not listed in the bus’s explicit grounded set to be treated as ideal ground. Off by default because this changes the physical network.
Implementations§
Source§impl NeutralKronOptions
impl NeutralKronOptions
Sourcepub fn with_neutral_terminal(
self,
bus: impl Into<String>,
terminal: impl Into<String>,
) -> Self
pub fn with_neutral_terminal( self, bus: impl Into<String>, terminal: impl Into<String>, ) -> Self
Override the neutral label for one bus.
Sourcepub const fn with_forced_ideal_ground(self, allow: bool) -> Self
pub const fn with_forced_ideal_ground(self, allow: bool) -> Self
Opt into treating an identified floating neutral as ideal ground.
Trait Implementations§
Source§impl Clone for NeutralKronOptions
impl Clone for NeutralKronOptions
Source§fn clone(&self) -> NeutralKronOptions
fn clone(&self) -> NeutralKronOptions
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for NeutralKronOptions
impl Debug for NeutralKronOptions
Source§impl Default for NeutralKronOptions
impl Default for NeutralKronOptions
Source§fn default() -> NeutralKronOptions
fn default() -> NeutralKronOptions
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for NeutralKronOptions
impl<'de> Deserialize<'de> for NeutralKronOptions
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for NeutralKronOptions
Source§impl PartialEq for NeutralKronOptions
impl PartialEq for NeutralKronOptions
Source§fn eq(&self, other: &NeutralKronOptions) -> bool
fn eq(&self, other: &NeutralKronOptions) -> bool
Tests for
self and other values to be equal, and is used by ==.Source§impl Serialize for NeutralKronOptions
impl Serialize for NeutralKronOptions
impl StructuralPartialEq for NeutralKronOptions
Auto Trait Implementations§
impl Freeze for NeutralKronOptions
impl RefUnwindSafe for NeutralKronOptions
impl Send for NeutralKronOptions
impl Sync for NeutralKronOptions
impl Unpin for NeutralKronOptions
impl UnsafeUnpin for NeutralKronOptions
impl UnwindSafe for NeutralKronOptions
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