Partager via


AbstractStringBuilder.Substring Method

Definition

Overloads

Substring(Int32)

Returns a new String that contains a subsequence of characters currently contained in this character sequence.

Substring(Int32, Int32)

Returns a new String that contains a subsequence of characters currently contained in this sequence.

Substring(Int32)

Returns a new String that contains a subsequence of characters currently contained in this character sequence.

[Android.Runtime.Register("substring", "(I)Ljava/lang/String;", "GetSubstring_IHandler")]
public virtual string? Substring (int start);
[<Android.Runtime.Register("substring", "(I)Ljava/lang/String;", "GetSubstring_IHandler")>]
abstract member Substring : int -> string
override this.Substring : int -> string

Parameters

start
Int32

The beginning index, inclusive.

Returns

The new string.

Attributes

Remarks

Returns a new String that contains a subsequence of characters currently contained in this character sequence. The substring begins at the specified index and extends to the end of this sequence.

Java documentation for java.lang.AbstractStringBuilder.substring(int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

Substring(Int32, Int32)

Returns a new String that contains a subsequence of characters currently contained in this sequence.

[Android.Runtime.Register("substring", "(II)Ljava/lang/String;", "GetSubstring_IIHandler")]
public virtual string? Substring (int start, int end);
[<Android.Runtime.Register("substring", "(II)Ljava/lang/String;", "GetSubstring_IIHandler")>]
abstract member Substring : int * int -> string
override this.Substring : int * int -> string

Parameters

start
Int32

The beginning index, inclusive.

end
Int32

The ending index, exclusive.

Returns

The new string.

Attributes

Remarks

Returns a new String that contains a subsequence of characters currently contained in this sequence. The substring begins at the specified start and extends to the character at index end - 1.

Java documentation for java.lang.AbstractStringBuilder.substring(int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to