-
Throwable 클래스란?Java 2023. 6. 16. 00:01반응형
개요
Exception에 대해 알아보던 중 CheckedException, UnCheckedException으로만 구분 짓곤 했었는데, Throwable이란 클래스가 종종 보이게 되어 확실하게 정리하고자 합니다.
Throwable 클래스란?
https://codedragon.tistory.com/4447 Throwable은 Java 언어의 모든 오류(Error Class) 및 예외(Exception Class)의 최상위(root) 클래스입니다.
Error는 프로그램의 회복을 기대하지 않는 치명적인 예외입니다.
예를 들어 IOError, OutOfMemoryError 등이 있습니다.
Exception은 프로그램 회복을 기대하는 예외입니다.
IOException, RuntimeException 등이 있습니다.
참고자료
https://docs.oracle.com/javase/8/docs/api/java/lang/Throwable.html
Throwable (Java Platform SE 8 )
Provides programmatic access to the stack trace information printed by printStackTrace(). Returns an array of stack trace elements, each representing one stack frame. The zeroth element of the array (assuming the array's length is non-zero) represents the
docs.oracle.com
'Java' 카테고리의 다른 글
BigDecimal이란? (0) 2024.01.10 구독의 보너스 날짜 계산하기 (0) 2023.09.19 Instant vs LocalDateTime (0) 2023.05.27 [Java] 날짜,시간과 관련된 LocalDateTime의 역사 (0) 2022.08.27 [Java]ExecutorService란? (0) 2022.07.31