hanzo_client/models/object_list.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 ObjectList {
16 /// Bucket is the bucket that was listed, friendly name.
17 #[serde(rename = "bucket", skip_serializing_if = "Option::is_none")]
18 pub bucket: Option<String>,
19 /// Objects are the entries at this level, keys RELATIVE to Prefix.
20 #[serde(rename = "objects", skip_serializing_if = "Option::is_none")]
21 pub objects: Option<Vec<models::ObjectItem>>,
22 /// Prefix is the sub-folder the listing was scoped to, cleaned. Empty for the bucket root.
23 #[serde(rename = "prefix", skip_serializing_if = "Option::is_none")]
24 pub prefix: Option<String>,
25 /// Total is how many entries came back. The listing is BOUNDED, so a bucket with more keys than the cap answers the cap and this says so — it is not a count of what the bucket holds.
26 #[serde(rename = "total", skip_serializing_if = "Option::is_none")]
27 pub total: Option<i32>,
28}
29
30impl ObjectList {
31 pub fn new() -> ObjectList {
32 ObjectList {
33 bucket: None,
34 objects: None,
35 prefix: None,
36 total: None,
37 }
38 }
39}
40