MongoDB\BSON\UTCDateTime::__toString

Returns the string representation of this UTCDateTime

Beschreibung

final public string MongoDB\BSON\UTCDateTime::__toString ( void )

Parameter-Liste

Diese Funktion hat keine Parameter.

Rückgabewerte

Returns the string representation of this UTCDateTime.

Fehler/Exceptions

  • Throws MongoDB\Driver\InvalidArgumentException on argument parsing errors.

Beispiele

Beispiel #1 MongoDB\BSON\UTCDateTime::__toString example

<?php

$utcdatetime 
= new MongoDB\BSON\UTCDateTime(1416445411987);
var_dump((string) $utcdatetime);

?>

Das oben gezeigte Beispiel erzeugt folgende Ausgabe:

string(13) "1416445411987"