Struct googauth_lib::ConfigFile [−][src]
pub struct ConfigFile {
pub version: u32,
pub name: String,
pub client_id: String,
pub client_secret: String,
pub scopes: Vec<String>,
pub redirect_url: String,
pub refresh_token: Option<String>,
pub id_token: Option<Token>,
pub access_token: Option<Token>,
}
Expand description
A configuration file that saves the information necessary to fetch tokens and to be able to refresh said tokens when needed.
Fields
version: u32
name: String
client_id: String
client_secret: String
scopes: Vec<String>
redirect_url: String
refresh_token: Option<String>
id_token: Option<Token>
access_token: Option<Token>
Implementations
pub fn config_file(
name: &str,
config_base_path: &ConfigBasePath
) -> Result<PathBuf, LibError>
pub fn read_config(
name: &str,
config_base_path: &ConfigBasePath
) -> Result<ConfigFile, LibError>
Trait Implementations
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 RefUnwindSafe for ConfigFile
impl Send for ConfigFile
impl Sync for ConfigFile
impl Unpin for ConfigFile
impl UnwindSafe for ConfigFile
Blanket Implementations
Mutably borrows from an owned value. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more