#![allow(non_camel_case_types)]
#![allow(non_upper_case_globals)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
#[repr(i32)]
pub enum EBroadcastPermission {
    Disabled = 0,
    FriendsApprove = 1,
    FriendsAllowed = 2,
    Public = 3,
    Subscribers = 4,
}

impl EBroadcastPermission {
    pub fn from_i32(val: i32) -> Option<Self> {
        match val {
            x if x == Self::Disabled as i32 => Some(Self::Disabled),
            x if x == Self::FriendsApprove as i32 => Some(Self::FriendsApprove),
            x if x == Self::FriendsAllowed as i32 => Some(Self::FriendsAllowed),
            x if x == Self::Public as i32 => Some(Self::Public),
            x if x == Self::Subscribers as i32 => Some(Self::Subscribers),
            _ => None,
        }
    }
}
