openapi_github/models/
migrations_update_import_request.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#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct MigrationsUpdateImportRequest {
16    /// The username to provide to the originating repository.
17    #[serde(rename = "vcs_username", skip_serializing_if = "Option::is_none")]
18    pub vcs_username: Option<String>,
19    /// The password to provide to the originating repository.
20    #[serde(rename = "vcs_password", skip_serializing_if = "Option::is_none")]
21    pub vcs_password: Option<String>,
22    /// The type of version control system you are migrating from.
23    #[serde(rename = "vcs", skip_serializing_if = "Option::is_none")]
24    pub vcs: Option<Vcs>,
25    /// For a tfvc import, the name of the project that is being imported.
26    #[serde(rename = "tfvc_project", skip_serializing_if = "Option::is_none")]
27    pub tfvc_project: Option<String>,
28}
29
30impl MigrationsUpdateImportRequest {
31    pub fn new() -> MigrationsUpdateImportRequest {
32        MigrationsUpdateImportRequest {
33            vcs_username: None,
34            vcs_password: None,
35            vcs: None,
36            tfvc_project: None,
37        }
38    }
39}
40/// The type of version control system you are migrating from.
41#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
42pub enum Vcs {
43    #[serde(rename = "subversion")]
44    Subversion,
45    #[serde(rename = "tfvc")]
46    Tfvc,
47    #[serde(rename = "git")]
48    Git,
49    #[serde(rename = "mercurial")]
50    Mercurial,
51}
52
53impl Default for Vcs {
54    fn default() -> Vcs {
55        Self::Subversion
56    }
57}
58