ftl.data.mongo.method.$$MongoRepositoryEstimatedDocumentCountsMethodBodyTemplateftl Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of rxmicro-annotation-processor-data-mongo Show documentation
Show all versions of rxmicro-annotation-processor-data-mongo Show documentation
The RxMicro Annotation Processor internal module that generates Mongo DB components.
<#-- -------------------------------------------------------------------------------------------------------- -->
<#if RETURN.mono>
return Mono.from(collection.estimatedDocumentCount());
<#-- -------------------------------------------------------------------------------------------------------- -->
<#elseif RETURN.future>
return new PublisherToRequiredMonoFutureAdapter<>(
collection.estimatedDocumentCount(),
useOptionalExceptionSupplier(${RETURN.simpleReactiveType}.class, ${RETURN.simpleResultType}.class)
);
<#-- -------------------------------------------------------------------------------------------------------- -->
<#elseif RETURN.single>
return Single.fromPublisher(collection.estimatedDocumentCount());
<#-- -------------------------------------------------------------------------------------------------------- -->
<#else>
//"The RxMicro framework does not know how to generate this method";
#if>
<#-- -------------------------------------------------------------------------------------------------------- -->