public SupportEnumTwoEvent( string id, SupportEnumTwo value) { Id = id; Value = value; }
public static bool CheckEventBeanPropInt(this SupportEnumTwo @enum, EventBean @event, String propertyName) { var value = @event.Get(propertyName); if (value == null && (!value.IsInt())) { return(false); } return(GetAssociatedValue(@enum) == (int?)value); }
public static bool CheckEventBeanPropInt( this SupportEnumTwo enumValue, EventBean @event, string propertyName) { var value = @event.Get(propertyName); if (value == null && !(value is int?)) { return false; } return GetAssociatedValue(enumValue) == (int?) value; }
public static string[] GetMystrings(this SupportEnumTwo value) { switch (value) { case SupportEnumTwo.ENUM_VALUE_1: return new[] {"1", "0", "0"}; case SupportEnumTwo.ENUM_VALUE_2: return new[] {"2", "0", "0"}; case SupportEnumTwo.ENUM_VALUE_3: return new[] {"3", "0", "0"}; default: throw new ArgumentException(nameof(value)); } }
public static int GetAssociatedValue(this SupportEnumTwo value) { switch (value) { case SupportEnumTwo.ENUM_VALUE_1: return 100; case SupportEnumTwo.ENUM_VALUE_2: return 200; case SupportEnumTwo.ENUM_VALUE_3: return 300; default: throw new ArgumentException(nameof(value)); } }
public static int GetAssociatedValue(this SupportEnumTwo @enum) { switch (@enum) { case SupportEnumTwo.ENUM_VALUE_1: return(100); case SupportEnumTwo.ENUM_VALUE_2: return(200); case SupportEnumTwo.ENUM_VALUE_3: return(300); } throw new ArgumentException(); }
public static string[] GetMystrings(this SupportEnumTwo @enum) { switch (@enum) { case SupportEnumTwo.ENUM_VALUE_1: return(new String[] { "1", "0", "0" }); case SupportEnumTwo.ENUM_VALUE_2: return(new String[] { "2", "0", "0" }); case SupportEnumTwo.ENUM_VALUE_3: return(new String[] { "3", "0", "0" }); } throw new ArgumentException(); }
public static Nested GetNested(this SupportEnumTwo enumValue) { return new Nested(GetAssociatedValue(enumValue)); }
public static bool CheckAssociatedValue( this SupportEnumTwo enumValue, int value) { return GetAssociatedValue(enumValue) == value; }
public static Nested GetNested(this SupportEnumTwo @enum) { return(new Nested(GetAssociatedValue(@enum))); }
public static bool CheckAssociatedValue(this SupportEnumTwo @enum, int value) { return(GetAssociatedValue(@enum) == value); }