Is there any predefined class in Java so that if I pass it a date, it must return if it is a valid date or not? For example, if I go through February 31 of a year, then it should return false, and if the date exists, then it should return me true for any date of any year.
And I also need a method that will tell me exactly which weekday this particular date is. I went through the Calender class, but I did not understand how to do this.
source
share