TextUtils.Substring 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
多載
| 名稱 | Description |
|---|---|
| Substring(ICharSequence, Int32, Int32) |
建立一個新的 String 物件,包含來源字串中給定的字元範圍。 |
| Substring(String, Int32, Int32) |
建立一個新的 String 物件,包含來源字串中給定的字元範圍。 |
Substring(ICharSequence, Int32, Int32)
建立一個新的 String 物件,包含來源字串中給定的字元範圍。
[Android.Runtime.Register("substring", "(Ljava/lang/CharSequence;II)Ljava/lang/String;", "")]
public static string? Substring(Java.Lang.ICharSequence? source, int start, int end);
[<Android.Runtime.Register("substring", "(Ljava/lang/CharSequence;II)Ljava/lang/String;", "")>]
static member Substring : Java.Lang.ICharSequence * int * int -> string
參數
- source
- ICharSequence
- start
- Int32
- end
- Int32
傳回
- 屬性
備註
建立一個新的 String 物件,包含來源字串中給定的字元範圍。 這與單純呼叫 CharSequence#subSequence(int, int) CharSequence.subSequence 不同,因為它不保留原始序列中的任何樣式執行,使實作更有效率。
Java 文件 android.text.TextUtils.substring(java.lang.CharSequence, int, int)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。
適用於
Substring(String, Int32, Int32)
建立一個新的 String 物件,包含來源字串中給定的字元範圍。
public static string? Substring(string? source, int start, int end);
static member Substring : string * int * int -> string
參數
- source
- String
- start
- Int32
- end
- Int32
傳回
備註
建立一個新的 String 物件,包含來源字串中給定的字元範圍。 這與單純呼叫 CharSequence#subSequence(int, int) CharSequence.subSequence 不同,因為它不保留原始序列中的任何樣式執行,使實作更有效率。
Java 文件 android.text.TextUtils.substring(java.lang.CharSequence, int, int)。
本頁部分內容為基於 Open Source Project 所創建與分享的作品,並依授權條款所描述的使用進行修改。