Trait to provide the $all (Match ALL In Array) method on appropriate callers.
Trait to provide the $and method as a bareword operator.
Trait to provide the $and method as a bareword operator.
$and ("Foo" -> "bar")
Targets an RValue of (String, Any)* to be converted to a DBObject
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24and
Base Operator class for Bareword Operators.
Base Operator class for Bareword Operators.
Bareword operators stand on their own - they lack the requirement for an LValue.
Operator implementations (see SetOp for an example) should partially apply with just their operator name. The apply method's type parameter can be used to restrict the valid RValue values at will.
1.0
SetOp
Trait to provide the $bit (bit) update method as a bareword Operator
Trait to provide the $bit (bit) update method as a bareword Operator
Bit does a bitwise operation either AND or OR against a given field or set of fields with no left anchor.
Targets an RValue of {field: {and|or: integer}}.
2.1.1
http://www.mongodb.org/display/DOCS/Updating#Updating-%24bit
Trait to provide the $within geospatial search method on appropriate callers
Trait to provide the $within geospatial search method on appropriate callers
Note that the args aren't TECHNICALLY latitude and longitude as they depend on: a) the order you specified your actual index in b) if you're using actual world maps or something else
Deprecated in MongoDB 2.4 use $geoWithin instead
2.0
http://www.mongodb.org/display/DOCS/Geospatial+Indexing
Trait to provide the $elemMatch method on appropriate callers.
Trait to provide the $elemMatch method on appropriate callers.
Targets (takes a right-hand value of) a DBObject view context
2.0
http://www.mongodb.org/display/DOCS/Dot+Notation+(Reaching+into+Objects)#DotNotation%28ReachingintoObjects%29-Matchingwith%24elemMatch
Trait to provide an equals method on appropriate callers.
Trait to provide an equals method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.
Trait to provide the $exists (Exists) method on appropriate callers.
Trait to provide the $exists (Exists) method on appropriate callers.
Targets (takes a right-hand value of) Booleans.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%7B%7B%24exists%7D%7D
Aggregation object for Bareword Operators.
Aggregation object for Bareword Operators. Bareword operators stand on their own - they lack the requirement for an LValue. This mixes them in so they can be pulled down in a single import.
Typically, you want to follow the model Implicits does, and mix this in if you want to use it but not import Implicits
1.0
com.mongodb.casbah.Implicits
Mixed trait which provides all possible operators.
Mixed trait which provides all possible operators. See Implicits for examples of usage.
Trait to provide the $intersects geospatial search method on appropriate callers
Trait to provide the $intersects geospatial search method on appropriate callers
2.6.2
http://www.mongodb.org/display/DOCS/Geospatial+Indexing
Trait to provide the $near geospatial search method on appropriate callers
Trait to provide the $near geospatial search method on appropriate callers
Note that the args aren't TECHNICALLY latitude and longitude as they depend on: a) the order you specified your actual index in b) if you're using actual world maps or something else
2.0
http://www.mongodb.org/display/DOCS/Geospatial+Indexing
Trait to provide the $nearSphere geospatial search method on appropriate callers
Trait to provide the $nearSphere geospatial search method on appropriate callers
Note that the args aren't TECHNICALLY latitude and longitude as they depend on: a) the order you specified your actual index in b) if you're using actual world maps or something else
2.0
http://www.mongodb.org/display/DOCS/Geospatial+Indexing
Trait to provide the nested $geoWithin geospatial search method on appropriate callers
Trait to provide the nested $geoWithin geospatial search method on appropriate callers
Note that the args aren't TECHNICALLY latitude and longitude as they depend on: a) the order you specified your actual index in b) if you're using actual world maps or something else
2.6.2
http://www.mongodb.org/display/DOCS/Geospatial+Indexing
Trait to provide the $gte (Greater Than Or Equal To) method on appropriate callers.
Trait to provide the $gte (Greater Than Or Equal To) method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, JDK And Joda Dates, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.*
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%3C%2C%3C%3D%2C%3E%2C%3E%3D
Trait to provide the $gt (Greater Than) method on appropriate callers.
Trait to provide the $gt (Greater Than) method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, JDK And Joda Dates, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.*
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%3C%2C%3C%3D%2C%3E%2C%3E%3D
Trait to provide the $in (In Array) method on appropriate callers.
Trait to provide the $in (In Array) method on appropriate callers.
Targets (takes a right-hand value of) Arrays of [Any] and variable argument lists of Any.
Note that the magic of Scala DSLey-ness means that you can write a method such as:
var x = "foo" $in (1, 2, 3, 5, 28)
As a valid statement - (1...28) is taken as the argument list to $in and converted to an Array under the covers.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24in
Trait to provide the $inc (inc) method as a bareword operator..
Trait to provide the $inc (inc) method as a bareword operator..
$inc ("foo" -> 5)
Targets an RValue of (String, ValidNumericType)* to be converted to a DBObject
Due to a quirk in the way I implemented type detection this fails if you mix ValidNumericType types. E.g. floats work, but not mixing floats and ints. This can be easily circumvented if you want 'ints' with floats by making your ints floats with .0:
$inc ("foo" -> 5.0, "bar" -> 1.6)
1.0
http://www.mongodb.org/display/DOCS/Updating#Updating-%24inc
Trait to provide the $lte (Less Than Or Equal To) method on appropriate callers.
Trait to provide the $lte (Less Than Or Equal To) method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, JDK And Joda Dates, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.*
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%3C%2C%3C%3D%2C%3E%2C%3E%3D
Trait to provide the $lt (Less Than) method on appropriate callers.
Trait to provide the $lt (Less Than) method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, JDK And Joda Dates, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%3C%2C%3C%3D%2C%3E%2C%3E%3D
Trait providing a projection / sort helper for use with text search
Trait providing a projection / sort helper for use with text search
To be used alongside $text and a text index to project / sort via the text match score.
> $text("hello") res0: { "$text" : { "$search" : "hello"}}
> $text("hola") $language "spanish" res1: { "$text" : { "$search" : "hola" , "$language" : "spanish"}}
2.7
http://docs.mongodb.org/manual/core/index-text/
Trait to provide the $mod (Modulo) method on appropriate callers.
Trait to provide the $mod (Modulo) method on appropriate callers.
Targets a left and right value where the formula is (field % left == right)
Left and Right can be any ValidNumericType and of two differing types (e.g. one int, one float)
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24mod
Trait to provide the $nor (nor) method as a bareword operator
Trait to provide the $nor (nor) method as a bareword operator
Nor is a combination of $not and $or with no left anchor
Targets an RValue of (String, Array[Any])* to be converted to a DBObject
2.0
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24nor
Trait to provide the $ne (Not Equal To) method on appropriate callers.
Trait to provide the $ne (Not Equal To) method on appropriate callers.
Targets (takes a right-hand value of) String, Numeric, Array, DBObject (and DBList), Iterable[_] and Tuple1->22.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24ne
Trait to provide the $nin (NOT In Array) method on appropriate callers.
Trait to provide the $nin (NOT In Array) method on appropriate callers.
Targets (takes a right-hand value of) Arrays of [Any] and variable argument lists of Any.
Note that the magic of Scala DSLey-ness means that you can write a method such as:
var x = "foo" $nin (1, 2, 3, 5, 28)
As a valid statement - (1...28) is taken as the argument list to $nin and converted to an Array under the covers.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24nin
Trait to provide the $not (Not) negation method on appropriate callers.
Trait to provide the $not (Not) negation method on appropriate callers.
Make sure your anchor it when you have multiple operators e.g.
"foo".$not $mod(5, 10)
Targets (takes a right-hand value of) DBObject or a Scala RegEx
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-Metaoperator%3A%24not
Trait to provide the $or method as a bareword operator.
Trait to provide the $or method as a bareword operator.
$or ("Foo" -> "bar")
Targets an RValue of (String, Any)* to be converted to a DBObject
2.0
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24or
Base trait for QueryOperators, children are required to define a value for field, which is a String and refers to the left-hand of the Query (e.g.
Base trait for QueryOperators, children
are required to define a value for field, which is a String
and refers to the left-hand of the Query (e.g. in Mongo:
{"foo": {"$ne": "bar"}}
"foo" is the field.
$regex operator to query by type.
$regex operator to query by type.
Takes a string for use in the $regex query
"foo" $regex "\^bar$"
2.6.2
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%7B%7B%24type%7D%7D
Trait to provide the $rename (Rename field) as a bareword operator
Trait to provide the $rename (Rename field) as a bareword operator
Targets (takes a right-hand value of) a DBObject or a Tuple of (String, String)
WORKS ONLY IN MONGODB 1.7.2+
2.0
http://www.mongodb.org/display/DOCS/Updating#Updating-%24rename
Trait to provide the $text search method on appropriate callers
Trait to provide the $text search method on appropriate callers
> $text("description") res0: { "$text" : { "$search" : "description"}}
> $text("description") $language "english" res1: { "$text" : { "$search" : "description" , "$language" : "english"}}
2.7
http://docs.mongodb.org/manual/core/index-text/
Trait to provide the $setOnInsert (SetOnInsert) SetOnInsert method as a bareword operator.
Trait to provide the $setOnInsert (SetOnInsert) SetOnInsert method as a bareword operator.
$setOnInsert ("Foo" -> "bar")
Targets an RValue of (String, Any)* to be converted to a DBObject
http://www.mongodb.org/display/DOCS/Updating#Updating-%24set
Trait to provide the $set (Set) Set method as a bareword operator.
Trait to provide the $set (Set) Set method as a bareword operator.
$set ("Foo" -> "bar")
Targets an RValue of (String, Any)* to be converted to a DBObject
http://www.mongodb.org/display/DOCS/Updating#Updating-%24set
Trait to provide the $size (Size) method on appropriate callers.
Trait to provide the $size (Size) method on appropriate callers.
Test value must be an Int.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24size
Trait to provide the $slice (Slice of Array) method on appropriate callers.
Trait to provide the $slice (Slice of Array) method on appropriate callers.
Targets (takes a right-hand value of) either an Int of slice indicator or a tuple of skip and limit.
> "foo" $slice 5 res0: (String, com.mongodb.DBObject) = (foo,{ "$slice" : 5})
> "foo" $slice (5, -1) res1: (String, com.mongodb.DBObject) = (foo,{ "$slice" : [ 5 , -1]})
2.0
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24sliceoperator
$type operator to query by type.
$type operator to query by type.
Can type a BSON.<enum value> or a Context Bounded check.
2.0
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%7B%7B%24type%7D%7D
Trait to provide the $unset (UnSet) UnSet method as a bareword operator..
Trait to provide the $unset (UnSet) UnSet method as a bareword operator..
$unset ("foo")
Targets an RValue of String*, where String are field names to be converted to a DBObject
http://www.mongodb.org/display/DOCS/Updating#Updating-%24unset
Trait to provide the $where (Where) method on appropriate callers.
Trait to provide the $where (Where) method on appropriate callers.
Targets (takes a right-hand value of) JSFunction [which is currently just as string containing a javascript function]
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-JavascriptExpressionsand%7B%7B%24where%7D%7D
Trait to provide the $all (Match ALL In Array) method on appropriate callers.
Targets (takes a right-hand value of) Arrays of [Any] and variable argument lists of Any.
Note that the magic of Scala DSLey-ness means that you can write a method such as:
var x = "foo" $all (1, 2, 3, 5, 28)
As a valid statement - (1...28) is taken as the argument list to $all and converted to an Array under the covers.
http://www.mongodb.org/display/DOCS/Advanced+Queries#AdvancedQueries-%24all