fusionauth_rust_client/models/
identity_provider_linking_strategy.rs1use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
17pub enum IdentityProviderLinkingStrategy {
18 #[serde(rename = "CreatePendingLink")]
19 CreatePendingLink,
20 #[serde(rename = "Disabled")]
21 Disabled,
22 #[serde(rename = "LinkAnonymously")]
23 LinkAnonymously,
24 #[serde(rename = "LinkByEmail")]
25 LinkByEmail,
26 #[serde(rename = "LinkByEmailForExistingUser")]
27 LinkByEmailForExistingUser,
28 #[serde(rename = "LinkByUsername")]
29 LinkByUsername,
30 #[serde(rename = "LinkByUsernameForExistingUser")]
31 LinkByUsernameForExistingUser,
32 #[serde(rename = "Unsupported")]
33 Unsupported,
34
35}
36
37impl std::fmt::Display for IdentityProviderLinkingStrategy {
38 fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
39 match self {
40 Self::CreatePendingLink => write!(f, "CreatePendingLink"),
41 Self::Disabled => write!(f, "Disabled"),
42 Self::LinkAnonymously => write!(f, "LinkAnonymously"),
43 Self::LinkByEmail => write!(f, "LinkByEmail"),
44 Self::LinkByEmailForExistingUser => write!(f, "LinkByEmailForExistingUser"),
45 Self::LinkByUsername => write!(f, "LinkByUsername"),
46 Self::LinkByUsernameForExistingUser => write!(f, "LinkByUsernameForExistingUser"),
47 Self::Unsupported => write!(f, "Unsupported"),
48 }
49 }
50}
51
52impl Default for IdentityProviderLinkingStrategy {
53 fn default() -> IdentityProviderLinkingStrategy {
54 Self::CreatePendingLink
55 }
56}
57