Notice
Recent Posts
Recent Comments
Link
| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | 30 |
Tags
- Item04
- @MockBean
- JPA
- restTemplate
- 플라이웨이트
- Web
- 디자인 패턴
- NotBlank
- 데이터베이스
- Spring Boot
- Effetive Java
- @ControllerAdvice
- FCM
- Service Locator
- Service Locator 패턴
- java
- deleteById
- Firebase
- @SpyBean
- NotEmpty
- 트랜잭션
- 이펙티브 자바
- Connection Pool
- Proxy Patter
- db
- SQL 삽입 공격
- Effective Java
- springboot
- multi module
- @Valid
Archives
- Today
- Total
목록NotBlank (1)
NoTimeForDawdling
API를 요청할 때 request body로 들어는 paramter에 대해 문자열 검증하는 방법으로 @NotNull, @NotEmpty, @NotBlank가 있습니다. 이 3가지 Annotation은 비슷해 보이지만 조금씩 다릅니다. 오늘은 이 3가지 Annotation의 차이점에 대해 확실하게 알고 넘어가 보겠습니다. 해당 포스트에서 사용할 DTO는 다음과 같습니다. @Getter @NoArgsConstructor public class ValidationDto { @NotNull private String notNull; @NotEmpty private String notEmpty; @NotBlank private String notBlank; } @NotNull @NotNull은 말 그대로 null..
SpringBoot
2021. 5. 14. 15:59