template here is of type CouchbaseTemplate, Im using Spring integrated with couch base. The javadoc for findViewById says
"Query a View for a list of documents of type T.
There is no need to Query.setIncludeDocs(boolean) explicitely, because it will be set to true all the time. It is valid to pass in a empty constructed Query object.
This method does not work with reduced views, because they by design do not contain references to original objects. Use the provided queryView method for more flexibility and direct access.
Specified by: findByView(…) in CouchbaseOperations
designName the name of the design document.
viewName the name of the viewName.
query the Query object to customize the viewName query.
entityClass the entity to map to.
the converted collection"