Mercurial > hg > isophonics-drupal-site
comparison core/lib/Drupal/Component/Datetime/DateTimePlus.php @ 14:1fec387a4317
Update Drupal core to 8.5.2 via Composer
author | Chris Cannam |
---|---|
date | Mon, 23 Apr 2018 09:46:53 +0100 |
parents | 7a779792577d |
children | c2387f117808 |
comparison
equal
deleted
inserted
replaced
13:5fb285c0d0e3 | 14:1fec387a4317 |
---|---|
278 * (optional) \DateTimeZone object, time zone string or NULL. NULL uses the | 278 * (optional) \DateTimeZone object, time zone string or NULL. NULL uses the |
279 * default system time zone. Defaults to NULL. Note that the $timezone | 279 * default system time zone. Defaults to NULL. Note that the $timezone |
280 * parameter and the current timezone are ignored when the $time parameter | 280 * parameter and the current timezone are ignored when the $time parameter |
281 * either is a UNIX timestamp (e.g. @946684800) or specifies a timezone | 281 * either is a UNIX timestamp (e.g. @946684800) or specifies a timezone |
282 * (e.g. 2010-01-28T15:00:00+02:00). | 282 * (e.g. 2010-01-28T15:00:00+02:00). |
283 * @see http://php.net/manual/en/datetime.construct.php | 283 * @see http://php.net/manual/datetime.construct.php |
284 * @param array $settings | 284 * @param array $settings |
285 * (optional) Keyed array of settings. Defaults to empty array. | 285 * (optional) Keyed array of settings. Defaults to empty array. |
286 * - langcode: (optional) String two letter language code used to control | 286 * - langcode: (optional) String two letter language code used to control |
287 * the result of the format(). Defaults to NULL. | 287 * the result of the format(). Defaults to NULL. |
288 * - debug: (optional) Boolean choice to leave debug values in the | 288 * - debug: (optional) Boolean choice to leave debug values in the |
702 } | 702 } |
703 | 703 |
704 return $value; | 704 return $value; |
705 } | 705 } |
706 | 706 |
707 /** | |
708 * Sets the default time for an object built from date-only data. | |
709 * | |
710 * The default time for a date without time can be anything, so long as it is | |
711 * consistently applied. If we use noon, dates in most timezones will have the | |
712 * same value for in both the local timezone and UTC. | |
713 */ | |
714 public function setDefaultDateTime() { | |
715 $this->dateTimeObject->setTime(12, 0, 0); | |
716 } | |
717 | |
707 } | 718 } |