대 TypeReference이 클래스의 목록에 JSON 문자열을 deserialise하려면에 나열된 다른 방법 StackOverflow question잭슨 - Deserialising JSON 문자열 - TypeFactory.constructCollectionType
유형 1 (docs link) :
List<SomeClass> someClassList = mapper.readValue(jsonString, typeFactory.constructCollectionType(List.class, SomeClass.class));
2 형 (docs link) :
List<SomeClass> list = mapper.readValue(jsonString, new TypeReference<List<SomeClass>>() { });
위의 두 가지 유형 모두에서 작동하지만 이러한 구현 간의 차이점은 무엇입니까? ?