Gordon Child
08/06/2021, 8:08 PMline.split(": ", 2)
(line is a String). I've tried line.split(": ", false, 2)
and line.split(delimiters = ": ", limit = 2)
val parts = line.split(": ", ignoreCase = false, limit = 2)
or
val parts = line.split(": ", limit = 2)
val [propertyName, propertyValue] = line.split(": ", limit = 2)
ephemient
08/06/2021, 8:28 PMval (propertyName, propertyValue) = line.split(": ", limit = 2)
does work thanks to standard operator fun component1()
etc. extensions. will throw if there's only 1 part thoughGordon Child
08/06/2021, 8:32 PM