public Date getDate ( String name , String format ) { Object value = get ( name ) ; if ( value instanceof Date ) { return ( Date ) value ; } if ( value != null ) { try { return new SimpleDateFormat ( format ) . parse ( value . toString ( ) ) ; } catch ( ParseException e ) { // ignore } } return null ; }
Obtains a date from the parameter using the given format