setWriteConcern() public method

Define write concern for all requests to current collection
public setWriteConcern ( string | integer $w, integer $timeout = 10000 ) : Collection
$w string | integer write concern
$timeout integer timeout in milliseconds
return Collection
示例#1
0
 public function testSetWriteConcern()
 {
     $this->collection->setWriteConcern('majority', 12000);
     $this->assertEquals(array('w' => 'majority', 'wtimeout' => 12000), $this->collection->getWriteConcern());
 }