UPDATE packet

The UPDATE packet is sent by the client to update a document in a collection. Note that more recent applications tend to use an MSG packet instead. For more details, consult the MongoDB documentation.


Methods

String getFullCollectionName()
Returns the full name of the collection being updated.

void setFullCollectionName(String s)
Sets the full name of the collection being updated

int getUpdateFlags()
Returns the flags for this update, where 0x0001 means upsert, and 0x0002 means multi-update.

void setUpdateFlags(int flags)
Sets the flags for this update

object getSelector()
Returns a BSON document that specifies the query for the document to update. See the MongoDB documentation for details on the format of this object.

object getUpdate()
Returns a BSON document that specifies the update to be performed. See the MongoDB documentation for details on the format of this object.