UNPKG

cql-execution

Version:

An execution framework for the Clinical Quality Language (CQL)

34 lines (26 loc) 955 B
// Generated by CoffeeScript 1.12.7 (function() { var Results; module.exports.Results = Results = (function() { function Results() { this.patientResults = {}; this.populationResults = {}; this.localIdPatientResultsMap = {}; } Results.prototype.recordPatientResult = function(patient_ctx, resultName, result) { var base, p, patientId; p = patient_ctx.patient; patientId = typeof p.getId === 'function' ? p.getId() : p.id(); if ((base = this.patientResults)[patientId] == null) { base[patientId] = {}; } this.patientResults[patientId][resultName] = result; return this.localIdPatientResultsMap[patientId] = patient_ctx.getAllLocalIds(); }; Results.prototype.recordPopulationResult = function(resultName, result) { return this.populationResults[resultName] = result; }; return Results; })(); }).call(this); //# sourceMappingURL=results.js.map