Retrieves a collection, creating it if not cached.
Retrieves a collection, creating it if not cached.
of the collection
optional collection options
the collection instance
Closes the connection
Closes the connection
A hash of the collections associated with this connection
A hash of the global options that are associated with this connection
The mongodb.Db instance, set when the connection is opened
Models defined on the mongoose instance are available to all connection created by the same mongoose instance.
Models defined on the mongoose instance are available to all connection created by the same mongoose instance.
the model name or class extending Model
the schema
the name (optional, inferred from model name)
indicates whether to skip initialization (defaults to false)
the model
Returns an array of model names created on this instance of Mongoose.
Returns an array of model names created on this instance of Mongoose.
an array of model names
Declares a global plugin executed on all Schemas.
Declares a global plugin executed on all Schemas.
the plugin callback
the optional options
Connection ready state
Connection ready state
Each state change emits its associated event name.
Sets mongoose options
Sets mongoose options
the options key
the the value to set or function
Mongoose Connection