Example usage for java.time ZoneOffset getLong

List of usage examples for java.time ZoneOffset getLong

Introduction

In this page you can find the example usage for java.time ZoneOffset getLong.

Prototype

@Override
public long getLong(TemporalField field) 

Source Link

Document

Gets the value of the specified field from this offset as a long .

Usage

From source file:Main.java

public static void main(String[] args) {
    ZoneOffset z = ZoneOffset.UTC;
    long t = z.getLong(ChronoField.OFFSET_SECONDS);
    System.out.println(t);//from w w  w  .  j a  v  a 2  s .  com
}