[ Oracle docs ] java.time
사용케이스
- epoch seconds using the
java.time
package, introduced in Java 8 and later.java.time.Instant
클래스는 epoch(January 1, 1970, 00:00:00 UTC) 이래로의 시간 중 지금의 포인트를 몇초나 지났는지로 나타내는 개념
- Instant에서 epochSeconds로 바꾸기 →
Instant.now().getEpochSecond()
LocalDateTime
ZonedDateTime
Instant