文档菜单
文档首页
/ / /
PHP库手册
/

MongoDB数据库类

本页内容

  • 定义
  • 方法
MongoDB\Database

提供对数据库的常见操作方法,例如执行数据库命令和管理集合。

您可以直接使用扩展的MongoDB\Driver\Manager类或从库中选择一个数据库。MongoDB\Client类。也可以通过withOptions()方法从现有的MongoDB\Database对象克隆数据库。

MongoDB\Database supports the readConcern, readPreference, typeMap, and writeConcern options. If you omit an option, the database inherits the value from the Manager constructor argument or the Client object used to select the database.

MongoDB\Database类中的操作继承数据库的选项。

返回

watch()

本页内容