java.time.ZoneOffset.isSupported() 方法示例


java.time.ZoneOffset.isSupported() 方法示例

package com.codingdict;

import java.time.ZoneOffset;
import java.time.temporal.ChronoField;

public class ZoneOffsetDemo {
   public static void main(String[] args) {

      ZoneOffset zoneOffset = ZoneOffset.of("Z");
      boolean result = zoneOffset.isSupported(ChronoField.OFFSET_SECONDS);
      System.out.println(result);  
   }
}