list 썸네일형 리스트형 [JAVA] LIST 형 POST 처리 - JsonMappingException: Can not deserialize instance of java.util.ArrayList out of START_OBJECT token at [Source: java.io.PushbackInputStream@5db922ae; line: 1, column: 1] [JAVA] LIST 형 POST 처리 // CLASS // Student , String name, Integer age @PostMapping("/test") public void test(@Valid @RequestBody List data) { .... } 위와 같이 Post 를 받아주면 아래의 에러를 만날 수 있다 JsonMappingException: Can not deserialize instance of java.util.ArrayList out of START_OBJECT token at [Source: java.io.PushbackInputStream@5db922ae; line: 1, column: 1] Json 파싱을 할 때, 올바른 방법이 아니라는 이야기인데, 어떻게 Student .. 더보기 [JAVA] Colletions Sort - 리스트 정렬하기 자바에서 리스트를 정렬할때, 반복문을 써서 직접 리스트 정렬을 구현해도 되지만, 그 이상 혹은 다른 기능이 필요한 것이 아니라면, 제공해주는 기능을 굳이 만들어서 사용할 필요는 없다. 아래의 Collections 클래스에서 제공해주는 메소드들을 이용하여 개발을 해보자. 참조 URL : https://docs.oracle.com/javase/7/docs/api/java/util/Collections.html Collections (Java Platform SE 7 ) Rotates the elements in the specified list by the specified distance. After calling this method, the element at index i will be the ele.. 더보기 이전 1 다음