View Source GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeAbsoluteDateTime (google_api_content_warehouse v0.4.0)
AbsoluteDateTime represents the resolved date/time expressions that need no further calculation. It has a section for date and a section for time. The date section will always be filled; if the time section is filled, hour is always filled; for (minute, second, partial_second), they are optional with a zero default value. But if partial_second is filled, (minute, second) must be filled, even they are 0s; if second is filled, minute must be filled. Next field#: 22.
Attributes
-
allowPersonal
(type:boolean()
, default:nil
) - allow_personal determines if personal datetimes are allowed to be used in the resolution of the personal datetime. If allow_personal is false and a personal date exists, the entire parse will be thrown out. -
day
(type:integer()
, default:nil
) - -
deleted11
(type:String.t
, default:nil
) - Deprecated fields. Do NOT use. -
holiday
(type:GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeHoliday.t
, default:nil
) - season, quarters and holidays will be soon handled as fetched relative datetimes and will be removed from the AbsoluteDateTime message. -
hour
(type:integer()
, default:nil
) - Time is 24-hour military time. -
hourState
(type:String.t
, default:nil
) - Note: This is marked as deprecated as we are moving into explicit parses using themeridiem
field, and leave the inference over implicit parses to the grounding/resolution libraries. -
isBc
(type:boolean()
, default:nil
) - |is_bc| is true if and only the date is Before Christ/Common Era. If |is_bc| is true, only year is meaningful in this proto, as Gregorian calendar is only meaningful for A.D. date/times. -
meridiem
(type:String.t
, default:nil
) - For expressions such as "am", "pm". Note: the name "meridiem" has been taken by a field in message ResolutionProperties. Examples: * "9 am": point { hour: 9 meridiem: AM hour_state: UNAMBIGUOUS } -
minute
(type:integer()
, default:nil
) - -
modifier
(type:String.t
, default:nil
) - For expressions such as "around 2 pm". -
month
(type:String.t
, default:nil
) - -
nonGregorianDate
(type:GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeNonGregorianDate.t
, default:nil
) - If present then: 1) the incoming non-Gregorian datetime will be converted to Gregorian. 2) exported DateTimeProperty fields will contain the converted Gregorian datetime. 3) DateTimeProperty.source_calendar will be set to the calendar-system that was used to specify the non-Gregorian date. -
partialSecond
(type:float()
, default:nil
) - -
properties
(type:GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeDateTimeProperty.t
, default:nil
) - -
quarter
(type:String.t
, default:nil
) - -
rangeModifier
(type:String.t
, default:nil
) - Modifier that return the appropriate subrange. For more information, see the description of RangeOfDateTimeModifier. Example: early 2020 early on March 20th When a point have a range_modifier field, the resolution library will expand the point into the widest range in contains. For example, in the case of a single date point like "April 22nd, 2022", the point will be transformed into a range with: - "begin: April 22nd 2022 00:00:00h" - "end: April 22nd 2022 23:59:59h" The modifier will then be applied over that range. -
season
(type:String.t
, default:nil
) - -
second
(type:integer()
, default:nil
) - -
timezone
(type:String.t
, default:nil
) - A string representation of the timezone information, see i18n/identifiers/timezones.{h,cc}. -
weekday
(type:String.t
, default:nil
) - The |weekday| field is populated to indicate that a day-of-the-week is explicitly mentioned in an absolute date utterance, such as [Tuesday, July 6th, 2021]. Note that when a day-of-the-week is included in other, non-absolute-date expressions, such as [on Tuesday], then this this field is not populated (and in fact an AbsoluteDateTime is not used at all.) Note: This field is populated only when the original expression contains a day-of-the-week. It is not populated by the grounding library to indicate that the date happens to be a Tuesday. Examples: "Tuesday, July 6th 2021" --> the day of the week is part of an absolute date expression, so this field is populated: point { year: 2021 month: JULY day: 6 weekday: TUESDAY } "on Tuesday" --> the day of the week is not part of an absolute date expression, so it is interpreted as a relative datetime: relative { fetched { target { weekday: TUESDAY } } } -
year
(type:integer()
, default:nil
) - Date.
Summary
Functions
Unwrap a decoded JSON object into its complex fields.
Types
@type t() :: %GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeAbsoluteDateTime{ allowPersonal: boolean() | nil, day: integer() | nil, deleted11: String.t() | nil, holiday: GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeHoliday.t() | nil, hour: integer() | nil, hourState: String.t() | nil, isBc: boolean() | nil, meridiem: String.t() | nil, minute: integer() | nil, modifier: String.t() | nil, month: String.t() | nil, nonGregorianDate: GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeNonGregorianDate.t() | nil, partialSecond: float() | nil, properties: GoogleApi.ContentWarehouse.V1.Model.NlpSemanticParsingDatetimeDateTimeProperty.t() | nil, quarter: String.t() | nil, rangeModifier: String.t() | nil, season: String.t() | nil, second: integer() | nil, timezone: String.t() | nil, weekday: String.t() | nil, year: integer() | nil }
Functions
Unwrap a decoded JSON object into its complex fields.