# The MongoDB\Driver\WriteResult class

(mongodb >=1.0.0)

## はじめに

The MongoDB\Driver\WriteResult class encapsulates information about an executed MongoDB\Driver\BulkWrite and may be returned by MongoDB\Driver\Manager::executeBulkWrite().

## クラス概要

final MongoDB\Driver\WriteResult {
/* メソッド */
final public getDeletedCount ( void ) : integer|null
final public getInsertedCount ( void ) : integer|null
final public getMatchedCount ( void ) : integer|null
final public getModifiedCount ( void ) : integer|null
final public getServer ( void ) : MongoDB\Driver\Server
final public getUpsertedCount ( void ) : integer|null
final public getUpsertedIds ( void ) : array
final public getWriteConcernError ( void ) : MongoDB\Driver\WriteConcernError|null
final public getWriteErrors ( void ) : array
final public isAcknowledged ( void ) : bool
}

## 目次

- MongoDB\Driver\WriteResult::getDeletedCount — Returns the number of documents deleted
- MongoDB\Driver\WriteResult::getInsertedCount — Returns the number of documents inserted (excluding upserts)
- MongoDB\Driver\WriteResult::getMatchedCount — Returns the number of documents selected for update
- MongoDB\Driver\WriteResult::getModifiedCount — Returns the number of existing documents updated
- MongoDB\Driver\WriteResult::getServer — Returns the server associated with this write result
- MongoDB\Driver\WriteResult::getUpsertedCount — Returns the number of documents inserted by an upsert
- MongoDB\Driver\WriteResult::getUpsertedIds — Returns an array of identifiers for upserted documents
- MongoDB\Driver\WriteResult::getWriteConcernError — Returns any write concern error that occurred
- MongoDB\Driver\WriteResult::getWriteErrors — Returns any write errors that occurred
- MongoDB\Driver\WriteResult::isAcknowledged — Returns whether the write was acknowledged