Koin class
Gather main features to use on Koin context
@author Arnaud Giuliani Ported to Dart from Kotlin by: @author - Pedro Bissonho
- Mixed in types
Constructors
- Koin()
Properties
- componentScope → Scope
-
Get the associated Koin instance
read-onlyoverride
- hashCode → int
-
The hash code for this object.
read-onlyinherited
- logger ↔ Logger
-
read / write
- loggerInstanceObserver ↔ LoggerInstanceObserver
-
read / write
- runtimeType → Type
-
A representation of the runtime type of the object.
read-onlyinherited
-
scopeObserves
→ KtHashSet<
ScopeObserver> -
final
- scopeRegistry → ScopeRegistry
-
read-only
Methods
-
bind<
S, P> ([Qualifier qualifier]) → S -
componentScope
Get instance instance from Koin by Primary Type P, as secondary type S
@param parameters
inherited
-
bindWithParam<
S, K, P> (P param, {Qualifier qualifier}) → S -
Get instance instance from Koin by Primary Type K, as secondary type S
@param parameters
override
-
bindWithType<
S> (Type secondaryType, Type primaryType, [Parameter parameter]) → S -
Get instance of primary type
primaryType
and return as secondary typeS
(not for scoped instances) -
close(
) → void - Close all resources from context
-
createContextIfNeeded(
) → void -
createEagerInstances(
) → void -
createRootScope(
) → void -
createScope<
T> (String scopeId, [dynamic source]) → Scope - Create a Scope instance
-
createScopeT2<
T> () → Scope -
createScopeWithQualifier(
String scopeId, Qualifier qualifier, [dynamic source]) → Scope -
createScopeWithSource<
T> (String scopeId, dynamic source) → Scope - Create a Scope instance
-
declare<
T> (T instance, {Qualifier qualifier, List< Type> secondaryTypes = const <Type>[], bool override = false}) → void - Declare a component definition from the given instance This result of declaring a single definition of type T, returning the given instance
-
deleteScope(
String scopeId) → void - Delete a scope instance
-
get<
T> ([Qualifier qualifier]) → T -
inherited
-
getAll<
T> () → List< T> - Get a all instance for given inferred class (in primary or secondary type)
-
getOrCreateScope<
T> (String scopeId) → Scope - Get or Create a Scope instance
-
getOrCreateScopeQualifier(
String scopeId, Qualifier qualifier) → Scope - Get or Create a Scope instance
-
getOrNull<
T> ([Qualifier qualifier, Parameter parameter]) → T - Get a Koin instance if available with return instance of type T or null.
-
getOrNullWithType<
T> ([Type type, Qualifier qualifier, Parameter parameter]) → T - Get a Koin instance if available
-
getScope(
String scopeId) → Scope - Get a scope instance by id.
-
getScopeOrNull(
String scopeId) → Scope - get a scope instance @param scopeId
-
getWithParam<
T, P> (P param, {Qualifier qualifier}) → T -
inherited
-
getWithType<
T> ([Type type, Qualifier qualifier, Parameter parameter]) → T - Get a Koin instance @return instance of type T
-
inject<
T> ([Qualifier qualifier]) → Lazy< T> -
Lazy inject instance from Koin
@param qualifier
@param parameters
inherited
-
injectOrNull<
T> (Qualifier qualifier, Parameter parameter) → Lazy< T> - Lazy inject a Koin instance if available. Return Lazy instance of type T or null. /
-
injectWithParam<
T, P> (P param, {Qualifier qualifier}) → Lazy< T> -
Lazy inject instance from Koin
inherited
-
loadModule(
Module module) → void -
loadModules(
List< Module> modules) → void -
loadScopeDefinition(
ScopeDefinition scopeDefinition) → void -
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a non-existent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
-
unloadModule(
Module module) → void -
unloadModules(
List< Module> modules) → void -
withScopeObserver(
ScopeObserver scopeObserver) → void
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited