const mixinafIoc::ServiceOverride
afIoc::ServiceOverride
(Service) - Override a defined service with your own implementation.
static Void bind(ServiceBinder binder) {
binder.bindImpl(PieAndChips#).withId("dinner")
}
@Contribute
static Void contributeServiceOverride(MappedConfig conf) {
config["dinner"] = conf.autobuild(PieAndMash#)
}
Note at present you can not override perThread scoped services and non-const (not immutable) services.
@since 1.2
@uses MappedConfig of Str:Obj (serviceId:overrideImpl)