Example usage for java.time LocalTime isSupported

List of usage examples for java.time LocalTime isSupported

Introduction

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

Prototype

@Override 
public boolean isSupported(TemporalUnit unit) 

Source Link

Document

Checks if the specified unit is supported.

Usage

From source file:Main.java

public static void main(String[] args) {
    LocalTime l = LocalTime.now();

    System.out.println(l.isSupported(ChronoField.MICRO_OF_SECOND));
}

From source file:Main.java

public static void main(String[] args) {
    LocalTime l = LocalTime.now();

    System.out.println(l.isSupported(ChronoUnit.MINUTES));
}