Java Date getDay() MethodThe 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) Syntax:ParametersNA ReturnIt returns the day of the week represented by this date object. Example 1Test it NowOutput: day of the week is : 3
Next TopicJava Util Date
|