1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
/*
* Hanzo Cloud API
*
* 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/.
*
* The version of the OpenAPI document: v1
*
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct SbomIngest {
#[serde(rename = "document", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
pub document: Option<Option<serde_json::Value>>,
/// Format names the document format; \"cyclonedx\" is the only one parsed.
#[serde(rename = "format", skip_serializing_if = "Option::is_none")]
pub format: Option<String>,
/// GitSha is the commit the image was built from.
#[serde(rename = "gitSha", skip_serializing_if = "Option::is_none")]
pub git_sha: Option<String>,
/// ImageDigest is the content-addressed digest (sha256:…) the components are keyed under. Required — it, not a tenant, is what an SBOM belongs to.
#[serde(rename = "imageDigest", skip_serializing_if = "Option::is_none")]
pub image_digest: Option<String>,
/// ImageRef is the human-readable image reference the digest was published as. A resolve matches on either this or the digest.
#[serde(rename = "imageRef", skip_serializing_if = "Option::is_none")]
pub image_ref: Option<String>,
/// SourceRepo is the repository the image was built from.
#[serde(rename = "sourceRepo", skip_serializing_if = "Option::is_none")]
pub source_repo: Option<String>,
}
impl SbomIngest {
pub fn new() -> SbomIngest {
SbomIngest {
document: None,
format: None,
git_sha: None,
image_digest: None,
image_ref: None,
source_repo: None,
}
}
}