/*
 * Hotdata API
 *
 * Powerful data platform API for datasets, queries, and analytics.
 *
 * The version of the OpenAPI document: 1.0.0
 * Contact: developers@hotdata.dev
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

/// SavedQuerySummary : Saved query summary for listing
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct SavedQuerySummary {
    #[serde(rename = "created_at")]
    pub created_at: String,
    #[serde(rename = "description")]
    pub description: String,
    #[serde(rename = "id")]
    pub id: String,
    #[serde(rename = "latest_version")]
    pub latest_version: i32,
    #[serde(rename = "name")]
    pub name: String,
    #[serde(rename = "tags")]
    pub tags: Vec<String>,
    #[serde(rename = "updated_at")]
    pub updated_at: String,
}

impl SavedQuerySummary {
    /// Saved query summary for listing
    pub fn new(
        created_at: String,
        description: String,
        id: String,
        latest_version: i32,
        name: String,
        tags: Vec<String>,
        updated_at: String,
    ) -> SavedQuerySummary {
        SavedQuerySummary {
            created_at,
            description,
            id,
            latest_version,
            name,
            tags,
            updated_at,
        }
    }
}
