MCPcopy Create free account
hub / github.com/HFQR/xitca-web / take_request

Method take_request

web/src/context.rs:120–127  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

118 }
119
120 pub fn take_request(&mut self) -> WebRequest<B>
121 where
122 B: Default,
123 {
124 let head = mem::take(self.req_mut());
125 let body = self.take_body_mut();
126 head.map(|ext| ext.map_body(|_| body))
127 }
128
129 /// Transform self to a WebResponse with given body type.
130 ///

Callers 3

callMethod · 0.80
callMethod · 0.80
callMethod · 0.80

Calls 5

takeFunction · 0.85
req_mutMethod · 0.80
take_body_mutMethod · 0.80
mapMethod · 0.45
map_bodyMethod · 0.45

Tested by

no test coverage detected