| | |
problem with implementing MVC
Thread Solved |
•
•
Join Date: Oct 2007
Posts: 280
Reputation:
Solved Threads: 19
I have recently encoutered an error that I have failed to figure out while trying to implement something in MVC. I have used a similar code on another program which seems to work but I cant figure out why this one is not working.
I get the error code "cannot find symbol class myGameModel". this error is repeated for the controller, panel and view.
I will post the controller and model only. Hope to get some advice. thanks.
PS. the above code is just a structure but when I compile the individual files, It cant seem to find other classes
I get the error code "cannot find symbol class myGameModel". this error is repeated for the controller, panel and view.
I will post the controller and model only. Hope to get some advice. thanks.
java Syntax (Toggle Plain Text)
//CONTROLLER package Game; public class myGameController{ private myGameModel model; private myGameView view; public myGameController(myGameModel model){ this.model=model; } public void set(myGameView view){ this.view=view; } public void newGame(myGameModel model){ model.newGame(); } } //MODEL package Game; import java.util.Observable; import java.*; public class myGameModel extends Observable { private myGameController controller; private boolean turn; private int[][] gameBoard=new int[3][3];; public void newGame() { //some code } }
![]() |
Similar Threads
Other Threads in the Java Forum
- Previous Thread: code required
- Next Thread: trouble with method call
| Thread Tools | Search this Thread |
911 addball addressbook android api append applet application apps array arrays automation binary bluetooth businessintelligence button card chat class client code collision component crashcourse css csv database eclipse ee error fractal free game gis givemetehcodez graphics gui html ide image input integer integration j2me japplet java javaarraylist javadoc javafx javaprojects jni jpanel julia jvm linux list loan loop machine map method methods migrate mobile netbeans newbie objects oriented output panel phone physics problem program programming project radio recursion reporting scanner se server service set sms socket software sort sql string swing test textfield threads transfer tree trolltech ubuntu utility windows





