package bson
The bson package, contains mirrors and companion objects for Bson
values.
- Alphabetic
- By Inheritance
- bson
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
type
BsonArray = bson.BsonArray
Alias to
org.bson.BsonArray
-
type
BsonBinary = bson.BsonBinary
Alias to
org.bson.BsonBinary
-
type
BsonBoolean = bson.BsonBoolean
Alias to
org.bson.BsonBoolean
-
type
BsonDateTime = bson.BsonDateTime
Alias to
org.bson.BsonDateTime
-
type
BsonDecimal128 = bson.BsonDecimal128
Alias to
org.bson.BsonDecimal128
Alias to
org.bson.BsonDecimal128
- Since
1.2
-
type
BsonDocument = bson.BsonDocument
Alias to
org.bson.BsonDocument
-
type
BsonDouble = bson.BsonDouble
Alias to
org.bson.BsonDouble
-
type
BsonElement = bson.BsonElement
Alias to
org.bson.BsonElement
-
type
BsonInt32 = bson.BsonInt32
Alias to
org.bson.BsonInt32
-
type
BsonInt64 = bson.BsonInt64
Alias to
org.bson.BsonInt64
-
type
BsonJavaScript = bson.BsonJavaScript
Alias to
org.bson.BsonJavaScript
-
type
BsonJavaScriptWithScope = bson.BsonJavaScriptWithScope
Alias to
org.bson.BsonJavaScriptWithScope
-
type
BsonMaxKey = bson.BsonMaxKey
Alias to
org.bson.BsonMaxKey
-
type
BsonMinKey = bson.BsonMinKey
Alias to
org.bson.BsonMinKey
-
type
BsonNull = bson.BsonNull
Alias to
org.bson.BsonNull
-
type
BsonNumber = bson.BsonNumber
Alias to
org.bson.BsonNumber
-
type
BsonObjectId = bson.BsonObjectId
Alias to
org.bson.BsonObjectId
-
type
BsonRegularExpression = bson.BsonRegularExpression
Alias to
org.bson.BsonRegularExpression
-
type
BsonString = bson.BsonString
Alias to
org.bson.BsonString
-
type
BsonSymbol = bson.BsonSymbol
Alias to
org.bson.BsonSymbol
-
type
BsonTimestamp = bson.BsonTimestamp
Alias to
org.bson.BsonTimestamp
-
trait
BsonTransformer[-T] extends AnyRef
BsonTransformers allow the transformation of type
T
to their corresponding BsonValue.BsonTransformers allow the transformation of type
T
to their corresponding BsonValue.Custom implementations can be written to implicitly to convert a
T
into a BsonValue so it can be stored in aDocument
.- T
the type of value to be transformed into a BsonValue.
- Annotations
- @implicitNotFound( ... )
- Since
1.0
-
type
BsonUndefined = bson.BsonUndefined
Alias to
org.bson.BsonUndefined
-
type
BsonValue = bson.BsonValue
Alias to
org.bson.BsonValue
-
type
Decimal128 = bson.types.Decimal128
Alias to
org.bson.Decimal128
Alias to
org.bson.Decimal128
- Since
1.2
-
trait
DefaultBsonTransformers extends AnyRef
Default BsonTransformers for native types.
-
type
Document = bson.collection.immutable.Document
An immutable Document implementation.
An immutable Document implementation.
A strictly typed
Map[String, BsonValue]
like structure that traverses the elements in insertion order. Unlike native scala maps there is no variance in the value type and it always has to be aBsonValue
. -
type
ObjectId = bson.types.ObjectId
Alias to
org.bson.ObjectId
Alias to
org.bson.ObjectId
- Since
1.2
-
implicit final
class
RichBsonElement extends AnyVal
Implicit value class for a BsonElement allowing easy access to the key/value pair
Value Members
-
val
Document: bson.collection.immutable.Document.type
An immutable Document implementation.
An immutable Document implementation.
A strictly typed
Map[String, BsonValue]
like structure that traverses the elements in insertion order. Unlike native scala maps there is no variance in the value type and it always has to be aBsonValue
. -
object
BsonArray
Companion helper for a BsonArray
Companion helper for a BsonArray
- Since
1.0
-
object
BsonBinary
Companion helper for a BsonBinary
Companion helper for a BsonBinary
- Since
1.0
-
object
BsonBoolean
Companion helper for a BsonBoolean
Companion helper for a BsonBoolean
- Since
1.0
-
object
BsonDateTime
Companion helper for a BsonDateTime
Companion helper for a BsonDateTime
- Since
1.0
-
object
BsonDecimal128
Companion helper for a BsonDecimal128
Companion helper for a BsonDecimal128
- Since
1.2
-
object
BsonDocument
Companion helper for a BsonDocument
Companion helper for a BsonDocument
- Since
1.0
-
object
BsonDouble
Companion helper for a BsonDouble
Companion helper for a BsonDouble
- Since
1.0
-
object
BsonElement
A companion helper for a
BsonElement
- the mapping from a name to a BsonValue.A companion helper for a
BsonElement
- the mapping from a name to a BsonValue.Used by the BsonMagnets and polices valid key/value pairs types for Document.
- Since
1.0
-
object
BsonInt32
Companion helper for a BsonInt32
Companion helper for a BsonInt32
- Since
1.0
-
object
BsonInt64
Companion helper for a BsonInt64
Companion helper for a BsonInt64
- Since
1.0
-
object
BsonJavaScript
Companion helper for a BsonJavaScript
Companion helper for a BsonJavaScript
- Since
1.0
-
object
BsonJavaScriptWithScope
Companion helper for a BsonJavaScriptWithScope
Companion helper for a BsonJavaScriptWithScope
- Since
1.0
-
object
BsonMagnets
A magnet pattern implementation enforcing the validity of user provided native values being able to be converted into BsonValues.
A magnet pattern implementation enforcing the validity of user provided native values being able to be converted into BsonValues.
- Attributes
- protected
- Since
1.0
-
object
BsonMaxKey
Companion helper for a BsonMaxKey
Companion helper for a BsonMaxKey
- Since
1.0
-
object
BsonMinKey
Companion helper for a BsonMinKey
Companion helper for a BsonMinKey
- Since
1.0
-
object
BsonNull
Companion helper for a BsonNull
Companion helper for a BsonNull
- Since
1.0
-
object
BsonNumber
Companion helper for a BsonNumber
Companion helper for a BsonNumber
- Since
1.0
-
object
BsonObjectId
Companion helper for a BsonObjectId
Companion helper for a BsonObjectId
- Since
1.0
-
object
BsonRegularExpression
Companion helper for a BsonRegularExpression
Companion helper for a BsonRegularExpression
- Since
1.0
-
object
BsonString
Companion helper for a BsonString
Companion helper for a BsonString
- Since
1.0
-
object
BsonSymbol
Companion helper for a BsonSymbol
Companion helper for a BsonSymbol
- Since
1.0
-
object
BsonTimestamp
Companion helper for a BsonTimestamp
Companion helper for a BsonTimestamp
- Since
1.0
-
object
BsonTransformer extends DefaultBsonTransformers
Maps the following native scala types to BsonValues:
Maps the following native scala types to BsonValues:
BsonValue => BsonValue
BigDecimal
=> BsonDecimal128Boolean => BsonBoolean
String => BsonString
Array[Byte] => BsonBinary
Regex => BsonRegex
Date => BsonDateTime
Decimal128
=> BsonDecimal128ObjectId => BsonObjectId
Int => BsonInt32
Long => BsonInt64
Double => BsonDouble
None => BsonNull
immutable.Document => BsonDocument
mutable.Document => BsonDocument
Option[T] => BsonValue
whereT
is one of the above typesSeq[(String, T)] => BsonDocument
whereT
is one of the above typesSeq[T] => BsonArray
whereT
is one of the above types
-
object
BsonUndefined
Companion helper for a BsonUndefined
Companion helper for a BsonUndefined
- Since
1.0
-
object
DefaultHelper
A helper containing the sealed
DefaultsTo
trait which is used to determine the default type for a given method.A helper containing the sealed
DefaultsTo
trait which is used to determine the default type for a given method.- Attributes
- protected[org.mongodb.scala]
- Since
1.0
This is the documentation for the MongoDB Scala driver.
Driver structure
The mongodb scala driver.
To get started you need a MongoClient instance, either from a connection string or via a org.mongodb.scala.MongoClientSettings.
Notable packages include: