1 /** 2 MongoDB operation flag definitions. 3 4 Copyright: © 2012-2016 Sönke Ludwig 5 License: Subject to the terms of the MIT license, as written in the included LICENSE.txt file. 6 Authors: Sönke Ludwig 7 */ 8 module vibe.db.mongo.flags; 9 10 deprecated public import vibe.db.mongo.impl.index : IndexFlags; 11 12 enum UpdateFlags { 13 none = 0, /// Normal update of a single document. 14 upsert = 1<<0, /// Creates a document if none exists. 15 multiUpdate = 1<<1, /// Updates all matching documents. 16 17 None = none, /// Deprecated compatibility alias 18 Upsert = upsert, /// Deprecated compatibility alias 19 MultiUpdate = multiUpdate /// Deprecated compatibility alias 20 } 21 22 enum InsertFlags { 23 none = 0, /// Normal insert. 24 continueOnError = 1<<0, /// For multiple inserted documents, continues inserting further documents after a failure. 25 26 None = none, /// Deprecated compatibility alias 27 ContinueOnError = continueOnError /// Deprecated compatibility alias 28 } 29 30 enum QueryFlags { 31 none = 0, /// Normal query 32 tailableCursor = 1<<1, /// 33 slaveOk = 1<<2, /// 34 oplogReplay = 1<<3, /// 35 noCursorTimeout = 1<<4, /// 36 awaitData = 1<<5, /// 37 exhaust = 1<<6, /// 38 partial = 1<<7, /// 39 40 None = none, /// Deprecated compatibility alias 41 TailableCursor = tailableCursor, /// Deprecated compatibility alias 42 SlaveOk = slaveOk, /// Deprecated compatibility alias 43 OplogReplay = oplogReplay, /// Deprecated compatibility alias 44 NoCursorTimeout = noCursorTimeout, /// Deprecated compatibility alias 45 AwaitData = awaitData, /// Deprecated compatibility alias 46 Exhaust = exhaust, /// Deprecated compatibility alias 47 Partial = partial /// Deprecated compatibility alias 48 } 49 50 enum DeleteFlags { 51 none = 0, 52 singleRemove = 1<<0, 53 54 None = none, /// Deprecated compatibility alias 55 SingleRemove = singleRemove /// Deprecated compatibility alias 56 } 57 58 enum ReplyFlags { 59 none = 0, 60 cursorNotFound = 1<<0, 61 queryFailure = 1<<1, 62 shardConfigStale = 1<<2, 63 awaitCapable = 1<<3, 64 65 None = none, /// Deprecated compatibility alias 66 CursorNotFound = cursorNotFound, /// Deprecated compatibility alias 67 QueryFailure = queryFailure, /// Deprecated compatibility alias 68 ShardConfigStale = shardConfigStale, /// Deprecated compatibility alias 69 AwaitCapable = awaitCapable /// Deprecated compatibility alias 70 }