4 * Creates a new CommandResult instance
6 * @param {object} result CommandResult object
7 * @param {Connection} connection A connection instance associated with this result
8 * @return {CommandResult} A cursor instance
10 var CommandResult = function(result, connection, message) {
12 this.connection = connection;
13 this.message = message;
17 * Convert CommandResult to JSON
21 CommandResult.prototype.toJSON = function() {
26 * Convert CommandResult to String representation
30 CommandResult.prototype.toString = function() {
31 return JSON.stringify(this.toJSON());
34 module.exports = CommandResult;