Java Date getDay() Method
The getDay() method of java date class returns the value between 0 to 6 which represents the day of the week by this date object.
This method is deprecated as of JDK version 1.1 and replaced by Calender.get(Calender.DAY_OF_WEEK)
It returns the day of the week represented by this date object.
Example 1Test it Now
day of the week is : 3