1 | <?php |
||
16 | class BatchInsert extends BatchOperation |
||
17 | { |
||
18 | protected $batchClass = '\MongoInsertBatch'; |
||
19 | |||
20 | private $isValidationEnabled = true; |
||
21 | |||
22 | /** |
||
23 | * Used for validating array of data |
||
24 | * @var Document |
||
25 | */ |
||
26 | private static $validator; |
||
27 | |||
28 | public function __construct(Collection $collection, $writeConcern = null, $timeout = null, $ordered = null) |
||
34 | |||
35 | public function enableValidation() |
||
40 | |||
41 | public function disableValidation() |
||
46 | |||
47 | public function isValidationEnabled() |
||
51 | |||
52 | /** |
||
53 | * @deprecated use self::isValidationEnabled() |
||
54 | * @return bool |
||
55 | */ |
||
56 | public function isValidationEbabled() |
||
60 | |||
61 | public function insert(array $document) |
||
76 | } |
||
77 |