Java SQL Date Create convertSqlDate2Calendar(java.sql.Date date)

Here you can find the source of convertSqlDate2Calendar(java.sql.Date date)

Description

Convert Date to Calendar.

License

Open Source License

Parameter

Parameter Description
date a parameter

Return

Calendar

Declaration

public static Calendar convertSqlDate2Calendar(java.sql.Date date) 

Method Source Code

//package com.java2s;

import java.util.Calendar;

import java.util.GregorianCalendar;

public class Main {
    /**/*from   www  .  j av  a2s .  com*/
     * <p>Convert Date to Calendar.</p>
     *
     * @param date
     * @return Calendar
     */
    public static Calendar convertSqlDate2Calendar(java.sql.Date date) {
        Calendar cal = null;
        if (date != null) {
            cal = GregorianCalendar.getInstance();
            cal.setTime(date);
        }
        return cal;
    }
}

Related

  1. convertiFecha(Date utilFecha)
  2. convertirSQLDate2String(java.sql.Date sqlDate)
  3. convertJavaDate2SqlDate(java.util.Date date)
  4. converToDate(String yyyy, String mm, String dd)
  5. convertSqlDate(java.util.Date date)
  6. convertSqlDateToJavaDate(java.sql.Date sqlDate)
  7. convertSQLDateToUtilDate(java.sql.Date date)
  8. convertSqlUtil(java.util.Date d)
  9. convertStringToSql(final String dateStr)