Struct actix_web::middleware::session::SessionStorage[][src]

pub struct SessionStorage<T, S>(_, _);
[]

Session storage middleware

use actix_web::middleware::session::{CookieSessionBackend, SessionStorage};
use actix_web::App;

fn main() {
    let app = App::new().middleware(SessionStorage::new(
        // <- create session middleware
        CookieSessionBackend::signed(&[0; 32]) // <- create cookie session backend
              .secure(false),
    ));
}

Methods

impl<S, T: SessionBackend<S>> SessionStorage<T, S>
[src]
[]

[]

Create session storage

Trait Implementations

impl<S: 'static, T: SessionBackend<S>> Middleware<S> for SessionStorage<T, S>
[src]
[+]

[]

Method is called when request is ready. It may return future, which should resolve before next middleware get called. Read more

[]

Method is called when handler returns response, but before sending http message to peer. Read more

[]

Method is called after body stream get sent to peer.

Auto Trait Implementations

impl<T, S> Send for SessionStorage<T, S> where
    S: Send,
    T: Send

impl<T, S> Sync for SessionStorage<T, S> where
    S: Sync,
    T: Sync