static DateTime tryParse(String formattedString) { // TODO: Optimize to avoid throwing. try { return parse(formattedString); } on FormatException { return null; } }