When we need to pass a type descriptor of a list into converter we should write
TypeDescriptor.collection(List.class, TypeDescriptor.valueOf(MyDto.class))
List
class is used a lot so it will helpful to have a method
TypeDescriptor.listOf(ListingDetailedDto.class)
which will return same result
Comment From: ishanarora04
This is available for grabs ?
Comment From: sbrannen
This is available for grabs ?
No. The team has not yet decided whether such convenience methods will be introduced.
Comment From: sbrannen
Team Decision: assigned to the General Backlog to allow this issue to gain wider community interest.
Comment From: eitan613
can i work on this then?
Comment From: sbrannen
can i work on this then?
@eitan613, no, not at this point. Please see https://github.com/spring-projects/spring-framework/issues/25393#issuecomment-664442119.
Comment From: eitan613
ok
Comment From: jhoeller
Since TypeDescriptor
has quite a lot of methods already and since it is mostly designed for getting derived from a method signature (which exposes potentially conversion-relevant annotations), we'll rather leave this with the essentially factory methods that we have there already. Custom convenience factory methods of that kind can easily be put into a utility class, after all.