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};

/// ClassroomAssignmentGrade : Grade for a student or groups GitHub Classroom assignment
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct ClassroomAssignmentGrade {
    /// Name of the assignment
    #[serde(rename = "assignment_name")]
    pub assignment_name: String,
    /// URL of the assignment
    #[serde(rename = "assignment_url")]
    pub assignment_url: String,
    /// URL of the starter code for the assignment
    #[serde(rename = "starter_code_url")]
    pub starter_code_url: String,
    /// GitHub username of the student
    #[serde(rename = "github_username")]
    pub github_username: String,
    /// Roster identifier of the student
    #[serde(rename = "roster_identifier")]
    pub roster_identifier: String,
    /// Name of the student's assignment repository
    #[serde(rename = "student_repository_name")]
    pub student_repository_name: String,
    /// URL of the student's assignment repository
    #[serde(rename = "student_repository_url")]
    pub student_repository_url: String,
    /// Timestamp of the student's assignment submission
    #[serde(rename = "submission_timestamp")]
    pub submission_timestamp: String,
    /// Number of points awarded to the student
    #[serde(rename = "points_awarded")]
    pub points_awarded: i32,
    /// Number of points available for the assignment
    #[serde(rename = "points_available")]
    pub points_available: i32,
    /// If a group assignment, name of the group the student is in
    #[serde(rename = "group_name", skip_serializing_if = "Option::is_none")]
    pub group_name: Option<String>,
}

impl ClassroomAssignmentGrade {
    /// Grade for a student or groups GitHub Classroom assignment
    pub fn new(assignment_name: String, assignment_url: String, starter_code_url: String, github_username: String, roster_identifier: String, student_repository_name: String, student_repository_url: String, submission_timestamp: String, points_awarded: i32, points_available: i32) -> ClassroomAssignmentGrade {
        ClassroomAssignmentGrade {
            assignment_name,
            assignment_url,
            starter_code_url,
            github_username,
            roster_identifier,
            student_repository_name,
            student_repository_url,
            submission_timestamp,
            points_awarded,
            points_available,
            group_name: None,
        }
    }
}