LookupExecutor

public class LookupExecutor

This class allows executing lookups by providing the lookup name as a string and the lookup params in name-value map. Used both by the REST api and the Databrowser UI for executing lookups based on only metadata. The dataservice and metadata must be provided during construction.

Constructors

LookupExecutor

public LookupExecutor(MotechDataService dataService, LookupDto lookup, Map<String, FieldDto> fieldsByName)

Methods

execute

public Object execute(Map<String, ?> lookupMap)

execute

public Object execute(Map<String, ?> lookupMap, QueryParams queryParams)

executeCount

public long executeCount(Map<String, ?> lookupMap)