object BsonMagnets
A magnet pattern implementation enforcing the validity of user provided native values being able to be converted into BsonValues.
- Attributes
- protected
- Since
1.0
- Alphabetic
- By Inheritance
- BsonMagnets
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Type Members
-
sealed
trait
CanBeBsonElement extends AnyRef
Represents a single BsonElement
Represents a single BsonElement
This is essentially a
(String, BsonValue)
key value pair. Any pair of(String, T)
where typeT
has a BsonTransformer in scope into a BsonValue is also a valid pair. -
sealed
trait
CanBeBsonElements extends AnyRef
Represents a sequence of BsonElements
Represents a sequence of BsonElements
This is essentially a
Iterable[(String, BsonValue)]
of key value pairs. Any pair of(String, T)
where typeT
has a BsonTransformer in scope into a BsonValue is also a valid pair. -
sealed
trait
CanBeBsonValue extends AnyRef
Represents any single BsonValue
Represents any single BsonValue
This is a
BsonValue
or any type ofT
that has a BsonTransformer in scope for the given type.
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
implicit
def
iterableToCanBeBsonElements[T](elems: Iterable[(String, T)])(implicit transformer: BsonTransformer[T]): CanBeBsonElements
Implicitly converts any iterable of key/value pairs into a CanBeBsonElements.
Implicitly converts any iterable of key/value pairs into a CanBeBsonElements.
- T
the type of the values
- elems
the iterable of key/value pairs
- transformer
the implicit transformer for the values
- returns
CanBeBsonElements representing the key/value pairs
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
implicit
def
singleToCanBeBsonValue[T](v: T)(implicit transformer: BsonTransformer[T]): CanBeBsonValue
Implicitly converts type
T
to a BsonValue as long as there is a BsonTransformer in scope for the given type.Implicitly converts type
T
to a BsonValue as long as there is a BsonTransformer in scope for the given type.- T
the type of the initial value
- v
the initial value
- transformer
implicitly provided BsonTransformer that needs to be in scope for type
T
to be transformed into a BsonValue- returns
A CanBeBsonValue that holds the transformed BsonValue
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
implicit
def
tupleToCanBeBsonElement[T](kv: (String, T))(implicit transformer: BsonTransformer[T]): CanBeBsonElement
Implicitly converts key/value tuple of type (String, T) into a
CanBeBsonElement
Implicitly converts key/value tuple of type (String, T) into a
CanBeBsonElement
- T
the type of the value
- kv
the key value pair
- transformer
the implicit BsonTransformer for the value
- returns
a CanBeBsonElement representing the key/value pair
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @throws( ... )
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: