Does declaring many identical anonymous classes waste memory in java?
- by depsypher
I recently ran across the following snippet in an existing codebase I'm working on and added the comment you see there. I know this particular piece of code can be rewritten to be cleaner, but I just wonder if my analysis is correct.
Will java create a new class declaration and store it in perm gen space for every call of this method, or will it…