pub struct RuntimeCors { /* private fields */ }Expand description
Actix runtime CORS middleware.
Implementations§
Source§impl RuntimeCors
impl RuntimeCors
Sourcepub fn new(config: RuntimeCorsConfig) -> Self
pub fn new(config: RuntimeCorsConfig) -> Self
Creates runtime CORS middleware from a product configuration.
Trait Implementations§
Source§impl<S, B> Transform<S, ServiceRequest> for RuntimeCorswhere
S: Service<ServiceRequest, Response = ServiceResponse<B>, Error = Error> + 'static,
B: MessageBody + 'static,
impl<S, B> Transform<S, ServiceRequest> for RuntimeCorswhere
S: Service<ServiceRequest, Response = ServiceResponse<B>, Error = Error> + 'static,
B: MessageBody + 'static,
Source§type Transform = RuntimeCorsMiddleware<S>
type Transform = RuntimeCorsMiddleware<S>
The
TransformService value created by this factorySource§type Future = Ready<Result<<RuntimeCors as Transform<S, ServiceRequest>>::Transform, <RuntimeCors as Transform<S, ServiceRequest>>::InitError>>
type Future = Ready<Result<<RuntimeCors as Transform<S, ServiceRequest>>::Transform, <RuntimeCors as Transform<S, ServiceRequest>>::InitError>>
The future response value.
Source§fn new_transform(&self, service: S) -> Self::Future
fn new_transform(&self, service: S) -> Self::Future
Creates and returns a new Transform component, asynchronously
Auto Trait Implementations§
impl Freeze for RuntimeCors
impl !RefUnwindSafe for RuntimeCors
impl !Send for RuntimeCors
impl !Sync for RuntimeCors
impl Unpin for RuntimeCors
impl UnsafeUnpin for RuntimeCors
impl !UnwindSafe for RuntimeCors
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