/commonlibrary/rust/ylong_runtime/ylong_runtime/tests/ |
H A D | process.rs | 62 /// 2. Use `spawn()` create a child handle 69 let mut child = command.spawn().unwrap(); in sdv_process_spawn_test() variables 70 assert!(child.id().is_some()); in sdv_process_spawn_test() 72 let status = child.wait().await.unwrap(); in sdv_process_spawn_test() 74 assert!(child.start_kill().is_err()); in sdv_process_spawn_test() 75 assert!(child.id().is_none()); in sdv_process_spawn_test() 77 let status = child.wait().await.unwrap(); in sdv_process_spawn_test() 87 /// 2. Take `child.stdin` and write something in it. 88 /// 3. Take `child.stdout` and read it, check the result. 89 /// 4. Check child' 93 let mut child = Command::new("rev") sdv_process_child_stdio_test() variables 143 let mut child = command.spawn().unwrap(); sdv_process_kill_test() variables 161 let mut child = command.spawn().unwrap(); sdv_process_try_wait_test() variables 212 let mut child = command.spawn().unwrap(); sdv_process_stdio_test() variables 223 let mut child = command.spawn().unwrap(); sdv_process_stdio_test() variables 258 let mut child = command.spawn().unwrap(); sdv_process_child_stdio_convert_test() variables 282 let mut child = command.spawn().unwrap(); sdv_process_debug_test() variables [all...] |
H A D | pty_process.rs | 27 /// 3. `spawn()` the child with pts of `Pty`. 70 /// 2. `spawn()` the child with pts of `Pty`. 81 let mut child = command.spawn(&pts).unwrap(); in sdv_pty_process_read_and_write_test() variables 85 let status = child.wait().await.unwrap(); in sdv_pty_process_read_and_write_test() 100 /// 2. `spawn()` the child with pts of `Pty`. 112 let mut child = command.spawn(&pts).unwrap(); in sdv_pty_split_test() variables 119 let status = child.wait().await.unwrap(); in sdv_pty_split_test() 132 /// 2. `spawn()` the child with pts of `Pty`. 144 let mut child = command.spawn(&pts).unwrap(); in sdv_pty_into_split_test() variables 151 let status = child in sdv_pty_into_split_test() 178 let mut child = command.spawn(&pts).unwrap(); sdv_pty_unsplit_test() variables [all...] |
H A D | signal.rs | 73 let mut stream = signal(SignalKind::child()).unwrap(); in sdv_signal_recv_multi_thread_test() 152 let mut signal = signal(SignalKind::child()).unwrap(); in sdv_signal_child()
|
/commonlibrary/rust/ylong_runtime/ylong_runtime/src/process/ |
H A D | child.rs | 31 /// Handle of child process 35 // Weather kill the child when drop 47 child: StdChild, 54 state: ChildState::Pending(super::sys::Child::new(child)?), 62 /// Gets the OS-assigned process identifier associated with this child. 64 /// If the child process is exited, it returns `None`. 72 /// let mut child = Command::new("ls") 75 /// let _id = child.id().expect("the child process is exited"); 80 ChildState::Pending(child) in id() 457 let mut child = Child::new(std_child, false, None, None, None).unwrap(); ut_process_child_new_test() variables 480 let mut child = Child::new(std_child, false, None, None, None).unwrap(); ut_process_try_wait_test() variables 507 let mut child = command.spawn().unwrap(); ut_process_stdio_test() variables 518 let mut child = command.spawn().unwrap(); ut_process_stdio_test() variables 552 let mut child = command.spawn().unwrap(); ut_process_child_stdio_convert_test() variables [all...] |
H A D | command.rs | 20 use crate::process::child::{Child, ChildStderr, ChildStdin, ChildStdout}; 88 /// Sets whether kill the child process when `Child` drop. 207 /// Clears the entire environment map for the child process. 226 /// Sets the child process's working directory. 245 /// Configuration for the child process's standard input (stdin) handle. 268 /// Configuration for the child process's standard output (stdout) handle. 291 /// Configuration for the child process's standard error (stderr) handle. 314 /// Executes the command as a child process, returning a handle to it. 317 /// This will spawn the child process synchronously and return a Future 318 /// handle of child proces 333 let mut child = self.std.spawn()?; spawn() variables 412 let mut child = child?; status() variables 659 let mut child = Command::new("rev") ut_process_child_stdio_test() variables 713 let mut child = command.spawn().unwrap(); ut_process_kill_test() variables 757 let mut child = command.spawn().unwrap(); ut_process_debug_test() variables [all...] |
H A D | mod.rs | 23 mod child; modules 24 pub use child::{Child, ChildStderr, ChildStdin, ChildStdout};
|
/commonlibrary/rust/ylong_runtime/ylong_runtime/src/process/sys/unix/ |
H A D | mod.rs | 14 mod child; modules 15 pub(crate) use child::*;
|
H A D | zombie_manager.rs | 45 pub(crate) fn push(&self, child: StdChild) { 46 self.vec.lock().unwrap().push(child) 67 if let Ok(recv) = signal_return_watch(SignalKind::child()) { in release_zombile_when_no_receiver() 76 vec.retain_mut(|child| { in reap_vec() 77 match child.try_wait() { in reap_vec() 78 // `Ok(None)` means the child has not exited in reap_vec()
|
H A D | child.rs | 34 pub(crate) fn new(child: StdChild) -> io::Result<Self> { 36 std: Some(child), 37 signal: signal(SignalKind::child())?,
|
/commonlibrary/rust/ylong_runtime/ylong_runtime/examples/ |
H A D | ylong_runtime_signal.rs | 44 let mut stream = signal(SignalKind::child()).unwrap(); in run_multi_thread_signal()
|
/commonlibrary/rust/ylong_runtime/ylong_runtime/src/signal/unix/ |
H A D | mod.rs | 102 /// Received by the parent process when a child process terminates or stops. 111 /// let mut signal = signal(SignalKind::child()).unwrap(); 117 pub const fn child() -> SignalKind { 395 /// let mut signal = signal(SignalKind::child()).unwrap(); 488 let mut signal = signal(SignalKind::child()).unwrap(); in ut_signal_child()
|