



Estude fácil! Tem muito documento disponível na Docsity
Ganhe pontos ajudando outros esrudantes ou compre um plano Premium
Esta página não é visível na pré-visualização
Não perca as partes importantes!




Class Tree Deprecated Index Help PREV CLASS NEXT CLASS FRAMES^ NO FRAMES SUMMARY: INNER | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD com.deitel.jhtp4.appenF
java.lang.Object | +-- com.deitel.jhtp4.appenF.Time public class Time extends java.lang.Object This class maintains the time in 24-hour format. Author: Deitel & Associates, Inc. See Also: Object
Time3 () Time3 constructor initializes each instance variable to zero. Time3 (int h) Time3 constructor: hour supplied, minute and second defaulted to 0 Time3 (int h, int m) Time3 constructor: hour and minute supplied, second defaulted to 0 Time3 (int h, int m, int s) Time3 constructor: hour, minute and second supplied Time3 (Time3 time) Time3 constructor: another Time3 object supplied
int (^) getHour () Gets the hour
int (^) getMinute () Gets the minute int (^) getSecond () Gets the second void (^) setHour (int h) Sets the hour void (^) setMinute (int m) Sets the minute void (^) setSecond (int s) Sets the second void (^) setTime (int h, int m, int s) Set a new time value using universal time. java.lang.String (^) toString () Convert to String in standard-time format java.lang.String (^) toUniversalString () Convert to String in universal-time format Methods inherited from class java.lang.Object clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
public Time3 () throws java.lang.Exception Time3 constructor initializes each instance variable to zero. Ensures that Time object starts in a consistent state. Throws: Exception - in the case of an invalid time
public Time3 (inth) throws java.lang.Exception Time3 constructor: hour supplied, minute and second defaulted to 0
throws java.lang.Exception Set a new time value using universal time. Perform validity checks on data. Set invalid values to zero. Parameters: h - the hour m - the minute s - the second Throws: Exception - in the case of an invalid time See Also: setHour(int), setMinute(int), setSecond(int)
public void setHour (inth) throws java.lang.Exception Sets the hour Parameters: h - the hour Throws: java.lang.Exception - in the case of an invalid time
public void setMinute (intm) throws java.lang.Exception Sets the minute Parameters: m - the minute Throws: java.lang.Exception - in the case of an invalid time
public void setSecond (ints) throws java.lang.Exception Sets the second Parameters: m - the minute Throws: java.lang.Exception - in the case of an invalid time
public int getHour ()
Gets the hour Returns: an int specifying the hour.
public int getMinute () Gets the minute Returns: an int specifying the minute.
public int getSecond () Gets the second Returns: an int specifying the second.
public java.lang.String toUniversalString () Convert to String in universal-time format Returns: a String representation of the time in universal-time format
public java.lang.String toString () Convert to String in standard-time format Overrides: toString in class java.lang.Object Returns: a String representation of the time in standard-time format Class Tree Deprecated Index Help PREV CLASS NEXT CLASS FRAMES^ NO FRAMES SUMMARY: INNER | FIELD | CONSTR | METHOD DETAIL: FIELD | CONSTR | METHOD