Period.OfMonths(Int32) Method

Definition

Obtains a Period representing a number of months.

[Android.Runtime.Register("ofMonths", "(I)Ljava/time/Period;", "", ApiSince=26)]
public static Java.Time.Period? OfMonths(int months);
[<Android.Runtime.Register("ofMonths", "(I)Ljava/time/Period;", "", ApiSince=26)>]
static member OfMonths : int -> Java.Time.Period

Parameters

months
Int32

the number of months, positive or negative

Returns

the period of months, not null

Attributes

Remarks

Obtains a Period representing a number of months. The resulting period will have the specified months. The years and days units will be zero.

Java reference for java.time.Period.ofMonths.

Applies to