pub struct AccountsAuthBuilder { /* private fields */ }Expand description
Builder for AccountsAuth.
Implementations§
Source§impl AccountsAuthBuilder
impl AccountsAuthBuilder
Sourcepub fn app_id(self, app_id: impl Into<String>) -> Self
pub fn app_id(self, app_id: impl Into<String>) -> Self
The app id to sign in to (default commit; a development deployment may use another).
Sourcepub fn telemetry(self, enabled: bool) -> Self
pub fn telemetry(self, enabled: bool) -> Self
When false, requests carry X-Accounts-Telemetry: off. Default true.
Sourcepub fn user_agent(self, product: impl Into<String>) -> Self
pub fn user_agent(self, product: impl Into<String>) -> Self
A product token prepended to the User-Agent, e.g. silicon-commit-cli/0.5.0.
Sourcepub fn build(self) -> Result<AccountsAuth, Error>
pub fn build(self) -> Result<AccountsAuth, Error>
Builds the client. Plain http:// is accepted only for this machine
(localhost, 127.0.0.1, ::1), so tokens never cross a network unencrypted.
Trait Implementations§
Source§impl Clone for AccountsAuthBuilder
impl Clone for AccountsAuthBuilder
Auto Trait Implementations§
impl Freeze for AccountsAuthBuilder
impl RefUnwindSafe for AccountsAuthBuilder
impl Send for AccountsAuthBuilder
impl Sync for AccountsAuthBuilder
impl Unpin for AccountsAuthBuilder
impl UnsafeUnpin for AccountsAuthBuilder
impl UnwindSafe for AccountsAuthBuilder
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