Here you can find the source of stringToDateTemporalCoverage(String dateString)
public static Date stringToDateTemporalCoverage(String dateString) throws ParseException
//package com.java2s; //License from project: Apache License import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; public class Main { public static Date stringToDateTemporalCoverage(String dateString) throws ParseException { SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd"); try {//from www . ja v a 2 s.com return sdf.parse(dateString); } catch (NullPointerException ex) { return null; } catch (ParseException ex) { return null; } } }