pub struct ActResult {
pub success: bool,
pub action_taken: String,
pub action_type: Option<String>,
pub screenshot: Option<String>,
pub error: Option<String>,
pub usage: AutomationUsage,
}Expand description
Result of a single action execution via act().
Fields§
§success: boolWhether the action was executed successfully.
action_taken: StringDescription of the action that was taken.
action_type: Option<String>The specific action executed (if any).
screenshot: Option<String>Base64-encoded screenshot after the action.
error: Option<String>Error message if the action failed.
usage: AutomationUsageToken usage for this action.
Implementations§
Source§impl ActResult
impl ActResult
Sourcepub fn with_action_type(self, action_type: impl Into<String>) -> Self
pub fn with_action_type(self, action_type: impl Into<String>) -> Self
Set the action type.
Sourcepub fn with_screenshot(self, screenshot: impl Into<String>) -> Self
pub fn with_screenshot(self, screenshot: impl Into<String>) -> Self
Set the screenshot.
Sourcepub fn with_usage(self, usage: AutomationUsage) -> Self
pub fn with_usage(self, usage: AutomationUsage) -> Self
Set usage stats.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ActResult
impl<'de> Deserialize<'de> for ActResult
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ActResult
impl RefUnwindSafe for ActResult
impl Send for ActResult
impl Sync for ActResult
impl Unpin for ActResult
impl UnwindSafe for ActResult
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