The goog.i18n.DateTimeParse Class

goog.i18n.DateTimeParse(pattern)

Construct a DateTimeParse based on current locale.

pattern {string|number}
pattern specification or pattern type.

.ambiguousYearCenturyStart {number}

Number of years prior to now that the century used to disambiguate two digit years will begin

.parse(text, date, opt_start)

Parse the given string and fill info into date object. This version does not validate the input.

text {string}
The string being parsed.
date {goog.date.DateLike}
The Date object to hold the parsed date.
opt_start {number=}
The position from where parse should begin.
returns {number}
How many characters parser advanced.

.strictParse(text, date, opt_start)

Parse the given string and fill info into date object. This version will validate the input and make sure it is a validate date/time.

text {string}
The string being parsed.
date {goog.date.DateLike}
The Date object to hold the parsed date.
opt_start {number=}
The position from where parse should begin.
returns {number}
How many characters parser advanced.