pub struct DeviceFlow {
pub host: String,
pub client_id: String,
pub user_code: Option<String>,
pub device_code: Option<String>,
pub verification_uri: Option<String>,
pub state: DeviceFlowState,
}
Fields§
§host: String
§client_id: String
§user_code: Option<String>
§device_code: Option<String>
§verification_uri: Option<String>
§state: DeviceFlowState
Implementations§
Source§impl DeviceFlow
impl DeviceFlow
pub fn new(client_id: &str, maybe_host: Option<&str>) -> Self
pub fn start( client_id: &str, maybe_host: Option<&str>, ) -> Result<DeviceFlow, DeviceFlowError>
pub fn setup(&mut self)
pub fn poll(&mut self, iterations: u32) -> Result<Credential, DeviceFlowError>
pub fn update(&mut self)
Trait Implementations§
Source§impl Clone for DeviceFlow
impl Clone for DeviceFlow
Source§fn clone(&self) -> DeviceFlow
fn clone(&self) -> DeviceFlow
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl Freeze for DeviceFlow
impl RefUnwindSafe for DeviceFlow
impl Send for DeviceFlow
impl Sync for DeviceFlow
impl Unpin for DeviceFlow
impl UnwindSafe for DeviceFlow
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