Home
last modified time | relevance | path

Searched defs:HttpError (Results 1 – 20 of 20) sorted by relevance

/commonlibrary/rust/ylong_http/ylong_http/src/
Derror.rs35 pub struct HttpError { struct
39 impl From<ErrorKind> for HttpError { argument
45 impl From<InvalidUri> for HttpError { implementation
52 impl From<H2Error> for HttpError { implementation
58 impl From<Infallible> for HttpError { implementation
64 impl Display for HttpError { implementation
70 impl Error for HttpError {} implementation
Dheaders.rs210 pub fn from_bytes(bytes: &[u8]) -> Result<Self, HttpError> { in from_bytes() argument
237 fn normalize(input: &[u8]) -> Result<String, HttpError> { in normalize() argument
316 pub fn from_bytes(bytes: &[u8]) -> Result<Self, HttpError> { in from_bytes() argument
357 pub fn append_bytes(&mut self, bytes: &[u8]) -> Result<(), HttpError> { in append_bytes() argument
382 pub fn to_str(&self) -> Result<String, HttpError> { in to_str() argument
722 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in insert()
724 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in insert()
759 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append()
761 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append()
/commonlibrary/rust/ylong_http/ylong_http/src/h1/response/
Ddecoder.rs214 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in decode() argument
229 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in version_phase() argument
253 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in status_code_phase() argument
274 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in reason_phase() argument
285 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in status_crlf_phase() argument
296 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in header_phase_with_init() argument
316 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in header_phase() argument
326 ) -> Result<Option<(ResponsePart, &'a [u8])>, HttpError> { in blank_line_phase() argument
341 fn decode_status_crlf<'a>(&mut self, buffer: &'a [u8]) -> Result<Option<&'a [u8]>, HttpError> { in decode_status_crlf() argument
356 fn decode_header<'a>(&mut self, buffer: &'a [u8]) -> Result<Option<&'a [u8]>, HttpError> { in decode_header() argument
[all …]
/commonlibrary/rust/ylong_http/ylong_http/src/request/
Dmod.rs104 <Uri as TryFrom<T>>::Error: Into<HttpError>, in get()
122 <Uri as TryFrom<T>>::Error: Into<HttpError>, in head()
140 <Uri as TryFrom<T>>::Error: Into<HttpError>, in post()
157 <Uri as TryFrom<T>>::Error: Into<HttpError>, in put()
175 <Uri as TryFrom<T>>::Error: Into<HttpError>, in delete()
193 <Uri as TryFrom<T>>::Error: Into<HttpError>, in connect()
211 <Uri as TryFrom<T>>::Error: Into<HttpError>, in options()
514 <Method as TryFrom<T>>::Error: Into<HttpError>, in method()
536 <Uri as TryFrom<T>>::Error: Into<HttpError>, in url()
557 <Version as TryFrom<T>>::Error: Into<HttpError>, in version()
[all …]
Dmethod.rs115 pub fn from_bytes(bytes: &[u8]) -> Result<Method, HttpError> { in from_bytes() argument
Duri.rs221 pub fn from_bytes(bytes: &[u8]) -> Result<Self, HttpError> { in from_bytes() argument
480 pub fn build(self) -> Result<Uri, HttpError> { in build() argument
766 pub fn as_u16(&self) -> Result<u16, HttpError> { in as_u16() argument
/commonlibrary/rust/ylong_http/ylong_http_client/src/async_impl/
Dadapter.rs88 <Method as TryFrom<T>>::Error: Into<HttpError>, in method()
98 <Uri as TryFrom<T>>::Error: Into<HttpError>, in url()
107 <Version as TryFrom<T>>::Error: Into<HttpError>, in version()
127 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in header()
129 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in header()
149 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append_header()
151 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append_header()
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/decode/
Dmulti.rs118 ) -> Result<(TokenStatus<MimeMulti, ()>, &'a [u8]), HttpError> { in decode() argument
156 ) -> Result<&'a [u8], HttpError> { in unknown_decode() argument
189 fn push_new_part_stage(&mut self, headers: Headers) -> Result<(), HttpError> { in push_new_part_stage() argument
201 ) -> Result<&'a [u8], HttpError> { in part_decode() argument
222 fn multi_decode<'a>(&mut self, data: DecodeData, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in multi_decode() argument
234 ) -> Result<&'a [u8], HttpError> { in middle_or_end_boundary_decode() argument
260 ) -> Result<&'a [u8], HttpError> { in first_boundary_decode() argument
272 ) -> Result<&'a [u8], HttpError> { in outermost_first_boundary_decode() argument
299 ) -> Result<&'a [u8], HttpError> { in inner_first_boundary_decode() argument
311 fn temp_multi_end(&mut self, by_part: bool) -> Result<(), HttpError> { in temp_multi_end() argument
[all …]
Dpart.rs73 ) -> Result<(TokenStatus<MimePart<'static>, ()>, &'a [u8]), HttpError> { in decode() argument
101 fn start_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in start_decode() argument
108 fn headers_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in headers_decode() argument
119 fn body_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in body_decode() argument
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/common/
Dmulti.rs158 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in insert_header()
160 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in insert_header()
173 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append_header()
175 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append_header()
189 ) -> Result<&mut Headers, HttpError> { in set_content_type() argument
391 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in insert_header()
393 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in insert_header()
416 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append_header()
418 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append_header()
537 pub fn build(self) -> Result<MimeMulti<'a>, HttpError> { in build() argument
Dpart.rs82 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in header()
84 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in header()
97 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append_header()
99 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append_header()
283 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in header()
285 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in header()
308 <HeaderName as TryFrom<N>>::Error: Into<HttpError>, in append_header()
310 <HeaderValue as TryFrom<V>>::Error: Into<HttpError>, in append_header()
398 pub fn build(self) -> Result<MimePart<'a>, HttpError> { in build() argument
Dheaders.rs161 ) -> Result<(TokenStatus<Headers, ()>, &'a [u8]), HttpError> { in decode() argument
189 fn start_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in start_decode() argument
231 fn crlf_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in crlf_decode() argument
242 fn name_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in name_decode() argument
264 fn value_decode<'a>(&mut self, buf: &'a [u8]) -> Result<&'a [u8], HttpError> { in value_decode() argument
Dmod.rs125 ) -> Result<TokenStatus<&[u8], usize>, HttpError> { in consume_crlf() argument
/commonlibrary/rust/ylong_http/ylong_http/src/h1/request/
Dencoder.rs248 pub fn encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in encode() argument
308 fn method_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in method_encode() argument
321 fn method_sp_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in method_sp_encode() argument
335 fn uri_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in uri_encode() argument
348 fn uri_sp_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in uri_sp_encode() argument
361 fn version_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in version_encode() argument
374 fn version_crlf_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in version_crlf_encode() argument
387 fn header_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in header_encode() argument
400 fn header_crlf_encode(&mut self, dst: &mut [u8]) -> Result<usize, HttpError> { in header_crlf_encode() argument
/commonlibrary/rust/ylong_http/ylong_http/src/response/
Dstatus.rs51 pub fn from_u16(code: u16) -> Result<StatusCode, HttpError> { in from_u16() argument
81 pub fn from_bytes(bytes: &[u8]) -> Result<Self, HttpError> { in from_bytes() argument
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/
Dmimetype.rs62 pub fn from_bytes(bytes: &'a [u8]) -> Result<Self, HttpError> { in from_bytes() argument
98 pub fn from_path(path: &'a Path) -> Result<Self, HttpError> { in from_path() argument
567 fn from_bytes(b: &[u8]) -> Result<Self, HttpError> { in from_bytes() argument
/commonlibrary/rust/ylong_http/ylong_http_client/src/async_impl/conn/
Dhttp2.rs196 ) -> Result<Frame, HttpError> { in build_headers_frame() argument
220 fn check_connection_specific_headers(id: u32, headers: &Headers) -> Result<(), HttpError> { in check_connection_specific_headers() argument
/commonlibrary/rust/ylong_http/ylong_http/src/body/
Dchunk.rs1017 pub fn decode<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunks<'a>, &'a [u8]), HttpError> { in decode() argument
1065 fn decode_size<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in decode_size() argument
1137 fn skip_extension<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in skip_extension() argument
1205 fn skip_crlf<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in skip_crlf() argument
1240 fn skip_trailer_crlf<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in skip_trailer_crlf() argument
1276 ) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in decode_trailer_data() argument
1329 fn decode_data<'a>(&mut self, buf: &'a [u8]) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in decode_data() argument
1369 ) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in skip_trailer_last_crlf() argument
1432 ) -> Result<(Chunk<'a>, &'a [u8]), HttpError> { in skip_last_crlf() argument
/commonlibrary/rust/ylong_http/ylong_http_client/src/util/
Ddispatcher.rs766 ) -> Poll<Result<(), HttpError>> { in poll_match_result() argument
1332 fn recv_frame(&mut self, id: u32) -> Result<Option<Frame>, HttpError> { in recv_frame() argument
1418 fn get_frame(frame: Option<Frame>) -> Result<Frame, HttpError> { in get_frame() argument
1436 fn is_io_available(occupied: &AtomicU32, id: u32) -> Result<bool, HttpError> { in is_io_available() argument
1452 ) -> Result<(), HttpError> { in compare_exchange_occupation() argument
/commonlibrary/rust/ylong_http/ylong_http/src/h2/
Dframe.rs546 pub fn error(&self, id: u32) -> Result<H2Error, HttpError> { in error() argument