1 | <?php |
||
28 | class Command |
||
29 | { |
||
30 | |||
31 | use AvailableCommands; |
||
32 | |||
33 | /** |
||
34 | * @var AnnotatedInterface |
||
35 | */ |
||
36 | private $model; |
||
37 | |||
38 | /** |
||
39 | * @var Mangan |
||
40 | */ |
||
41 | private $mn; |
||
42 | |||
43 | /** |
||
44 | * @var string |
||
45 | */ |
||
46 | private $collection; |
||
47 | |||
48 | 13 | public function __construct(AnnotatedInterface $model = null, Mangan $mangan = null) |
|
63 | |||
64 | 2 | public function call($command, $arguments = []) |
|
92 | |||
93 | public function __call($name, $arguments) |
||
101 | |||
102 | /** |
||
103 | * Explicitly creates a collection or view. |
||
104 | * |
||
105 | * Parameter `$params` depends on MongoDB version, |
||
106 | * see (official documentation)[https://docs.mongodb.com/manual/reference/command/create/] for details |
||
107 | * |
||
108 | * @param string $collectionName The name of the new collection |
||
109 | * @param array $params |
||
110 | * @return array |
||
111 | */ |
||
112 | 1 | public function create($collectionName, $params = []) |
|
119 | |||
120 | 2 | public function createUser(User $user, $writeConcerns = []) |
|
134 | |||
135 | 2 | public function dropUser($username, $writeConcerns = []) |
|
146 | |||
147 | 8 | public function createIndex($keys, $options = []) |
|
156 | |||
157 | /** |
||
158 | * NOTE: This is broken |
||
159 | * @return array |
||
160 | * @throws Exceptions\ManganException |
||
161 | */ |
||
162 | public function getIndexes() |
||
166 | |||
167 | /** |
||
168 | * The `collStats` command returns a variety of storage statistics for a given collection. |
||
169 | * |
||
170 | * @param string $collectionName The name of the target collection. If the collection does not exist, collStats returns an error message. |
||
171 | * @param int $scale Optional. The scale used in the output to display the sizes of items. By default, output displays sizes in bytes. To display kilobytes rather than bytes, specify a scale value of 1024. The scale factor rounds values to whole numbers. |
||
172 | * @param boolean $verbose Optional. When true, collStats increases reporting for the MMAPv1 Storage Engine. Defaults to false. |
||
173 | * @return array |
||
174 | */ |
||
175 | 9 | public function collStats($collectionName, $scale = 1, $verbose = false) |
|
184 | |||
185 | } |
||
186 |
This check looks from parameters that have been defined for a function or method, but which are not used in the method body.