Companion

Functions

Link copied to clipboard
inline fun <T : Any> auto(size: Int, initializer: (Int) -> T): MutableBuffer<T>

Creates a MutableBuffer of given type T. If the type is primitive, specialized buffers are used (IntBuffer, DoubleBuffer, etc.), ListBuffer is returned otherwise.

inline fun <T : Any> auto(type: KClass<out T>, size: Int, initializer: (Int) -> T): MutableBuffer<T>

Creates a MutableBuffer of given type. If the type is primitive, specialized buffers are used (IntBuffer, DoubleBuffer, etc.), ListBuffer is returned otherwise.

Link copied to clipboard
inline fun <T> boxing(size: Int, initializer: (Int) -> T): MutableBuffer<T>

Create a boxing mutable buffer of given type

Link copied to clipboard
inline fun double(size: Int, initializer: (Int) -> Double): DoubleBuffer

Creates a DoubleBuffer with the specified size, where each element is calculated by calling the specified initializer function.

Link copied to clipboard
inline fun float(size: Int, initializer: (Int) -> Float): FloatBuffer

Creates a FloatBuffer with the specified size, where each element is calculated by calling the specified initializer function.

Link copied to clipboard
inline fun int(size: Int, initializer: (Int) -> Int): IntBuffer

Creates a IntBuffer with the specified size, where each element is calculated by calling the specified initializer function.

Link copied to clipboard
inline fun long(size: Int, initializer: (Int) -> Long): LongBuffer

Creates a LongBuffer with the specified size, where each element is calculated by calling the specified initializer function.

Link copied to clipboard
inline fun short(size: Int, initializer: (Int) -> Short): ShortBuffer

Creates a ShortBuffer with the specified size, where each element is calculated by calling the specified initializer function.