|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.ObjectRock
This class models a rock that has a certain mass.
Constructor Summary | |
Rock(double m)
Initialize a Rock object with the given mass in kilograms. |
Method Summary | |
double |
getMass()
Return the mass of this Rock in kilograms. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Rock(double m)
m
- the mass in kilogramsMethod Detail |
public double getMass()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |