array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'pt_BR', ), 'this' => array ( 0 => 'class.mongodb-driver-session.php', 1 => 'MongoDB\\Driver\\Session', ), 'up' => array ( 0 => 'book.mongodb.php', 1 => 'MongoDB\\Driver', ), 'prev' => array ( 0 => 'mongodb-driver-bulkwrite.update.php', 1 => 'MongoDB\\Driver\\BulkWrite::update', ), 'next' => array ( 0 => 'mongodb-driver-session.aborttransaction.php', 1 => 'MongoDB\\Driver\\Session::abortTransaction', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'en', 'path' => 'reference/mongodb/mongodb/driver/session.xml', ), 'extra_header_links' => array ( 'rel' => 'alternate', 'href' => '/manual/en/feeds/class.mongodb-driver-session.atom', 'type' => 'application/atom+xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(mongodb >=1.4.0)
The MongoDB\Driver\Session class represents a client session and is returned by MongoDB\Driver\Manager::startSession(). Commands, queries, and write operations may then be associated the session.
MongoDB\Driver\Session::TRANSACTION_NONE
There is no transaction in progress.
MongoDB\Driver\Session::TRANSACTION_STARTING
A transaction has been started, but no operation has been sent to the server.
MongoDB\Driver\Session::TRANSACTION_IN_PROGRESS
A transaction is in progress.
MongoDB\Driver\Session::TRANSACTION_COMMITTED
The transaction was committed.
MongoDB\Driver\Session::TRANSACTION_ABORTED
The transaction was aborted.