|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectbot.Thing
bot.Box
Holds other objects--used to illustrate casting to get to the take() method.
| Field Summary |
| Fields inherited from class bot.Thing |
name, owner |
| Constructor Summary | |
Box()
Make an empty box. |
|
Box(Thing con)
Make box with "con" in it. |
|
| Method Summary | |
String |
examine()
Describe the thing. |
String |
pictureName()
This is the graphic that should be used to render the thing on the screen. |
Thing |
take()
Take the contents out of the box. |
String |
use()
All things can be used. |
double |
weight()
Boxes weigh 5 plus whatever is inside them. |
| Methods inherited from class bot.Thing |
claim, clone, getName, getOwner, nudge, toString |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public Box(Thing con)
public Box()
| Method Detail |
public Thing take()
public String use()
Thing
use in class Thingpublic String examine()
Thing
examine in class Thingpublic String pictureName()
Thing
pictureName in class Thingpublic double weight()
weight in class Thing
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||