#![allow(non_camel_case_types)]
#![allow(non_upper_case_globals)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
#[repr(i32)]
pub enum ESessionPersistence {
    Invalid = -1,
    Ephemeral = 0,
    Persistent = 1,
}

impl ESessionPersistence {
    pub fn from_i32(val: i32) -> Option<Self> {
        match val {
            x if x == Self::Invalid as i32 => Some(Self::Invalid),
            x if x == Self::Ephemeral as i32 => Some(Self::Ephemeral),
            x if x == Self::Persistent as i32 => Some(Self::Persistent),
            _ => None,
        }
    }
}
