@@ -11,18 +11,21 @@ class Connection extends BaseConnection
1111{
1212 /**
1313 * The MongoDB database handler.
14+ *
1415 * @var \MongoDB\Database
1516 */
1617 protected $ db ;
1718
1819 /**
1920 * The MongoDB connection handler.
21+ *
2022 * @var \MongoDB\Client
2123 */
2224 protected $ connection ;
2325
2426 /**
2527 * Create a new database connection instance.
28+ *
2629 * @param array $config
2730 */
2831 public function __construct (array $ config )
@@ -53,6 +56,7 @@ public function __construct(array $config)
5356
5457 /**
5558 * Begin a fluent query against a database collection.
59+ *
5660 * @param string $collection
5761 * @return Query\Builder
5862 */
@@ -65,6 +69,7 @@ public function collection($collection)
6569
6670 /**
6771 * Begin a fluent query against a database collection.
72+ *
6873 * @param string $table
6974 * @param string|null $as
7075 * @return Query\Builder
@@ -76,6 +81,7 @@ public function table($table, $as = null)
7681
7782 /**
7883 * Get a MongoDB collection.
84+ *
7985 * @param string $name
8086 * @return Collection
8187 */
@@ -94,6 +100,7 @@ public function getSchemaBuilder()
94100
95101 /**
96102 * Get the MongoDB database object.
103+ *
97104 * @return \MongoDB\Database
98105 */
99106 public function getMongoDB ()
@@ -103,6 +110,7 @@ public function getMongoDB()
103110
104111 /**
105112 * return MongoDB object.
113+ *
106114 * @return \MongoDB\Client
107115 */
108116 public function getMongoClient ()
@@ -120,6 +128,7 @@ public function getDatabaseName()
120128
121129 /**
122130 * Get the name of the default database based on db config or try to detect it from dsn.
131+ *
123132 * @param string $dsn
124133 * @param array $config
125134 * @return string
@@ -140,6 +149,7 @@ protected function getDefaultDatabaseName($dsn, $config)
140149
141150 /**
142151 * Create a new MongoDB connection.
152+ *
143153 * @param string $dsn
144154 * @param array $config
145155 * @param array $options
@@ -175,6 +185,7 @@ public function disconnect()
175185
176186 /**
177187 * Determine if the given configuration array has a dsn string.
188+ *
178189 * @param array $config
179190 * @return bool
180191 */
@@ -185,6 +196,7 @@ protected function hasDsnString(array $config)
185196
186197 /**
187198 * Get the DSN string form configuration.
199+ *
188200 * @param array $config
189201 * @return string
190202 */
@@ -195,6 +207,7 @@ protected function getDsnString(array $config)
195207
196208 /**
197209 * Get the DSN string for a host / port configuration.
210+ *
198211 * @param array $config
199212 * @return string
200213 */
@@ -218,6 +231,7 @@ protected function getHostDsn(array $config)
218231
219232 /**
220233 * Create a DSN string from a configuration.
234+ *
221235 * @param array $config
222236 * @return string
223237 */
@@ -270,6 +284,7 @@ protected function getDefaultSchemaGrammar()
270284
271285 /**
272286 * Set database.
287+ *
273288 * @param \MongoDB\Database $db
274289 */
275290 public function setDatabase (\MongoDB \Database $ db )
@@ -279,6 +294,7 @@ public function setDatabase(\MongoDB\Database $db)
279294
280295 /**
281296 * Dynamically pass methods to the connection.
297+ *
282298 * @param string $method
283299 * @param array $parameters
284300 * @return mixed
0 commit comments