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 CodeScanningSarifsStatus {
    /// `pending` files have not yet been processed, while `complete` means results from the SARIF have been stored. `failed` files have either not been processed at all, or could only be partially processed.
    #[serde(rename = "processing_status", skip_serializing_if = "Option::is_none")]
    pub processing_status: Option<ProcessingStatus>,
    /// The REST API URL for getting the analyses associated with the upload.
    #[serde(rename = "analyses_url", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub analyses_url: Option<Option<String>>,
    /// Any errors that ocurred during processing of the delivery.
    #[serde(rename = "errors", default, with = "::serde_with::rust::double_option", skip_serializing_if = "Option::is_none")]
    pub errors: Option<Option<Vec<String>>>,
}

impl CodeScanningSarifsStatus {
    pub fn new() -> CodeScanningSarifsStatus {
        CodeScanningSarifsStatus {
            processing_status: None,
            analyses_url: None,
            errors: None,
        }
    }
}
/// `pending` files have not yet been processed, while `complete` means results from the SARIF have been stored. `failed` files have either not been processed at all, or could only be partially processed.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum ProcessingStatus {
    #[serde(rename = "pending")]
    Pending,
    #[serde(rename = "complete")]
    Complete,
    #[serde(rename = "failed")]
    Failed,
}

impl Default for ProcessingStatus {
    fn default() -> ProcessingStatus {
        Self::Pending
    }
}