1 | <?php |
||
20 | class CollectionHelper |
||
21 | { |
||
22 | public const DEFAULT_STRATEGY = ClassMetadata::STORAGE_STRATEGY_PUSH_ALL; |
||
23 | |||
24 | public function __construct() |
||
32 | |||
33 | /** |
||
34 | * Returns whether update query must be included in query updating owning document. |
||
35 | */ |
||
36 | 267 | public static function isAtomic(string $strategy) : bool |
|
40 | |||
41 | /** |
||
42 | * Returns whether Collection hold associative array. |
||
43 | */ |
||
44 | 204 | public static function isHash(string $strategy) : bool |
|
48 | |||
49 | /** |
||
50 | * Returns whether Collection hold array indexed by consecutive numbers. |
||
51 | */ |
||
52 | 397 | public static function isList(?string $strategy) : bool |
|
56 | |||
57 | /** |
||
58 | * Returns whether strategy uses $set to update its data. |
||
59 | */ |
||
60 | 1020 | public static function usesSet(string $strategy) : bool |
|
72 | } |
||
73 |
If you suppress an error, we recommend checking for the error condition explicitly: