Interface RemoteMongoDatabase
-
- All Known Implementing Classes:
RemoteMongoDatabaseImpl
public interface RemoteMongoDatabase
The RemoteMongoDatabase interface.
-
-
Method Summary
Modifier and Type Method Description RemoteMongoCollection<Document>
getCollection(String collectionName)
Gets a collection.<DocumentT>
RemoteMongoCollection<DocumentT>getCollection(String collectionName, Class<DocumentT> documentClass)
Gets a collection, with a specific default document class.String
getName()
Gets the name of the database.
-
-
-
Method Detail
-
getName
String getName()
Gets the name of the database.- Returns:
- the database name
-
getCollection
RemoteMongoCollection<Document> getCollection(String collectionName)
Gets a collection.- Parameters:
collectionName
- the name of the collection to return- Returns:
- the collection
-
getCollection
<DocumentT> RemoteMongoCollection<DocumentT> getCollection(String collectionName, Class<DocumentT> documentClass)
Gets a collection, with a specific default document class.- Type Parameters:
DocumentT
- the type of the class to use instead ofDocument
.- Parameters:
collectionName
- the name of the collection to returndocumentClass
- the default class to cast any documents returned from the database into.- Returns:
- the collection
-
-