Skip to content

Instantly share code, notes, and snippets.

@kuraydev
Created January 9, 2016 21:36
Show Gist options
  • Select an option

  • Save kuraydev/0363fc65dfe72600e33c to your computer and use it in GitHub Desktop.

Select an option

Save kuraydev/0363fc65dfe72600e33c to your computer and use it in GitHub Desktop.
This is how to get current day
Calendar calendar = Calendar.getInstance();
int day = calendar.get(Calendar.DAY_OF_WEEK);
switch (day){
case Calendar.SUNDAY:
//Your code
break;
case Calendar.MONDAY:
//Your code
break;
...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment