//core/io.islandtime/YearMonth/copy
copy¶
common
fun copy(year: Int = this.year, month: Month = this.month): YearMonth
Returns a copy of this year-month with the values of any individual components replaced by the new values specified.
Throws¶
io.islandtime.DateTimeException | if the year is invalid |
common
fun copy(year: Int = this.year, monthNumber: Int): YearMonth
Returns a copy of this year-month with the values of any individual components replaced by the new values specified.
Throws¶
io.islandtime.DateTimeException | if the year or month is invalid |