Example usage for java.time OffsetDateTime minusNanos

List of usage examples for java.time OffsetDateTime minusNanos

Introduction

In this page you can find the example usage for java.time OffsetDateTime minusNanos.

Prototype

public OffsetDateTime minusNanos(long nanos) 

Source Link

Document

Returns a copy of this OffsetDateTime with the specified number of nanoseconds subtracted.

Usage

From source file:Main.java

public static void main(String[] args) {
    OffsetDateTime o = OffsetDateTime.now();
    OffsetDateTime d = o.minusNanos(1200);
    System.out.println(d);//  w ww  .  jav  a 2 s  .c o  m
}