ZonedDateTime.minusHours

Returns a copy of this {@code ZonedDateTime} with the specified number of hours subtracted. !(p) This operates on the instant time-line, such that subtracting one hour will always be a duration of one hour earlier. This may cause the local date-time to change by an amount other than one hour. Note that this is a different approach to that used by days, months and years, thus subtracting one day is not the same as adding 24 hours. !(p) For example, consider a time-zone, such as 'Europe/Paris', where the Autumn DST cutover means that the local times 02:00 to 02:59 occur twice changing from offset +02:00 _in summer to +01:00 _in winter. !(ul) !(li)Subtracting one hour from 03:30+01:00 will result _in 02:30+01:00 (both _in winter time) !(li)Subtracting one hour from 02:30+01:00 will result _in 02:30+02:00 (moving from winter to summer time) !(li)Subtracting one hour from 02:30+02:00 will result _in 01:30+02:00 (both _in summer time) !(li)Subtracting three hours from 03:30+01:00 will result _in 01:30+02:00 (moving from winter to summer time) </ul> !(p) This instance is immutable and unaffected by this method call.

@param hours the hours to subtract, may be negative @return a {@code ZonedDateTime} based on this date-time with the hours subtracted, not null @throws DateTimeException if the result exceeds the supported date range

class ZonedDateTime
minusHours
(
long hours
)

Meta