Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question: How to scan for this #149

Open
jakenuts opened this issue Aug 6, 2021 · 1 comment
Open

Question: How to scan for this #149

jakenuts opened this issue Aug 6, 2021 · 1 comment

Comments

@jakenuts
Copy link

jakenuts commented Aug 6, 2021

Apologies that this isn't a bug, not sure where to best ask the question and will try here and S.O.

I need to scan & register services that are constrained generics starting with a contrained-generic parameter of their parent class. I'm now sure how I got this absurdly complicated setup in the first place, but hoping to replicate what seems relatively easy in Autofac with IServiceCollection/Scrutor.

Here is the absurdly complex model:

image

And the pseudo-attempt to register them. I can't determine how to go from the open parent type to a semi-open parent type constrained to the passed in context type.

image

Thanks so much!

@jakenuts
Copy link
Author

jakenuts commented Aug 6, 2021

Got a bit closer with a Where..

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant