pub struct ExecuteCommandResponse {
pub success: bool,
pub exit_code: Option<i32>,
pub output: String,
pub raw_output: Option<String>,
pub duration_ms: u64,
pub timed_out: bool,
pub total_bytes: u64,
pub truncated: bool,
}Expand description
Response for command execution.
Fields§
§success: boolWhether execution was successful.
exit_code: Option<i32>Exit code (if process completed).
output: StringCleaned output text.
raw_output: Option<String>Raw output (base64 encoded if binary content detected).
duration_ms: u64Execution duration in milliseconds.
timed_out: boolWhether the command timed out.
total_bytes: u64Bytes the command produced, including any this response does not carry.
Equal to the size of output unless truncated is set.
truncated: boolWhether output is a prefix of what the command produced.
Always present, including when false: a caller must not have to infer completeness from the absence of a field.
Implementations§
Source§impl ExecuteCommandResponse
impl ExecuteCommandResponse
pub fn from_result(result: &ExecutionResult) -> Self
pub fn with_raw_output(self, include: bool, raw: &[u8]) -> Self
Trait Implementations§
Source§impl Clone for ExecuteCommandResponse
impl Clone for ExecuteCommandResponse
Source§fn clone(&self) -> ExecuteCommandResponse
fn clone(&self) -> ExecuteCommandResponse
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ExecuteCommandResponse
impl Debug for ExecuteCommandResponse
Auto Trait Implementations§
impl Freeze for ExecuteCommandResponse
impl RefUnwindSafe for ExecuteCommandResponse
impl Send for ExecuteCommandResponse
impl Sync for ExecuteCommandResponse
impl Unpin for ExecuteCommandResponse
impl UnsafeUnpin for ExecuteCommandResponse
impl UnwindSafe for ExecuteCommandResponse
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more