openapi-github 0.1.0

OpenAPI specs from https://github.com/github/rest-api-description with the 'x-octokit' extension required by the Octokit SDKs
Documentation
/*
 * GitHub's official OpenAPI spec + Octokit extension
 *
 * OpenAPI specs from https://github.com/github/rest-api-description with the 'x-octokit' extension required by the Octokit SDKs
 *
 * The version of the OpenAPI document: 16.6.0
 * 
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ProjectCard {
    #[serde(rename = "after_id", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub after_id: Option<Option<i32>>,
    /// Whether or not the card is archived
    #[serde(rename = "archived")]
    pub archived: bool,
    #[serde(rename = "column_id", deserialize_with = "Option::deserialize")]
    pub column_id: Option<i32>,
    #[serde(rename = "column_url")]
    pub column_url: String,
    #[serde(rename = "content_url", skip_serializing_if = "Option::is_none")]
    pub content_url: Option<String>,
    #[serde(rename = "created_at")]
    pub created_at: String,
    #[serde(rename = "creator", deserialize_with = "Option::deserialize")]
    pub creator: Option<Box<models::User1>>,
    /// The project card's ID
    #[serde(rename = "id")]
    pub id: i32,
    #[serde(rename = "node_id")]
    pub node_id: String,
    #[serde(rename = "note", deserialize_with = "Option::deserialize")]
    pub note: Option<String>,
    #[serde(rename = "project_url")]
    pub project_url: String,
    #[serde(rename = "updated_at")]
    pub updated_at: String,
    #[serde(rename = "url")]
    pub url: String,
}

impl ProjectCard {
    pub fn new(archived: bool, column_id: Option<i32>, column_url: String, created_at: String, creator: Option<models::User1>, id: i32, node_id: String, note: Option<String>, project_url: String, updated_at: String, url: String) -> ProjectCard {
        ProjectCard {
            after_id: None,
            archived,
            column_id,
            column_url,
            content_url: None,
            created_at,
            creator: creator.map(Box::new),
            id,
            node_id,
            note,
            project_url,
            updated_at,
            url,
        }
    }
}