BootstrapRegistryInitializer class abstract interface

Strategy interface used to programmatically register bootstrap instances into a BootstrapRegistry before the application context is refreshed.

Implementations of this interface are typically used to pre-register pods or resources (like loggers, metrics, or external connections) that need to be available early in the application's lifecycle.

This is useful in scenarios where specific types or suppliers must be initialized before the full application context is available.

Example:

class MyRegistryInitializer implements BootstrapRegistryInitializer {
  @override
  void initialize(BootstrapRegistry registry) {
    registry.register(MyService.classType, (ctx) => MyService());
  }
}

To use it, register the initializer before launching the application context, or during your application bootstrap phase.

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

initialize(BootstrapRegistry registry) Future<void>
Strategy interface used to programmatically register bootstrap instances into a BootstrapRegistry before the application context is refreshed.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited