/ohos5.0/foundation/systemabilitymgr/safwk/interfaces/innerkits/safwk/rust/tests/ |
H A D | basic.rs | 27 std::thread::sleep(std::time::Duration::from_secs(20)); in init() 29 std::thread::sleep(std::time::Duration::from_secs(20)); in init() 49 std::thread::sleep(std::time::Duration::from_secs(5)); in reason() 54 std::thread::sleep(std::time::Duration::from_secs(5)); in reason() 59 std::thread::sleep(std::time::Duration::from_secs(5)); in reason() 64 std::thread::sleep(std::time::Duration::from_secs(5)); in reason()
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http_client/src/util/config/ |
H A D | settings.rs | 207 pub fn from_secs(secs: u64) -> Self { in from_secs() method 208 Self(Some(Duration::from_secs(secs))) in from_secs() 269 self.min = (cmp::min(self.max, min), Duration::from_secs(secs)); in min_speed() 545 let timeout = Timeout::from_secs(5); in ut_timeout_clone() 583 assert_eq!(speed.min, (1024, Duration::from_secs(12))) in ut_speed_limit_min_speed()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/tests/ |
H A D | join_set.rs | 194 sleep(Duration::from_secs(100000)).await; in sdv_join_set_cancel_one() 222 sleep(Duration::from_secs(10000)).await; in sdv_join_set_cancel_all() 274 sleep(Duration::from_secs(100000)).await; in sdv_join_set_shutdown() 297 sleep(Duration::from_secs(100000)).await; in sdv_join_set_drop()
|
H A D | block_on.rs | 85 sleep(time::Duration::from_secs(1)); in sdv_block_on_nest_spawn_spawn_blocking() 115 sleep(time::Duration::from_secs(1)); in sdv_block_on_nest_spawn_and_spawn() 128 sleep(time::Duration::from_secs(1)); in sdv_block_on_nest_spawn_and_spawn() 163 sleep(time::Duration::from_secs(1)); in sdv_block_on_nest_spawn_nest_spawn()
|
H A D | task_cancel.rs | 36 sleep(Duration::from_secs(100)).await; in sdv_task_cancel_simple() 97 sleep(Duration::from_secs(1000000)); in sdv_task_cancel_multiple()
|
H A D | tcp_test.rs | 138 .set_linger(Some(std::time::Duration::from_secs(1))) in sdv_tcp_stream_basic() 142 Some(std::time::Duration::from_secs(1)) in sdv_tcp_stream_basic() 472 sleep(Duration::from_secs(10000)).await; in sdv_tcp_cancel() 486 sleep(Duration::from_secs(100000)).await; in sdv_tcp_cancel() 494 sleep(Duration::from_secs(10000)).await; in sdv_tcp_cancel() 581 ylong_runtime::time::sleep(std::time::Duration::from_secs(10)).await; in sdv_tcp_unexpected_eof()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/examples/ |
H A D | ylong_runtime_timer_memory.rs | 32 ylong_runtime::time::timeout(Duration::from_secs(1), read_big_data()).await in run_forever() 53 std::thread::sleep(Duration::from_secs(3600)); in main()
|
H A D | ylong_timer_out_of_context.rs | 22 ylong_runtime::time::sleep(Duration::from_secs(1)); in main()
|
H A D | ylong_runtime_short_block.rs | 22 sleep(Duration::from_secs(1)); in main()
|
H A D | ylong_runtime_spawn_fail.rs | 24 ylong_runtime::time::sleep(Duration::from_secs(100)).await; in main()
|
H A D | ylong_runtime_create_thread_fail.rs | 26 thread::sleep(Duration::from_secs(1000)); in main()
|
H A D | ylong_runtime_task_starvation.rs | 31 thread::sleep(Duration::from_secs(5)); in main()
|
/ohos5.0/base/request/request/services/examples/ |
H A D | run_count.rs | 45 std::thread::sleep(std::time::Duration::from_secs(1)); in main() 52 std::thread::sleep(std::time::Duration::from_secs(30000)); in main()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/src/executor/ |
H A D | blocking_pool.rs | 29 pub(crate) const BLOCKING_THREAD_QUIT_WAIT_TIME: Duration = Duration::from_secs(1); 104 const BLOCKING_THREAD_KEEP_ALIVE_TIME: Duration = Duration::from_secs(5); 424 RuntimeBuilder::new_multi_thread().keep_alive_time(Duration::from_secs(1)); in ut_blocking_pool_new() 459 assert!(!blocking_pool.shutdown(Duration::from_secs(3))); in ut_blocking_pool_shutdown() 468 assert!(blocking_pool.shutdown(Duration::from_secs(3))); in ut_blocking_pool_shutdown() 478 assert!(!blocking_pool.shutdown(Duration::from_secs(0))); in ut_blocking_pool_shutdown()
|
/ohos5.0/base/request/request/services/tests/ |
H A D | resume.rs | 38 std::thread::sleep(std::time::Duration::from_secs(1)); in sdv_start_resume() 49 ylong_runtime::time::sleep(Duration::from_secs(1)).await; in sdv_start_resume()
|
H A D | start.rs | 46 ylong_runtime::time::sleep(Duration::from_secs(1)).await; in sdv_start_basic()
|
/ohos5.0/foundation/communication/netstack/interfaces/innerkits/rust/ylong_http_client/src/reqwest_impl/ |
H A D | config.rs | 56 pub fn from_secs(secs: u64) -> Self { in from_secs() method 57 Self(Some(Duration::from_secs(secs))) in from_secs() 111 self.min = (cmp::min(self.max, min), Duration::from_secs(duration)); in min_speed()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/docs/ |
H A D | user_guide.md | 24 .keep_alive_time(std::time::Duration::from_secs(10)) 87 sleep(Duration::from_secs(100)).await; 146 let result = timeout(Duration::from_millis(100), sleep(Duration::from_secs(1)));
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/benches/bin/ |
H A D | ylong_tokio_spawn.rs | 40 sleep(Duration::from_secs(5)); in async_task() 44 sleep(Duration::from_secs(5)); in task()
|
/ohos5.0/commonlibrary/rust/ylong_http/ylong_http_client/tests/ |
H A D | sdv_async_http_client_error.rs | 64 .connect_timeout(Timeout::from_secs(1)) in sdv_err_start_connect_timeout() 123 .request_timeout(Timeout::from_secs(1)) in sdv_err_req_timeout()
|
/ohos5.0/base/request/request/services/src/manage/events/ |
H A D | mod.rs | 293 std::thread::sleep(time::Duration::from_secs(10)); in ut_task_manager_start() 320 std::thread::sleep(time::Duration::from_secs(20)); in ut_task_manager_pause_resume() 347 std::thread::sleep(time::Duration::from_secs(20)); in ut_task_manager_stop_resume()
|
/ohos5.0/base/request/request/services/src/manage/ |
H A D | task_manager.rs | 434 sleep(Duration::from_secs(RESTORE_ALL_TASKS_INTERVAL)).await; in restore_all_tasks() 440 sleep(Duration::from_secs(CLEAR_INTERVAL)).await; in clear_timeout_tasks() 447 sleep(Duration::from_secs(LOG_INTERVAL)).await; in log_all_task_info()
|
/ohos5.0/base/request/request/services/src/task/ |
H A D | client.rs | 37 .connect_timeout(Timeout::from_secs(CONNECT_TIMEOUT)) in build_client() 38 .request_timeout(Timeout::from_secs(SECONDS_IN_ONE_WEEK)) in build_client()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/src/builder/ |
H A D | mod.rs | 380 let keep_alive_time = Duration::from_secs(0); in ut_thread_pool_builder_keep_alive_time() 388 let keep_alive_time = Duration::from_secs(1); in ut_thread_pool_builder_keep_alive_time()
|
/ohos5.0/commonlibrary/rust/ylong_runtime/ylong_runtime/src/time/ |
H A D | sleep.rs | 21 const TEN_YEARS: Duration = Duration::from_secs(86400 * 365 * 10); 335 let past = Instant::now().checked_sub(Duration::from_secs(1)).unwrap(); in ut_timer_sleep_zero()
|