C:\slop>javac Inventory.java
Inventory.java:60: cannot find symbol
symbol : method findWholeInventory(Camera)
location: class Inventory
findWholeInventory(cameras[3]);
^
1 error
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Daniel Kavanaugh wrote:So Should it read cameras.findWholeInventory(cameras[3]); ?
Daniel Kavanaugh wrote:Also, would it be possible for me to display all the elements in these arrays within a GUI?
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Daniel Kavanaugh wrote:So Should it read cameras.findWholeInventory(cameras[3]); ?
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
No. Plain and simple: if you haven’t made some dreadful error in how you extended the Camera class, then that will not cause any problems. Fred R has already given you a heavy hint as to what the problem you noticed is.Daniel Kavanaugh wrote: . . .
DigitalCamera is a subclass that extends Camera, could that be a problem? . . .
Until you have got the Camera and DigitalCamera classes working at the command line, you forget there even is such a thing as a GUI.Daniel Kavanaugh wrote:Also, would it be possible for me to display all the elements in these arrays within a GUI?
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Consider Paul's rocket mass heater. |