Struct saturn_cli::config::Config
source · pub struct Config { /* private fields */ }Implementations§
source§impl Config
impl Config
pub fn load(filename: Option<PathBuf>) -> Result<Self, Error>
pub fn save(&self, filename: Option<PathBuf>) -> Result<(), Error>
pub fn set_calendar_id(&mut self, calendar_id: String)
pub fn set_access_token(&mut self, access_token: Option<String>)
pub fn set_access_token_expires_at(&mut self, expires_at: Option<NaiveDateTime>)
pub fn set_refresh_token(&mut self, refresh_token: Option<String>)
pub fn set_refresh_token_expires_at( &mut self, expires_at: Option<NaiveDateTime> )
pub fn access_token(&self) -> Option<String>
pub fn access_token_expires_at(&self) -> Option<NaiveDateTime>
pub fn refresh_token(&self) -> Option<String>
pub fn refresh_token_expires_at(&self) -> Option<NaiveDateTime>
pub fn set_redirect_url(&mut self, redirect_url: Option<String>)
pub fn calendar_id(&self) -> String
pub fn redirect_url(&self) -> Option<String>
pub fn set_db_type(&mut self, typ: DBType)
pub fn db_type(&self) -> DBType
pub fn set_sync_duration( &mut self, sync_duration: Option<FancyDuration<Duration>> )
pub fn sync_duration(&self) -> Option<FancyDuration<Duration>>
pub fn set_client_info(&mut self, client_id: String, client_secret: String)
pub fn has_client(&self) -> bool
pub fn client_id(&self) -> Option<String>
pub fn client_secret(&self) -> Option<String>
Trait Implementations§
source§impl<'de> Deserialize<'de> for Config
impl<'de> Deserialize<'de> for Config
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
source§impl Into<ClientParameters> for Config
impl Into<ClientParameters> for Config
source§fn into(self) -> ClientParameters
fn into(self) -> ClientParameters
Converts this type into the (usually inferred) input type.
Auto Trait Implementations§
impl RefUnwindSafe for Config
impl Send for Config
impl Sync for Config
impl Unpin for Config
impl UnwindSafe for Config
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