use serde::{Deserialize, Serialize}; /*
                                      * BigQuery API
                                      *
                                      * A data platform for customers to create, manage, share and query data.
                                      *
                                      * The version of the OpenAPI document: v2
                                      *
                                      * Generated by: https://openapi-generator.tech
                                      */

#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct TableDataInsertAllRequest {
    /// [Optional] Accept rows that contain values that do not match the schema. The unknown values are ignored. Default is false, which treats unknown values as errors.
    #[serde(
        rename = "ignoreUnknownValues",
        skip_serializing_if = "Option::is_none"
    )]
    pub ignore_unknown_values: Option<bool>,
    /// The resource type of the response.
    #[serde(rename = "kind", skip_serializing_if = "Option::is_none")]
    pub kind: Option<String>,
    /// The rows to insert.
    #[serde(rename = "rows", skip_serializing_if = "Option::is_none")]
    pub rows: Option<
        Vec<crate::google_rest_apis::bigquery_v2::models::TableDataInsertAllRequestRowsInner>,
    >,
    /// [Optional] Insert all valid rows of a request, even if invalid rows exist. The default value is false, which causes the entire request to fail if any invalid rows exist.
    #[serde(rename = "skipInvalidRows", skip_serializing_if = "Option::is_none")]
    pub skip_invalid_rows: Option<bool>,
    /// If specified, treats the destination table as a base template, and inserts the rows into an instance table named \"{destination}{templateSuffix}\". BigQuery will manage creation of the instance table, using the schema of the base template table. See https://cloud.google.com/bigquery/streaming-data-into-bigquery#template-tables for considerations when working with templates tables.
    #[serde(rename = "templateSuffix", skip_serializing_if = "Option::is_none")]
    pub template_suffix: Option<String>,
}

impl TableDataInsertAllRequest {
    pub fn new() -> TableDataInsertAllRequest {
        TableDataInsertAllRequest {
            ignore_unknown_values: None,
            kind: None,
            rows: None,
            skip_invalid_rows: None,
            template_suffix: None,
        }
    }
}
