windmill-api 1.817.0

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * Windmill API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.817.0
 * Contact: contact@windmill.dev
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct AclSource {
    #[serde(rename = "role")]
    pub role: String,
    /// what role gave of the grant's privileges. A revoke is held back only by a source out of reach that gave some of what it takes back.
    #[serde(rename = "privileges")]
    pub privileges: Vec<String>,
    /// whether the data table's connection can take back what role gave. On an object that is the owner, when the connection acts for the owner, and otherwise the connection itself; for a default privilege, a creating role the connection acts for. What a source out of reach gave is not revocable from here; privileges only other sources gave still are.
    #[serde(rename = "reachable")]
    pub reachable: bool,
}

impl AclSource {
    pub fn new(role: String, privileges: Vec<String>, reachable: bool) -> AclSource {
        AclSource {
            role,
            privileges,
            reachable,
        }
    }
}