GoLang MongoDB\BSON\Timestamp::jsonSerialize

request it (321)
GoLang replacement for PHP's MongoDB\BSON\Timestamp::jsonSerialize [edit | history]



Do you know a GoLang replacement for PHP's MongoDB\BSON\Timestamp::jsonSerialize? Write it!

PHP MongoDB\BSON\Timestamp::jsonSerialize

PHP original manual for MongoDB\BSON\Timestamp::jsonSerialize [ show | php.net ]

MongoDB\BSON\Timestamp::jsonSerialize

(mongodb >=1.2.0)

MongoDB\BSON\Timestamp::jsonSerializeReturns a representation that can be converted to JSON

Description

final public mixed MongoDB\BSON\Timestamp::jsonSerialize ( void )

Parameters

This function has no parameters.

Return Values

Returns data which can be serialized by json_encode() to produce an extended JSON representation of the MongoDB\BSON\Timestamp.

The output is consistent with the MongoDB\BSON\toJSON() function, which represents the driver specifc legacy extended JSON format, which does not necessarily match the relaxed or » canonical extended JSON representation.

Errors/Exceptions

See Also