Package | Description |
---|---|
com.mongodb.client |
This package contains client interfaces
|
Modifier and Type | Method and Description |
---|---|
MongoCollection<Document> |
MongoDatabase.getCollection(String collectionName)
Gets a collection.
|
<TDocument> |
MongoDatabase.getCollection(String collectionName,
Class<TDocument> documentClass)
Gets a collection, with a specific default document class.
|
MongoCollection<TDocument> |
MongoCollection.withCodecRegistry(CodecRegistry codecRegistry)
Create a new MongoCollection instance with a different codec registry.
|
<NewTDocument> |
MongoCollection.withDocumentClass(Class<NewTDocument> clazz)
Create a new MongoCollection instance with a different default class to cast any documents returned from the database into..
|
MongoCollection<TDocument> |
MongoCollection.withReadConcern(ReadConcern readConcern)
Create a new MongoCollection instance with a different read concern.
|
MongoCollection<TDocument> |
MongoCollection.withReadPreference(ReadPreference readPreference)
Create a new MongoCollection instance with a different read preference.
|
MongoCollection<TDocument> |
MongoCollection.withWriteConcern(WriteConcern writeConcern)
Create a new MongoCollection instance with a different write concern.
|
Copyright © 2016. All Rights Reserved.