3 ms·
> But since you can't define methods using reflection, I'd say this isn't used much and isn't really a problem in Java. You can do about anything you want wit
by mbell 13y ago
> But since you can't define methods using reflection, I'd say this isn't used much and isn't really a problem in Java.
You can do about anything you want with cglib / Javassist. Dynamically subtyping or byte code re-writing a class is how many Java ORMs work.
- ZitchDog 13y agoCorrect. You can also use Dynamic Proxies, for metaprogramming, which are built right into the language.