getAny

inline fun <T : Any> <Error class: unknown class>.getAny(): <Error class: unknown class>(source)

Retrieves the first available instance of type T from the current scope. This is useful when you need any instance of a type and don't care which one.

Return

The first available instance of type T

Parameters

T

The type of instance to retrieve

Throws

if no instances of type T are available


inline fun <T : Any> <Error class: unknown class>.getAny(): <Error class: unknown class>(source)

Retrieves the first available instance of type T from the Koin container. This is useful when you need any instance of a type and don't care which one.

Return

The first available instance of type T

Parameters

T

The type of instance to retrieve

Throws

if no instances of type T are available