DateTimeFormatter.WithLocale(Locale) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
回傳一份帶有新位置的格式化器副本。
[Android.Runtime.Register("withLocale", "(Ljava/util/Locale;)Ljava/time/format/DateTimeFormatter;", "", ApiSince=26)]
public Java.Time.Format.DateTimeFormatter? WithLocale(Java.Util.Locale? locale);
[<Android.Runtime.Register("withLocale", "(Ljava/util/Locale;)Ljava/time/format/DateTimeFormatter;", "", ApiSince=26)>]
member this.WithLocale : Java.Util.Locale -> Java.Time.Format.DateTimeFormatter
參數
- locale
- Locale
新地點,而非 null
傳回
基於此格式化器,包含所要求的區域,而非 null 格式化器
- 屬性
備註
回傳一份帶有新位置的格式化器副本。
此工具用於查找格式化器中需要特定本地化的部分,例如文字或本地化圖案。
該位置會依傳入方式儲存,無需進一步處理。
此實例是不可變且不受此方法呼叫影響的。
Java 文件 java.time.format.DateTimeFormatter.withLocale(java.util.Locale)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。