pub struct MultiConfig {
pub active_relay_id: Option<String>,
pub relays: Vec<RelayProfile>,
}Fields§
§active_relay_id: Option<String>§relays: Vec<RelayProfile>Implementations§
Source§impl MultiConfig
impl MultiConfig
pub fn load() -> Self
pub fn save(&self) -> Result<(), String>
pub fn active_profile(&self) -> Option<&RelayProfile>
pub fn active_profile_mut(&mut self) -> Option<&mut RelayProfile>
pub fn to_active_config(&self) -> Config
pub fn from_legacy_pub(old: Config) -> Self
Trait Implementations§
Source§impl Clone for MultiConfig
impl Clone for MultiConfig
Source§fn clone(&self) -> MultiConfig
fn clone(&self) -> MultiConfig
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 MultiConfig
impl Debug for MultiConfig
Source§impl Default for MultiConfig
impl Default for MultiConfig
Source§fn default() -> MultiConfig
fn default() -> MultiConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for MultiConfig
impl<'de> Deserialize<'de> for MultiConfig
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
Auto Trait Implementations§
impl Freeze for MultiConfig
impl RefUnwindSafe for MultiConfig
impl Send for MultiConfig
impl Sync for MultiConfig
impl Unpin for MultiConfig
impl UnsafeUnpin for MultiConfig
impl UnwindSafe for MultiConfig
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