Method: DateTime._strptime

Defined in:
ext/date/date_core.c

._strptime(string[, format = '%FT%T%z']) ⇒ Hash

Parses the given representation of date and time with the given template, and returns a hash of parsed elements. _strptime does not support specification of flags and width unlike strftime.

See also strptime(3) and #strftime.

Returns:

  • (Hash)


7869
7870
7871
7872
7873
# File 'ext/date/date_core.c', line 7869

static VALUE
datetime_s__strptime(int argc, VALUE *argv, VALUE klass)
{
    return date_s__strptime_internal(argc, argv, klass, "%FT%T%z");
}