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

Create MethodInjector implementation with Reflections #78

Open
derrop opened this issue Dec 28, 2020 · 0 comments
Open

Create MethodInjector implementation with Reflections #78

derrop opened this issue Dec 28, 2020 · 0 comments
Labels
discussion Needs to be discussed in a meeting improvement An improvement to an existing feature

Comments

@derrop
Copy link
Member

derrop commented Dec 28, 2020

Is your feature request related to a problem? Please describe.
Currently there are the MethodInjectors that are generated with Javassist, but that takes some time to generate. If a MethodInjector should only be used once (for example to invoke a getter which won't be reused anymore), this is unnecessary and reflections can be used.

Describe the solution you'd like
The given interface in MethodInjector.Factory.generate should be implemented with a Proxy and the target method should be invoked via Reflections. This solution will be faster when executed once, but for multiple invocations Javassist should still be used.

Describe alternatives you've considered
The InjectedInvocationHelper that has been removed in this commit could be implemented again to simply invoke a method with a Map of Keys (from Guice) and their values and without creating an interface.

@derrop derrop added improvement An improvement to an existing feature discussion Needs to be discussed in a meeting labels Dec 28, 2020
@zortax zortax added this to To do in Flint Development Jan 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion Needs to be discussed in a meeting improvement An improvement to an existing feature
Projects
Development

No branches or pull requests

1 participant