dcsimg

Can an anonymous class have static members?

John Zukowski

With one exception, anonymous classes cannot contain static fields, methods, or classes. The only static thing they can contain are static final constants.