[][src]Struct oxide_auth::frontends::actix::request::OAuthResponse

pub struct OAuthResponse { /* fields omitted */ }

An http response replacement that can be sent as an actix message.

This is the generic answer to oauth authorization code and bearer token requests.

Methods

impl OAuthResponse[src]

pub fn consent_form(grant: PreGrant) -> Self[src]

Construct a response that represents a consent form.

Use this in an OwnerSolicitor implementation for OAuthRequest to construct the OwnerConsent::InProgress variant.

pub fn new(inner: Response) -> Self[src]

Create the response with predetermined content.

pub fn unwrap(self) -> HttpResponse[src]

Retrive the internal response, assuming that it does not require consent.

Convert the response into an http response.

When the response represents a required consent form, use the argument as the response to the user agent instead. This replacement response should generally display the wanting client and required scopes in a clear and click-jacking protected manner to the authenticated resource owner. When the resource owner is not currently authenticated (i.e. logged in), this is a good opportunity to redirect to such a login page.

Convert the response into an http response.

When the response represents a required consent form, use the provided function to construct the response to the user agent instead. This replacement response should generally display the wanting client and required scopes in a clear and click-jacking protected manner to the authenticated resource owner. When the resource owner is not currently authenticated (i.e. logged in), this is a good opportunity to redirect to such a login page.

Trait Implementations

impl WebResponse for OAuthResponse[src]

type Error = OAuthError

The error generated when trying to construct an unhandled or invalid response.

impl Default for OAuthResponse[src]

impl Clone for OAuthResponse[src]

fn clone_from(&mut self, source: &Self)1.0.0[src]

Performs copy-assignment from source. Read more

impl Debug for OAuthResponse[src]

Auto Trait Implementations

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

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

The type returned in the event of a conversion error.

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Erased for T

impl<T> Typeable for T where
    T: Any

fn get_type(&self) -> TypeId

Get the TypeId of this object.

impl<T> DebugAny for T where
    T: Any + Debug

impl<T> CloneAny for T where
    T: Clone + Any

impl<T> UnsafeAny for T where
    T: Any

impl<T> IntoCollection<T> for T

impl<T, I> AsResult<T, I> for T where
    I: Input,