pub struct GithubAuth {
pub client_id: String,
pub device_code: String,
pub access_token: String,
}Expand description
ディスクに保存する GitHub 認証状態。GitHub のデバイスフローは client_secret を 要求しないため GdriveAuth と異なり client_id + token のみ。device_code は login → poll の間、CUI の別呼び出しをまたいで引き継ぐために保存する。
Fields§
§client_id: String§device_code: String§access_token: StringImplementations§
Source§impl GithubAuth
impl GithubAuth
pub fn has_client(&self) -> bool
pub fn is_logged_in(&self) -> bool
Trait Implementations§
Source§impl Clone for GithubAuth
impl Clone for GithubAuth
Source§fn clone(&self) -> GithubAuth
fn clone(&self) -> GithubAuth
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 GithubAuth
impl Debug for GithubAuth
Source§impl Default for GithubAuth
impl Default for GithubAuth
Source§fn default() -> GithubAuth
fn default() -> GithubAuth
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for GithubAuth
impl RefUnwindSafe for GithubAuth
impl Send for GithubAuth
impl Sync for GithubAuth
impl Unpin for GithubAuth
impl UnsafeUnpin for GithubAuth
impl UnwindSafe for GithubAuth
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