| @@ 310-317 (lines=8) @@ | ||
| 307 | * |
|
| 308 | * @return array |
|
| 309 | */ |
|
| 310 | public function getDeleteDiff() |
|
| 311 | { |
|
| 312 | return array_udiff_assoc( |
|
| 313 | $this->snapshot, |
|
| 314 | $this->coll->toArray(), |
|
| 315 | function ($a, $b) { return $a === $b ? 0 : 1; } |
|
| 316 | ); |
|
| 317 | } |
|
| 318 | ||
| 319 | /** |
|
| 320 | * INTERNAL: get objects that were removed, unlike getDeleteDiff this doesn't care about indices. |
|
| @@ 345-352 (lines=8) @@ | ||
| 342 | * |
|
| 343 | * @return array |
|
| 344 | */ |
|
| 345 | public function getInsertDiff() |
|
| 346 | { |
|
| 347 | return array_udiff_assoc( |
|
| 348 | $this->coll->toArray(), |
|
| 349 | $this->snapshot, |
|
| 350 | function ($a, $b) { return $a === $b ? 0 : 1; } |
|
| 351 | ); |
|
| 352 | } |
|
| 353 | ||
| 354 | /** |
|
| 355 | * INTERNAL: |
|