pub struct HookRunResult {
pub denied: bool,
pub failed: bool,
pub messages: Vec<String>,
}Expand description
Result of running a hook command.
Fields§
§denied: boolWhether the hook denied the request (exit code 2).
failed: boolWhether the hook itself failed (non-zero, non-2 exit code or timeout).
messages: Vec<String>Messages captured from the hook’s stdout.
Implementations§
Source§impl HookRunResult
impl HookRunResult
Sourcepub const fn allow_with(messages: Vec<String>) -> Self
pub const fn allow_with(messages: Vec<String>) -> Self
Hook allowed the request with informational messages.
Trait Implementations§
Source§impl Clone for HookRunResult
impl Clone for HookRunResult
Source§fn clone(&self) -> HookRunResult
fn clone(&self) -> HookRunResult
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 HookRunResult
impl Debug for HookRunResult
impl Eq for HookRunResult
Source§impl PartialEq for HookRunResult
impl PartialEq for HookRunResult
Source§fn eq(&self, other: &HookRunResult) -> bool
fn eq(&self, other: &HookRunResult) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for HookRunResult
Auto Trait Implementations§
impl Freeze for HookRunResult
impl RefUnwindSafe for HookRunResult
impl Send for HookRunResult
impl Sync for HookRunResult
impl Unpin for HookRunResult
impl UnsafeUnpin for HookRunResult
impl UnwindSafe for HookRunResult
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.