Object Constructors and Methods对象构造函数和方法

Note注意

For details on specific methods, including syntax and examples, click on the specific method to go to its reference page.有关特定方法的详细信息,包括语法和示例,请单击特定方法以转到其参考页面。

Name名称Description描述
BulkWriteResult()Wrapper around the result set from Bulk.execute().包装来自Bulk.execute()的结果集。
Date()Creates a date object. 创建日期对象。By default creates a date object including the current date.默认情况下,创建包含当前日期的日期对象。
ObjectId()Returns an ObjectId.返回ObjectId
ObjectId.getTimestamp()Returns the timestamp portion of an ObjectId.返回ObjectId的时间戳部分。
ObjectId.toString()Displays the string representation of an ObjectId.显示ObjectId的字符串表示形式。
ObjectId.valueOf()Displays the str attribute of an ObjectId as a hexadecimal string.ObjectIdstr属性显示为十六进制字符串。
UUID()Converts a 32-byte hexadecimal string to the UUID BSON subtype.将32字节十六进制字符串转换为UUID BSON子类型。
WriteResult()Wrapper around the result set from write methods.包装来自写方法的结果集。
WriteResult.hasWriteError()Returns a boolean specifying whether the results include WriteResult.writeError.返回一个布尔值,指定结果是否包括WriteResult.writeError
WriteResult.hasWriteConcernError()Returns a boolean specifying whether whether the results include WriteResult.writeConcernError.返回一个布尔值,指定结果是否包含WriteResult.writeConcernError
←  db.getFreeMonitoringStatusBulkWriteResult() →