Development · Native API migration preview · Coverage validation in progress Published release →

API Browser

Method

WithCalendar

func WithCalendar(calendar: Calendar) -> DateTimeFormat

Declaring type: DateTimeFormat
Module: System.Globalization
Assembly: System.Runtime.dll
Source file: DateTimeFormat.rvn

Creates a formatter preserving this culture and selecting another calendar. The original is unchanged.

Parameters

Name Type Description
calendar Calendar Calendar field projection.

Return value

DateTimeFormat

A new immutable formatter.