Java Hour getMinOfHour(long l1)

Here you can find the source of getMinOfHour(long l1)

Description

get Min Of Hour

License

Open Source License

Declaration

public static int getMinOfHour(long l1) 

Method Source Code

//package com.java2s;

import java.util.Calendar;

public class Main {

    public static int getMinOfHour(long l1) {
        Calendar cal1 = Calendar.getInstance();
        cal1.setTimeInMillis(l1);//  w  w  w .  jav  a  2  s .  c om
        return cal1.get(Calendar.MINUTE);
    }

    /**
     * Returns the value of the given calendar field.
     * 
     * @param l1    timeVal
     * @param type  calendar-specific value
     * @return
     */
    public static int get(long l1, int type) {
        Calendar cal1 = Calendar.getInstance();
        cal1.setTimeInMillis(l1);
        return cal1.get(type);
    }
}

Related

  1. getHours(java.util.Date _date)
  2. getHoursByDate(Date date, int hours)
  3. getHoursOfTowDiffDate(String p_startDate, String p_endDate)
  4. getLastHour()
  5. getLasthour()
  6. getPreHour()
  7. getPreHourText(String pattern)
  8. getPrevHour(Date date)
  9. getSecondsPassedInHour()