CharsRefBuilder

A builder for CharsRef instances.

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
object Companion

Functions

Link copied to clipboard
open override fun append(c: Char): CharsRefBuilder
open override fun append(csq: CharSequence?): CharsRefBuilder
open override fun append(csq: CharSequence?, start: Int, end: Int): CharsRefBuilder

fun append(otherChars: CharArray, otherOffset: Int, otherLength: Int)

Appends the given array to this CharsRef

Link copied to clipboard
fun charAt(offset: Int): Char

Return the char at the given offset.

Link copied to clipboard

Return a reference to the chars of this builder.

Link copied to clipboard
fun clear()

Reset this builder to the empty state.

Link copied to clipboard
fun copyChars(other: CharsRef)

Copies the given CharsRef referenced content into this instance.

fun copyChars(otherChars: CharArray, otherOffset: Int, otherLength: Int)

Copies the given array into this instance.

Link copied to clipboard
fun copyUTF8Bytes(bytes: ByteArray, offset: Int, length: Int)

Copy the provided bytes, interpreted as UTF-8 bytes.

Link copied to clipboard
open operator override fun equals(obj: Any?): Boolean
Link copied to clipboard
fun get(): CharsRef

Return a CharsRef that points to the internal content of this builder. Any update to the content of this builder might invalidate the provided ref and vice-versa.

Link copied to clipboard
fun grow(newLength: Int)

Used to grow the reference array.

Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
fun length(): Int

Return the number of chars in this buffer.

Link copied to clipboard
fun setCharAt(offset: Int, b: Char)

Set a char.

Link copied to clipboard
fun setLength(length: Int)

Set the length.

Link copied to clipboard

Build a new CharsRef that has the same content as this builder.

Link copied to clipboard
open override fun toString(): String