Rename split method to splitBy and revive old split implementation interpreting parameter as regex to provide the migration path.

This commit is contained in:
Ilya Gorbunov
2015-03-26 22:49:07 +03:00
committed by Ilya Gorbunov
parent b10d869cd7
commit b3165ac771
5 changed files with 24 additions and 8 deletions
+11 -2
View File
@@ -11,10 +11,19 @@ native("lastIndexOf")
public fun String.nativeLastIndexOf(str : String, fromIndex : Int) : Int = noImpl
library("splitString")
public fun String.splitByRegex(regex: String): Array<String> = noImpl
public fun String.splitWithRegex(regex: String): Array<String> = noImpl
library("splitString")
public fun String.splitByRegex(regex: String, limit: Int): Array<String> = noImpl
public fun String.splitWithRegex(regex: String, limit: Int): Array<String> = noImpl
deprecated("Use splitWithRegex (temporary)")
library("splitString")
public fun String.split(regex: String): Array<String> = noImpl
deprecated("Use splitWithRegex (temporary)")
library("splitString")
public fun String.split(regex: String, limit: Int): Array<String> = noImpl
native public fun String.substring(beginIndex : Int) : String = noImpl
native public fun String.substring(beginIndex : Int, endIndex : Int) : String = noImpl