Java SQL Date Create asDate(java.sql.Date sqlDate)

Here you can find the source of asDate(java.sql.Date sqlDate)

Description

as Date

License

Apache License

Declaration

public static java.util.Date asDate(java.sql.Date sqlDate) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static java.util.Date asDate(java.sql.Date sqlDate) {
        return sqlDate != null ? new java.util.Date(sqlDate.getTime()) : null;
    }/*  w  ww. j av a  2  s. c o  m*/

    public static java.util.Date asDate(java.sql.Timestamp sqlTimestamp) {
        return sqlTimestamp != null ? new java.util.Date(sqlTimestamp.getTime()) : null;
    }
}

Related

  1. asDate(Object tsObj)
  2. asSqlDate(Date date)
  3. asSqlDate(Date date)
  4. asSqlDate(String date)