kmongo / org.litote.kmongo.coroutine / CoroutineCollection / withDocumentClass

withDocumentClass

fun <reified NewT : Any> withDocumentClass(): CoroutineCollection<NewT> (source)

Create a new MongoCollection instance with a different default class to cast any documents returned from the database into..

Parameters

Return
a new MongoCollection instance with the different default class