commonsensesoftware / more-rs-di

Rust Dependency Injection (DI) framework
MIT License
20 stars 3 forks source link

Add Validation #4

Closed commonsensesoftware closed 1 year ago

commonsensesoftware commented 1 year ago

Adds service validation which covers the following main scenarios:

ServiceCollection::build_provider() should not allow an invalid ServiceProvider to be created. The signature will, therefore, now be:

pub fn build_provider(&self) -> Result<ServiceProvider, ValidationError>() { }

Since that is a breaking change, the crate will also bump to 2.0.