Compiler Error J0056

Missing return type specification

The compiler detected a method declaration without a return type specified. All method declarations must specify a return type. If the method is not meant to return a value, use the void keyword.

The following example illustrates this error:

public class Simple {
   
   public method1() { // error: no return type
   
      // do something meaningful
   }
}