DEV Community

Discussion on: Dynamic Enums

darshitpp profile image
Darshit Patel Author

Perhaps, there may be a slight performance hit, but the part using Reflections runs only once -- when the class is loaded for the first time. We can, of course, manually use map.put(), but the intent was for us asking the JVM to do it automatically. I do not have benchmarks for this, but would be happy to include it in the post should you do so!