|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mars_sim.msp.core.time.EarthClock
public class EarthClock
The EarthClock class keeps track of Earth Universal Time. It should be synchronized with the Mars clock.
| Constructor Summary | |
|---|---|
EarthClock(String dateString)
Constructor |
|
| Method Summary | |
|---|---|
void |
addTime(double seconds)
Adds time to the calendar |
String |
getDateString()
Returns the date formatted in a string |
int |
getDayOfMonth()
|
int |
getMonth()
|
String |
getTimeStamp()
Returns the date/time formatted in a string |
int |
getYear()
|
String |
toString()
Displays the string version of the clock. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public EarthClock(String dateString)
dateString - the UT date string in format: "MM/dd/yyyy hh:mm:ss".
Exception - if date string is invalid.| Method Detail |
|---|
public String getTimeStamp()
public String getDateString()
public void addTime(double seconds)
seconds - seconds added to the calendarpublic String toString()
toString in class Objectpublic int getDayOfMonth()
public int getMonth()
public int getYear()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||