dash-licenses
dash-licenses copied to clipboard
Make the implementation more extensible by adding dependency injection
Passing values (e.g. the settings, and logging) around via constructors is cumbersome. Further, things like the ContentIdParsers should be configurable and extendable (e.g., the FlatFileReader constructor hardcodes the parsers that it uses, this should be extendable). Dependency injection will make this sort of configuration easier.
The IContext notion doesn't allow for extensibility. Dependency injection would likely be a better solution that would make it possible to, for example, reuse some of the services in a server-side process.