-
Notifications
You must be signed in to change notification settings - Fork 0
/
o_auth2_scope.rs
44 lines (40 loc) · 1002 Bytes
/
o_auth2_scope.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/*
* traQ v3
*
* traQ v3 API
*
* The version of the OpenAPI document: 3.0
*
* Generated by: https://openapi-generator.tech
*/
/// OAuth2Scope : OAuth2スコープ
/// OAuth2スコープ
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum OAuth2Scope {
#[serde(rename = "openid")]
Openid,
#[serde(rename = "profile")]
Profile,
#[serde(rename = "read")]
Read,
#[serde(rename = "write")]
Write,
#[serde(rename = "manage_bot")]
ManageBot,
}
impl ToString for OAuth2Scope {
fn to_string(&self) -> String {
match self {
Self::Openid => String::from("openid"),
Self::Profile => String::from("profile"),
Self::Read => String::from("read"),
Self::Write => String::from("write"),
Self::ManageBot => String::from("manage_bot"),
}
}
}
impl Default for OAuth2Scope {
fn default() -> OAuth2Scope {
Self::Openid
}
}