Springboot 내장된 유용한 Utils
Assert
// 필수 매개 변수 object는 비어 있지 않아야 합니다(Not Null). 그렇지 않으면 예외를 던지고 내보내지지 않습니다.
// 매개 변수 message 매개 변수는 예외 정보를 사용자 지정하는 데 사용됩니다.
void notNull(Object object, String message)
// 필수 매개변수는 비어 있어야 하며(Null), 그렇지 않으면 이상을 던지고 '반출'되지 않습니다.
// notNull() 메서드 주장 규칙과 반대입니다
void isNull(Object object, String message)
// 필수 매개변수는 참(True)이어야 하며, 그렇지 않으면 이상을 던지고 '반출'되지 않습니다.
void isTrue(boolean expression, String message)
// 요구 파라미터(List/Set)는 비어 있지 않아야 하며(Not Empty), 그렇지 않으면 이상을 던지면 릴리스되지 않습니다.
void notEmpty(Collection collection, String message)
// 요구 파라미터(String)는 반드시 길이(즉, Not Empty)가 있어야 하며, 그렇지 않으면 이상을 던지면 방출되지 않습니다.
void hasLength(String text, String message)
// 요구 파라미터(String)에는 반드시 내용(즉, Not Blank)이 있어야 하며, 그렇지 않으면 이상을 던지면 반출되지 않습니다.
void hasText(String text, String message)
// 요구 파라미터는 지정된 유형의 실례입니다. 그렇지 않으면 이상을 던지면, 풀어주지 않습니다.
void isInstanceOf(Class type, Object obj, String message)
// 요구 파라미터 `subType`은 반드시 파라미터 superType의 서브클래스 또는 구현클래스여야 하며, 그렇지 않으면 이상을 던질 경우 릴리스되지 않습니다.
void isAssignable(Class superType, Class subType, String message)ObjectUtils
객체기본정보 가져오기 유틸
판단유틸
기타 유틸
StringUtils
String 판단유틸
String 제어 유틸
경로string 관련제어
CollectionUtils
컬랙션 판단
컬랙션 제어
file、resource、IO Stream
FileCopyUtils
input
output
ResourceUtils
자원 경로에서 파일 가져오기
Resource
StreamUtils
input
output
Reflection , AOP
ReflectionUtils
정보 가져오기 메서드
수행메서드
field 정보가져오기
설정 메서드
AopUtils
proxy 판단
proxy target class
AopContext
현재 proxy 객체 가져오기
끝!
PreviousSpringboot 3가지 CROS 설정NextSpring Security WebSecurityConfigurerAdapter 가 deprecated 된 이슈해결하기
Last updated