On Tue, 2011-05-17 at 14:42 -0700, Jeffrey Black wrote:
> Hey there Miguel. > > Have a look here: > > http://struts.apache.org/2.0.14/docs/type-conversion.html#TypeConversion-GenericsandErasure Thanks Jb. In my case a possible solution is to remove the generic reference to the list (ie, changing List<MyInterface> to List). This isn't usually necessary because Spring automatically injects the implementations in non-collection objects (ie, a private SomeInterface property is automatically injected with whichever bean we defined for SomeInterface in Spring), but doesn't work with collections (or I haven't figured out how to configure that in Spring). Given that an implementation-agnostic solution is preferable, the advice on the page "instantiate the target implementation first (eg. in a prepare method) or substitute in an implementation." is not, in my opinion, preferable. Miguel