Skip to main content

iceberg_rest_catalog/models/
commit_transaction_request.rs

1/*
2 * Apache Iceberg REST Catalog API
3 *
4 * Defines the specification for the first version of the REST Catalog API. Implementations should ideally support both Iceberg table specs v1 and v2, with priority given to v2.
5 *
6 * The version of the OpenAPI document: 0.0.1
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use iceberg_rust::catalog::commit::CommitTable;
13use serde::{Deserialize, Serialize};
14
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct CommitTransactionRequest {
17    #[serde(rename = "table-changes")]
18    pub table_changes: Vec<CommitTable>,
19}
20
21impl CommitTransactionRequest {
22    pub fn new(table_changes: Vec<CommitTable>) -> CommitTransactionRequest {
23        CommitTransactionRequest { table_changes }
24    }
25}