UNPKG

@phema/cql-execution

Version:

An execution framework for the Clinical Quality Language (CQL)

272 lines (188 loc) 7.01 kB
// Generated by CoffeeScript 1.12.7 (function() { var Address, Attachment, BackboneElement, CORE, CodeableConcept, Coding, ContactPoint, DT, DomainResource, Element, ElementDefinition, Extension, Group, GroupCharacteristicComponent, HumanName, Identifier, Narrative, Parameters, Period, Quantity, Range, Ratio, Reference, Resource, SampledData, Timing, extend = function(child, parent) { for (var key in parent) { if (hasProp.call(parent, key)) child[key] = parent[key]; } function ctor() { this.constructor = child; } ctor.prototype = parent.prototype; child.prototype = new ctor(); child.__super__ = parent.prototype; return child; }, hasProp = {}.hasOwnProperty; DT = require('../cql-datatypes'); CORE = require('./core'); Element = CORE.Element; Resource = CORE.Resource; Timing = CORE.Timing; Period = CORE.Period; Parameters = CORE.Parameters; Coding = CORE.Coding; Resource = CORE.Resource; Range = CORE.Range; Quantity = CORE.Quantity; Attachment = CORE.Attachment; BackboneElement = CORE.BackboneElement; DomainResource = CORE.DomainResource; ContactPoint = CORE.ContactPoint; ElementDefinition = CORE.ElementDefinition; Extension = CORE.Extension; HumanName = CORE.HumanName; Address = CORE.Address; Ratio = CORE.Ratio; SampledData = CORE.SampledData; Reference = CORE.Reference; CodeableConcept = CORE.CodeableConcept; Identifier = CORE.Identifier; Narrative = CORE.Narrative; Element = CORE.Element; /** Embedded class @class GroupCharacteristicComponent @exports GroupCharacteristicComponent as GroupCharacteristicComponent */ GroupCharacteristicComponent = (function(superClass) { extend(GroupCharacteristicComponent, superClass); function GroupCharacteristicComponent(json) { this.json = json; GroupCharacteristicComponent.__super__.constructor.call(this, this.json); } /** A code that identifies the kind of trait being asserted. @returns {CodeableConcept} */ GroupCharacteristicComponent.prototype.code = function() { if (this.json['code']) { return new CodeableConcept(this.json['code']); } }; /** The value of the trait that holds (or does not hold - see 'exclude') for members of the group. @returns {CodeableConcept} */ GroupCharacteristicComponent.prototype.valueCodeableConcept = function() { if (this.json['valueCodeableConcept']) { return new CodeableConcept(this.json['valueCodeableConcept']); } }; /** The value of the trait that holds (or does not hold - see 'exclude') for members of the group. @returns {Array} an array of {@link boolean} objects */ GroupCharacteristicComponent.prototype.valueBoolean = function() { return this.json['valueBoolean']; }; /** The value of the trait that holds (or does not hold - see 'exclude') for members of the group. @returns {Quantity} */ GroupCharacteristicComponent.prototype.valueQuantity = function() { if (this.json['valueQuantity']) { return new Quantity(this.json['valueQuantity']); } }; /** The value of the trait that holds (or does not hold - see 'exclude') for members of the group. @returns {Range} */ GroupCharacteristicComponent.prototype.valueRange = function() { if (this.json['valueRange']) { return new Range(this.json['valueRange']); } }; /** If true, indicates the characteristic is one that is NOT held by members of the group. @returns {Array} an array of {@link boolean} objects */ GroupCharacteristicComponent.prototype.exclude = function() { return this.json['exclude']; }; return GroupCharacteristicComponent; })(BackboneElement); /** Represents a defined collection of entities that may be discussed or acted upon collectively but which are not expected to act collectively and are not formally or legally recognized. I.e. A collection of entities that isn't an Organization. @class Group @exports Group as Group */ Group = (function(superClass) { extend(Group, superClass); function Group(json) { this.json = json; Group.__super__.constructor.call(this, this.json); } /** A unique business identifier for this group. @returns {Identifier} */ Group.prototype.identifier = function() { if (this.json['identifier']) { return new Identifier(this.json['identifier']); } }; /** Identifies the broad classification of the kind of resources the group includes. @returns {Array} an array of {@link String} objects */ Group.prototype.type = function() { return this.json['type']; }; /** If true, indicates that the resource refers to a specific group of real individuals. If false, the group defines a set of intended individuals. @returns {Array} an array of {@link boolean} objects */ Group.prototype.actual = function() { return this.json['actual']; }; /** Provides a specific type of resource the group includes. E.g. "cow", "syringe", etc. @returns {CodeableConcept} */ Group.prototype.code = function() { if (this.json['code']) { return new CodeableConcept(this.json['code']); } }; /** A label assigned to the group for human identification and communication. @returns {Array} an array of {@link String} objects */ Group.prototype.name = function() { return this.json['name']; }; /** A count of the number of resource instances that are part of the group. @returns {Array} an array of {@link Number} objects */ Group.prototype.quantity = function() { return this.json['quantity']; }; /** Identifies the traits shared by members of the group. @returns {Array} an array of {@link GroupCharacteristicComponent} objects */ Group.prototype.characteristic = function() { var i, item, len, ref, results; if (this.json['characteristic']) { ref = this.json['characteristic']; results = []; for (i = 0, len = ref.length; i < len; i++) { item = ref[i]; results.push(new GroupCharacteristicComponent(item)); } return results; } }; /** Identifies the resource instances that are members of the group. @returns {Array} an array of {@link Reference} objects */ Group.prototype.member = function() { var i, item, len, ref, results; if (this.json['member']) { ref = this.json['member']; results = []; for (i = 0, len = ref.length; i < len; i++) { item = ref[i]; results.push(new Reference(item)); } return results; } }; return Group; })(DomainResource); module.exports.Group = Group; }).call(this); //# sourceMappingURL=group.js.map