mirror of
https://github.com/actix/actix-extras.git
synced 2025-06-27 02:37:42 +02:00
Impl BodyEncoding for Response (#740)
This commit is contained in:
@ -189,6 +189,18 @@ impl<B> Response<B> {
|
||||
self.head.keep_alive()
|
||||
}
|
||||
|
||||
/// Responses extensions
|
||||
#[inline]
|
||||
pub fn extensions(&self) -> Ref<Extensions> {
|
||||
self.head.extensions.borrow()
|
||||
}
|
||||
|
||||
/// Mutable reference to a the response's extensions
|
||||
#[inline]
|
||||
pub fn extensions_mut(&mut self) -> RefMut<Extensions> {
|
||||
self.head.extensions.borrow_mut()
|
||||
}
|
||||
|
||||
/// Get body os this response
|
||||
#[inline]
|
||||
pub fn body(&self) -> &ResponseBody<B> {
|
||||
|
Reference in New Issue
Block a user