godot.core.memory.GodotWeakReference.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of godot-library-debug Show documentation
Show all versions of godot-library-debug Show documentation
Contains godot api as kotlin classes and jvm cpp interaction code.
package godot.core.memory
import godot.core.KtObject
import godot.core.ObjectID
import java.lang.ref.ReferenceQueue
import java.lang.ref.WeakReference
internal class GodotWeakReference(
binding: GodotBinding,
queue: ReferenceQueue,
val id: ObjectID
) : WeakReference(binding, queue)
internal class GodotBinding {
internal var wrapper: KtObject? = null
internal var scriptInstance: KtObject? = null
val value: KtObject?
get() = scriptInstance?: wrapper
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy