fun fields(vararg projections: Bson): Bson
(source)
Creates a projection that combines the list of projections into a single one. If there are duplicate keys, the last one takes precedence.
projections
- the list of projections to combine
Return
the combined projection
fun fields(projections: List<Bson>): Bson
(source)
Creates a projection that combines the list of projections into a single one. If there are duplicate keys, the last one takes precedence.
projections
- the list of projections to combine
Return
the combined projection
Mongodb
.driver.manual