Android Guides | Samples

Java.Lang.String.Split Method

Splits this string using the supplied regularExpression.

Syntax

[Android.Runtime.Register("split", "(Ljava/lang/String;)[Ljava/lang/String;", "")]
public String[] Split (String expr)

See Also

Parameters

regularExpression

Exceptions

TypeReason
NullPointerExceptionif regularExpression == null
!:NoType:if the syntax of the supplied regular expression is not valid.

Remarks

Splits this string using the supplied regularExpression. Equivalent to split(regularExpression, 0). See Pattern.Split(ICharSequence,Int32) for an explanation of limit. See Pattern for regular expression syntax.

If the same regular expression is to be used for multiple operations, it may be more efficient to reuse a compiled Pattern.

[Android Documentation]

Requirements

Namespace: Java.Lang
Assembly: Mono.Android (in Mono.Android.dll)
Assembly Versions: 0.0.0.0
Since: Added in API level 1