openapi_github/models/
repository_rule_params_status_check_configuration.rs

1/*
2 * GitHub's official OpenAPI spec + Octokit extension
3 *
4 * OpenAPI specs from https://github.com/github/rest-api-description with the 'x-octokit' extension required by the Octokit SDKs
5 *
6 * The version of the OpenAPI document: 16.6.0
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// RepositoryRuleParamsStatusCheckConfiguration : Required status check
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct RepositoryRuleParamsStatusCheckConfiguration {
17    /// The status check context name that must be present on the commit.
18    #[serde(rename = "context")]
19    pub context: String,
20    /// The optional integration ID that this status check must originate from.
21    #[serde(rename = "integration_id", skip_serializing_if = "Option::is_none")]
22    pub integration_id: Option<i32>,
23}
24
25impl RepositoryRuleParamsStatusCheckConfiguration {
26    /// Required status check
27    pub fn new(context: String) -> RepositoryRuleParamsStatusCheckConfiguration {
28        RepositoryRuleParamsStatusCheckConfiguration {
29            context,
30            integration_id: None,
31        }
32    }
33}
34