How many methods are defined in the Time class in java?
A
Correct answer
Explanation
There are 10 methods present in the Time class in java. These are:-
1) getDate()
2) getDay()
3) getMonth()
4) getYear()
5) setDate(int i)
6) setMonth(int i)
7) setTime(int i)
8) setYear(int i)
9) toString():- Formats a time in JDBC time escape format
10) valueOf(String s):- Converts a string in JDBC time escape format to a Time value
So, this is the correct answer.