Entity2 JPA 엔티티의 객체지향적 설계 package jpashop.jpaorder.domain;import javax.persistence.*;import java.time.LocalDateTime;@Entity@Table(name = "ORDERS")public class Order { @Id @GeneratedValue @Column(name = "ORDER_ID") private Long id; @Column(name = "MEMBER_ID") private Long memberId; private LocalDateTime orderDate; @Enumerated(EnumType.STRING) private OrderStatus orderStatus;} ❓ 이런 방식의 설계는 객체지향스럽지 않다 RDB에 맞춘 설계이다 객.. JPA 2024. 12. 9. Entity 클래스와 DTO를 분리하는 이유 ❓ ChatGPT에 질문package jpabook.jpashop.controller;import jakarta.validation.Valid;import jpabook.jpashop.domain.Address;import jpabook.jpashop.domain.Member;import jpabook.jpashop.service.MemberService;import lombok.RequiredArgsConstructor;import lombok.extern.slf4j.Slf4j;import org.springframework.stereotype.Controller;import org.springframework.ui.Model;import org.springframework.validation.Bind.. spring 2024. 11. 30. 이전 1 다음