/commonlibrary/rust/ylong_runtime/ylong_runtime/src/task/ |
H A D | waker.rs | 24 let header = ptr as *mut Header; in get_header_by_raw_ptr() 25 let non_header = NonNull::new(header); in get_header_by_raw_ptr() 29 panic!("task header is null"); in get_header_by_raw_ptr() 37 let header = ptr.cast::<Header>(); in clone() 38 (*header).state.inc_ref(); in clone() 39 raw_waker::<T>(header) in clone() 43 let header = get_header_by_raw_ptr(ptr); in wake() 44 let vir_tble = header.as_ref().vtable; in wake() 45 (vir_tble.schedule)(header, true); in wake() 49 let header in wake_by_ref() [all...] |
H A D | task_handle.rs | 45 fn header(&self) -> &Header { in header() functions 46 unsafe { self.task.as_ref().header() } in header() 67 let cur = match self.header().state.turning_to_finish() { in finish() 83 let prev = self.header().state.dec_ref(); 94 if self.header().state.try_turning_to_un_join_handle() { 98 match self.header().state.turn_to_un_join_handle() { 121 let result = self.header().state.turn_to_set_waker(); in set_waker_inner() 145 self.header() 173 let action = self.header().state.turning_to_running(); 185 // turn the task header int [all...] |
H A D | raw.rs | 119 pub(crate) fn header(&self) -> &Header { 124 let vir_table = self.header().vtable; 129 let vir_table = self.header().vtable; 134 let vir_table = self.header().vtable; 139 let vir_table = self.header().vtable; 144 let vir_table = self.header().vtable; 151 let vir_table = self.header().vtable; 166 let vir_table = self.header().vtable; 285 header: Header, 457 // Create the common header [all...] |
H A D | join_handle.rs | 75 state::is_finished(self.raw.header().state.get_current_state()) in is_finished() 83 let cur = self.raw.header().state.get_current_state(); 105 let cur = self.raw.header().state.get_current_state(); 146 raw.header().state.inc_ref(); 161 let state = self.raw.header().state.get_current_state(); in is_finished()
|
/commonlibrary/rust/ylong_http/ylong_http/examples/ |
H A D | mimebody_multi.rs | 42 // of the text in this part means no header fields were 135 .header("Content-type", "text/plain; charset=US-ASCII") in main() 145 .header("Content-type", "audio/basic") in main() 146 .header("Content-Transfer-Encoding", "base64") in main() 153 .header("Content-type", "image/jpeg") in main() 154 .header("Content-Transfer-Encoding", "base64") in main() 164 .header("Content-type", "text/enriched") in main() 171 .header("Content-type", "message/rfc822") in main()
|
H A D | mimebody_multi_then_async_data.rs | 60 .header("Content-type", "text/plain; charset=US-ASCII") 70 .header("Content-type", "audio/basic") 71 .header("Content-Transfer-Encoding", "base64") 78 .header("Content-type", "image/jpeg") 79 .header("Content-Transfer-Encoding", "base64") 89 .header("Content-type", "text/enriched") 96 .header("Content-type", "message/rfc822")
|
/commonlibrary/rust/ylong_http/ylong_http/tests/ |
H A D | sdv_http_headers.rs | 29 let header = Header::from_raw_parts(name, value); in sdv_client_send_request_repeatedly() 30 let cloned_header = header.clone(); in sdv_client_send_request_repeatedly() 31 assert_eq!(header, cloned_header); in sdv_client_send_request_repeatedly() 32 assert_eq!(format!("{:?}", header), "Header { name: HeaderName { name: \"john-doe\" }, value: HeaderValue { inner: [[70, 111, 111]], is_sensitive: false } }"); in sdv_client_send_request_repeatedly()
|
/commonlibrary/rust/ylong_http/ylong_http/src/h2/ |
H A D | decoder.rs | 180 // 9-byte header information of the current frame 181 header: FrameHeader, 297 header: FrameHeader::new(), in default() 385 && (self.header.stream_id != self.continuations.stream_id in decode_frame_payload() 386 || self.header.frame_type != 9) in decode_frame_payload() 391 let frame_end_index = self.header.payload_length - self.offset; 397 let frame = match self.header.frame_type { 412 self.header.reset(); 422 if !is_connection_frame(self.header.stream_id) { in decode_ping_payload() 432 if self.header in decode_ping_payload() [all...] |
H A D | parts.rs | 55 Header::Other(header) => self.map.append(header.as_str(), value.as_str()).unwrap(),
|
/commonlibrary/rust/ylong_http/ylong_http/src/h2/hpack/ |
H A D | table.rs | 40 StaticTable::header(index) 42 self.dynamic.header(index - 62) 47 pub(crate) fn index(&self, header: &Header, value: &str) -> Option<TableIndex> { 49 StaticTable::index(header, value), 50 self.dynamic.index(header, value), 72 /// The dynamic table consists of a list of header fields maintained in 77 /// The dynamic table is initially empty. Entries are added as each header block 89 /// header field representations. 120 pub(crate) fn header(&self, index: usize) -> Option<(Header, String)> { 125 pub(crate) fn update(&mut self, header 300 fn header(index: usize) -> Option<(Header, String)> { header() functions [all...] |
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/common/ |
H A D | part.rs | 26 /// closing boundary delimiter line. Each body part then consists of a header 39 /// .header("accept", "text/html") 79 pub(crate) fn header<N, V>(&mut self, name: N, value: V) -> Result<&mut Headers, HttpError> 217 /// .header("accept", "text/html") 269 /// Inserts header to the MIME body part. 277 /// .header("accept", "text/html") 278 /// .header("accept", "text/plain"); 280 pub fn header<N, V>(mut self, name: N, value: V) -> Self in header() functions 288 inner.header(name, value)?; in header() 294 /// Appends header t [all...] |
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/decode/ |
H A D | multi.rs | 47 /// .header("key1", "value1") 576 .header("key1", "value1") in ut_mime_multi_decoder_one_part() 641 .header("key1", "value1") in ut_mime_multi_decoder_one_part_no_body() 674 .header("key1", "value1") in ut_mime_multi_decoder_several_parts() 681 .header("key2", "value2") in ut_mime_multi_decoder_several_parts() 714 .header("key1", "value1") in ut_mime_multi_decoder_several_parts_has_lwsp() 721 .header("key2", "value2") in ut_mime_multi_decoder_several_parts_has_lwsp() 758 .header("key1", "value1") in ut_mime_multi_decoder_nest() 799 .header("key1", "value1") in ut_mime_multi_decoder_nest2() 809 .header("key in ut_mime_multi_decoder_nest2() [all...] |
H A D | part.rs | 292 .header("name1", "value1") in ut_mime_part_decoder_decode() 293 .header("name2", "value2") in ut_mime_part_decoder_decode() 351 .header("name1", "value1") in ut_decode_headers_decode_times() 352 .header("name2", "value2") in ut_decode_headers_decode_times()
|
/commonlibrary/rust/ylong_http/ylong_http/src/h3/ |
H A D | parts.rs | 57 NameField::Other(header) => self.map.append(header.as_str(), value.as_str()).unwrap(), in update() 102 let (pseudo, header) = part.parts(); in ut_h3_part_update() 109 header.get("test-key").map(|v| v.to_string().unwrap()), in ut_h3_part_update()
|
/commonlibrary/rust/ylong_http/ylong_http_client/src/async_impl/ |
H A D | request.rs | 98 /// .header("Content-Type", "application/octet-stream") 173 /// let builder = RequestBuilder::new().header("Content-Type", "application/octet-stream"); 175 pub fn header(mut self, name: &str, value: &str) -> Self { in header() functions 176 self.0 = self.0.header(name, value); in header() 208 builder = builder.header( in body() 219 builder = builder.header("Content-Type", value.as_str()); in body() 222 builder = builder.header("Content-Length", format!("{size}").as_str()); in body()
|
/commonlibrary/rust/ylong_http/ylong_http_client/tests/tcp_server/ |
H A D | mod.rs | 104 assert!(request_str.contains(host.as_str()), "Incorrect host header!"); 109 assert!(request_str.contains(header_str.as_str()), "Incorrect {} header!", $req_n); 127 let header = format_header_str($resp_n, $resp_v); 128 resp_str.push_str(header.as_str()); 203 assert!(request_str.contains(accept.as_str()), "Incorrect accept header!"); 207 assert!(request_str.contains(host.as_str()), "Incorrect host header!"); 212 assert!(request_str.contains(header_str.as_str()), "Incorrect {} header!", $req_n); 229 let header = format_header_str($resp_n, $resp_v); 230 resp_str.push_str(header.as_str()); 270 $(.header( [all...] |
/commonlibrary/rust/ylong_http/ylong_http_client/src/util/ |
H A D | test_utils.rs | 49 $(.header($req_n, $req_v))* 107 let header = format_header_str($resp_n, $resp_v); 108 resp_str.push_str(header.as_str());
|
/commonlibrary/rust/ylong_http/ylong_http_client/src/util/h3/ |
H A D | streams.rs | 66 pub(crate) header: Option<Frame>, 74 fn new(frame_tx: BoundedSender<RespMessage>, header: Frame, data: BodyDataRef) -> Self { in new() 78 header: Some(header), in new() 162 header: Frame, 172 .insert(id, BidirectionalStream::new(rx, header, data)); 365 Ok(stream.header.take()) 523 // stream.header = None; 551 stream.header = None; 575 stream.header [all...] |
/commonlibrary/rust/ylong_http/ylong_http_client/src/util/h2/ |
H A D | streams.rs | 121 pub(crate) header: Option<Frame>, 424 _ => Ok(stream.header.take()), 517 unsent_stream.header = None; 523 unsent_stream.header = None; 539 stream.header = None; 573 stream.header = None; 661 stream.header = None; 766 header: Some(headers),
|
/commonlibrary/rust/ylong_http/ylong_http_client/tests/common/ |
H A D | mod.rs | 235 $(.header($req_n, $req_v))* 259 $(.header($req_n, $req_v))* 308 .expect(format!("Get request header \"{}\" failed", $req_n).as_str()) 310 .expect(format!("Convert request header \"{}\" into string failed", $req_n).as_str()), 311 "Assert request header {} failed", $req_n, 320 $(.header($resp_n, $resp_v))* 371 .expect(format!("Get request header \"{}\" failed", $req_n).as_str()) 373 .expect(format!("Convert request header \"{}\" into string failed", $req_n).as_str()), 374 "Assert request header {} failed", $req_n, 383 $(.header( [all...] |
/commonlibrary/rust/ylong_runtime/ylong_runtime/src/executor/ |
H A D | queue.rs | 522 .map(|header| unsafe { Task::from_raw(header) }); 532 let header = task.into_header(); 533 list.push_front(header);
|
/commonlibrary/rust/ylong_http/ylong_http/src/request/ |
H A D | mod.rs | 36 //! .header("ACCEPT", "text/html") 475 /// .header("ACCEPT", "text/html") 586 /// let request = RequestBuilder::new().header("ACCEPT", "text/html"); 588 pub fn header<N, V>(mut self, name: N, value: V) -> Self in header() functions 707 /// 5. Sets header by calling `RequestBuilder::insert_header`. 708 /// 6. Sets header by calling `RequestBuilder::append_header`. 720 .header("ACCEPT", "text/html") in ut_request_builder_build() 742 /// 5. Sets header by calling `RequestBuilder.insert_header`. 743 /// 6. Sets header by calling `RequestBuilder.append_header`. 759 .header("ACCEP in ut_request_builder_build_2() [all...] |
/commonlibrary/rust/ylong_http/ylong_http/src/body/mime/ |
H A D | mime_test_macro.rs | 28 $(.header($name, $value))*
|
/commonlibrary/rust/ylong_http/ylong_http_client/tests/ |
H A D | sdv_async_https_pinning.rs | 275 .header("Content-Length", "5") in sdv_client_public_key_pinning_error()
|
/commonlibrary/rust/ylong_http/ylong_http/src/h1/request/ |
H A D | encoder.rs | 29 //! .header("ACCEPT", "text/html") 87 /// .header("ACCEPT", "text/html") 148 // "HeaderCrlf" phase of encoding /r/n after header. 177 /// .header("ACCEPT", "text/html") 229 /// .header("ACCEPT", "text/html") 289 /// .header("ACCEPT", "text/html") 508 fn new(header: Headers) -> Self { in new() 509 let mut header_iter = header.into_iter(); in new() 714 $(.header($name, $value))* in ut_request_encoder_encode_1() 747 // No header in ut_request_encoder_encode_1() [all...] |