Example usage for java.time Instant get

List of usage examples for java.time Instant get

Introduction

In this page you can find the example usage for java.time Instant get.

Prototype

@Override 
public int get(TemporalField field) 

Source Link

Document

Gets the value of the specified field from this instant as an int .

Usage

From source file:Main.java

public static void main(String[] args) {
    Instant instant = Instant.parse("2014-12-03T10:15:30.00Z");
    System.out.println(instant.get(ChronoField.NANO_OF_SECOND));

}