Error message in Java after extending JFrame -


i'm having trouble snippet of code working on. extending jframe in class contains main method. sort of new java (learned in university, have practice it, still stuck). have return type in locate method ide, eclipse neon, saying convert component. here code:

import javax.swing.jframe;  public class board extends jframe  { /**  *   */ private static final long serialversionuid = 1l; boolean result; int counter2; int counter = 100000; point point = new point(1,2,3);  int to_be_changed = 100000; point[] point2 = new point[100000]; private int fortree = 0;   public static void main(string[] args)  {     board bb = new board();     int colchange = 1;           bb.add(1 ,0 ,1);      new work(bb);                } public void add(int xco, int yco, int colr) {     point2[point2.length - counter] = new point(xco, yco, colr);     counter--;     counter2++; }  public boolean filled(int x1, int y1) {     int = 0;      do{         if (i > 100000){ = 0; }         result = ((point2[i].getpoinx() == x1) && (point2[i].getpointy()== y1));         i++;       }while((result == false) && (i != counter2));       return result; }  public point locate(int x1, int y1) {     point backer = new point(0,0,0);      (int j = 0; ((j < point2.length) && (result == false) && (point2[j]) != null); j++ )     {         if ((point2[j].getpoinx() == x1) && (point2[j].getpointy() == y1))           {             backer = point2[j];             result = true;          }     }      return backer; }  public void setfortree() {     this.fortree++; }  public int getfortree() {     return this.fortree; }  }  class work {     work(board y)     {     intelligence p = new intelligence();     system.out.println(p.tree(0, 0, y, 1, 1));     } } 

can please tell me going on? lot

the jframe class contains lot of methods. overriding existing method. 1 of methods belongs superclass container , has

  • as return-type component.
  • same list of parameters (two ints).

    @deprecated public component locate(int x, int y)

eclipse knows , reminds locate needs return component. easy test renaming of method.


Comments

Popular posts from this blog

php - How to display all orders for a single product showing the most recent first? Woocommerce -

asp.net - How to correctly use QUERY_STRING in ISAPI rewrite? -

angularjs - How restrict admin panel using in backend laravel and admin panel on angular? -