LocalDateTime.WithDayOfYear(Int32) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Returns a copy of this LocalDateTime with the day-of-year altered.
[Android.Runtime.Register("withDayOfYear", "(I)Ljava/time/LocalDateTime;", "", ApiSince=26)]
public Java.Time.LocalDateTime? WithDayOfYear(int dayOfYear);
[<Android.Runtime.Register("withDayOfYear", "(I)Ljava/time/LocalDateTime;", "", ApiSince=26)>]
member this.WithDayOfYear : int -> Java.Time.LocalDateTime
Parameters
- dayOfYear
- Int32
the day-of-year to set in the result, from 1 to 365-366
Returns
a LocalDateTime based on this date with the requested day, not null
- Attributes
Remarks
Returns a copy of this LocalDateTime with the day-of-year altered. If the resulting date-time is invalid, an exception is thrown. This instance is immutable and unaffected by this method call.
Java reference for java.time.LocalDateTime.withDayOfYear.