Enum auto conversion issue
wysohn opened this issue ยท 0 comments
Likely the methods returned by Java.lang.Class.getMethods()
is in random order, so the parameter checking should be in a proper order
- Check for String parameter. If both String and Enum parameters exist, just use the String one. This is an ambiguous case, but if the method is overloaded and String and Enum are used in the same place, the original author of the method probably intended the user to use the method instead of converting the String to Enum
- Check for an Enum parameter. If the input is String and the paramter is Enum, do the conversion.
- Signature mismatch. An Exception will be thrown