Hi,
I would like to declare a static final class instance, and set one of its field variables in the same line (all outside of a method). Ideally, it'd look something like this:
public class MyClass { public static final MyClass myInstance = new MyClass() { field = value }; // declaration of field & constructor for MyClass }
but that doesn't work. Is this possible / does anyone have any ideas?