fn infer_format(string: &str) -> Option<&str> {
    if string.parse::<i32>().is_ok() {
        return Some("integer");
    } else if NaiveDate::parse_from_str(string, "%Y-%m-%d").is_ok() {
        return Some("date");
    } else if DateTime::parse_from_rfc3339(string).is_ok() {
        return Some("date-time");
    }
    None
}
/// Infer a format of the given string.
///
/// Currently only the following formats are supported:
///   - integer
///   - date
///   - date-time
Infer a format of the given string.
Currently only the following formats are supported:
integer
date
date-time
Infer a format of the given string . Currently only the following formats are supported : integer date date - time
fn infer_format(string: &str) -> Option<&str> {
    if string.parse::<i32>().is_ok() {
        return Some("integer");
    } else if NaiveDate::parse_from_str(string, "%Y-%m-%d").is_ok() {
        return Some("date");
    } else if DateTime::parse_from_rfc3339(string).is_ok() {
        return Some("date-time");
    }
    None
}
fn infer_format ( string : & str ) -> Option < & str > { if string . parse :: < i32 > ( ) . is_ok ( ) { return Some ( " " ) ; } else if NaiveDate :: parse_from_str ( string , " " ) . is_ok ( ) { return Some ( " " ) ; } else if DateTime :: parse_from_rfc3339 ( string ) . is_ok ( ) { return Some ( " " ) ; } None }
Infer a format of the given string.
Infer a format of the given string .
string
&str