override<T> method
void
override<T>(
- T key,
- Constructable<
T> clazz
Implementation
void override<T>(T key, Constructable<T> clazz) {
if (!_services.containsKey(key)) {
throw Exception('Service not exists, you can\t override it');
}
_services[key as Type] = clazz();
}