LocalDateTime.Of Method

Definition

Overloads

Name Description
Of(Int32, Month, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute and second, setting the nanosecond to zero.

Of(LocalDate, LocalTime)

Obtains an instance of LocalDateTime from a date and time.

Of(Int32, Month, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour and minute, setting the second and nanosecond to zero.

Of(Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour and minute, setting the second and nanosecond to zero.

Of(Int32, Int32, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute, second and nanosecond.

Of(Int32, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute and second, setting the nanosecond to zero.

Of(Int32, Month, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute, second and nanosecond.

Of(Int32, Month, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute and second, setting the nanosecond to zero.

[Android.Runtime.Register("of", "(ILjava/time/Month;IIII)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, Java.Time.Month? month, int dayOfMonth, int hour, int minute, int second);
[<Android.Runtime.Register("of", "(ILjava/time/Month;IIII)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * Java.Time.Month * int * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Month

the month-of-year to represent, not null

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

second
Int32

the second-of-minute to represent, from 0 to 59

Returns

the local date-time, not null

Attributes

Remarks

To be added.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(LocalDate, LocalTime)

Obtains an instance of LocalDateTime from a date and time.

[Android.Runtime.Register("of", "(Ljava/time/LocalDate;Ljava/time/LocalTime;)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(Java.Time.LocalDate? date, Java.Time.LocalTime? time);
[<Android.Runtime.Register("of", "(Ljava/time/LocalDate;Ljava/time/LocalTime;)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : Java.Time.LocalDate * Java.Time.LocalTime -> Java.Time.LocalDateTime

Parameters

date
LocalDate

the local date, not null

time
LocalTime

the local time, not null

Returns

the local date-time, not null

Attributes

Remarks

To be added.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(Int32, Month, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour and minute, setting the second and nanosecond to zero.

[Android.Runtime.Register("of", "(ILjava/time/Month;III)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, Java.Time.Month? month, int dayOfMonth, int hour, int minute);
[<Android.Runtime.Register("of", "(ILjava/time/Month;III)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * Java.Time.Month * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Month

the month-of-year to represent, not null

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

Returns

the local date-time, not null

Attributes

Remarks

Obtains an instance of LocalDateTime from year, month, day, hour and minute, setting the second and nanosecond to zero. This returns a LocalDateTime with the specified year, month, day-of-month, hour and minute. The day must be valid for the year and month, otherwise an exception will be thrown. The second and nanosecond fields will be set to zero.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour and minute, setting the second and nanosecond to zero.

[Android.Runtime.Register("of", "(IIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, int month, int dayOfMonth, int hour, int minute);
[<Android.Runtime.Register("of", "(IIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * int * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Int32

the month-of-year to represent, from 1 (January) to 12 (December)

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

Returns

the local date-time, not null

Attributes

Remarks

To be added.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(Int32, Int32, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute, second and nanosecond.

[Android.Runtime.Register("of", "(IIIIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, int month, int dayOfMonth, int hour, int minute, int second, int nanoOfSecond);
[<Android.Runtime.Register("of", "(IIIIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * int * int * int * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Int32

the month-of-year to represent, from 1 (January) to 12 (December)

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

second
Int32

the second-of-minute to represent, from 0 to 59

nanoOfSecond
Int32

the nano-of-second to represent, from 0 to 999,999,999

Returns

the local date-time, not null

Attributes

Remarks

Obtains an instance of LocalDateTime from year, month, day, hour, minute, second and nanosecond. This returns a LocalDateTime with the specified year, month, day-of-month, hour, minute, second and nanosecond. The day must be valid for the year and month, otherwise an exception will be thrown.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(Int32, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute and second, setting the nanosecond to zero.

[Android.Runtime.Register("of", "(IIIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, int month, int dayOfMonth, int hour, int minute, int second);
[<Android.Runtime.Register("of", "(IIIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * int * int * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Int32

the month-of-year to represent, from 1 (January) to 12 (December)

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

second
Int32

the second-of-minute to represent, from 0 to 59

Returns

the local date-time, not null

Attributes

Remarks

To be added.

Java reference for java.time.LocalDateTime.of.

Applies to

Of(Int32, Month, Int32, Int32, Int32, Int32, Int32)

Obtains an instance of LocalDateTime from year, month, day, hour, minute, second and nanosecond.

[Android.Runtime.Register("of", "(ILjava/time/Month;IIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public static Java.Time.LocalDateTime? Of(int year, Java.Time.Month? month, int dayOfMonth, int hour, int minute, int second, int nanoOfSecond);
[<Android.Runtime.Register("of", "(ILjava/time/Month;IIIII)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
static member Of : int * Java.Time.Month * int * int * int * int * int -> Java.Time.LocalDateTime

Parameters

year
Int32

the year to represent, from MIN_YEAR to MAX_YEAR

month
Month

the month-of-year to represent, not null

dayOfMonth
Int32

the day-of-month to represent, from 1 to 31

hour
Int32

the hour-of-day to represent, from 0 to 23

minute
Int32

the minute-of-hour to represent, from 0 to 59

second
Int32

the second-of-minute to represent, from 0 to 59

nanoOfSecond
Int32

the nano-of-second to represent, from 0 to 999,999,999

Returns

the local date-time, not null

Attributes

Remarks

To be added.

Java reference for java.time.LocalDateTime.of.

Applies to