共用方式為


CharsetEncoder.ReplaceWith(Byte[]) 方法

定義

變更此編碼器的取代值。

[Android.Runtime.Register("replaceWith", "([B)Ljava/nio/charset/CharsetEncoder;", "")]
public Java.Nio.Charset.CharsetEncoder? ReplaceWith (byte[]? newReplacement);
[<Android.Runtime.Register("replaceWith", "([B)Ljava/nio/charset/CharsetEncoder;", "")>]
member this.ReplaceWith : byte[] -> Java.Nio.Charset.CharsetEncoder

參數

newReplacement
Byte[]

新的取代專案;不得為 null、必須具有非零長度、

                must not be longer than the value returned by the
                <code data-dev-comment-type="c">#maxBytesPerChar() maxBytesPerChar</code> method, and
                must be <code data-dev-comment-type="c">#isLegalReplacement legal</code>

傳回

此編碼器

屬性

例外狀況

如果指定的取代無法滿足上述需求,則為 。

備註

變更此編碼器的取代值。

這個方法會 #implReplaceWith implReplaceWith 叫用 方法,在檢查新的取代是否可接受之後,傳遞新的取代。

java.nio.charset.CharsetEncoder.replaceWith(byte[])Java 檔。

此頁面的部分是根據 Android 開放原始碼專案所建立和共用的工作進行修改,並根據 Creative Commons 2.5 屬性授權中所述的詞彙使用。

適用於