hanzo_client/models/code_result.rs
1/*
2 * Hanzo Cloud API
3 *
4 * The Hanzo Cloud API as a customer calls it: every operation under /v1/ except the operator's admin product, relay routes, legacy spellings and capabilities still reached by flag. Tagged by product: the first path segment after /v1/.
5 *
6 * The version of the OpenAPI document: v1
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct CodeResult {
16 /// Files are what this run CREATED OR CHANGED, decided by mtime against a marker taken before the program started — so it is the run's output, not a listing of the directory. Fetch each from GET /v1/exec/download/{session}/{id}.
17 #[serde(rename = "files", skip_serializing_if = "Option::is_none")]
18 pub files: Option<Vec<models::CodeFile>>,
19 /// SessionID is the sandbox this run used — the one that was passed in, or the fresh one that was leased. Pass it to the next run to keep the filesystem.
20 #[serde(rename = "session_id", skip_serializing_if = "Option::is_none")]
21 pub session_id: Option<String>,
22 /// Stderr is what the program wrote to standard error, INCLUDING a compiler's diagnostics and the trace of a program that exited non-zero. Its presence is not a failed call.
23 #[serde(rename = "stderr", skip_serializing_if = "Option::is_none")]
24 pub stderr: Option<String>,
25 /// Stdout is what the program wrote to standard output.
26 #[serde(rename = "stdout", skip_serializing_if = "Option::is_none")]
27 pub stdout: Option<String>,
28}
29
30impl CodeResult {
31 pub fn new() -> CodeResult {
32 CodeResult {
33 files: None,
34 session_id: None,
35 stderr: None,
36 stdout: None,
37 }
38 }
39}
40