Here you can find the source of toDateQueryFormat(Date value)
public static String toDateQueryFormat(Date value)
//package com.java2s; //License from project: Apache License import java.text.SimpleDateFormat; import java.util.Date; public class Main { public static final String ISO8601_FMT = "yyyy-MM-dd'T'00:00:00'Z'"; /**/* w w w .ja va 2 s .co m*/ * Transforms a Date instance into a String using the default date parser. */ public static String toDateQueryFormat(Date value) { return new SimpleDateFormat(ISO8601_FMT).format(value); } }