command : déplacement du trait
Command
This commit is contained in:
parent
f48a79df4e
commit
ea9eb49697
1 changed files with 4 additions and 4 deletions
|
@ -4,10 +4,6 @@ pub struct ExitCode {
|
||||||
exit_code: u8,
|
exit_code: u8,
|
||||||
}
|
}
|
||||||
|
|
||||||
pub trait Command {
|
|
||||||
fn spawn(&self) -> ExitCode;
|
|
||||||
}
|
|
||||||
|
|
||||||
impl ExitCode {
|
impl ExitCode {
|
||||||
pub fn new(exit_code: u8) -> Self {
|
pub fn new(exit_code: u8) -> Self {
|
||||||
Self { exit_code }
|
Self { exit_code }
|
||||||
|
@ -18,6 +14,10 @@ impl ExitCode {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub trait Command {
|
||||||
|
fn spawn(&self) -> ExitCode;
|
||||||
|
}
|
||||||
|
|
||||||
pub struct UnixProgram {
|
pub struct UnixProgram {
|
||||||
argv: Vec<String>,
|
argv: Vec<String>,
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue