Add comments to setDate, setTime, setTimestamp methods to reduce confusion to the Hibernate newbies in future.

This commit is contained in:
Ocean-Blue 2011-06-16 12:36:10 -07:00
parent 1e88107f3e
commit afc406a03b
1 changed files with 20 additions and 0 deletions

View File

@ -405,8 +405,28 @@ public interface Query {
public Query setBigDecimal(String name, BigDecimal number);
public Query setBigInteger(String name, BigInteger number);
/**
* Bind the date (time is truncated) of a given Date object to a named query parameter.
*
* @param name The name of the parameter
* @param date The date object
*/
public Query setDate(String name, Date date);
/**
* Bind the time (date is truncated) of a given Date object to a named query parameter.
*
* @param name The name of the parameter
* @param date The date object
*/
public Query setTime(String name, Date date);
/**
* Bind the date and the time of a given Date object to a named query parameter.
*
* @param name The name of the parameter
* @param date The date object
*/
public Query setTimestamp(String name, Date date);
public Query setCalendar(String name, Calendar calendar);