Moodle PHP Documentation 4.1
Moodle 4.1.11 (Build: 20240610) (c8c84b4af18)
MongoDB\DeleteResult Class Reference

Public Member Functions

 __construct (WriteResult $writeResult)
 
 getDeletedCount ()
 Return the number of documents that were deleted.
 
 isAcknowledged ()
 Return whether this delete was acknowledged by the server.
 

Member Function Documentation

◆ getDeletedCount()

MongoDB\DeleteResult::getDeletedCount ( )

Return the number of documents that were deleted.

This method should only be called if the write was acknowledged.

See also
DeleteResult\isAcknowledged()
Return values
integer|null
Exceptions
BadMethodCallExceptionis the write result is unacknowledged

◆ isAcknowledged()

MongoDB\DeleteResult::isAcknowledged ( )

Return whether this delete was acknowledged by the server.

If the delete was not acknowledged, other fields from the WriteResult (e.g. deletedCount) will be undefined.

Return values
boolean

The documentation for this class was generated from the following file: