DropCollection
    
            
            in package
            
        
    
            
            implements
                            Executable                    
    
    
        
            Operation for the drop command.
Tags
Interfaces, Classes, Traits and Enums
- Executable
 
Table of Contents
- $collectionName : string
 - $databaseName : string
 - $errorCodeNamespaceNotFound : int
 - $options : array<string|int, mixed>
 - __construct() : mixed
 - Constructs a drop command.
 - execute() : array<string|int, mixed>|object
 - Execute the operation.
 - createOptions() : array<string|int, mixed>
 - Create options for executing the command.
 
Properties
$collectionName
    private
        string
    $collectionName
    
    
    
    
$databaseName
    private
        string
    $databaseName
    
    
    
    
$errorCodeNamespaceNotFound
    private
    static    int
    $errorCodeNamespaceNotFound
     = 26
    
    
    
$options
    private
        array<string|int, mixed>
    $options
    
    
    
    
Methods
__construct()
Constructs a drop command.
    public
                    __construct(string $databaseName, string $collectionName[, array<string|int, mixed> $options = [] ]) : mixed
        Supported options:
- 
session (MongoDB\Driver\Session): Client session.
 - 
typeMap (array): Type map for BSON deserialization. This will be used for the returned command result document.
 - 
writeConcern (MongoDB\Driver\WriteConcern): Write concern.
 
Parameters
- $databaseName : string
 - 
                    
Database name
 - $collectionName : string
 - 
                    
Collection name
 - $options : array<string|int, mixed> = []
 - 
                    
Command options
 
Tags
Return values
mixed —execute()
Execute the operation.
    public
                    execute(Server $server) : array<string|int, mixed>|object
    
        Parameters
- $server : Server
 
Tags
Return values
array<string|int, mixed>|object —Command result document
createOptions()
Create options for executing the command.
    private
                    createOptions() : array<string|int, mixed>