v1.9.10
  • Solutions
    • Multiplatform
    • Server-side
    • Data science
    • Android
  • Docs
  • Community
  • Teach
  • Play
    • Playground
    • Examples
    • Koans
← Docs
kotlin-stdlib / kotlinx.cinterop / StableRef

StableRef

Native
1.3
class StableRef<out T : Any>
(source)

Functions

Native
1.3

asCPointer

Converts the handle to C pointer.

fun asCPointer(): COpaquePointer
Native
1.3

dispose

Disposes the handle. It must not be used after that.

fun dispose()
Native
1.3

get

Returns the object this handle was created for.

fun get(): T

Companion Object Functions

Native
1.3

create

Creates a handle for given object.

fun <T : Any> create(any: T): StableRef<T>
Stay in touch:
  • Contributing to Kotlin
  • Releases
  • Press Kit
  • Security
  • Blog
  • Issue Tracker
  • Brand assets
  • Careers
Kotlin™ is protected under the Kotlin Foundation and licensed under the Apache 2 license.
Supported and developed by JetBrains