Extensions for java.lang.StringBuilder
appendln
Appends a line separator to this StringBuilder.
fun StringBuilder.appendln(): StringBuilderAppends value to this StringBuilder, followed by a line separator.
fun StringBuilder.appendln(
value: StringBuffer?
): StringBuilderfun StringBuilder.appendln(
value: CharSequence?
): StringBuilderfun StringBuilder.appendln(value: String?): StringBuilderfun StringBuilder.appendln(value: Any?): StringBuilderfun StringBuilder.appendln(
value: StringBuilder?
): StringBuilderfun StringBuilder.appendln(value: CharArray): StringBuilderfun StringBuilder.appendln(value: Char): StringBuilderfun StringBuilder.appendln(value: Boolean): StringBuilderfun StringBuilder.appendln(value: Int): StringBuilderfun StringBuilder.appendln(value: Short): StringBuilderfun StringBuilder.appendln(value: Byte): StringBuilderfun StringBuilder.appendln(value: Long): StringBuilderfun StringBuilder.appendln(value: Float): StringBuilderfun StringBuilder.appendln(value: Double): StringBuilderappendRange
Appends characters in a subarray of the specified character array value to this string builder and returns this instance.
fun StringBuilder.appendRange(
value: CharArray,
startIndex: Int,
endIndex: Int
): StringBuilderAppends a subsequence of the specified character sequence value to this string builder and returns this instance.
fun StringBuilder.appendRange(
value: CharSequence?,
startIndex: Int,
endIndex: Int
): StringBuilderclear
Clears the content of this string builder making it empty and returns this instance.
fun StringBuilder.clear(): StringBuilderdeleteAt
Removes the character at the specified index from this string builder and returns this instance.
fun StringBuilder.deleteAt(index: Int): StringBuilderdeleteRange
Removes characters in the specified range from this string builder and returns this instance.
fun StringBuilder.deleteRange(
startIndex: Int,
endIndex: Int
): StringBuilderinsertRange
Inserts characters in a subarray of the specified character array value into this string builder at the specified index and returns this instance.
fun StringBuilder.insertRange(
index: Int,
value: CharArray,
startIndex: Int,
endIndex: Int
): StringBuilderInserts characters in a subsequence of the specified character sequence value into this string builder at the specified index and returns this instance.
fun StringBuilder.insertRange(
index: Int,
value: CharSequence?,
startIndex: Int,
endIndex: Int
): StringBuilderset
Sets the character at the specified index to the specified value.
operator fun StringBuilder.set(index: Int, value: Char)setRange
Replaces characters in the specified range of this string builder with characters in the specified string value and returns this instance.
fun StringBuilder.setRange(
startIndex: Int,
endIndex: Int,
value: String
): StringBuildertoCharArray
Copies characters from this string builder into the destination character array.
fun StringBuilder.toCharArray(
destination: CharArray,
destinationOffset: Int = 0,
startIndex: Int = 0,
endIndex: Int = this.length)