get Current Day Of Week - Android java.util

Android examples for java.util:Week

Description

get Current Day Of Week

Demo Code

import android.text.TextUtils;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;
import java.util.GregorianCalendar;
import java.util.TimeZone;

public class Main{


    public static final int getCurrentDayOfWeek() {

        return Calendar.getInstance().get(Calendar.DAY_OF_WEEK) - 1;

    }/*from ww  w.j  av a2s .c o  m*/

}

Related Tutorials