How to define a member interface in a static context in java?
You cannot define interfaces within methods.
I think the scenario the error message is referring to is defining an interface inside an inner class (which can be done, but only if that is a static
inner class):
class A{
static class X{
interface Y{}
}
}