[Java] ResponseEntity<> 사용 이유?
·
Server/Java
ResponseEntity? Java Spring의 문서를 보면 ResponseEntity를 다음과 같이 이야기한다. Extension of HttpEntity that adds an HttpStatusCode status code. Used in RestTemplate as well as in @Controller methods. HttpStatusCode 상태 코드를 추가한 HttpEntity의 확장이라고 설명하고 있다. HttpEntity public class HttpEntity { public static final HttpEntity EMPTY = new HttpEntity(); private final HttpHeaders headers; @Nullable private final T bod..