Skip to content
This repository has been archived by the owner on Oct 2, 2019. It is now read-only.

Add support for "poor man's DI" (without container) #13

Open
BrunoJuchli opened this issue Jul 19, 2017 · 0 comments
Open

Add support for "poor man's DI" (without container) #13

BrunoJuchli opened this issue Jul 19, 2017 · 0 comments

Comments

@BrunoJuchli
Copy link
Owner

BrunoJuchli commented Jul 19, 2017

Enable support for StaticProxy.Fody in scenarios where the user does not use a DI Container.

Ideas / Alternatives:

  • Add an alternative to new by something like StaticProxy.New(() => new MyProxiedType(argument1, argument2), .. list of interceptors...) which, upon compilation, will be replaced by `new MyProxiedType(argument1, argument2, interceptors)
  • same syntax but no IL-Weaving: use Activator.Activate to supply all parameters
    Use a syntax as in Ninject's ".ToConstructor" binding to specify
  • other?

To progress, first investigate the constraints these alternatives have (for example, are there targets where Activator.Activate is not supported? Are Expressions supported?).

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

No branches or pull requests

1 participant