register method
Registers a single Provider with the application.
Throws ProviderException.duplicateRegistration if the provider is already registered.
The provider's Provider.register method is immediately called to bind services.
Implementation
void register(Provider provider) {
if (_providers.contains(provider)) {
throw ProviderException.duplicateRegistration(type: provider.runtimeType);
}
_providers.add(provider);
provider.register(container);
}