harbor_api/models/
audit_log.rs

1/*
2 * Harbor API
3 *
4 * These APIs provide services for manipulating Harbor project.
5 *
6 * The version of the OpenAPI document: 2.0
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 AuditLog {
16    /// The ID of the audit log entry.
17    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
18    pub id: Option<i32>,
19    /// Username of the user in this log entry.
20    #[serde(rename = "username", skip_serializing_if = "Option::is_none")]
21    pub username: Option<String>,
22    /// Name of the repository in this log entry.
23    #[serde(rename = "resource", skip_serializing_if = "Option::is_none")]
24    pub resource: Option<String>,
25    /// Tag of the repository in this log entry.
26    #[serde(rename = "resource_type", skip_serializing_if = "Option::is_none")]
27    pub resource_type: Option<String>,
28    /// The operation against the repository in this log entry.
29    #[serde(rename = "operation", skip_serializing_if = "Option::is_none")]
30    pub operation: Option<String>,
31    /// The time when this operation is triggered.
32    #[serde(rename = "op_time", skip_serializing_if = "Option::is_none")]
33    pub op_time: Option<String>,
34}
35
36impl AuditLog {
37    pub fn new() -> AuditLog {
38        AuditLog {
39            id: None,
40            username: None,
41            resource: None,
42            resource_type: None,
43            operation: None,
44            op_time: None,
45        }
46    }
47}
48