Example usage for java.time MonthDay getLong

List of usage examples for java.time MonthDay getLong

Introduction

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

Prototype

@Override
public long getLong(TemporalField field) 

Source Link

Document

Gets the value of the specified field from this month-day as a long .

Usage

From source file:Main.java

public static void main(String[] args) {
    MonthDay m = MonthDay.now();
    long n = m.getLong(ChronoField.MONTH_OF_YEAR);
    System.out.println(n);/*from www  . j  a  va  2 s. c o  m*/

}