WeakContextScope

open class WeakContextScope<in C>(newRepo: () -> ScopeRegistry) : Scope<C>

Scope that map scope registries associated to weak contexts.

In essence, the context is weak, and for a given context, its registry will be GC'd when it is itself GC'd.

Constructors

WeakContextScope
Link copied to clipboard
fun WeakContextScope(newRepo: () -> ScopeRegistry = { StandardScopeRegistry() })

Types

Of
Link copied to clipboard
object Of : WeakContextScope<Any>

Functions

equals
Link copied to clipboard
open operator fun equals(other: Any?): Boolean
getRegistry
Link copied to clipboard
open override fun getRegistry(context: C): ScopeRegistry
Get a registry for a given context.
hashCode
Link copied to clipboard
open fun hashCode(): Int
toString
Link copied to clipboard
open fun toString(): String

Properties

map
Link copied to clipboard
val map: WeakHashMap<C, ScopeRegistry>
newRepo
Link copied to clipboard
val newRepo: () -> ScopeRegistry

Inheritors

WeakContextScope
Link copied to clipboard