public PostfixExpressionKind createPostfixExpressionKindFromString(EDataType eDataType, String initialValue)
        {
            PostfixExpressionKind result = PostfixExpressionKind.get(initialValue);

            if (result == null)
            {
                throw new ArgumentException(
                          "The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.name + "'");
            }
            return(result);
        }
Example #2
0
 public static PostfixExpressionKind getByName(string name)
 {
     for (int i = 0; i < VALUES_ARRAY.Length; ++i)
     {
         PostfixExpressionKind result = VALUES_ARRAY[i];
         if (result.getName() == name)
         {
             return(result);
         }
     }
     return(null);
 }
Example #3
0
 public static PostfixExpressionKind get(string literal)
 {
     for (int i = 0; i < VALUES_ARRAY.Length; ++i)
     {
         PostfixExpressionKind result = VALUES_ARRAY[i];
         if (result.ToString() == literal)
         {
             return(result);
         }
     }
     return(null);
 }