Carlos Hoces wrote:class Coffee is not static, and you try to reference it from a static context: main.
If you make Coffee static, you'll have a clean compilation.
That's wrong. Of course you can use non-static classes in a static context. That's what constructors are for... If you couldn't use non-static classes in a static context there wouldn't be any non-static classes. Rob's answer is right, nested enum => qualified name.