Java Date Time Java Java API
java.time.OffsetTime
public int getMinute()
Returns the minute-of-hour field from this OffsetTime instance.
package com.logicbig.example.offsettime;import java.time.OffsetTime;import java.time.ZoneOffset;public class GetMinuteExample { public static void main(String... args) { OffsetTime d = OffsetTime.of(17, 40, 33, 20000, ZoneOffset.ofHours(-6)); System.out.println(d); int minute = d.getMinute(); System.out.println(minute); }}
17:40:33.000020-06:0040