openapi_github/models/
copilot_usage_metrics_breakdown_inner.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/// CopilotUsageMetricsBreakdownInner : Breakdown of Copilot usage by editor for this language
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct CopilotUsageMetricsBreakdownInner {
17    /// The language in which Copilot suggestions were shown to users in the specified editor.
18    #[serde(rename = "language", skip_serializing_if = "Option::is_none")]
19    pub language: Option<String>,
20    /// The editor in which Copilot suggestions were shown to users for the specified language.
21    #[serde(rename = "editor", skip_serializing_if = "Option::is_none")]
22    pub editor: Option<String>,
23    /// The number of Copilot suggestions shown to users in the editor specified during the day specified.
24    #[serde(rename = "suggestions_count", skip_serializing_if = "Option::is_none")]
25    pub suggestions_count: Option<i32>,
26    /// The number of Copilot suggestions accepted by users in the editor specified during the day specified.
27    #[serde(rename = "acceptances_count", skip_serializing_if = "Option::is_none")]
28    pub acceptances_count: Option<i32>,
29    /// The number of lines of code suggested by Copilot in the editor specified during the day specified.
30    #[serde(rename = "lines_suggested", skip_serializing_if = "Option::is_none")]
31    pub lines_suggested: Option<i32>,
32    /// The number of lines of code accepted by users in the editor specified during the day specified.
33    #[serde(rename = "lines_accepted", skip_serializing_if = "Option::is_none")]
34    pub lines_accepted: Option<i32>,
35    /// The number of users who were shown Copilot completion suggestions in the editor specified during the day specified.
36    #[serde(rename = "active_users", skip_serializing_if = "Option::is_none")]
37    pub active_users: Option<i32>,
38}
39
40impl CopilotUsageMetricsBreakdownInner {
41    /// Breakdown of Copilot usage by editor for this language
42    pub fn new() -> CopilotUsageMetricsBreakdownInner {
43        CopilotUsageMetricsBreakdownInner {
44            language: None,
45            editor: None,
46            suggestions_count: None,
47            acceptances_count: None,
48            lines_suggested: None,
49            lines_accepted: None,
50            active_users: None,
51        }
52    }
53}
54