"Asia/Seoul" 같은 타임존 안에는 일광 절약 시간제에 대한 정보와 UTC+9:00와 같은 UTC로 부터 시간 차이인 오프셋 정보를 모두 포함하고 있다.
자바는 타임존을 ZoneId 클래스로 제공한다.
ZoneId.systemDefault() : 시스템이 사용하는 기본 ZoneId 를 반환한다.ZoneId.of() : 타임존을 직접 제공해서 ZoneId 를 반환한다.ZoneId 는 내부에 일광 절약 시간 관련 정보, UTC와의 오프셋 정보를 포함하고 있다.
ZonedDateTime 은 LocalDateTime 에 시간대 정보인 ZoneId 가 합쳐진 것이다.
now() : 현재 시간대의 현재 날짜와 시간을 가진 ZonedDateTime 객체를 생성한다.now(ZoneId zone) : 지정된 시간대의 현재 날짜와 시간을 가진ZonedDateTime 객체를 생성한다.of(LocalDate date, LocalTime time, ZoneId zone) : 주어진 날짜, 시간, 시간대로 ZonedDateTime 객체를 생성한다.of(LocalDateTime dateTime, ZoneId zone) : 주어진 LocalDateTime 과 시간대로ZonedDateTime 객체를 생성한다.of(int year, int month, int dayOfMonth, int hour, int minute, int second, int nanoOfSecond, ZoneId zone) : 주어진 날짜, 시간, 나노초, 시간대로 ZonedDateTimewithZoneSameInstant(ZoneId zone) : 다른 시간대로 시간을 변환하되, 절대 시간(UTC)을 유지한다.withZoneSameLocal(ZoneId zone) : 시간대를 변경하되, 로컬 날짜와 시간은 그대로 유지한다.withEarlierOffsetAtOverlap() : 겹치는 오프셋(여름 시간제 등)이 있을 때, 이전 오프셋을 사용한다.withLaterOffsetAtOverlap() : 겹치는 오프셋이 있을 때, 나중 오프셋을 사용한다.getOffset() : 현재 ZonedDateTime 의 오프셋을 반환한다.getZone() : 현재 ZonedDateTime 의 시간대를 반환한다.toLocalDateTime() : ZonedDateTime 을 LocalDateTimetoInstant() : ZonedDateTime 을 Instant으로 변환한다.toEpochSecond() : 1970-01-01T00:00:00Z부터 현재 ZonedDateTime 까지의 초 수를 반환한다.