Example usage for java.time LocalTime minusHours

List of usage examples for java.time LocalTime minusHours

Introduction

In this page you can find the example usage for java.time LocalTime minusHours.

Prototype

public LocalTime minusHours(long hoursToSubtract) 

Source Link

Document

Returns a copy of this LocalTime with the specified number of hours subtracted.

Usage

From source file:Main.java

public static void main(String[] args) {
    LocalTime l = LocalTime.now();
    LocalTime s = l.minusHours(1);
    System.out.println(s);//from  www  .j av a  2 s  . c  om
}