|
From: Steven D. <ste...@gm...> - 2005-09-03 00:15:21
|
Hi, After reading Keith's blog entry on dynamic method invocation on actions in SWF and passing arguments from the flow and request scope I've been hitting a number of problem with the implementations in spring binding. The first problem has to do with the conversion package. DefaultConversionService does not take into account assignable classes. If you specify for example java.util.Map as target class and java.util.HashMap is the source class conversion will fail with a message saying no conversion is found from HashMap to Map. The obvious solution to me seems to test if the target class is assignable to the source class and do no conversion in that case. Specifying no target type in the Argument class can circumvent this problem. A second problem however arises when searching for a method to execute. If your method for example is "execute(Map)" and the argument value is java.util.HashMap the method lookup will fail since the method signature and argument types to not match (Map !=3D HashMap). The obvious solution to me seems to search for methods whose arguments are assignable by the argument types. This again implicates a significant change in key spring binding classes that probably should be discussed. Steven |