Skip to content

Commit 5686f9c

Browse files
GromNaNisfedorov
authored andcommitted
Add MongoDB\BSON\UTCDateTime::toDateTimeImmutable()
New method in ext-mongodb 1.20.0 https://www.php.net/manual/en/mongodb-bson-utcdatetime.todatetimeimmutable.php
1 parent b164b02 commit 5686f9c

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

mongodb/BSON/UTCDateTime.php

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,13 @@ public static function __set_state(array $properties) {}
2626
*/
2727
final public function toDateTime(): \DateTime {}
2828

29+
/**
30+
* Returns the DateTimeImmutable representation of this UTCDateTime
31+
* @since 1.20.0
32+
* @link https://php.net/manual/en/mongodb-bson-utcdatetime.todatetimeimmutable.php
33+
*/
34+
final public function toDateTimeImmutable(): \DateTimeImmutable {}
35+
2936
/**
3037
* Returns the string representation of this UTCDateTime
3138
* @link https://php.net/manual/en/mongodb-bson-utcdatetime.tostring.php

0 commit comments

Comments
 (0)