#![allow(non_camel_case_types)]
#![allow(non_upper_case_globals)]
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
#[repr(i32)]
pub enum EContentDescriptorID {
    NudityOrSexualContent = 1,
    FrequentViolenceOrGore = 2,
    AdultOnlySexualContent = 3,
    GratuitousSexualContent = 4,
    AnyMatureContent = 5,
    MAX = 6,
}

impl EContentDescriptorID {
    pub fn from_i32(val: i32) -> Option<Self> {
        match val {
            x if x == Self::NudityOrSexualContent as i32 => Some(Self::NudityOrSexualContent),
            x if x == Self::FrequentViolenceOrGore as i32 => Some(Self::FrequentViolenceOrGore),
            x if x == Self::AdultOnlySexualContent as i32 => Some(Self::AdultOnlySexualContent),
            x if x == Self::GratuitousSexualContent as i32 => Some(Self::GratuitousSexualContent),
            x if x == Self::AnyMatureContent as i32 => Some(Self::AnyMatureContent),
            x if x == Self::MAX as i32 => Some(Self::MAX),
            _ => None,
        }
    }
}
