Compiler Error J0130

Cannot declare an interface method to be 'native', 'static', 'synchronized' or 'final'

The compiler detected one of the keywords shown in the error message used in the declaration of an interface method. Because an interface method does not have implementation code, it cannot be declared as native, static, synchronized, or final.

The following example illustrates this error:

interface Simple {
   
   public final void method1();
   /*error: ‘method1’ cannot be declared 
      as final in an interface*/
}