예제 #1
0
 public bool TryGetCustomProperty(string name, out CustomProperty property)
 {
     return(m_Properties.TryGetProperty(name, out property));
 }
예제 #2
0
 public static string GetValueAsString(this CustomProperty property)
 {
     return(property.m_Value);
 }
예제 #3
0
        public static bool TryGetProperty(this List <CustomProperty> list, string propertyName, out CustomProperty property)
        {
            if (list != null)
            {
                property = list.Find(p => String.Equals(p.m_Name, propertyName, StringComparison.OrdinalIgnoreCase));
                return(property != null);
            }

            property = null;
            return(false);
        }
예제 #4
0
 public static T GetValueAsEnum <T>(this CustomProperty property)
 {
     return(property.m_Value.ToEnum <T>());
 }
예제 #5
0
 public static bool GetValueAsBool(this CustomProperty property)
 {
     return(property.m_Value.ToBool());
 }
예제 #6
0
 public static float GetValueAsFloat(this CustomProperty property)
 {
     return(property.m_Value.ToFloat());
 }
예제 #7
0
 public static int GetValueAsInt(this CustomProperty property)
 {
     return(property.m_Value.ToInt());
 }
예제 #8
0
 public static Color GetValueAsColor(this CustomProperty property)
 {
     return(property.m_Value.ToColor());
 }