Skip to main content

RequestSigner

Struct RequestSigner 

Source
pub struct RequestSigner { /* private fields */ }
Expand description

RequestSigner for Google service requests.

Implementations§

Source§

impl RequestSigner

Source

pub fn new(service: impl Into<String>) -> Self

Create a new builder with the specified service.

Source

pub fn with_scope(self, scope: impl Into<String>) -> Self

Set the OAuth2 scope.

Source

pub fn with_signer_email(self, signer_email: impl Into<String>) -> Self

Set the signer service account email used for query signing via IAMCredentials signBlob.

This is required when generating signed URLs without an embedded service account private key (e.g. ADC / WIF / impersonation tokens).

Source

pub fn with_region(self, region: impl Into<String>) -> Self

Set the region for the builder.

Trait Implementations§

Source§

impl Debug for RequestSigner

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for RequestSigner

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl SignRequest for RequestSigner

Source§

type Credential = Credential

Credential used by this builder. Read more
Source§

async fn sign_request( &self, ctx: &Context, req: &mut Parts, credential: Option<&Self::Credential>, expires_in: Option<Duration>, ) -> Result<()>

Construct the signing request. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> SignRequestDyn for T
where T: SignRequest + ?Sized,

Source§

type Credential = <T as SignRequest>::Credential

Credential used by this builder.
Source§

fn sign_request_dyn<'a>( &'a self, ctx: &'a Context, req: &'a mut Parts, credential: Option<&'a <T as SignRequestDyn>::Credential>, expires_in: Option<Duration>, ) -> Pin<Box<dyn Future<Output = Result<(), Error>> + Send + 'a>>

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> MaybeSend for T
where T: Send,