001package org.hl7.fhir.r4.model;
002
003/*-
004 * #%L
005 * org.hl7.fhir.r4
006 * %%
007 * Copyright (C) 2014 - 2019 Health Level 7
008 * %%
009 * Licensed under the Apache License, Version 2.0 (the "License");
010 * you may not use this file except in compliance with the License.
011 * You may obtain a copy of the License at
012 * 
013 *      http://www.apache.org/licenses/LICENSE-2.0
014 * 
015 * Unless required by applicable law or agreed to in writing, software
016 * distributed under the License is distributed on an "AS IS" BASIS,
017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
018 * See the License for the specific language governing permissions and
019 * limitations under the License.
020 * #L%
021 */
022
023/*
024  Copyright (c) 2011+, HL7, Inc.
025  All rights reserved.
026  
027  Redistribution and use in source and binary forms, with or without modification, 
028  are permitted provided that the following conditions are met:
029  
030   * Redistributions of source code must retain the above copyright notice, this 
031     list of conditions and the following disclaimer.
032   * Redistributions in binary form must reproduce the above copyright notice, 
033     this list of conditions and the following disclaimer in the documentation 
034     and/or other materials provided with the distribution.
035   * Neither the name of HL7 nor the names of its contributors may be used to 
036     endorse or promote products derived from this software without specific 
037     prior written permission.
038  
039  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
040  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
041  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
042  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
043  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
044  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
045  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
046  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
047  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
048  POSSIBILITY OF SUCH DAMAGE.
049  
050*/
051
052// Generated on Thu, Dec 13, 2018 14:07+1100 for FHIR v4.0.0
053import java.util.ArrayList;
054import java.util.Date;
055import java.util.List;
056
057import org.hl7.fhir.exceptions.FHIRException;
058import org.hl7.fhir.instance.model.api.IBaseBackboneElement;
059import org.hl7.fhir.r4.model.Enumerations.PublicationStatus;
060import org.hl7.fhir.r4.model.Enumerations.PublicationStatusEnumFactory;
061import org.hl7.fhir.utilities.Utilities;
062
063import ca.uhn.fhir.model.api.annotation.Block;
064import ca.uhn.fhir.model.api.annotation.Child;
065import ca.uhn.fhir.model.api.annotation.ChildOrder;
066import ca.uhn.fhir.model.api.annotation.Description;
067import ca.uhn.fhir.model.api.annotation.ResourceDef;
068import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
069/**
070 * The Measure resource provides the definition of a quality measure.
071 */
072@ResourceDef(name="Measure", profile="http://hl7.org/fhir/StructureDefinition/Measure")
073@ChildOrder(names={"url", "identifier", "version", "name", "title", "subtitle", "status", "experimental", "subject[x]", "date", "publisher", "contact", "description", "useContext", "jurisdiction", "purpose", "usage", "copyright", "approvalDate", "lastReviewDate", "effectivePeriod", "topic", "author", "editor", "reviewer", "endorser", "relatedArtifact", "library", "disclaimer", "scoring", "compositeScoring", "type", "riskAdjustment", "rateAggregation", "rationale", "clinicalRecommendationStatement", "improvementNotation", "definition", "guidance", "group", "supplementalData"})
074public class Measure extends MetadataResource {
075
076    @Block()
077    public static class MeasureGroupComponent extends BackboneElement implements IBaseBackboneElement {
078        /**
079         * Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures.
080         */
081        @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false)
082        @Description(shortDefinition="Meaning of the group", formalDefinition="Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures." )
083        protected CodeableConcept code;
084
085        /**
086         * The human readable description of this population group.
087         */
088        @Child(name = "description", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
089        @Description(shortDefinition="Summary description", formalDefinition="The human readable description of this population group." )
090        protected StringType description;
091
092        /**
093         * A population criteria for the measure.
094         */
095        @Child(name = "population", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
096        @Description(shortDefinition="Population criteria", formalDefinition="A population criteria for the measure." )
097        protected List<MeasureGroupPopulationComponent> population;
098
099        /**
100         * The stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.
101         */
102        @Child(name = "stratifier", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
103        @Description(shortDefinition="Stratifier criteria for the measure", formalDefinition="The stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path." )
104        protected List<MeasureGroupStratifierComponent> stratifier;
105
106        private static final long serialVersionUID = -1797567579L;
107
108    /**
109     * Constructor
110     */
111      public MeasureGroupComponent() {
112        super();
113      }
114
115        /**
116         * @return {@link #code} (Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures.)
117         */
118        public CodeableConcept getCode() { 
119          if (this.code == null)
120            if (Configuration.errorOnAutoCreate())
121              throw new Error("Attempt to auto-create MeasureGroupComponent.code");
122            else if (Configuration.doAutoCreate())
123              this.code = new CodeableConcept(); // cc
124          return this.code;
125        }
126
127        public boolean hasCode() { 
128          return this.code != null && !this.code.isEmpty();
129        }
130
131        /**
132         * @param value {@link #code} (Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures.)
133         */
134        public MeasureGroupComponent setCode(CodeableConcept value) { 
135          this.code = value;
136          return this;
137        }
138
139        /**
140         * @return {@link #description} (The human readable description of this population group.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
141         */
142        public StringType getDescriptionElement() { 
143          if (this.description == null)
144            if (Configuration.errorOnAutoCreate())
145              throw new Error("Attempt to auto-create MeasureGroupComponent.description");
146            else if (Configuration.doAutoCreate())
147              this.description = new StringType(); // bb
148          return this.description;
149        }
150
151        public boolean hasDescriptionElement() { 
152          return this.description != null && !this.description.isEmpty();
153        }
154
155        public boolean hasDescription() { 
156          return this.description != null && !this.description.isEmpty();
157        }
158
159        /**
160         * @param value {@link #description} (The human readable description of this population group.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
161         */
162        public MeasureGroupComponent setDescriptionElement(StringType value) { 
163          this.description = value;
164          return this;
165        }
166
167        /**
168         * @return The human readable description of this population group.
169         */
170        public String getDescription() { 
171          return this.description == null ? null : this.description.getValue();
172        }
173
174        /**
175         * @param value The human readable description of this population group.
176         */
177        public MeasureGroupComponent setDescription(String value) { 
178          if (Utilities.noString(value))
179            this.description = null;
180          else {
181            if (this.description == null)
182              this.description = new StringType();
183            this.description.setValue(value);
184          }
185          return this;
186        }
187
188        /**
189         * @return {@link #population} (A population criteria for the measure.)
190         */
191        public List<MeasureGroupPopulationComponent> getPopulation() { 
192          if (this.population == null)
193            this.population = new ArrayList<MeasureGroupPopulationComponent>();
194          return this.population;
195        }
196
197        /**
198         * @return Returns a reference to <code>this</code> for easy method chaining
199         */
200        public MeasureGroupComponent setPopulation(List<MeasureGroupPopulationComponent> thePopulation) { 
201          this.population = thePopulation;
202          return this;
203        }
204
205        public boolean hasPopulation() { 
206          if (this.population == null)
207            return false;
208          for (MeasureGroupPopulationComponent item : this.population)
209            if (!item.isEmpty())
210              return true;
211          return false;
212        }
213
214        public MeasureGroupPopulationComponent addPopulation() { //3
215          MeasureGroupPopulationComponent t = new MeasureGroupPopulationComponent();
216          if (this.population == null)
217            this.population = new ArrayList<MeasureGroupPopulationComponent>();
218          this.population.add(t);
219          return t;
220        }
221
222        public MeasureGroupComponent addPopulation(MeasureGroupPopulationComponent t) { //3
223          if (t == null)
224            return this;
225          if (this.population == null)
226            this.population = new ArrayList<MeasureGroupPopulationComponent>();
227          this.population.add(t);
228          return this;
229        }
230
231        /**
232         * @return The first repetition of repeating field {@link #population}, creating it if it does not already exist
233         */
234        public MeasureGroupPopulationComponent getPopulationFirstRep() { 
235          if (getPopulation().isEmpty()) {
236            addPopulation();
237          }
238          return getPopulation().get(0);
239        }
240
241        /**
242         * @return {@link #stratifier} (The stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.)
243         */
244        public List<MeasureGroupStratifierComponent> getStratifier() { 
245          if (this.stratifier == null)
246            this.stratifier = new ArrayList<MeasureGroupStratifierComponent>();
247          return this.stratifier;
248        }
249
250        /**
251         * @return Returns a reference to <code>this</code> for easy method chaining
252         */
253        public MeasureGroupComponent setStratifier(List<MeasureGroupStratifierComponent> theStratifier) { 
254          this.stratifier = theStratifier;
255          return this;
256        }
257
258        public boolean hasStratifier() { 
259          if (this.stratifier == null)
260            return false;
261          for (MeasureGroupStratifierComponent item : this.stratifier)
262            if (!item.isEmpty())
263              return true;
264          return false;
265        }
266
267        public MeasureGroupStratifierComponent addStratifier() { //3
268          MeasureGroupStratifierComponent t = new MeasureGroupStratifierComponent();
269          if (this.stratifier == null)
270            this.stratifier = new ArrayList<MeasureGroupStratifierComponent>();
271          this.stratifier.add(t);
272          return t;
273        }
274
275        public MeasureGroupComponent addStratifier(MeasureGroupStratifierComponent t) { //3
276          if (t == null)
277            return this;
278          if (this.stratifier == null)
279            this.stratifier = new ArrayList<MeasureGroupStratifierComponent>();
280          this.stratifier.add(t);
281          return this;
282        }
283
284        /**
285         * @return The first repetition of repeating field {@link #stratifier}, creating it if it does not already exist
286         */
287        public MeasureGroupStratifierComponent getStratifierFirstRep() { 
288          if (getStratifier().isEmpty()) {
289            addStratifier();
290          }
291          return getStratifier().get(0);
292        }
293
294        protected void listChildren(List<Property> children) {
295          super.listChildren(children);
296          children.add(new Property("code", "CodeableConcept", "Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures.", 0, 1, code));
297          children.add(new Property("description", "string", "The human readable description of this population group.", 0, 1, description));
298          children.add(new Property("population", "", "A population criteria for the measure.", 0, java.lang.Integer.MAX_VALUE, population));
299          children.add(new Property("stratifier", "", "The stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, stratifier));
300        }
301
302        @Override
303        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
304          switch (_hash) {
305          case 3059181: /*code*/  return new Property("code", "CodeableConcept", "Indicates a meaning for the group. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing groups to be correlated across measures.", 0, 1, code);
306          case -1724546052: /*description*/  return new Property("description", "string", "The human readable description of this population group.", 0, 1, description);
307          case -2023558323: /*population*/  return new Property("population", "", "A population criteria for the measure.", 0, java.lang.Integer.MAX_VALUE, population);
308          case 90983669: /*stratifier*/  return new Property("stratifier", "", "The stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, stratifier);
309          default: return super.getNamedProperty(_hash, _name, _checkValid);
310          }
311
312        }
313
314      @Override
315      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
316        switch (hash) {
317        case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept
318        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType
319        case -2023558323: /*population*/ return this.population == null ? new Base[0] : this.population.toArray(new Base[this.population.size()]); // MeasureGroupPopulationComponent
320        case 90983669: /*stratifier*/ return this.stratifier == null ? new Base[0] : this.stratifier.toArray(new Base[this.stratifier.size()]); // MeasureGroupStratifierComponent
321        default: return super.getProperty(hash, name, checkValid);
322        }
323
324      }
325
326      @Override
327      public Base setProperty(int hash, String name, Base value) throws FHIRException {
328        switch (hash) {
329        case 3059181: // code
330          this.code = castToCodeableConcept(value); // CodeableConcept
331          return value;
332        case -1724546052: // description
333          this.description = castToString(value); // StringType
334          return value;
335        case -2023558323: // population
336          this.getPopulation().add((MeasureGroupPopulationComponent) value); // MeasureGroupPopulationComponent
337          return value;
338        case 90983669: // stratifier
339          this.getStratifier().add((MeasureGroupStratifierComponent) value); // MeasureGroupStratifierComponent
340          return value;
341        default: return super.setProperty(hash, name, value);
342        }
343
344      }
345
346      @Override
347      public Base setProperty(String name, Base value) throws FHIRException {
348        if (name.equals("code")) {
349          this.code = castToCodeableConcept(value); // CodeableConcept
350        } else if (name.equals("description")) {
351          this.description = castToString(value); // StringType
352        } else if (name.equals("population")) {
353          this.getPopulation().add((MeasureGroupPopulationComponent) value);
354        } else if (name.equals("stratifier")) {
355          this.getStratifier().add((MeasureGroupStratifierComponent) value);
356        } else
357          return super.setProperty(name, value);
358        return value;
359      }
360
361      @Override
362      public Base makeProperty(int hash, String name) throws FHIRException {
363        switch (hash) {
364        case 3059181:  return getCode(); 
365        case -1724546052:  return getDescriptionElement();
366        case -2023558323:  return addPopulation(); 
367        case 90983669:  return addStratifier(); 
368        default: return super.makeProperty(hash, name);
369        }
370
371      }
372
373      @Override
374      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
375        switch (hash) {
376        case 3059181: /*code*/ return new String[] {"CodeableConcept"};
377        case -1724546052: /*description*/ return new String[] {"string"};
378        case -2023558323: /*population*/ return new String[] {};
379        case 90983669: /*stratifier*/ return new String[] {};
380        default: return super.getTypesForProperty(hash, name);
381        }
382
383      }
384
385      @Override
386      public Base addChild(String name) throws FHIRException {
387        if (name.equals("code")) {
388          this.code = new CodeableConcept();
389          return this.code;
390        }
391        else if (name.equals("description")) {
392          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
393        }
394        else if (name.equals("population")) {
395          return addPopulation();
396        }
397        else if (name.equals("stratifier")) {
398          return addStratifier();
399        }
400        else
401          return super.addChild(name);
402      }
403
404      public MeasureGroupComponent copy() {
405        MeasureGroupComponent dst = new MeasureGroupComponent();
406        copyValues(dst);
407        dst.code = code == null ? null : code.copy();
408        dst.description = description == null ? null : description.copy();
409        if (population != null) {
410          dst.population = new ArrayList<MeasureGroupPopulationComponent>();
411          for (MeasureGroupPopulationComponent i : population)
412            dst.population.add(i.copy());
413        };
414        if (stratifier != null) {
415          dst.stratifier = new ArrayList<MeasureGroupStratifierComponent>();
416          for (MeasureGroupStratifierComponent i : stratifier)
417            dst.stratifier.add(i.copy());
418        };
419        return dst;
420      }
421
422      @Override
423      public boolean equalsDeep(Base other_) {
424        if (!super.equalsDeep(other_))
425          return false;
426        if (!(other_ instanceof MeasureGroupComponent))
427          return false;
428        MeasureGroupComponent o = (MeasureGroupComponent) other_;
429        return compareDeep(code, o.code, true) && compareDeep(description, o.description, true) && compareDeep(population, o.population, true)
430           && compareDeep(stratifier, o.stratifier, true);
431      }
432
433      @Override
434      public boolean equalsShallow(Base other_) {
435        if (!super.equalsShallow(other_))
436          return false;
437        if (!(other_ instanceof MeasureGroupComponent))
438          return false;
439        MeasureGroupComponent o = (MeasureGroupComponent) other_;
440        return compareValues(description, o.description, true);
441      }
442
443      public boolean isEmpty() {
444        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, description, population
445          , stratifier);
446      }
447
448  public String fhirType() {
449    return "Measure.group";
450
451  }
452
453  }
454
455    @Block()
456    public static class MeasureGroupPopulationComponent extends BackboneElement implements IBaseBackboneElement {
457        /**
458         * The type of population criteria.
459         */
460        @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false)
461        @Description(shortDefinition="initial-population | numerator | numerator-exclusion | denominator | denominator-exclusion | denominator-exception | measure-population | measure-population-exclusion | measure-observation", formalDefinition="The type of population criteria." )
462        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/measure-population")
463        protected CodeableConcept code;
464
465        /**
466         * The human readable description of this population criteria.
467         */
468        @Child(name = "description", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
469        @Description(shortDefinition="The human readable description of this population criteria", formalDefinition="The human readable description of this population criteria." )
470        protected StringType description;
471
472        /**
473         * An expression that specifies the criteria for the population, typically the name of an expression in a library.
474         */
475        @Child(name = "criteria", type = {Expression.class}, order=3, min=1, max=1, modifier=false, summary=false)
476        @Description(shortDefinition="The criteria that defines this population", formalDefinition="An expression that specifies the criteria for the population, typically the name of an expression in a library." )
477        protected Expression criteria;
478
479        private static final long serialVersionUID = 2107514056L;
480
481    /**
482     * Constructor
483     */
484      public MeasureGroupPopulationComponent() {
485        super();
486      }
487
488    /**
489     * Constructor
490     */
491      public MeasureGroupPopulationComponent(Expression criteria) {
492        super();
493        this.criteria = criteria;
494      }
495
496        /**
497         * @return {@link #code} (The type of population criteria.)
498         */
499        public CodeableConcept getCode() { 
500          if (this.code == null)
501            if (Configuration.errorOnAutoCreate())
502              throw new Error("Attempt to auto-create MeasureGroupPopulationComponent.code");
503            else if (Configuration.doAutoCreate())
504              this.code = new CodeableConcept(); // cc
505          return this.code;
506        }
507
508        public boolean hasCode() { 
509          return this.code != null && !this.code.isEmpty();
510        }
511
512        /**
513         * @param value {@link #code} (The type of population criteria.)
514         */
515        public MeasureGroupPopulationComponent setCode(CodeableConcept value) { 
516          this.code = value;
517          return this;
518        }
519
520        /**
521         * @return {@link #description} (The human readable description of this population criteria.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
522         */
523        public StringType getDescriptionElement() { 
524          if (this.description == null)
525            if (Configuration.errorOnAutoCreate())
526              throw new Error("Attempt to auto-create MeasureGroupPopulationComponent.description");
527            else if (Configuration.doAutoCreate())
528              this.description = new StringType(); // bb
529          return this.description;
530        }
531
532        public boolean hasDescriptionElement() { 
533          return this.description != null && !this.description.isEmpty();
534        }
535
536        public boolean hasDescription() { 
537          return this.description != null && !this.description.isEmpty();
538        }
539
540        /**
541         * @param value {@link #description} (The human readable description of this population criteria.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
542         */
543        public MeasureGroupPopulationComponent setDescriptionElement(StringType value) { 
544          this.description = value;
545          return this;
546        }
547
548        /**
549         * @return The human readable description of this population criteria.
550         */
551        public String getDescription() { 
552          return this.description == null ? null : this.description.getValue();
553        }
554
555        /**
556         * @param value The human readable description of this population criteria.
557         */
558        public MeasureGroupPopulationComponent setDescription(String value) { 
559          if (Utilities.noString(value))
560            this.description = null;
561          else {
562            if (this.description == null)
563              this.description = new StringType();
564            this.description.setValue(value);
565          }
566          return this;
567        }
568
569        /**
570         * @return {@link #criteria} (An expression that specifies the criteria for the population, typically the name of an expression in a library.)
571         */
572        public Expression getCriteria() { 
573          if (this.criteria == null)
574            if (Configuration.errorOnAutoCreate())
575              throw new Error("Attempt to auto-create MeasureGroupPopulationComponent.criteria");
576            else if (Configuration.doAutoCreate())
577              this.criteria = new Expression(); // cc
578          return this.criteria;
579        }
580
581        public boolean hasCriteria() { 
582          return this.criteria != null && !this.criteria.isEmpty();
583        }
584
585        /**
586         * @param value {@link #criteria} (An expression that specifies the criteria for the population, typically the name of an expression in a library.)
587         */
588        public MeasureGroupPopulationComponent setCriteria(Expression value) { 
589          this.criteria = value;
590          return this;
591        }
592
593        protected void listChildren(List<Property> children) {
594          super.listChildren(children);
595          children.add(new Property("code", "CodeableConcept", "The type of population criteria.", 0, 1, code));
596          children.add(new Property("description", "string", "The human readable description of this population criteria.", 0, 1, description));
597          children.add(new Property("criteria", "Expression", "An expression that specifies the criteria for the population, typically the name of an expression in a library.", 0, 1, criteria));
598        }
599
600        @Override
601        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
602          switch (_hash) {
603          case 3059181: /*code*/  return new Property("code", "CodeableConcept", "The type of population criteria.", 0, 1, code);
604          case -1724546052: /*description*/  return new Property("description", "string", "The human readable description of this population criteria.", 0, 1, description);
605          case 1952046943: /*criteria*/  return new Property("criteria", "Expression", "An expression that specifies the criteria for the population, typically the name of an expression in a library.", 0, 1, criteria);
606          default: return super.getNamedProperty(_hash, _name, _checkValid);
607          }
608
609        }
610
611      @Override
612      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
613        switch (hash) {
614        case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept
615        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType
616        case 1952046943: /*criteria*/ return this.criteria == null ? new Base[0] : new Base[] {this.criteria}; // Expression
617        default: return super.getProperty(hash, name, checkValid);
618        }
619
620      }
621
622      @Override
623      public Base setProperty(int hash, String name, Base value) throws FHIRException {
624        switch (hash) {
625        case 3059181: // code
626          this.code = castToCodeableConcept(value); // CodeableConcept
627          return value;
628        case -1724546052: // description
629          this.description = castToString(value); // StringType
630          return value;
631        case 1952046943: // criteria
632          this.criteria = castToExpression(value); // Expression
633          return value;
634        default: return super.setProperty(hash, name, value);
635        }
636
637      }
638
639      @Override
640      public Base setProperty(String name, Base value) throws FHIRException {
641        if (name.equals("code")) {
642          this.code = castToCodeableConcept(value); // CodeableConcept
643        } else if (name.equals("description")) {
644          this.description = castToString(value); // StringType
645        } else if (name.equals("criteria")) {
646          this.criteria = castToExpression(value); // Expression
647        } else
648          return super.setProperty(name, value);
649        return value;
650      }
651
652      @Override
653      public Base makeProperty(int hash, String name) throws FHIRException {
654        switch (hash) {
655        case 3059181:  return getCode(); 
656        case -1724546052:  return getDescriptionElement();
657        case 1952046943:  return getCriteria(); 
658        default: return super.makeProperty(hash, name);
659        }
660
661      }
662
663      @Override
664      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
665        switch (hash) {
666        case 3059181: /*code*/ return new String[] {"CodeableConcept"};
667        case -1724546052: /*description*/ return new String[] {"string"};
668        case 1952046943: /*criteria*/ return new String[] {"Expression"};
669        default: return super.getTypesForProperty(hash, name);
670        }
671
672      }
673
674      @Override
675      public Base addChild(String name) throws FHIRException {
676        if (name.equals("code")) {
677          this.code = new CodeableConcept();
678          return this.code;
679        }
680        else if (name.equals("description")) {
681          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
682        }
683        else if (name.equals("criteria")) {
684          this.criteria = new Expression();
685          return this.criteria;
686        }
687        else
688          return super.addChild(name);
689      }
690
691      public MeasureGroupPopulationComponent copy() {
692        MeasureGroupPopulationComponent dst = new MeasureGroupPopulationComponent();
693        copyValues(dst);
694        dst.code = code == null ? null : code.copy();
695        dst.description = description == null ? null : description.copy();
696        dst.criteria = criteria == null ? null : criteria.copy();
697        return dst;
698      }
699
700      @Override
701      public boolean equalsDeep(Base other_) {
702        if (!super.equalsDeep(other_))
703          return false;
704        if (!(other_ instanceof MeasureGroupPopulationComponent))
705          return false;
706        MeasureGroupPopulationComponent o = (MeasureGroupPopulationComponent) other_;
707        return compareDeep(code, o.code, true) && compareDeep(description, o.description, true) && compareDeep(criteria, o.criteria, true)
708          ;
709      }
710
711      @Override
712      public boolean equalsShallow(Base other_) {
713        if (!super.equalsShallow(other_))
714          return false;
715        if (!(other_ instanceof MeasureGroupPopulationComponent))
716          return false;
717        MeasureGroupPopulationComponent o = (MeasureGroupPopulationComponent) other_;
718        return compareValues(description, o.description, true);
719      }
720
721      public boolean isEmpty() {
722        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, description, criteria
723          );
724      }
725
726  public String fhirType() {
727    return "Measure.group.population";
728
729  }
730
731  }
732
733    @Block()
734    public static class MeasureGroupStratifierComponent extends BackboneElement implements IBaseBackboneElement {
735        /**
736         * Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.
737         */
738        @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false)
739        @Description(shortDefinition="Meaning of the stratifier", formalDefinition="Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures." )
740        protected CodeableConcept code;
741
742        /**
743         * The human readable description of this stratifier criteria.
744         */
745        @Child(name = "description", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
746        @Description(shortDefinition="The human readable description of this stratifier", formalDefinition="The human readable description of this stratifier criteria." )
747        protected StringType description;
748
749        /**
750         * An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.
751         */
752        @Child(name = "criteria", type = {Expression.class}, order=3, min=0, max=1, modifier=false, summary=false)
753        @Description(shortDefinition="How the measure should be stratified", formalDefinition="An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element." )
754        protected Expression criteria;
755
756        /**
757         * A component of the stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.
758         */
759        @Child(name = "component", type = {}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
760        @Description(shortDefinition="Stratifier criteria component for the measure", formalDefinition="A component of the stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path." )
761        protected List<MeasureGroupStratifierComponentComponent> component;
762
763        private static final long serialVersionUID = -1706793609L;
764
765    /**
766     * Constructor
767     */
768      public MeasureGroupStratifierComponent() {
769        super();
770      }
771
772        /**
773         * @return {@link #code} (Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.)
774         */
775        public CodeableConcept getCode() { 
776          if (this.code == null)
777            if (Configuration.errorOnAutoCreate())
778              throw new Error("Attempt to auto-create MeasureGroupStratifierComponent.code");
779            else if (Configuration.doAutoCreate())
780              this.code = new CodeableConcept(); // cc
781          return this.code;
782        }
783
784        public boolean hasCode() { 
785          return this.code != null && !this.code.isEmpty();
786        }
787
788        /**
789         * @param value {@link #code} (Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.)
790         */
791        public MeasureGroupStratifierComponent setCode(CodeableConcept value) { 
792          this.code = value;
793          return this;
794        }
795
796        /**
797         * @return {@link #description} (The human readable description of this stratifier criteria.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
798         */
799        public StringType getDescriptionElement() { 
800          if (this.description == null)
801            if (Configuration.errorOnAutoCreate())
802              throw new Error("Attempt to auto-create MeasureGroupStratifierComponent.description");
803            else if (Configuration.doAutoCreate())
804              this.description = new StringType(); // bb
805          return this.description;
806        }
807
808        public boolean hasDescriptionElement() { 
809          return this.description != null && !this.description.isEmpty();
810        }
811
812        public boolean hasDescription() { 
813          return this.description != null && !this.description.isEmpty();
814        }
815
816        /**
817         * @param value {@link #description} (The human readable description of this stratifier criteria.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
818         */
819        public MeasureGroupStratifierComponent setDescriptionElement(StringType value) { 
820          this.description = value;
821          return this;
822        }
823
824        /**
825         * @return The human readable description of this stratifier criteria.
826         */
827        public String getDescription() { 
828          return this.description == null ? null : this.description.getValue();
829        }
830
831        /**
832         * @param value The human readable description of this stratifier criteria.
833         */
834        public MeasureGroupStratifierComponent setDescription(String value) { 
835          if (Utilities.noString(value))
836            this.description = null;
837          else {
838            if (this.description == null)
839              this.description = new StringType();
840            this.description.setValue(value);
841          }
842          return this;
843        }
844
845        /**
846         * @return {@link #criteria} (An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.)
847         */
848        public Expression getCriteria() { 
849          if (this.criteria == null)
850            if (Configuration.errorOnAutoCreate())
851              throw new Error("Attempt to auto-create MeasureGroupStratifierComponent.criteria");
852            else if (Configuration.doAutoCreate())
853              this.criteria = new Expression(); // cc
854          return this.criteria;
855        }
856
857        public boolean hasCriteria() { 
858          return this.criteria != null && !this.criteria.isEmpty();
859        }
860
861        /**
862         * @param value {@link #criteria} (An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.)
863         */
864        public MeasureGroupStratifierComponent setCriteria(Expression value) { 
865          this.criteria = value;
866          return this;
867        }
868
869        /**
870         * @return {@link #component} (A component of the stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.)
871         */
872        public List<MeasureGroupStratifierComponentComponent> getComponent() { 
873          if (this.component == null)
874            this.component = new ArrayList<MeasureGroupStratifierComponentComponent>();
875          return this.component;
876        }
877
878        /**
879         * @return Returns a reference to <code>this</code> for easy method chaining
880         */
881        public MeasureGroupStratifierComponent setComponent(List<MeasureGroupStratifierComponentComponent> theComponent) { 
882          this.component = theComponent;
883          return this;
884        }
885
886        public boolean hasComponent() { 
887          if (this.component == null)
888            return false;
889          for (MeasureGroupStratifierComponentComponent item : this.component)
890            if (!item.isEmpty())
891              return true;
892          return false;
893        }
894
895        public MeasureGroupStratifierComponentComponent addComponent() { //3
896          MeasureGroupStratifierComponentComponent t = new MeasureGroupStratifierComponentComponent();
897          if (this.component == null)
898            this.component = new ArrayList<MeasureGroupStratifierComponentComponent>();
899          this.component.add(t);
900          return t;
901        }
902
903        public MeasureGroupStratifierComponent addComponent(MeasureGroupStratifierComponentComponent t) { //3
904          if (t == null)
905            return this;
906          if (this.component == null)
907            this.component = new ArrayList<MeasureGroupStratifierComponentComponent>();
908          this.component.add(t);
909          return this;
910        }
911
912        /**
913         * @return The first repetition of repeating field {@link #component}, creating it if it does not already exist
914         */
915        public MeasureGroupStratifierComponentComponent getComponentFirstRep() { 
916          if (getComponent().isEmpty()) {
917            addComponent();
918          }
919          return getComponent().get(0);
920        }
921
922        protected void listChildren(List<Property> children) {
923          super.listChildren(children);
924          children.add(new Property("code", "CodeableConcept", "Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.", 0, 1, code));
925          children.add(new Property("description", "string", "The human readable description of this stratifier criteria.", 0, 1, description));
926          children.add(new Property("criteria", "Expression", "An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.", 0, 1, criteria));
927          children.add(new Property("component", "", "A component of the stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, component));
928        }
929
930        @Override
931        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
932          switch (_hash) {
933          case 3059181: /*code*/  return new Property("code", "CodeableConcept", "Indicates a meaning for the stratifier. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.", 0, 1, code);
934          case -1724546052: /*description*/  return new Property("description", "string", "The human readable description of this stratifier criteria.", 0, 1, description);
935          case 1952046943: /*criteria*/  return new Property("criteria", "Expression", "An expression that specifies the criteria for the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.", 0, 1, criteria);
936          case -1399907075: /*component*/  return new Property("component", "", "A component of the stratifier criteria for the measure report, specified as either the name of a valid CQL expression defined within a referenced library or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, component);
937          default: return super.getNamedProperty(_hash, _name, _checkValid);
938          }
939
940        }
941
942      @Override
943      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
944        switch (hash) {
945        case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept
946        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType
947        case 1952046943: /*criteria*/ return this.criteria == null ? new Base[0] : new Base[] {this.criteria}; // Expression
948        case -1399907075: /*component*/ return this.component == null ? new Base[0] : this.component.toArray(new Base[this.component.size()]); // MeasureGroupStratifierComponentComponent
949        default: return super.getProperty(hash, name, checkValid);
950        }
951
952      }
953
954      @Override
955      public Base setProperty(int hash, String name, Base value) throws FHIRException {
956        switch (hash) {
957        case 3059181: // code
958          this.code = castToCodeableConcept(value); // CodeableConcept
959          return value;
960        case -1724546052: // description
961          this.description = castToString(value); // StringType
962          return value;
963        case 1952046943: // criteria
964          this.criteria = castToExpression(value); // Expression
965          return value;
966        case -1399907075: // component
967          this.getComponent().add((MeasureGroupStratifierComponentComponent) value); // MeasureGroupStratifierComponentComponent
968          return value;
969        default: return super.setProperty(hash, name, value);
970        }
971
972      }
973
974      @Override
975      public Base setProperty(String name, Base value) throws FHIRException {
976        if (name.equals("code")) {
977          this.code = castToCodeableConcept(value); // CodeableConcept
978        } else if (name.equals("description")) {
979          this.description = castToString(value); // StringType
980        } else if (name.equals("criteria")) {
981          this.criteria = castToExpression(value); // Expression
982        } else if (name.equals("component")) {
983          this.getComponent().add((MeasureGroupStratifierComponentComponent) value);
984        } else
985          return super.setProperty(name, value);
986        return value;
987      }
988
989      @Override
990      public Base makeProperty(int hash, String name) throws FHIRException {
991        switch (hash) {
992        case 3059181:  return getCode(); 
993        case -1724546052:  return getDescriptionElement();
994        case 1952046943:  return getCriteria(); 
995        case -1399907075:  return addComponent(); 
996        default: return super.makeProperty(hash, name);
997        }
998
999      }
1000
1001      @Override
1002      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1003        switch (hash) {
1004        case 3059181: /*code*/ return new String[] {"CodeableConcept"};
1005        case -1724546052: /*description*/ return new String[] {"string"};
1006        case 1952046943: /*criteria*/ return new String[] {"Expression"};
1007        case -1399907075: /*component*/ return new String[] {};
1008        default: return super.getTypesForProperty(hash, name);
1009        }
1010
1011      }
1012
1013      @Override
1014      public Base addChild(String name) throws FHIRException {
1015        if (name.equals("code")) {
1016          this.code = new CodeableConcept();
1017          return this.code;
1018        }
1019        else if (name.equals("description")) {
1020          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
1021        }
1022        else if (name.equals("criteria")) {
1023          this.criteria = new Expression();
1024          return this.criteria;
1025        }
1026        else if (name.equals("component")) {
1027          return addComponent();
1028        }
1029        else
1030          return super.addChild(name);
1031      }
1032
1033      public MeasureGroupStratifierComponent copy() {
1034        MeasureGroupStratifierComponent dst = new MeasureGroupStratifierComponent();
1035        copyValues(dst);
1036        dst.code = code == null ? null : code.copy();
1037        dst.description = description == null ? null : description.copy();
1038        dst.criteria = criteria == null ? null : criteria.copy();
1039        if (component != null) {
1040          dst.component = new ArrayList<MeasureGroupStratifierComponentComponent>();
1041          for (MeasureGroupStratifierComponentComponent i : component)
1042            dst.component.add(i.copy());
1043        };
1044        return dst;
1045      }
1046
1047      @Override
1048      public boolean equalsDeep(Base other_) {
1049        if (!super.equalsDeep(other_))
1050          return false;
1051        if (!(other_ instanceof MeasureGroupStratifierComponent))
1052          return false;
1053        MeasureGroupStratifierComponent o = (MeasureGroupStratifierComponent) other_;
1054        return compareDeep(code, o.code, true) && compareDeep(description, o.description, true) && compareDeep(criteria, o.criteria, true)
1055           && compareDeep(component, o.component, true);
1056      }
1057
1058      @Override
1059      public boolean equalsShallow(Base other_) {
1060        if (!super.equalsShallow(other_))
1061          return false;
1062        if (!(other_ instanceof MeasureGroupStratifierComponent))
1063          return false;
1064        MeasureGroupStratifierComponent o = (MeasureGroupStratifierComponent) other_;
1065        return compareValues(description, o.description, true);
1066      }
1067
1068      public boolean isEmpty() {
1069        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, description, criteria
1070          , component);
1071      }
1072
1073  public String fhirType() {
1074    return "Measure.group.stratifier";
1075
1076  }
1077
1078  }
1079
1080    @Block()
1081    public static class MeasureGroupStratifierComponentComponent extends BackboneElement implements IBaseBackboneElement {
1082        /**
1083         * Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.
1084         */
1085        @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false)
1086        @Description(shortDefinition="Meaning of the stratifier component", formalDefinition="Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures." )
1087        protected CodeableConcept code;
1088
1089        /**
1090         * The human readable description of this stratifier criteria component.
1091         */
1092        @Child(name = "description", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false)
1093        @Description(shortDefinition="The human readable description of this stratifier component", formalDefinition="The human readable description of this stratifier criteria component." )
1094        protected StringType description;
1095
1096        /**
1097         * An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.
1098         */
1099        @Child(name = "criteria", type = {Expression.class}, order=3, min=1, max=1, modifier=false, summary=false)
1100        @Description(shortDefinition="Component of how the measure should be stratified", formalDefinition="An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element." )
1101        protected Expression criteria;
1102
1103        private static final long serialVersionUID = 2107514056L;
1104
1105    /**
1106     * Constructor
1107     */
1108      public MeasureGroupStratifierComponentComponent() {
1109        super();
1110      }
1111
1112    /**
1113     * Constructor
1114     */
1115      public MeasureGroupStratifierComponentComponent(Expression criteria) {
1116        super();
1117        this.criteria = criteria;
1118      }
1119
1120        /**
1121         * @return {@link #code} (Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.)
1122         */
1123        public CodeableConcept getCode() { 
1124          if (this.code == null)
1125            if (Configuration.errorOnAutoCreate())
1126              throw new Error("Attempt to auto-create MeasureGroupStratifierComponentComponent.code");
1127            else if (Configuration.doAutoCreate())
1128              this.code = new CodeableConcept(); // cc
1129          return this.code;
1130        }
1131
1132        public boolean hasCode() { 
1133          return this.code != null && !this.code.isEmpty();
1134        }
1135
1136        /**
1137         * @param value {@link #code} (Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.)
1138         */
1139        public MeasureGroupStratifierComponentComponent setCode(CodeableConcept value) { 
1140          this.code = value;
1141          return this;
1142        }
1143
1144        /**
1145         * @return {@link #description} (The human readable description of this stratifier criteria component.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
1146         */
1147        public StringType getDescriptionElement() { 
1148          if (this.description == null)
1149            if (Configuration.errorOnAutoCreate())
1150              throw new Error("Attempt to auto-create MeasureGroupStratifierComponentComponent.description");
1151            else if (Configuration.doAutoCreate())
1152              this.description = new StringType(); // bb
1153          return this.description;
1154        }
1155
1156        public boolean hasDescriptionElement() { 
1157          return this.description != null && !this.description.isEmpty();
1158        }
1159
1160        public boolean hasDescription() { 
1161          return this.description != null && !this.description.isEmpty();
1162        }
1163
1164        /**
1165         * @param value {@link #description} (The human readable description of this stratifier criteria component.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
1166         */
1167        public MeasureGroupStratifierComponentComponent setDescriptionElement(StringType value) { 
1168          this.description = value;
1169          return this;
1170        }
1171
1172        /**
1173         * @return The human readable description of this stratifier criteria component.
1174         */
1175        public String getDescription() { 
1176          return this.description == null ? null : this.description.getValue();
1177        }
1178
1179        /**
1180         * @param value The human readable description of this stratifier criteria component.
1181         */
1182        public MeasureGroupStratifierComponentComponent setDescription(String value) { 
1183          if (Utilities.noString(value))
1184            this.description = null;
1185          else {
1186            if (this.description == null)
1187              this.description = new StringType();
1188            this.description.setValue(value);
1189          }
1190          return this;
1191        }
1192
1193        /**
1194         * @return {@link #criteria} (An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.)
1195         */
1196        public Expression getCriteria() { 
1197          if (this.criteria == null)
1198            if (Configuration.errorOnAutoCreate())
1199              throw new Error("Attempt to auto-create MeasureGroupStratifierComponentComponent.criteria");
1200            else if (Configuration.doAutoCreate())
1201              this.criteria = new Expression(); // cc
1202          return this.criteria;
1203        }
1204
1205        public boolean hasCriteria() { 
1206          return this.criteria != null && !this.criteria.isEmpty();
1207        }
1208
1209        /**
1210         * @param value {@link #criteria} (An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.)
1211         */
1212        public MeasureGroupStratifierComponentComponent setCriteria(Expression value) { 
1213          this.criteria = value;
1214          return this;
1215        }
1216
1217        protected void listChildren(List<Property> children) {
1218          super.listChildren(children);
1219          children.add(new Property("code", "CodeableConcept", "Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.", 0, 1, code));
1220          children.add(new Property("description", "string", "The human readable description of this stratifier criteria component.", 0, 1, description));
1221          children.add(new Property("criteria", "Expression", "An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.", 0, 1, criteria));
1222        }
1223
1224        @Override
1225        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1226          switch (_hash) {
1227          case 3059181: /*code*/  return new Property("code", "CodeableConcept", "Indicates a meaning for the stratifier component. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing stratifiers to be correlated across measures.", 0, 1, code);
1228          case -1724546052: /*description*/  return new Property("description", "string", "The human readable description of this stratifier criteria component.", 0, 1, description);
1229          case 1952046943: /*criteria*/  return new Property("criteria", "Expression", "An expression that specifies the criteria for this component of the stratifier. This is typically the name of an expression defined within a referenced library, but it may also be a path to a stratifier element.", 0, 1, criteria);
1230          default: return super.getNamedProperty(_hash, _name, _checkValid);
1231          }
1232
1233        }
1234
1235      @Override
1236      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1237        switch (hash) {
1238        case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept
1239        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType
1240        case 1952046943: /*criteria*/ return this.criteria == null ? new Base[0] : new Base[] {this.criteria}; // Expression
1241        default: return super.getProperty(hash, name, checkValid);
1242        }
1243
1244      }
1245
1246      @Override
1247      public Base setProperty(int hash, String name, Base value) throws FHIRException {
1248        switch (hash) {
1249        case 3059181: // code
1250          this.code = castToCodeableConcept(value); // CodeableConcept
1251          return value;
1252        case -1724546052: // description
1253          this.description = castToString(value); // StringType
1254          return value;
1255        case 1952046943: // criteria
1256          this.criteria = castToExpression(value); // Expression
1257          return value;
1258        default: return super.setProperty(hash, name, value);
1259        }
1260
1261      }
1262
1263      @Override
1264      public Base setProperty(String name, Base value) throws FHIRException {
1265        if (name.equals("code")) {
1266          this.code = castToCodeableConcept(value); // CodeableConcept
1267        } else if (name.equals("description")) {
1268          this.description = castToString(value); // StringType
1269        } else if (name.equals("criteria")) {
1270          this.criteria = castToExpression(value); // Expression
1271        } else
1272          return super.setProperty(name, value);
1273        return value;
1274      }
1275
1276      @Override
1277      public Base makeProperty(int hash, String name) throws FHIRException {
1278        switch (hash) {
1279        case 3059181:  return getCode(); 
1280        case -1724546052:  return getDescriptionElement();
1281        case 1952046943:  return getCriteria(); 
1282        default: return super.makeProperty(hash, name);
1283        }
1284
1285      }
1286
1287      @Override
1288      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1289        switch (hash) {
1290        case 3059181: /*code*/ return new String[] {"CodeableConcept"};
1291        case -1724546052: /*description*/ return new String[] {"string"};
1292        case 1952046943: /*criteria*/ return new String[] {"Expression"};
1293        default: return super.getTypesForProperty(hash, name);
1294        }
1295
1296      }
1297
1298      @Override
1299      public Base addChild(String name) throws FHIRException {
1300        if (name.equals("code")) {
1301          this.code = new CodeableConcept();
1302          return this.code;
1303        }
1304        else if (name.equals("description")) {
1305          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
1306        }
1307        else if (name.equals("criteria")) {
1308          this.criteria = new Expression();
1309          return this.criteria;
1310        }
1311        else
1312          return super.addChild(name);
1313      }
1314
1315      public MeasureGroupStratifierComponentComponent copy() {
1316        MeasureGroupStratifierComponentComponent dst = new MeasureGroupStratifierComponentComponent();
1317        copyValues(dst);
1318        dst.code = code == null ? null : code.copy();
1319        dst.description = description == null ? null : description.copy();
1320        dst.criteria = criteria == null ? null : criteria.copy();
1321        return dst;
1322      }
1323
1324      @Override
1325      public boolean equalsDeep(Base other_) {
1326        if (!super.equalsDeep(other_))
1327          return false;
1328        if (!(other_ instanceof MeasureGroupStratifierComponentComponent))
1329          return false;
1330        MeasureGroupStratifierComponentComponent o = (MeasureGroupStratifierComponentComponent) other_;
1331        return compareDeep(code, o.code, true) && compareDeep(description, o.description, true) && compareDeep(criteria, o.criteria, true)
1332          ;
1333      }
1334
1335      @Override
1336      public boolean equalsShallow(Base other_) {
1337        if (!super.equalsShallow(other_))
1338          return false;
1339        if (!(other_ instanceof MeasureGroupStratifierComponentComponent))
1340          return false;
1341        MeasureGroupStratifierComponentComponent o = (MeasureGroupStratifierComponentComponent) other_;
1342        return compareValues(description, o.description, true);
1343      }
1344
1345      public boolean isEmpty() {
1346        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, description, criteria
1347          );
1348      }
1349
1350  public String fhirType() {
1351    return "Measure.group.stratifier.component";
1352
1353  }
1354
1355  }
1356
1357    @Block()
1358    public static class MeasureSupplementalDataComponent extends BackboneElement implements IBaseBackboneElement {
1359        /**
1360         * Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures.
1361         */
1362        @Child(name = "code", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false)
1363        @Description(shortDefinition="Meaning of the supplemental data", formalDefinition="Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures." )
1364        protected CodeableConcept code;
1365
1366        /**
1367         * An indicator of the intended usage for the supplemental data element. Supplemental data indicates the data is additional information requested to augment the measure information. Risk adjustment factor indicates the data is additional information used to calculate risk adjustment factors when applying a risk model to the measure calculation.
1368         */
1369        @Child(name = "usage", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1370        @Description(shortDefinition="supplemental-data | risk-adjustment-factor", formalDefinition="An indicator of the intended usage for the supplemental data element. Supplemental data indicates the data is additional information requested to augment the measure information. Risk adjustment factor indicates the data is additional information used to calculate risk adjustment factors when applying a risk model to the measure calculation." )
1371        @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/measure-data-usage")
1372        protected List<CodeableConcept> usage;
1373
1374        /**
1375         * The human readable description of this supplemental data.
1376         */
1377        @Child(name = "description", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false)
1378        @Description(shortDefinition="The human readable description of this supplemental data", formalDefinition="The human readable description of this supplemental data." )
1379        protected StringType description;
1380
1381        /**
1382         * The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element.
1383         */
1384        @Child(name = "criteria", type = {Expression.class}, order=4, min=1, max=1, modifier=false, summary=false)
1385        @Description(shortDefinition="Expression describing additional data to be reported", formalDefinition="The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element." )
1386        protected Expression criteria;
1387
1388        private static final long serialVersionUID = -1897021670L;
1389
1390    /**
1391     * Constructor
1392     */
1393      public MeasureSupplementalDataComponent() {
1394        super();
1395      }
1396
1397    /**
1398     * Constructor
1399     */
1400      public MeasureSupplementalDataComponent(Expression criteria) {
1401        super();
1402        this.criteria = criteria;
1403      }
1404
1405        /**
1406         * @return {@link #code} (Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures.)
1407         */
1408        public CodeableConcept getCode() { 
1409          if (this.code == null)
1410            if (Configuration.errorOnAutoCreate())
1411              throw new Error("Attempt to auto-create MeasureSupplementalDataComponent.code");
1412            else if (Configuration.doAutoCreate())
1413              this.code = new CodeableConcept(); // cc
1414          return this.code;
1415        }
1416
1417        public boolean hasCode() { 
1418          return this.code != null && !this.code.isEmpty();
1419        }
1420
1421        /**
1422         * @param value {@link #code} (Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures.)
1423         */
1424        public MeasureSupplementalDataComponent setCode(CodeableConcept value) { 
1425          this.code = value;
1426          return this;
1427        }
1428
1429        /**
1430         * @return {@link #usage} (An indicator of the intended usage for the supplemental data element. Supplemental data indicates the data is additional information requested to augment the measure information. Risk adjustment factor indicates the data is additional information used to calculate risk adjustment factors when applying a risk model to the measure calculation.)
1431         */
1432        public List<CodeableConcept> getUsage() { 
1433          if (this.usage == null)
1434            this.usage = new ArrayList<CodeableConcept>();
1435          return this.usage;
1436        }
1437
1438        /**
1439         * @return Returns a reference to <code>this</code> for easy method chaining
1440         */
1441        public MeasureSupplementalDataComponent setUsage(List<CodeableConcept> theUsage) { 
1442          this.usage = theUsage;
1443          return this;
1444        }
1445
1446        public boolean hasUsage() { 
1447          if (this.usage == null)
1448            return false;
1449          for (CodeableConcept item : this.usage)
1450            if (!item.isEmpty())
1451              return true;
1452          return false;
1453        }
1454
1455        public CodeableConcept addUsage() { //3
1456          CodeableConcept t = new CodeableConcept();
1457          if (this.usage == null)
1458            this.usage = new ArrayList<CodeableConcept>();
1459          this.usage.add(t);
1460          return t;
1461        }
1462
1463        public MeasureSupplementalDataComponent addUsage(CodeableConcept t) { //3
1464          if (t == null)
1465            return this;
1466          if (this.usage == null)
1467            this.usage = new ArrayList<CodeableConcept>();
1468          this.usage.add(t);
1469          return this;
1470        }
1471
1472        /**
1473         * @return The first repetition of repeating field {@link #usage}, creating it if it does not already exist
1474         */
1475        public CodeableConcept getUsageFirstRep() { 
1476          if (getUsage().isEmpty()) {
1477            addUsage();
1478          }
1479          return getUsage().get(0);
1480        }
1481
1482        /**
1483         * @return {@link #description} (The human readable description of this supplemental data.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
1484         */
1485        public StringType getDescriptionElement() { 
1486          if (this.description == null)
1487            if (Configuration.errorOnAutoCreate())
1488              throw new Error("Attempt to auto-create MeasureSupplementalDataComponent.description");
1489            else if (Configuration.doAutoCreate())
1490              this.description = new StringType(); // bb
1491          return this.description;
1492        }
1493
1494        public boolean hasDescriptionElement() { 
1495          return this.description != null && !this.description.isEmpty();
1496        }
1497
1498        public boolean hasDescription() { 
1499          return this.description != null && !this.description.isEmpty();
1500        }
1501
1502        /**
1503         * @param value {@link #description} (The human readable description of this supplemental data.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
1504         */
1505        public MeasureSupplementalDataComponent setDescriptionElement(StringType value) { 
1506          this.description = value;
1507          return this;
1508        }
1509
1510        /**
1511         * @return The human readable description of this supplemental data.
1512         */
1513        public String getDescription() { 
1514          return this.description == null ? null : this.description.getValue();
1515        }
1516
1517        /**
1518         * @param value The human readable description of this supplemental data.
1519         */
1520        public MeasureSupplementalDataComponent setDescription(String value) { 
1521          if (Utilities.noString(value))
1522            this.description = null;
1523          else {
1524            if (this.description == null)
1525              this.description = new StringType();
1526            this.description.setValue(value);
1527          }
1528          return this;
1529        }
1530
1531        /**
1532         * @return {@link #criteria} (The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element.)
1533         */
1534        public Expression getCriteria() { 
1535          if (this.criteria == null)
1536            if (Configuration.errorOnAutoCreate())
1537              throw new Error("Attempt to auto-create MeasureSupplementalDataComponent.criteria");
1538            else if (Configuration.doAutoCreate())
1539              this.criteria = new Expression(); // cc
1540          return this.criteria;
1541        }
1542
1543        public boolean hasCriteria() { 
1544          return this.criteria != null && !this.criteria.isEmpty();
1545        }
1546
1547        /**
1548         * @param value {@link #criteria} (The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element.)
1549         */
1550        public MeasureSupplementalDataComponent setCriteria(Expression value) { 
1551          this.criteria = value;
1552          return this;
1553        }
1554
1555        protected void listChildren(List<Property> children) {
1556          super.listChildren(children);
1557          children.add(new Property("code", "CodeableConcept", "Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures.", 0, 1, code));
1558          children.add(new Property("usage", "CodeableConcept", "An indicator of the intended usage for the supplemental data element. Supplemental data indicates the data is additional information requested to augment the measure information. Risk adjustment factor indicates the data is additional information used to calculate risk adjustment factors when applying a risk model to the measure calculation.", 0, java.lang.Integer.MAX_VALUE, usage));
1559          children.add(new Property("description", "string", "The human readable description of this supplemental data.", 0, 1, description));
1560          children.add(new Property("criteria", "Expression", "The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element.", 0, 1, criteria));
1561        }
1562
1563        @Override
1564        public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1565          switch (_hash) {
1566          case 3059181: /*code*/  return new Property("code", "CodeableConcept", "Indicates a meaning for the supplemental data. This can be as simple as a unique identifier, or it can establish meaning in a broader context by drawing from a terminology, allowing supplemental data to be correlated across measures.", 0, 1, code);
1567          case 111574433: /*usage*/  return new Property("usage", "CodeableConcept", "An indicator of the intended usage for the supplemental data element. Supplemental data indicates the data is additional information requested to augment the measure information. Risk adjustment factor indicates the data is additional information used to calculate risk adjustment factors when applying a risk model to the measure calculation.", 0, java.lang.Integer.MAX_VALUE, usage);
1568          case -1724546052: /*description*/  return new Property("description", "string", "The human readable description of this supplemental data.", 0, 1, description);
1569          case 1952046943: /*criteria*/  return new Property("criteria", "Expression", "The criteria for the supplemental data. This is typically the name of a valid expression defined within a referenced library, but it may also be a path to a specific data element. The criteria defines the data to be returned for this element.", 0, 1, criteria);
1570          default: return super.getNamedProperty(_hash, _name, _checkValid);
1571          }
1572
1573        }
1574
1575      @Override
1576      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1577        switch (hash) {
1578        case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept
1579        case 111574433: /*usage*/ return this.usage == null ? new Base[0] : this.usage.toArray(new Base[this.usage.size()]); // CodeableConcept
1580        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType
1581        case 1952046943: /*criteria*/ return this.criteria == null ? new Base[0] : new Base[] {this.criteria}; // Expression
1582        default: return super.getProperty(hash, name, checkValid);
1583        }
1584
1585      }
1586
1587      @Override
1588      public Base setProperty(int hash, String name, Base value) throws FHIRException {
1589        switch (hash) {
1590        case 3059181: // code
1591          this.code = castToCodeableConcept(value); // CodeableConcept
1592          return value;
1593        case 111574433: // usage
1594          this.getUsage().add(castToCodeableConcept(value)); // CodeableConcept
1595          return value;
1596        case -1724546052: // description
1597          this.description = castToString(value); // StringType
1598          return value;
1599        case 1952046943: // criteria
1600          this.criteria = castToExpression(value); // Expression
1601          return value;
1602        default: return super.setProperty(hash, name, value);
1603        }
1604
1605      }
1606
1607      @Override
1608      public Base setProperty(String name, Base value) throws FHIRException {
1609        if (name.equals("code")) {
1610          this.code = castToCodeableConcept(value); // CodeableConcept
1611        } else if (name.equals("usage")) {
1612          this.getUsage().add(castToCodeableConcept(value));
1613        } else if (name.equals("description")) {
1614          this.description = castToString(value); // StringType
1615        } else if (name.equals("criteria")) {
1616          this.criteria = castToExpression(value); // Expression
1617        } else
1618          return super.setProperty(name, value);
1619        return value;
1620      }
1621
1622      @Override
1623      public Base makeProperty(int hash, String name) throws FHIRException {
1624        switch (hash) {
1625        case 3059181:  return getCode(); 
1626        case 111574433:  return addUsage(); 
1627        case -1724546052:  return getDescriptionElement();
1628        case 1952046943:  return getCriteria(); 
1629        default: return super.makeProperty(hash, name);
1630        }
1631
1632      }
1633
1634      @Override
1635      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1636        switch (hash) {
1637        case 3059181: /*code*/ return new String[] {"CodeableConcept"};
1638        case 111574433: /*usage*/ return new String[] {"CodeableConcept"};
1639        case -1724546052: /*description*/ return new String[] {"string"};
1640        case 1952046943: /*criteria*/ return new String[] {"Expression"};
1641        default: return super.getTypesForProperty(hash, name);
1642        }
1643
1644      }
1645
1646      @Override
1647      public Base addChild(String name) throws FHIRException {
1648        if (name.equals("code")) {
1649          this.code = new CodeableConcept();
1650          return this.code;
1651        }
1652        else if (name.equals("usage")) {
1653          return addUsage();
1654        }
1655        else if (name.equals("description")) {
1656          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
1657        }
1658        else if (name.equals("criteria")) {
1659          this.criteria = new Expression();
1660          return this.criteria;
1661        }
1662        else
1663          return super.addChild(name);
1664      }
1665
1666      public MeasureSupplementalDataComponent copy() {
1667        MeasureSupplementalDataComponent dst = new MeasureSupplementalDataComponent();
1668        copyValues(dst);
1669        dst.code = code == null ? null : code.copy();
1670        if (usage != null) {
1671          dst.usage = new ArrayList<CodeableConcept>();
1672          for (CodeableConcept i : usage)
1673            dst.usage.add(i.copy());
1674        };
1675        dst.description = description == null ? null : description.copy();
1676        dst.criteria = criteria == null ? null : criteria.copy();
1677        return dst;
1678      }
1679
1680      @Override
1681      public boolean equalsDeep(Base other_) {
1682        if (!super.equalsDeep(other_))
1683          return false;
1684        if (!(other_ instanceof MeasureSupplementalDataComponent))
1685          return false;
1686        MeasureSupplementalDataComponent o = (MeasureSupplementalDataComponent) other_;
1687        return compareDeep(code, o.code, true) && compareDeep(usage, o.usage, true) && compareDeep(description, o.description, true)
1688           && compareDeep(criteria, o.criteria, true);
1689      }
1690
1691      @Override
1692      public boolean equalsShallow(Base other_) {
1693        if (!super.equalsShallow(other_))
1694          return false;
1695        if (!(other_ instanceof MeasureSupplementalDataComponent))
1696          return false;
1697        MeasureSupplementalDataComponent o = (MeasureSupplementalDataComponent) other_;
1698        return compareValues(description, o.description, true);
1699      }
1700
1701      public boolean isEmpty() {
1702        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, usage, description
1703          , criteria);
1704      }
1705
1706  public String fhirType() {
1707    return "Measure.supplementalData";
1708
1709  }
1710
1711  }
1712
1713    /**
1714     * A formal identifier that is used to identify this measure when it is represented in other formats, or referenced in a specification, model, design or an instance.
1715     */
1716    @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
1717    @Description(shortDefinition="Additional identifier for the measure", formalDefinition="A formal identifier that is used to identify this measure when it is represented in other formats, or referenced in a specification, model, design or an instance." )
1718    protected List<Identifier> identifier;
1719
1720    /**
1721     * An explanatory or alternate title for the measure giving additional information about its content.
1722     */
1723    @Child(name = "subtitle", type = {StringType.class}, order=1, min=0, max=1, modifier=false, summary=false)
1724    @Description(shortDefinition="Subordinate title of the measure", formalDefinition="An explanatory or alternate title for the measure giving additional information about its content." )
1725    protected StringType subtitle;
1726
1727    /**
1728     * The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.
1729     */
1730    @Child(name = "subject", type = {CodeableConcept.class, Group.class}, order=2, min=0, max=1, modifier=false, summary=false)
1731    @Description(shortDefinition="E.g. Patient, Practitioner, RelatedPerson, Organization, Location, Device", formalDefinition="The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything." )
1732    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/subject-type")
1733    protected Type subject;
1734
1735    /**
1736     * Explanation of why this measure is needed and why it has been designed as it has.
1737     */
1738    @Child(name = "purpose", type = {MarkdownType.class}, order=3, min=0, max=1, modifier=false, summary=false)
1739    @Description(shortDefinition="Why this measure is defined", formalDefinition="Explanation of why this measure is needed and why it has been designed as it has." )
1740    protected MarkdownType purpose;
1741
1742    /**
1743     * A detailed description, from a clinical perspective, of how the measure is used.
1744     */
1745    @Child(name = "usage", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false)
1746    @Description(shortDefinition="Describes the clinical usage of the measure", formalDefinition="A detailed description, from a clinical perspective, of how the measure is used." )
1747    protected StringType usage;
1748
1749    /**
1750     * A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.
1751     */
1752    @Child(name = "copyright", type = {MarkdownType.class}, order=5, min=0, max=1, modifier=false, summary=false)
1753    @Description(shortDefinition="Use and/or publishing restrictions", formalDefinition="A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure." )
1754    protected MarkdownType copyright;
1755
1756    /**
1757     * The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.
1758     */
1759    @Child(name = "approvalDate", type = {DateType.class}, order=6, min=0, max=1, modifier=false, summary=false)
1760    @Description(shortDefinition="When the measure was approved by publisher", formalDefinition="The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage." )
1761    protected DateType approvalDate;
1762
1763    /**
1764     * The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.
1765     */
1766    @Child(name = "lastReviewDate", type = {DateType.class}, order=7, min=0, max=1, modifier=false, summary=false)
1767    @Description(shortDefinition="When the measure was last reviewed", formalDefinition="The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date." )
1768    protected DateType lastReviewDate;
1769
1770    /**
1771     * The period during which the measure content was or is planned to be in active use.
1772     */
1773    @Child(name = "effectivePeriod", type = {Period.class}, order=8, min=0, max=1, modifier=false, summary=true)
1774    @Description(shortDefinition="When the measure is expected to be used", formalDefinition="The period during which the measure content was or is planned to be in active use." )
1775    protected Period effectivePeriod;
1776
1777    /**
1778     * Descriptive topics related to the content of the measure. Topics provide a high-level categorization grouping types of measures that can be useful for filtering and searching.
1779     */
1780    @Child(name = "topic", type = {CodeableConcept.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1781    @Description(shortDefinition="The category of the measure, such as Education, Treatment, Assessment, etc.", formalDefinition="Descriptive topics related to the content of the measure. Topics provide a high-level categorization grouping types of measures that can be useful for filtering and searching." )
1782    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/definition-topic")
1783    protected List<CodeableConcept> topic;
1784
1785    /**
1786     * An individiual or organization primarily involved in the creation and maintenance of the content.
1787     */
1788    @Child(name = "author", type = {ContactDetail.class}, order=10, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1789    @Description(shortDefinition="Who authored the content", formalDefinition="An individiual or organization primarily involved in the creation and maintenance of the content." )
1790    protected List<ContactDetail> author;
1791
1792    /**
1793     * An individual or organization primarily responsible for internal coherence of the content.
1794     */
1795    @Child(name = "editor", type = {ContactDetail.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1796    @Description(shortDefinition="Who edited the content", formalDefinition="An individual or organization primarily responsible for internal coherence of the content." )
1797    protected List<ContactDetail> editor;
1798
1799    /**
1800     * An individual or organization primarily responsible for review of some aspect of the content.
1801     */
1802    @Child(name = "reviewer", type = {ContactDetail.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1803    @Description(shortDefinition="Who reviewed the content", formalDefinition="An individual or organization primarily responsible for review of some aspect of the content." )
1804    protected List<ContactDetail> reviewer;
1805
1806    /**
1807     * An individual or organization responsible for officially endorsing the content for use in some setting.
1808     */
1809    @Child(name = "endorser", type = {ContactDetail.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1810    @Description(shortDefinition="Who endorsed the content", formalDefinition="An individual or organization responsible for officially endorsing the content for use in some setting." )
1811    protected List<ContactDetail> endorser;
1812
1813    /**
1814     * Related artifacts such as additional documentation, justification, or bibliographic references.
1815     */
1816    @Child(name = "relatedArtifact", type = {RelatedArtifact.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1817    @Description(shortDefinition="Additional documentation, citations, etc.", formalDefinition="Related artifacts such as additional documentation, justification, or bibliographic references." )
1818    protected List<RelatedArtifact> relatedArtifact;
1819
1820    /**
1821     * A reference to a Library resource containing the formal logic used by the measure.
1822     */
1823    @Child(name = "library", type = {CanonicalType.class}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1824    @Description(shortDefinition="Logic used by the measure", formalDefinition="A reference to a Library resource containing the formal logic used by the measure." )
1825    protected List<CanonicalType> library;
1826
1827    /**
1828     * Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.
1829     */
1830    @Child(name = "disclaimer", type = {MarkdownType.class}, order=16, min=0, max=1, modifier=false, summary=true)
1831    @Description(shortDefinition="Disclaimer for use of the measure or its referenced content", formalDefinition="Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure." )
1832    protected MarkdownType disclaimer;
1833
1834    /**
1835     * Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented.
1836     */
1837    @Child(name = "scoring", type = {CodeableConcept.class}, order=17, min=0, max=1, modifier=false, summary=true)
1838    @Description(shortDefinition="proportion | ratio | continuous-variable | cohort", formalDefinition="Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented." )
1839    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/measure-scoring")
1840    protected CodeableConcept scoring;
1841
1842    /**
1843     * If this is a composite measure, the scoring method used to combine the component measures to determine the composite score.
1844     */
1845    @Child(name = "compositeScoring", type = {CodeableConcept.class}, order=18, min=0, max=1, modifier=false, summary=true)
1846    @Description(shortDefinition="opportunity | all-or-nothing | linear | weighted", formalDefinition="If this is a composite measure, the scoring method used to combine the component measures to determine the composite score." )
1847    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/composite-measure-scoring")
1848    protected CodeableConcept compositeScoring;
1849
1850    /**
1851     * Indicates whether the measure is used to examine a process, an outcome over time, a patient-reported outcome, or a structure measure such as utilization.
1852     */
1853    @Child(name = "type", type = {CodeableConcept.class}, order=19, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
1854    @Description(shortDefinition="process | outcome | structure | patient-reported-outcome | composite", formalDefinition="Indicates whether the measure is used to examine a process, an outcome over time, a patient-reported outcome, or a structure measure such as utilization." )
1855    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/measure-type")
1856    protected List<CodeableConcept> type;
1857
1858    /**
1859     * A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.
1860     */
1861    @Child(name = "riskAdjustment", type = {StringType.class}, order=20, min=0, max=1, modifier=false, summary=true)
1862    @Description(shortDefinition="How risk adjustment is applied for this measure", formalDefinition="A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results." )
1863    protected StringType riskAdjustment;
1864
1865    /**
1866     * Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.
1867     */
1868    @Child(name = "rateAggregation", type = {StringType.class}, order=21, min=0, max=1, modifier=false, summary=true)
1869    @Description(shortDefinition="How is rate aggregation performed for this measure", formalDefinition="Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result." )
1870    protected StringType rateAggregation;
1871
1872    /**
1873     * Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.
1874     */
1875    @Child(name = "rationale", type = {MarkdownType.class}, order=22, min=0, max=1, modifier=false, summary=true)
1876    @Description(shortDefinition="Detailed description of why the measure exists", formalDefinition="Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence." )
1877    protected MarkdownType rationale;
1878
1879    /**
1880     * Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.
1881     */
1882    @Child(name = "clinicalRecommendationStatement", type = {MarkdownType.class}, order=23, min=0, max=1, modifier=false, summary=true)
1883    @Description(shortDefinition="Summary of clinical guidelines", formalDefinition="Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure." )
1884    protected MarkdownType clinicalRecommendationStatement;
1885
1886    /**
1887     * Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range).
1888     */
1889    @Child(name = "improvementNotation", type = {CodeableConcept.class}, order=24, min=0, max=1, modifier=false, summary=true)
1890    @Description(shortDefinition="increase | decrease", formalDefinition="Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range)." )
1891    @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/measure-improvement-notation")
1892    protected CodeableConcept improvementNotation;
1893
1894    /**
1895     * Provides a description of an individual term used within the measure.
1896     */
1897    @Child(name = "definition", type = {MarkdownType.class}, order=25, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true)
1898    @Description(shortDefinition="Defined terms used in the measure documentation", formalDefinition="Provides a description of an individual term used within the measure." )
1899    protected List<MarkdownType> definition;
1900
1901    /**
1902     * Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.
1903     */
1904    @Child(name = "guidance", type = {MarkdownType.class}, order=26, min=0, max=1, modifier=false, summary=true)
1905    @Description(shortDefinition="Additional guidance for implementers", formalDefinition="Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure." )
1906    protected MarkdownType guidance;
1907
1908    /**
1909     * A group of population criteria for the measure.
1910     */
1911    @Child(name = "group", type = {}, order=27, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1912    @Description(shortDefinition="Population criteria group", formalDefinition="A group of population criteria for the measure." )
1913    protected List<MeasureGroupComponent> group;
1914
1915    /**
1916     * The supplemental data criteria for the measure report, specified as either the name of a valid CQL expression within a referenced library, or a valid FHIR Resource Path.
1917     */
1918    @Child(name = "supplementalData", type = {}, order=28, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false)
1919    @Description(shortDefinition="What other data should be reported with the measure", formalDefinition="The supplemental data criteria for the measure report, specified as either the name of a valid CQL expression within a referenced library, or a valid FHIR Resource Path." )
1920    protected List<MeasureSupplementalDataComponent> supplementalData;
1921
1922    private static final long serialVersionUID = 341731972L;
1923
1924  /**
1925   * Constructor
1926   */
1927    public Measure() {
1928      super();
1929    }
1930
1931  /**
1932   * Constructor
1933   */
1934    public Measure(Enumeration<PublicationStatus> status) {
1935      super();
1936      this.status = status;
1937    }
1938
1939    /**
1940     * @return {@link #url} (An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value
1941     */
1942    public UriType getUrlElement() { 
1943      if (this.url == null)
1944        if (Configuration.errorOnAutoCreate())
1945          throw new Error("Attempt to auto-create Measure.url");
1946        else if (Configuration.doAutoCreate())
1947          this.url = new UriType(); // bb
1948      return this.url;
1949    }
1950
1951    public boolean hasUrlElement() { 
1952      return this.url != null && !this.url.isEmpty();
1953    }
1954
1955    public boolean hasUrl() { 
1956      return this.url != null && !this.url.isEmpty();
1957    }
1958
1959    /**
1960     * @param value {@link #url} (An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value
1961     */
1962    public Measure setUrlElement(UriType value) { 
1963      this.url = value;
1964      return this;
1965    }
1966
1967    /**
1968     * @return An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.
1969     */
1970    public String getUrl() { 
1971      return this.url == null ? null : this.url.getValue();
1972    }
1973
1974    /**
1975     * @param value An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.
1976     */
1977    public Measure setUrl(String value) { 
1978      if (Utilities.noString(value))
1979        this.url = null;
1980      else {
1981        if (this.url == null)
1982          this.url = new UriType();
1983        this.url.setValue(value);
1984      }
1985      return this;
1986    }
1987
1988    /**
1989     * @return {@link #identifier} (A formal identifier that is used to identify this measure when it is represented in other formats, or referenced in a specification, model, design or an instance.)
1990     */
1991    public List<Identifier> getIdentifier() { 
1992      if (this.identifier == null)
1993        this.identifier = new ArrayList<Identifier>();
1994      return this.identifier;
1995    }
1996
1997    /**
1998     * @return Returns a reference to <code>this</code> for easy method chaining
1999     */
2000    public Measure setIdentifier(List<Identifier> theIdentifier) { 
2001      this.identifier = theIdentifier;
2002      return this;
2003    }
2004
2005    public boolean hasIdentifier() { 
2006      if (this.identifier == null)
2007        return false;
2008      for (Identifier item : this.identifier)
2009        if (!item.isEmpty())
2010          return true;
2011      return false;
2012    }
2013
2014    public Identifier addIdentifier() { //3
2015      Identifier t = new Identifier();
2016      if (this.identifier == null)
2017        this.identifier = new ArrayList<Identifier>();
2018      this.identifier.add(t);
2019      return t;
2020    }
2021
2022    public Measure addIdentifier(Identifier t) { //3
2023      if (t == null)
2024        return this;
2025      if (this.identifier == null)
2026        this.identifier = new ArrayList<Identifier>();
2027      this.identifier.add(t);
2028      return this;
2029    }
2030
2031    /**
2032     * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist
2033     */
2034    public Identifier getIdentifierFirstRep() { 
2035      if (getIdentifier().isEmpty()) {
2036        addIdentifier();
2037      }
2038      return getIdentifier().get(0);
2039    }
2040
2041    /**
2042     * @return {@link #version} (The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value
2043     */
2044    public StringType getVersionElement() { 
2045      if (this.version == null)
2046        if (Configuration.errorOnAutoCreate())
2047          throw new Error("Attempt to auto-create Measure.version");
2048        else if (Configuration.doAutoCreate())
2049          this.version = new StringType(); // bb
2050      return this.version;
2051    }
2052
2053    public boolean hasVersionElement() { 
2054      return this.version != null && !this.version.isEmpty();
2055    }
2056
2057    public boolean hasVersion() { 
2058      return this.version != null && !this.version.isEmpty();
2059    }
2060
2061    /**
2062     * @param value {@link #version} (The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value
2063     */
2064    public Measure setVersionElement(StringType value) { 
2065      this.version = value;
2066      return this;
2067    }
2068
2069    /**
2070     * @return The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.
2071     */
2072    public String getVersion() { 
2073      return this.version == null ? null : this.version.getValue();
2074    }
2075
2076    /**
2077     * @param value The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.
2078     */
2079    public Measure setVersion(String value) { 
2080      if (Utilities.noString(value))
2081        this.version = null;
2082      else {
2083        if (this.version == null)
2084          this.version = new StringType();
2085        this.version.setValue(value);
2086      }
2087      return this;
2088    }
2089
2090    /**
2091     * @return {@link #name} (A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
2092     */
2093    public StringType getNameElement() { 
2094      if (this.name == null)
2095        if (Configuration.errorOnAutoCreate())
2096          throw new Error("Attempt to auto-create Measure.name");
2097        else if (Configuration.doAutoCreate())
2098          this.name = new StringType(); // bb
2099      return this.name;
2100    }
2101
2102    public boolean hasNameElement() { 
2103      return this.name != null && !this.name.isEmpty();
2104    }
2105
2106    public boolean hasName() { 
2107      return this.name != null && !this.name.isEmpty();
2108    }
2109
2110    /**
2111     * @param value {@link #name} (A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value
2112     */
2113    public Measure setNameElement(StringType value) { 
2114      this.name = value;
2115      return this;
2116    }
2117
2118    /**
2119     * @return A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.
2120     */
2121    public String getName() { 
2122      return this.name == null ? null : this.name.getValue();
2123    }
2124
2125    /**
2126     * @param value A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.
2127     */
2128    public Measure setName(String value) { 
2129      if (Utilities.noString(value))
2130        this.name = null;
2131      else {
2132        if (this.name == null)
2133          this.name = new StringType();
2134        this.name.setValue(value);
2135      }
2136      return this;
2137    }
2138
2139    /**
2140     * @return {@link #title} (A short, descriptive, user-friendly title for the measure.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
2141     */
2142    public StringType getTitleElement() { 
2143      if (this.title == null)
2144        if (Configuration.errorOnAutoCreate())
2145          throw new Error("Attempt to auto-create Measure.title");
2146        else if (Configuration.doAutoCreate())
2147          this.title = new StringType(); // bb
2148      return this.title;
2149    }
2150
2151    public boolean hasTitleElement() { 
2152      return this.title != null && !this.title.isEmpty();
2153    }
2154
2155    public boolean hasTitle() { 
2156      return this.title != null && !this.title.isEmpty();
2157    }
2158
2159    /**
2160     * @param value {@link #title} (A short, descriptive, user-friendly title for the measure.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value
2161     */
2162    public Measure setTitleElement(StringType value) { 
2163      this.title = value;
2164      return this;
2165    }
2166
2167    /**
2168     * @return A short, descriptive, user-friendly title for the measure.
2169     */
2170    public String getTitle() { 
2171      return this.title == null ? null : this.title.getValue();
2172    }
2173
2174    /**
2175     * @param value A short, descriptive, user-friendly title for the measure.
2176     */
2177    public Measure setTitle(String value) { 
2178      if (Utilities.noString(value))
2179        this.title = null;
2180      else {
2181        if (this.title == null)
2182          this.title = new StringType();
2183        this.title.setValue(value);
2184      }
2185      return this;
2186    }
2187
2188    /**
2189     * @return {@link #subtitle} (An explanatory or alternate title for the measure giving additional information about its content.). This is the underlying object with id, value and extensions. The accessor "getSubtitle" gives direct access to the value
2190     */
2191    public StringType getSubtitleElement() { 
2192      if (this.subtitle == null)
2193        if (Configuration.errorOnAutoCreate())
2194          throw new Error("Attempt to auto-create Measure.subtitle");
2195        else if (Configuration.doAutoCreate())
2196          this.subtitle = new StringType(); // bb
2197      return this.subtitle;
2198    }
2199
2200    public boolean hasSubtitleElement() { 
2201      return this.subtitle != null && !this.subtitle.isEmpty();
2202    }
2203
2204    public boolean hasSubtitle() { 
2205      return this.subtitle != null && !this.subtitle.isEmpty();
2206    }
2207
2208    /**
2209     * @param value {@link #subtitle} (An explanatory or alternate title for the measure giving additional information about its content.). This is the underlying object with id, value and extensions. The accessor "getSubtitle" gives direct access to the value
2210     */
2211    public Measure setSubtitleElement(StringType value) { 
2212      this.subtitle = value;
2213      return this;
2214    }
2215
2216    /**
2217     * @return An explanatory or alternate title for the measure giving additional information about its content.
2218     */
2219    public String getSubtitle() { 
2220      return this.subtitle == null ? null : this.subtitle.getValue();
2221    }
2222
2223    /**
2224     * @param value An explanatory or alternate title for the measure giving additional information about its content.
2225     */
2226    public Measure setSubtitle(String value) { 
2227      if (Utilities.noString(value))
2228        this.subtitle = null;
2229      else {
2230        if (this.subtitle == null)
2231          this.subtitle = new StringType();
2232        this.subtitle.setValue(value);
2233      }
2234      return this;
2235    }
2236
2237    /**
2238     * @return {@link #status} (The status of this measure. Enables tracking the life-cycle of the content.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
2239     */
2240    public Enumeration<PublicationStatus> getStatusElement() { 
2241      if (this.status == null)
2242        if (Configuration.errorOnAutoCreate())
2243          throw new Error("Attempt to auto-create Measure.status");
2244        else if (Configuration.doAutoCreate())
2245          this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb
2246      return this.status;
2247    }
2248
2249    public boolean hasStatusElement() { 
2250      return this.status != null && !this.status.isEmpty();
2251    }
2252
2253    public boolean hasStatus() { 
2254      return this.status != null && !this.status.isEmpty();
2255    }
2256
2257    /**
2258     * @param value {@link #status} (The status of this measure. Enables tracking the life-cycle of the content.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value
2259     */
2260    public Measure setStatusElement(Enumeration<PublicationStatus> value) { 
2261      this.status = value;
2262      return this;
2263    }
2264
2265    /**
2266     * @return The status of this measure. Enables tracking the life-cycle of the content.
2267     */
2268    public PublicationStatus getStatus() { 
2269      return this.status == null ? null : this.status.getValue();
2270    }
2271
2272    /**
2273     * @param value The status of this measure. Enables tracking the life-cycle of the content.
2274     */
2275    public Measure setStatus(PublicationStatus value) { 
2276        if (this.status == null)
2277          this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory());
2278        this.status.setValue(value);
2279      return this;
2280    }
2281
2282    /**
2283     * @return {@link #experimental} (A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value
2284     */
2285    public BooleanType getExperimentalElement() { 
2286      if (this.experimental == null)
2287        if (Configuration.errorOnAutoCreate())
2288          throw new Error("Attempt to auto-create Measure.experimental");
2289        else if (Configuration.doAutoCreate())
2290          this.experimental = new BooleanType(); // bb
2291      return this.experimental;
2292    }
2293
2294    public boolean hasExperimentalElement() { 
2295      return this.experimental != null && !this.experimental.isEmpty();
2296    }
2297
2298    public boolean hasExperimental() { 
2299      return this.experimental != null && !this.experimental.isEmpty();
2300    }
2301
2302    /**
2303     * @param value {@link #experimental} (A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value
2304     */
2305    public Measure setExperimentalElement(BooleanType value) { 
2306      this.experimental = value;
2307      return this;
2308    }
2309
2310    /**
2311     * @return A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.
2312     */
2313    public boolean getExperimental() { 
2314      return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue();
2315    }
2316
2317    /**
2318     * @param value A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.
2319     */
2320    public Measure setExperimental(boolean value) { 
2321        if (this.experimental == null)
2322          this.experimental = new BooleanType();
2323        this.experimental.setValue(value);
2324      return this;
2325    }
2326
2327    /**
2328     * @return {@link #subject} (The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.)
2329     */
2330    public Type getSubject() { 
2331      return this.subject;
2332    }
2333
2334    /**
2335     * @return {@link #subject} (The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.)
2336     */
2337    public CodeableConcept getSubjectCodeableConcept() throws FHIRException { 
2338      if (this.subject == null)
2339        this.subject = new CodeableConcept();
2340      if (!(this.subject instanceof CodeableConcept))
2341        throw new FHIRException("Type mismatch: the type CodeableConcept was expected, but "+this.subject.getClass().getName()+" was encountered");
2342      return (CodeableConcept) this.subject;
2343    }
2344
2345    public boolean hasSubjectCodeableConcept() { 
2346      return this != null && this.subject instanceof CodeableConcept;
2347    }
2348
2349    /**
2350     * @return {@link #subject} (The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.)
2351     */
2352    public Reference getSubjectReference() throws FHIRException { 
2353      if (this.subject == null)
2354        this.subject = new Reference();
2355      if (!(this.subject instanceof Reference))
2356        throw new FHIRException("Type mismatch: the type Reference was expected, but "+this.subject.getClass().getName()+" was encountered");
2357      return (Reference) this.subject;
2358    }
2359
2360    public boolean hasSubjectReference() { 
2361      return this != null && this.subject instanceof Reference;
2362    }
2363
2364    public boolean hasSubject() { 
2365      return this.subject != null && !this.subject.isEmpty();
2366    }
2367
2368    /**
2369     * @param value {@link #subject} (The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.)
2370     */
2371    public Measure setSubject(Type value) { 
2372      if (value != null && !(value instanceof CodeableConcept || value instanceof Reference))
2373        throw new Error("Not the right type for Measure.subject[x]: "+value.fhirType());
2374      this.subject = value;
2375      return this;
2376    }
2377
2378    /**
2379     * @return {@link #date} (The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
2380     */
2381    public DateTimeType getDateElement() { 
2382      if (this.date == null)
2383        if (Configuration.errorOnAutoCreate())
2384          throw new Error("Attempt to auto-create Measure.date");
2385        else if (Configuration.doAutoCreate())
2386          this.date = new DateTimeType(); // bb
2387      return this.date;
2388    }
2389
2390    public boolean hasDateElement() { 
2391      return this.date != null && !this.date.isEmpty();
2392    }
2393
2394    public boolean hasDate() { 
2395      return this.date != null && !this.date.isEmpty();
2396    }
2397
2398    /**
2399     * @param value {@link #date} (The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value
2400     */
2401    public Measure setDateElement(DateTimeType value) { 
2402      this.date = value;
2403      return this;
2404    }
2405
2406    /**
2407     * @return The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.
2408     */
2409    public Date getDate() { 
2410      return this.date == null ? null : this.date.getValue();
2411    }
2412
2413    /**
2414     * @param value The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.
2415     */
2416    public Measure setDate(Date value) { 
2417      if (value == null)
2418        this.date = null;
2419      else {
2420        if (this.date == null)
2421          this.date = new DateTimeType();
2422        this.date.setValue(value);
2423      }
2424      return this;
2425    }
2426
2427    /**
2428     * @return {@link #publisher} (The name of the organization or individual that published the measure.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value
2429     */
2430    public StringType getPublisherElement() { 
2431      if (this.publisher == null)
2432        if (Configuration.errorOnAutoCreate())
2433          throw new Error("Attempt to auto-create Measure.publisher");
2434        else if (Configuration.doAutoCreate())
2435          this.publisher = new StringType(); // bb
2436      return this.publisher;
2437    }
2438
2439    public boolean hasPublisherElement() { 
2440      return this.publisher != null && !this.publisher.isEmpty();
2441    }
2442
2443    public boolean hasPublisher() { 
2444      return this.publisher != null && !this.publisher.isEmpty();
2445    }
2446
2447    /**
2448     * @param value {@link #publisher} (The name of the organization or individual that published the measure.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value
2449     */
2450    public Measure setPublisherElement(StringType value) { 
2451      this.publisher = value;
2452      return this;
2453    }
2454
2455    /**
2456     * @return The name of the organization or individual that published the measure.
2457     */
2458    public String getPublisher() { 
2459      return this.publisher == null ? null : this.publisher.getValue();
2460    }
2461
2462    /**
2463     * @param value The name of the organization or individual that published the measure.
2464     */
2465    public Measure setPublisher(String value) { 
2466      if (Utilities.noString(value))
2467        this.publisher = null;
2468      else {
2469        if (this.publisher == null)
2470          this.publisher = new StringType();
2471        this.publisher.setValue(value);
2472      }
2473      return this;
2474    }
2475
2476    /**
2477     * @return {@link #contact} (Contact details to assist a user in finding and communicating with the publisher.)
2478     */
2479    public List<ContactDetail> getContact() { 
2480      if (this.contact == null)
2481        this.contact = new ArrayList<ContactDetail>();
2482      return this.contact;
2483    }
2484
2485    /**
2486     * @return Returns a reference to <code>this</code> for easy method chaining
2487     */
2488    public Measure setContact(List<ContactDetail> theContact) { 
2489      this.contact = theContact;
2490      return this;
2491    }
2492
2493    public boolean hasContact() { 
2494      if (this.contact == null)
2495        return false;
2496      for (ContactDetail item : this.contact)
2497        if (!item.isEmpty())
2498          return true;
2499      return false;
2500    }
2501
2502    public ContactDetail addContact() { //3
2503      ContactDetail t = new ContactDetail();
2504      if (this.contact == null)
2505        this.contact = new ArrayList<ContactDetail>();
2506      this.contact.add(t);
2507      return t;
2508    }
2509
2510    public Measure addContact(ContactDetail t) { //3
2511      if (t == null)
2512        return this;
2513      if (this.contact == null)
2514        this.contact = new ArrayList<ContactDetail>();
2515      this.contact.add(t);
2516      return this;
2517    }
2518
2519    /**
2520     * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist
2521     */
2522    public ContactDetail getContactFirstRep() { 
2523      if (getContact().isEmpty()) {
2524        addContact();
2525      }
2526      return getContact().get(0);
2527    }
2528
2529    /**
2530     * @return {@link #description} (A free text natural language description of the measure from a consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
2531     */
2532    public MarkdownType getDescriptionElement() { 
2533      if (this.description == null)
2534        if (Configuration.errorOnAutoCreate())
2535          throw new Error("Attempt to auto-create Measure.description");
2536        else if (Configuration.doAutoCreate())
2537          this.description = new MarkdownType(); // bb
2538      return this.description;
2539    }
2540
2541    public boolean hasDescriptionElement() { 
2542      return this.description != null && !this.description.isEmpty();
2543    }
2544
2545    public boolean hasDescription() { 
2546      return this.description != null && !this.description.isEmpty();
2547    }
2548
2549    /**
2550     * @param value {@link #description} (A free text natural language description of the measure from a consumer's perspective.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value
2551     */
2552    public Measure setDescriptionElement(MarkdownType value) { 
2553      this.description = value;
2554      return this;
2555    }
2556
2557    /**
2558     * @return A free text natural language description of the measure from a consumer's perspective.
2559     */
2560    public String getDescription() { 
2561      return this.description == null ? null : this.description.getValue();
2562    }
2563
2564    /**
2565     * @param value A free text natural language description of the measure from a consumer's perspective.
2566     */
2567    public Measure setDescription(String value) { 
2568      if (value == null)
2569        this.description = null;
2570      else {
2571        if (this.description == null)
2572          this.description = new MarkdownType();
2573        this.description.setValue(value);
2574      }
2575      return this;
2576    }
2577
2578    /**
2579     * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate measure instances.)
2580     */
2581    public List<UsageContext> getUseContext() { 
2582      if (this.useContext == null)
2583        this.useContext = new ArrayList<UsageContext>();
2584      return this.useContext;
2585    }
2586
2587    /**
2588     * @return Returns a reference to <code>this</code> for easy method chaining
2589     */
2590    public Measure setUseContext(List<UsageContext> theUseContext) { 
2591      this.useContext = theUseContext;
2592      return this;
2593    }
2594
2595    public boolean hasUseContext() { 
2596      if (this.useContext == null)
2597        return false;
2598      for (UsageContext item : this.useContext)
2599        if (!item.isEmpty())
2600          return true;
2601      return false;
2602    }
2603
2604    public UsageContext addUseContext() { //3
2605      UsageContext t = new UsageContext();
2606      if (this.useContext == null)
2607        this.useContext = new ArrayList<UsageContext>();
2608      this.useContext.add(t);
2609      return t;
2610    }
2611
2612    public Measure addUseContext(UsageContext t) { //3
2613      if (t == null)
2614        return this;
2615      if (this.useContext == null)
2616        this.useContext = new ArrayList<UsageContext>();
2617      this.useContext.add(t);
2618      return this;
2619    }
2620
2621    /**
2622     * @return The first repetition of repeating field {@link #useContext}, creating it if it does not already exist
2623     */
2624    public UsageContext getUseContextFirstRep() { 
2625      if (getUseContext().isEmpty()) {
2626        addUseContext();
2627      }
2628      return getUseContext().get(0);
2629    }
2630
2631    /**
2632     * @return {@link #jurisdiction} (A legal or geographic region in which the measure is intended to be used.)
2633     */
2634    public List<CodeableConcept> getJurisdiction() { 
2635      if (this.jurisdiction == null)
2636        this.jurisdiction = new ArrayList<CodeableConcept>();
2637      return this.jurisdiction;
2638    }
2639
2640    /**
2641     * @return Returns a reference to <code>this</code> for easy method chaining
2642     */
2643    public Measure setJurisdiction(List<CodeableConcept> theJurisdiction) { 
2644      this.jurisdiction = theJurisdiction;
2645      return this;
2646    }
2647
2648    public boolean hasJurisdiction() { 
2649      if (this.jurisdiction == null)
2650        return false;
2651      for (CodeableConcept item : this.jurisdiction)
2652        if (!item.isEmpty())
2653          return true;
2654      return false;
2655    }
2656
2657    public CodeableConcept addJurisdiction() { //3
2658      CodeableConcept t = new CodeableConcept();
2659      if (this.jurisdiction == null)
2660        this.jurisdiction = new ArrayList<CodeableConcept>();
2661      this.jurisdiction.add(t);
2662      return t;
2663    }
2664
2665    public Measure addJurisdiction(CodeableConcept t) { //3
2666      if (t == null)
2667        return this;
2668      if (this.jurisdiction == null)
2669        this.jurisdiction = new ArrayList<CodeableConcept>();
2670      this.jurisdiction.add(t);
2671      return this;
2672    }
2673
2674    /**
2675     * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist
2676     */
2677    public CodeableConcept getJurisdictionFirstRep() { 
2678      if (getJurisdiction().isEmpty()) {
2679        addJurisdiction();
2680      }
2681      return getJurisdiction().get(0);
2682    }
2683
2684    /**
2685     * @return {@link #purpose} (Explanation of why this measure is needed and why it has been designed as it has.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value
2686     */
2687    public MarkdownType getPurposeElement() { 
2688      if (this.purpose == null)
2689        if (Configuration.errorOnAutoCreate())
2690          throw new Error("Attempt to auto-create Measure.purpose");
2691        else if (Configuration.doAutoCreate())
2692          this.purpose = new MarkdownType(); // bb
2693      return this.purpose;
2694    }
2695
2696    public boolean hasPurposeElement() { 
2697      return this.purpose != null && !this.purpose.isEmpty();
2698    }
2699
2700    public boolean hasPurpose() { 
2701      return this.purpose != null && !this.purpose.isEmpty();
2702    }
2703
2704    /**
2705     * @param value {@link #purpose} (Explanation of why this measure is needed and why it has been designed as it has.). This is the underlying object with id, value and extensions. The accessor "getPurpose" gives direct access to the value
2706     */
2707    public Measure setPurposeElement(MarkdownType value) { 
2708      this.purpose = value;
2709      return this;
2710    }
2711
2712    /**
2713     * @return Explanation of why this measure is needed and why it has been designed as it has.
2714     */
2715    public String getPurpose() { 
2716      return this.purpose == null ? null : this.purpose.getValue();
2717    }
2718
2719    /**
2720     * @param value Explanation of why this measure is needed and why it has been designed as it has.
2721     */
2722    public Measure setPurpose(String value) { 
2723      if (value == null)
2724        this.purpose = null;
2725      else {
2726        if (this.purpose == null)
2727          this.purpose = new MarkdownType();
2728        this.purpose.setValue(value);
2729      }
2730      return this;
2731    }
2732
2733    /**
2734     * @return {@link #usage} (A detailed description, from a clinical perspective, of how the measure is used.). This is the underlying object with id, value and extensions. The accessor "getUsage" gives direct access to the value
2735     */
2736    public StringType getUsageElement() { 
2737      if (this.usage == null)
2738        if (Configuration.errorOnAutoCreate())
2739          throw new Error("Attempt to auto-create Measure.usage");
2740        else if (Configuration.doAutoCreate())
2741          this.usage = new StringType(); // bb
2742      return this.usage;
2743    }
2744
2745    public boolean hasUsageElement() { 
2746      return this.usage != null && !this.usage.isEmpty();
2747    }
2748
2749    public boolean hasUsage() { 
2750      return this.usage != null && !this.usage.isEmpty();
2751    }
2752
2753    /**
2754     * @param value {@link #usage} (A detailed description, from a clinical perspective, of how the measure is used.). This is the underlying object with id, value and extensions. The accessor "getUsage" gives direct access to the value
2755     */
2756    public Measure setUsageElement(StringType value) { 
2757      this.usage = value;
2758      return this;
2759    }
2760
2761    /**
2762     * @return A detailed description, from a clinical perspective, of how the measure is used.
2763     */
2764    public String getUsage() { 
2765      return this.usage == null ? null : this.usage.getValue();
2766    }
2767
2768    /**
2769     * @param value A detailed description, from a clinical perspective, of how the measure is used.
2770     */
2771    public Measure setUsage(String value) { 
2772      if (Utilities.noString(value))
2773        this.usage = null;
2774      else {
2775        if (this.usage == null)
2776          this.usage = new StringType();
2777        this.usage.setValue(value);
2778      }
2779      return this;
2780    }
2781
2782    /**
2783     * @return {@link #copyright} (A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value
2784     */
2785    public MarkdownType getCopyrightElement() { 
2786      if (this.copyright == null)
2787        if (Configuration.errorOnAutoCreate())
2788          throw new Error("Attempt to auto-create Measure.copyright");
2789        else if (Configuration.doAutoCreate())
2790          this.copyright = new MarkdownType(); // bb
2791      return this.copyright;
2792    }
2793
2794    public boolean hasCopyrightElement() { 
2795      return this.copyright != null && !this.copyright.isEmpty();
2796    }
2797
2798    public boolean hasCopyright() { 
2799      return this.copyright != null && !this.copyright.isEmpty();
2800    }
2801
2802    /**
2803     * @param value {@link #copyright} (A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value
2804     */
2805    public Measure setCopyrightElement(MarkdownType value) { 
2806      this.copyright = value;
2807      return this;
2808    }
2809
2810    /**
2811     * @return A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.
2812     */
2813    public String getCopyright() { 
2814      return this.copyright == null ? null : this.copyright.getValue();
2815    }
2816
2817    /**
2818     * @param value A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.
2819     */
2820    public Measure setCopyright(String value) { 
2821      if (value == null)
2822        this.copyright = null;
2823      else {
2824        if (this.copyright == null)
2825          this.copyright = new MarkdownType();
2826        this.copyright.setValue(value);
2827      }
2828      return this;
2829    }
2830
2831    /**
2832     * @return {@link #approvalDate} (The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.). This is the underlying object with id, value and extensions. The accessor "getApprovalDate" gives direct access to the value
2833     */
2834    public DateType getApprovalDateElement() { 
2835      if (this.approvalDate == null)
2836        if (Configuration.errorOnAutoCreate())
2837          throw new Error("Attempt to auto-create Measure.approvalDate");
2838        else if (Configuration.doAutoCreate())
2839          this.approvalDate = new DateType(); // bb
2840      return this.approvalDate;
2841    }
2842
2843    public boolean hasApprovalDateElement() { 
2844      return this.approvalDate != null && !this.approvalDate.isEmpty();
2845    }
2846
2847    public boolean hasApprovalDate() { 
2848      return this.approvalDate != null && !this.approvalDate.isEmpty();
2849    }
2850
2851    /**
2852     * @param value {@link #approvalDate} (The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.). This is the underlying object with id, value and extensions. The accessor "getApprovalDate" gives direct access to the value
2853     */
2854    public Measure setApprovalDateElement(DateType value) { 
2855      this.approvalDate = value;
2856      return this;
2857    }
2858
2859    /**
2860     * @return The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.
2861     */
2862    public Date getApprovalDate() { 
2863      return this.approvalDate == null ? null : this.approvalDate.getValue();
2864    }
2865
2866    /**
2867     * @param value The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.
2868     */
2869    public Measure setApprovalDate(Date value) { 
2870      if (value == null)
2871        this.approvalDate = null;
2872      else {
2873        if (this.approvalDate == null)
2874          this.approvalDate = new DateType();
2875        this.approvalDate.setValue(value);
2876      }
2877      return this;
2878    }
2879
2880    /**
2881     * @return {@link #lastReviewDate} (The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.). This is the underlying object with id, value and extensions. The accessor "getLastReviewDate" gives direct access to the value
2882     */
2883    public DateType getLastReviewDateElement() { 
2884      if (this.lastReviewDate == null)
2885        if (Configuration.errorOnAutoCreate())
2886          throw new Error("Attempt to auto-create Measure.lastReviewDate");
2887        else if (Configuration.doAutoCreate())
2888          this.lastReviewDate = new DateType(); // bb
2889      return this.lastReviewDate;
2890    }
2891
2892    public boolean hasLastReviewDateElement() { 
2893      return this.lastReviewDate != null && !this.lastReviewDate.isEmpty();
2894    }
2895
2896    public boolean hasLastReviewDate() { 
2897      return this.lastReviewDate != null && !this.lastReviewDate.isEmpty();
2898    }
2899
2900    /**
2901     * @param value {@link #lastReviewDate} (The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.). This is the underlying object with id, value and extensions. The accessor "getLastReviewDate" gives direct access to the value
2902     */
2903    public Measure setLastReviewDateElement(DateType value) { 
2904      this.lastReviewDate = value;
2905      return this;
2906    }
2907
2908    /**
2909     * @return The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.
2910     */
2911    public Date getLastReviewDate() { 
2912      return this.lastReviewDate == null ? null : this.lastReviewDate.getValue();
2913    }
2914
2915    /**
2916     * @param value The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.
2917     */
2918    public Measure setLastReviewDate(Date value) { 
2919      if (value == null)
2920        this.lastReviewDate = null;
2921      else {
2922        if (this.lastReviewDate == null)
2923          this.lastReviewDate = new DateType();
2924        this.lastReviewDate.setValue(value);
2925      }
2926      return this;
2927    }
2928
2929    /**
2930     * @return {@link #effectivePeriod} (The period during which the measure content was or is planned to be in active use.)
2931     */
2932    public Period getEffectivePeriod() { 
2933      if (this.effectivePeriod == null)
2934        if (Configuration.errorOnAutoCreate())
2935          throw new Error("Attempt to auto-create Measure.effectivePeriod");
2936        else if (Configuration.doAutoCreate())
2937          this.effectivePeriod = new Period(); // cc
2938      return this.effectivePeriod;
2939    }
2940
2941    public boolean hasEffectivePeriod() { 
2942      return this.effectivePeriod != null && !this.effectivePeriod.isEmpty();
2943    }
2944
2945    /**
2946     * @param value {@link #effectivePeriod} (The period during which the measure content was or is planned to be in active use.)
2947     */
2948    public Measure setEffectivePeriod(Period value) { 
2949      this.effectivePeriod = value;
2950      return this;
2951    }
2952
2953    /**
2954     * @return {@link #topic} (Descriptive topics related to the content of the measure. Topics provide a high-level categorization grouping types of measures that can be useful for filtering and searching.)
2955     */
2956    public List<CodeableConcept> getTopic() { 
2957      if (this.topic == null)
2958        this.topic = new ArrayList<CodeableConcept>();
2959      return this.topic;
2960    }
2961
2962    /**
2963     * @return Returns a reference to <code>this</code> for easy method chaining
2964     */
2965    public Measure setTopic(List<CodeableConcept> theTopic) { 
2966      this.topic = theTopic;
2967      return this;
2968    }
2969
2970    public boolean hasTopic() { 
2971      if (this.topic == null)
2972        return false;
2973      for (CodeableConcept item : this.topic)
2974        if (!item.isEmpty())
2975          return true;
2976      return false;
2977    }
2978
2979    public CodeableConcept addTopic() { //3
2980      CodeableConcept t = new CodeableConcept();
2981      if (this.topic == null)
2982        this.topic = new ArrayList<CodeableConcept>();
2983      this.topic.add(t);
2984      return t;
2985    }
2986
2987    public Measure addTopic(CodeableConcept t) { //3
2988      if (t == null)
2989        return this;
2990      if (this.topic == null)
2991        this.topic = new ArrayList<CodeableConcept>();
2992      this.topic.add(t);
2993      return this;
2994    }
2995
2996    /**
2997     * @return The first repetition of repeating field {@link #topic}, creating it if it does not already exist
2998     */
2999    public CodeableConcept getTopicFirstRep() { 
3000      if (getTopic().isEmpty()) {
3001        addTopic();
3002      }
3003      return getTopic().get(0);
3004    }
3005
3006    /**
3007     * @return {@link #author} (An individiual or organization primarily involved in the creation and maintenance of the content.)
3008     */
3009    public List<ContactDetail> getAuthor() { 
3010      if (this.author == null)
3011        this.author = new ArrayList<ContactDetail>();
3012      return this.author;
3013    }
3014
3015    /**
3016     * @return Returns a reference to <code>this</code> for easy method chaining
3017     */
3018    public Measure setAuthor(List<ContactDetail> theAuthor) { 
3019      this.author = theAuthor;
3020      return this;
3021    }
3022
3023    public boolean hasAuthor() { 
3024      if (this.author == null)
3025        return false;
3026      for (ContactDetail item : this.author)
3027        if (!item.isEmpty())
3028          return true;
3029      return false;
3030    }
3031
3032    public ContactDetail addAuthor() { //3
3033      ContactDetail t = new ContactDetail();
3034      if (this.author == null)
3035        this.author = new ArrayList<ContactDetail>();
3036      this.author.add(t);
3037      return t;
3038    }
3039
3040    public Measure addAuthor(ContactDetail t) { //3
3041      if (t == null)
3042        return this;
3043      if (this.author == null)
3044        this.author = new ArrayList<ContactDetail>();
3045      this.author.add(t);
3046      return this;
3047    }
3048
3049    /**
3050     * @return The first repetition of repeating field {@link #author}, creating it if it does not already exist
3051     */
3052    public ContactDetail getAuthorFirstRep() { 
3053      if (getAuthor().isEmpty()) {
3054        addAuthor();
3055      }
3056      return getAuthor().get(0);
3057    }
3058
3059    /**
3060     * @return {@link #editor} (An individual or organization primarily responsible for internal coherence of the content.)
3061     */
3062    public List<ContactDetail> getEditor() { 
3063      if (this.editor == null)
3064        this.editor = new ArrayList<ContactDetail>();
3065      return this.editor;
3066    }
3067
3068    /**
3069     * @return Returns a reference to <code>this</code> for easy method chaining
3070     */
3071    public Measure setEditor(List<ContactDetail> theEditor) { 
3072      this.editor = theEditor;
3073      return this;
3074    }
3075
3076    public boolean hasEditor() { 
3077      if (this.editor == null)
3078        return false;
3079      for (ContactDetail item : this.editor)
3080        if (!item.isEmpty())
3081          return true;
3082      return false;
3083    }
3084
3085    public ContactDetail addEditor() { //3
3086      ContactDetail t = new ContactDetail();
3087      if (this.editor == null)
3088        this.editor = new ArrayList<ContactDetail>();
3089      this.editor.add(t);
3090      return t;
3091    }
3092
3093    public Measure addEditor(ContactDetail t) { //3
3094      if (t == null)
3095        return this;
3096      if (this.editor == null)
3097        this.editor = new ArrayList<ContactDetail>();
3098      this.editor.add(t);
3099      return this;
3100    }
3101
3102    /**
3103     * @return The first repetition of repeating field {@link #editor}, creating it if it does not already exist
3104     */
3105    public ContactDetail getEditorFirstRep() { 
3106      if (getEditor().isEmpty()) {
3107        addEditor();
3108      }
3109      return getEditor().get(0);
3110    }
3111
3112    /**
3113     * @return {@link #reviewer} (An individual or organization primarily responsible for review of some aspect of the content.)
3114     */
3115    public List<ContactDetail> getReviewer() { 
3116      if (this.reviewer == null)
3117        this.reviewer = new ArrayList<ContactDetail>();
3118      return this.reviewer;
3119    }
3120
3121    /**
3122     * @return Returns a reference to <code>this</code> for easy method chaining
3123     */
3124    public Measure setReviewer(List<ContactDetail> theReviewer) { 
3125      this.reviewer = theReviewer;
3126      return this;
3127    }
3128
3129    public boolean hasReviewer() { 
3130      if (this.reviewer == null)
3131        return false;
3132      for (ContactDetail item : this.reviewer)
3133        if (!item.isEmpty())
3134          return true;
3135      return false;
3136    }
3137
3138    public ContactDetail addReviewer() { //3
3139      ContactDetail t = new ContactDetail();
3140      if (this.reviewer == null)
3141        this.reviewer = new ArrayList<ContactDetail>();
3142      this.reviewer.add(t);
3143      return t;
3144    }
3145
3146    public Measure addReviewer(ContactDetail t) { //3
3147      if (t == null)
3148        return this;
3149      if (this.reviewer == null)
3150        this.reviewer = new ArrayList<ContactDetail>();
3151      this.reviewer.add(t);
3152      return this;
3153    }
3154
3155    /**
3156     * @return The first repetition of repeating field {@link #reviewer}, creating it if it does not already exist
3157     */
3158    public ContactDetail getReviewerFirstRep() { 
3159      if (getReviewer().isEmpty()) {
3160        addReviewer();
3161      }
3162      return getReviewer().get(0);
3163    }
3164
3165    /**
3166     * @return {@link #endorser} (An individual or organization responsible for officially endorsing the content for use in some setting.)
3167     */
3168    public List<ContactDetail> getEndorser() { 
3169      if (this.endorser == null)
3170        this.endorser = new ArrayList<ContactDetail>();
3171      return this.endorser;
3172    }
3173
3174    /**
3175     * @return Returns a reference to <code>this</code> for easy method chaining
3176     */
3177    public Measure setEndorser(List<ContactDetail> theEndorser) { 
3178      this.endorser = theEndorser;
3179      return this;
3180    }
3181
3182    public boolean hasEndorser() { 
3183      if (this.endorser == null)
3184        return false;
3185      for (ContactDetail item : this.endorser)
3186        if (!item.isEmpty())
3187          return true;
3188      return false;
3189    }
3190
3191    public ContactDetail addEndorser() { //3
3192      ContactDetail t = new ContactDetail();
3193      if (this.endorser == null)
3194        this.endorser = new ArrayList<ContactDetail>();
3195      this.endorser.add(t);
3196      return t;
3197    }
3198
3199    public Measure addEndorser(ContactDetail t) { //3
3200      if (t == null)
3201        return this;
3202      if (this.endorser == null)
3203        this.endorser = new ArrayList<ContactDetail>();
3204      this.endorser.add(t);
3205      return this;
3206    }
3207
3208    /**
3209     * @return The first repetition of repeating field {@link #endorser}, creating it if it does not already exist
3210     */
3211    public ContactDetail getEndorserFirstRep() { 
3212      if (getEndorser().isEmpty()) {
3213        addEndorser();
3214      }
3215      return getEndorser().get(0);
3216    }
3217
3218    /**
3219     * @return {@link #relatedArtifact} (Related artifacts such as additional documentation, justification, or bibliographic references.)
3220     */
3221    public List<RelatedArtifact> getRelatedArtifact() { 
3222      if (this.relatedArtifact == null)
3223        this.relatedArtifact = new ArrayList<RelatedArtifact>();
3224      return this.relatedArtifact;
3225    }
3226
3227    /**
3228     * @return Returns a reference to <code>this</code> for easy method chaining
3229     */
3230    public Measure setRelatedArtifact(List<RelatedArtifact> theRelatedArtifact) { 
3231      this.relatedArtifact = theRelatedArtifact;
3232      return this;
3233    }
3234
3235    public boolean hasRelatedArtifact() { 
3236      if (this.relatedArtifact == null)
3237        return false;
3238      for (RelatedArtifact item : this.relatedArtifact)
3239        if (!item.isEmpty())
3240          return true;
3241      return false;
3242    }
3243
3244    public RelatedArtifact addRelatedArtifact() { //3
3245      RelatedArtifact t = new RelatedArtifact();
3246      if (this.relatedArtifact == null)
3247        this.relatedArtifact = new ArrayList<RelatedArtifact>();
3248      this.relatedArtifact.add(t);
3249      return t;
3250    }
3251
3252    public Measure addRelatedArtifact(RelatedArtifact t) { //3
3253      if (t == null)
3254        return this;
3255      if (this.relatedArtifact == null)
3256        this.relatedArtifact = new ArrayList<RelatedArtifact>();
3257      this.relatedArtifact.add(t);
3258      return this;
3259    }
3260
3261    /**
3262     * @return The first repetition of repeating field {@link #relatedArtifact}, creating it if it does not already exist
3263     */
3264    public RelatedArtifact getRelatedArtifactFirstRep() { 
3265      if (getRelatedArtifact().isEmpty()) {
3266        addRelatedArtifact();
3267      }
3268      return getRelatedArtifact().get(0);
3269    }
3270
3271    /**
3272     * @return {@link #library} (A reference to a Library resource containing the formal logic used by the measure.)
3273     */
3274    public List<CanonicalType> getLibrary() { 
3275      if (this.library == null)
3276        this.library = new ArrayList<CanonicalType>();
3277      return this.library;
3278    }
3279
3280    /**
3281     * @return Returns a reference to <code>this</code> for easy method chaining
3282     */
3283    public Measure setLibrary(List<CanonicalType> theLibrary) { 
3284      this.library = theLibrary;
3285      return this;
3286    }
3287
3288    public boolean hasLibrary() { 
3289      if (this.library == null)
3290        return false;
3291      for (CanonicalType item : this.library)
3292        if (!item.isEmpty())
3293          return true;
3294      return false;
3295    }
3296
3297    /**
3298     * @return {@link #library} (A reference to a Library resource containing the formal logic used by the measure.)
3299     */
3300    public CanonicalType addLibraryElement() {//2 
3301      CanonicalType t = new CanonicalType();
3302      if (this.library == null)
3303        this.library = new ArrayList<CanonicalType>();
3304      this.library.add(t);
3305      return t;
3306    }
3307
3308    /**
3309     * @param value {@link #library} (A reference to a Library resource containing the formal logic used by the measure.)
3310     */
3311    public Measure addLibrary(String value) { //1
3312      CanonicalType t = new CanonicalType();
3313      t.setValue(value);
3314      if (this.library == null)
3315        this.library = new ArrayList<CanonicalType>();
3316      this.library.add(t);
3317      return this;
3318    }
3319
3320    /**
3321     * @param value {@link #library} (A reference to a Library resource containing the formal logic used by the measure.)
3322     */
3323    public boolean hasLibrary(String value) { 
3324      if (this.library == null)
3325        return false;
3326      for (CanonicalType v : this.library)
3327        if (v.getValue().equals(value)) // canonical(Library)
3328          return true;
3329      return false;
3330    }
3331
3332    /**
3333     * @return {@link #disclaimer} (Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.). This is the underlying object with id, value and extensions. The accessor "getDisclaimer" gives direct access to the value
3334     */
3335    public MarkdownType getDisclaimerElement() { 
3336      if (this.disclaimer == null)
3337        if (Configuration.errorOnAutoCreate())
3338          throw new Error("Attempt to auto-create Measure.disclaimer");
3339        else if (Configuration.doAutoCreate())
3340          this.disclaimer = new MarkdownType(); // bb
3341      return this.disclaimer;
3342    }
3343
3344    public boolean hasDisclaimerElement() { 
3345      return this.disclaimer != null && !this.disclaimer.isEmpty();
3346    }
3347
3348    public boolean hasDisclaimer() { 
3349      return this.disclaimer != null && !this.disclaimer.isEmpty();
3350    }
3351
3352    /**
3353     * @param value {@link #disclaimer} (Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.). This is the underlying object with id, value and extensions. The accessor "getDisclaimer" gives direct access to the value
3354     */
3355    public Measure setDisclaimerElement(MarkdownType value) { 
3356      this.disclaimer = value;
3357      return this;
3358    }
3359
3360    /**
3361     * @return Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.
3362     */
3363    public String getDisclaimer() { 
3364      return this.disclaimer == null ? null : this.disclaimer.getValue();
3365    }
3366
3367    /**
3368     * @param value Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.
3369     */
3370    public Measure setDisclaimer(String value) { 
3371      if (value == null)
3372        this.disclaimer = null;
3373      else {
3374        if (this.disclaimer == null)
3375          this.disclaimer = new MarkdownType();
3376        this.disclaimer.setValue(value);
3377      }
3378      return this;
3379    }
3380
3381    /**
3382     * @return {@link #scoring} (Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented.)
3383     */
3384    public CodeableConcept getScoring() { 
3385      if (this.scoring == null)
3386        if (Configuration.errorOnAutoCreate())
3387          throw new Error("Attempt to auto-create Measure.scoring");
3388        else if (Configuration.doAutoCreate())
3389          this.scoring = new CodeableConcept(); // cc
3390      return this.scoring;
3391    }
3392
3393    public boolean hasScoring() { 
3394      return this.scoring != null && !this.scoring.isEmpty();
3395    }
3396
3397    /**
3398     * @param value {@link #scoring} (Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented.)
3399     */
3400    public Measure setScoring(CodeableConcept value) { 
3401      this.scoring = value;
3402      return this;
3403    }
3404
3405    /**
3406     * @return {@link #compositeScoring} (If this is a composite measure, the scoring method used to combine the component measures to determine the composite score.)
3407     */
3408    public CodeableConcept getCompositeScoring() { 
3409      if (this.compositeScoring == null)
3410        if (Configuration.errorOnAutoCreate())
3411          throw new Error("Attempt to auto-create Measure.compositeScoring");
3412        else if (Configuration.doAutoCreate())
3413          this.compositeScoring = new CodeableConcept(); // cc
3414      return this.compositeScoring;
3415    }
3416
3417    public boolean hasCompositeScoring() { 
3418      return this.compositeScoring != null && !this.compositeScoring.isEmpty();
3419    }
3420
3421    /**
3422     * @param value {@link #compositeScoring} (If this is a composite measure, the scoring method used to combine the component measures to determine the composite score.)
3423     */
3424    public Measure setCompositeScoring(CodeableConcept value) { 
3425      this.compositeScoring = value;
3426      return this;
3427    }
3428
3429    /**
3430     * @return {@link #type} (Indicates whether the measure is used to examine a process, an outcome over time, a patient-reported outcome, or a structure measure such as utilization.)
3431     */
3432    public List<CodeableConcept> getType() { 
3433      if (this.type == null)
3434        this.type = new ArrayList<CodeableConcept>();
3435      return this.type;
3436    }
3437
3438    /**
3439     * @return Returns a reference to <code>this</code> for easy method chaining
3440     */
3441    public Measure setType(List<CodeableConcept> theType) { 
3442      this.type = theType;
3443      return this;
3444    }
3445
3446    public boolean hasType() { 
3447      if (this.type == null)
3448        return false;
3449      for (CodeableConcept item : this.type)
3450        if (!item.isEmpty())
3451          return true;
3452      return false;
3453    }
3454
3455    public CodeableConcept addType() { //3
3456      CodeableConcept t = new CodeableConcept();
3457      if (this.type == null)
3458        this.type = new ArrayList<CodeableConcept>();
3459      this.type.add(t);
3460      return t;
3461    }
3462
3463    public Measure addType(CodeableConcept t) { //3
3464      if (t == null)
3465        return this;
3466      if (this.type == null)
3467        this.type = new ArrayList<CodeableConcept>();
3468      this.type.add(t);
3469      return this;
3470    }
3471
3472    /**
3473     * @return The first repetition of repeating field {@link #type}, creating it if it does not already exist
3474     */
3475    public CodeableConcept getTypeFirstRep() { 
3476      if (getType().isEmpty()) {
3477        addType();
3478      }
3479      return getType().get(0);
3480    }
3481
3482    /**
3483     * @return {@link #riskAdjustment} (A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.). This is the underlying object with id, value and extensions. The accessor "getRiskAdjustment" gives direct access to the value
3484     */
3485    public StringType getRiskAdjustmentElement() { 
3486      if (this.riskAdjustment == null)
3487        if (Configuration.errorOnAutoCreate())
3488          throw new Error("Attempt to auto-create Measure.riskAdjustment");
3489        else if (Configuration.doAutoCreate())
3490          this.riskAdjustment = new StringType(); // bb
3491      return this.riskAdjustment;
3492    }
3493
3494    public boolean hasRiskAdjustmentElement() { 
3495      return this.riskAdjustment != null && !this.riskAdjustment.isEmpty();
3496    }
3497
3498    public boolean hasRiskAdjustment() { 
3499      return this.riskAdjustment != null && !this.riskAdjustment.isEmpty();
3500    }
3501
3502    /**
3503     * @param value {@link #riskAdjustment} (A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.). This is the underlying object with id, value and extensions. The accessor "getRiskAdjustment" gives direct access to the value
3504     */
3505    public Measure setRiskAdjustmentElement(StringType value) { 
3506      this.riskAdjustment = value;
3507      return this;
3508    }
3509
3510    /**
3511     * @return A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.
3512     */
3513    public String getRiskAdjustment() { 
3514      return this.riskAdjustment == null ? null : this.riskAdjustment.getValue();
3515    }
3516
3517    /**
3518     * @param value A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.
3519     */
3520    public Measure setRiskAdjustment(String value) { 
3521      if (Utilities.noString(value))
3522        this.riskAdjustment = null;
3523      else {
3524        if (this.riskAdjustment == null)
3525          this.riskAdjustment = new StringType();
3526        this.riskAdjustment.setValue(value);
3527      }
3528      return this;
3529    }
3530
3531    /**
3532     * @return {@link #rateAggregation} (Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.). This is the underlying object with id, value and extensions. The accessor "getRateAggregation" gives direct access to the value
3533     */
3534    public StringType getRateAggregationElement() { 
3535      if (this.rateAggregation == null)
3536        if (Configuration.errorOnAutoCreate())
3537          throw new Error("Attempt to auto-create Measure.rateAggregation");
3538        else if (Configuration.doAutoCreate())
3539          this.rateAggregation = new StringType(); // bb
3540      return this.rateAggregation;
3541    }
3542
3543    public boolean hasRateAggregationElement() { 
3544      return this.rateAggregation != null && !this.rateAggregation.isEmpty();
3545    }
3546
3547    public boolean hasRateAggregation() { 
3548      return this.rateAggregation != null && !this.rateAggregation.isEmpty();
3549    }
3550
3551    /**
3552     * @param value {@link #rateAggregation} (Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.). This is the underlying object with id, value and extensions. The accessor "getRateAggregation" gives direct access to the value
3553     */
3554    public Measure setRateAggregationElement(StringType value) { 
3555      this.rateAggregation = value;
3556      return this;
3557    }
3558
3559    /**
3560     * @return Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.
3561     */
3562    public String getRateAggregation() { 
3563      return this.rateAggregation == null ? null : this.rateAggregation.getValue();
3564    }
3565
3566    /**
3567     * @param value Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.
3568     */
3569    public Measure setRateAggregation(String value) { 
3570      if (Utilities.noString(value))
3571        this.rateAggregation = null;
3572      else {
3573        if (this.rateAggregation == null)
3574          this.rateAggregation = new StringType();
3575        this.rateAggregation.setValue(value);
3576      }
3577      return this;
3578    }
3579
3580    /**
3581     * @return {@link #rationale} (Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.). This is the underlying object with id, value and extensions. The accessor "getRationale" gives direct access to the value
3582     */
3583    public MarkdownType getRationaleElement() { 
3584      if (this.rationale == null)
3585        if (Configuration.errorOnAutoCreate())
3586          throw new Error("Attempt to auto-create Measure.rationale");
3587        else if (Configuration.doAutoCreate())
3588          this.rationale = new MarkdownType(); // bb
3589      return this.rationale;
3590    }
3591
3592    public boolean hasRationaleElement() { 
3593      return this.rationale != null && !this.rationale.isEmpty();
3594    }
3595
3596    public boolean hasRationale() { 
3597      return this.rationale != null && !this.rationale.isEmpty();
3598    }
3599
3600    /**
3601     * @param value {@link #rationale} (Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.). This is the underlying object with id, value and extensions. The accessor "getRationale" gives direct access to the value
3602     */
3603    public Measure setRationaleElement(MarkdownType value) { 
3604      this.rationale = value;
3605      return this;
3606    }
3607
3608    /**
3609     * @return Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.
3610     */
3611    public String getRationale() { 
3612      return this.rationale == null ? null : this.rationale.getValue();
3613    }
3614
3615    /**
3616     * @param value Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.
3617     */
3618    public Measure setRationale(String value) { 
3619      if (value == null)
3620        this.rationale = null;
3621      else {
3622        if (this.rationale == null)
3623          this.rationale = new MarkdownType();
3624        this.rationale.setValue(value);
3625      }
3626      return this;
3627    }
3628
3629    /**
3630     * @return {@link #clinicalRecommendationStatement} (Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.). This is the underlying object with id, value and extensions. The accessor "getClinicalRecommendationStatement" gives direct access to the value
3631     */
3632    public MarkdownType getClinicalRecommendationStatementElement() { 
3633      if (this.clinicalRecommendationStatement == null)
3634        if (Configuration.errorOnAutoCreate())
3635          throw new Error("Attempt to auto-create Measure.clinicalRecommendationStatement");
3636        else if (Configuration.doAutoCreate())
3637          this.clinicalRecommendationStatement = new MarkdownType(); // bb
3638      return this.clinicalRecommendationStatement;
3639    }
3640
3641    public boolean hasClinicalRecommendationStatementElement() { 
3642      return this.clinicalRecommendationStatement != null && !this.clinicalRecommendationStatement.isEmpty();
3643    }
3644
3645    public boolean hasClinicalRecommendationStatement() { 
3646      return this.clinicalRecommendationStatement != null && !this.clinicalRecommendationStatement.isEmpty();
3647    }
3648
3649    /**
3650     * @param value {@link #clinicalRecommendationStatement} (Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.). This is the underlying object with id, value and extensions. The accessor "getClinicalRecommendationStatement" gives direct access to the value
3651     */
3652    public Measure setClinicalRecommendationStatementElement(MarkdownType value) { 
3653      this.clinicalRecommendationStatement = value;
3654      return this;
3655    }
3656
3657    /**
3658     * @return Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.
3659     */
3660    public String getClinicalRecommendationStatement() { 
3661      return this.clinicalRecommendationStatement == null ? null : this.clinicalRecommendationStatement.getValue();
3662    }
3663
3664    /**
3665     * @param value Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.
3666     */
3667    public Measure setClinicalRecommendationStatement(String value) { 
3668      if (value == null)
3669        this.clinicalRecommendationStatement = null;
3670      else {
3671        if (this.clinicalRecommendationStatement == null)
3672          this.clinicalRecommendationStatement = new MarkdownType();
3673        this.clinicalRecommendationStatement.setValue(value);
3674      }
3675      return this;
3676    }
3677
3678    /**
3679     * @return {@link #improvementNotation} (Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range).)
3680     */
3681    public CodeableConcept getImprovementNotation() { 
3682      if (this.improvementNotation == null)
3683        if (Configuration.errorOnAutoCreate())
3684          throw new Error("Attempt to auto-create Measure.improvementNotation");
3685        else if (Configuration.doAutoCreate())
3686          this.improvementNotation = new CodeableConcept(); // cc
3687      return this.improvementNotation;
3688    }
3689
3690    public boolean hasImprovementNotation() { 
3691      return this.improvementNotation != null && !this.improvementNotation.isEmpty();
3692    }
3693
3694    /**
3695     * @param value {@link #improvementNotation} (Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range).)
3696     */
3697    public Measure setImprovementNotation(CodeableConcept value) { 
3698      this.improvementNotation = value;
3699      return this;
3700    }
3701
3702    /**
3703     * @return {@link #definition} (Provides a description of an individual term used within the measure.)
3704     */
3705    public List<MarkdownType> getDefinition() { 
3706      if (this.definition == null)
3707        this.definition = new ArrayList<MarkdownType>();
3708      return this.definition;
3709    }
3710
3711    /**
3712     * @return Returns a reference to <code>this</code> for easy method chaining
3713     */
3714    public Measure setDefinition(List<MarkdownType> theDefinition) { 
3715      this.definition = theDefinition;
3716      return this;
3717    }
3718
3719    public boolean hasDefinition() { 
3720      if (this.definition == null)
3721        return false;
3722      for (MarkdownType item : this.definition)
3723        if (!item.isEmpty())
3724          return true;
3725      return false;
3726    }
3727
3728    /**
3729     * @return {@link #definition} (Provides a description of an individual term used within the measure.)
3730     */
3731    public MarkdownType addDefinitionElement() {//2 
3732      MarkdownType t = new MarkdownType();
3733      if (this.definition == null)
3734        this.definition = new ArrayList<MarkdownType>();
3735      this.definition.add(t);
3736      return t;
3737    }
3738
3739    /**
3740     * @param value {@link #definition} (Provides a description of an individual term used within the measure.)
3741     */
3742    public Measure addDefinition(String value) { //1
3743      MarkdownType t = new MarkdownType();
3744      t.setValue(value);
3745      if (this.definition == null)
3746        this.definition = new ArrayList<MarkdownType>();
3747      this.definition.add(t);
3748      return this;
3749    }
3750
3751    /**
3752     * @param value {@link #definition} (Provides a description of an individual term used within the measure.)
3753     */
3754    public boolean hasDefinition(String value) { 
3755      if (this.definition == null)
3756        return false;
3757      for (MarkdownType v : this.definition)
3758        if (v.getValue().equals(value)) // markdown
3759          return true;
3760      return false;
3761    }
3762
3763    /**
3764     * @return {@link #guidance} (Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.). This is the underlying object with id, value and extensions. The accessor "getGuidance" gives direct access to the value
3765     */
3766    public MarkdownType getGuidanceElement() { 
3767      if (this.guidance == null)
3768        if (Configuration.errorOnAutoCreate())
3769          throw new Error("Attempt to auto-create Measure.guidance");
3770        else if (Configuration.doAutoCreate())
3771          this.guidance = new MarkdownType(); // bb
3772      return this.guidance;
3773    }
3774
3775    public boolean hasGuidanceElement() { 
3776      return this.guidance != null && !this.guidance.isEmpty();
3777    }
3778
3779    public boolean hasGuidance() { 
3780      return this.guidance != null && !this.guidance.isEmpty();
3781    }
3782
3783    /**
3784     * @param value {@link #guidance} (Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.). This is the underlying object with id, value and extensions. The accessor "getGuidance" gives direct access to the value
3785     */
3786    public Measure setGuidanceElement(MarkdownType value) { 
3787      this.guidance = value;
3788      return this;
3789    }
3790
3791    /**
3792     * @return Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.
3793     */
3794    public String getGuidance() { 
3795      return this.guidance == null ? null : this.guidance.getValue();
3796    }
3797
3798    /**
3799     * @param value Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.
3800     */
3801    public Measure setGuidance(String value) { 
3802      if (value == null)
3803        this.guidance = null;
3804      else {
3805        if (this.guidance == null)
3806          this.guidance = new MarkdownType();
3807        this.guidance.setValue(value);
3808      }
3809      return this;
3810    }
3811
3812    /**
3813     * @return {@link #group} (A group of population criteria for the measure.)
3814     */
3815    public List<MeasureGroupComponent> getGroup() { 
3816      if (this.group == null)
3817        this.group = new ArrayList<MeasureGroupComponent>();
3818      return this.group;
3819    }
3820
3821    /**
3822     * @return Returns a reference to <code>this</code> for easy method chaining
3823     */
3824    public Measure setGroup(List<MeasureGroupComponent> theGroup) { 
3825      this.group = theGroup;
3826      return this;
3827    }
3828
3829    public boolean hasGroup() { 
3830      if (this.group == null)
3831        return false;
3832      for (MeasureGroupComponent item : this.group)
3833        if (!item.isEmpty())
3834          return true;
3835      return false;
3836    }
3837
3838    public MeasureGroupComponent addGroup() { //3
3839      MeasureGroupComponent t = new MeasureGroupComponent();
3840      if (this.group == null)
3841        this.group = new ArrayList<MeasureGroupComponent>();
3842      this.group.add(t);
3843      return t;
3844    }
3845
3846    public Measure addGroup(MeasureGroupComponent t) { //3
3847      if (t == null)
3848        return this;
3849      if (this.group == null)
3850        this.group = new ArrayList<MeasureGroupComponent>();
3851      this.group.add(t);
3852      return this;
3853    }
3854
3855    /**
3856     * @return The first repetition of repeating field {@link #group}, creating it if it does not already exist
3857     */
3858    public MeasureGroupComponent getGroupFirstRep() { 
3859      if (getGroup().isEmpty()) {
3860        addGroup();
3861      }
3862      return getGroup().get(0);
3863    }
3864
3865    /**
3866     * @return {@link #supplementalData} (The supplemental data criteria for the measure report, specified as either the name of a valid CQL expression within a referenced library, or a valid FHIR Resource Path.)
3867     */
3868    public List<MeasureSupplementalDataComponent> getSupplementalData() { 
3869      if (this.supplementalData == null)
3870        this.supplementalData = new ArrayList<MeasureSupplementalDataComponent>();
3871      return this.supplementalData;
3872    }
3873
3874    /**
3875     * @return Returns a reference to <code>this</code> for easy method chaining
3876     */
3877    public Measure setSupplementalData(List<MeasureSupplementalDataComponent> theSupplementalData) { 
3878      this.supplementalData = theSupplementalData;
3879      return this;
3880    }
3881
3882    public boolean hasSupplementalData() { 
3883      if (this.supplementalData == null)
3884        return false;
3885      for (MeasureSupplementalDataComponent item : this.supplementalData)
3886        if (!item.isEmpty())
3887          return true;
3888      return false;
3889    }
3890
3891    public MeasureSupplementalDataComponent addSupplementalData() { //3
3892      MeasureSupplementalDataComponent t = new MeasureSupplementalDataComponent();
3893      if (this.supplementalData == null)
3894        this.supplementalData = new ArrayList<MeasureSupplementalDataComponent>();
3895      this.supplementalData.add(t);
3896      return t;
3897    }
3898
3899    public Measure addSupplementalData(MeasureSupplementalDataComponent t) { //3
3900      if (t == null)
3901        return this;
3902      if (this.supplementalData == null)
3903        this.supplementalData = new ArrayList<MeasureSupplementalDataComponent>();
3904      this.supplementalData.add(t);
3905      return this;
3906    }
3907
3908    /**
3909     * @return The first repetition of repeating field {@link #supplementalData}, creating it if it does not already exist
3910     */
3911    public MeasureSupplementalDataComponent getSupplementalDataFirstRep() { 
3912      if (getSupplementalData().isEmpty()) {
3913        addSupplementalData();
3914      }
3915      return getSupplementalData().get(0);
3916    }
3917
3918      protected void listChildren(List<Property> children) {
3919        super.listChildren(children);
3920        children.add(new Property("url", "uri", "An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.", 0, 1, url));
3921        children.add(new Property("identifier", "Identifier", "A formal identifier that is used to identify this measure when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier));
3922        children.add(new Property("version", "string", "The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.", 0, 1, version));
3923        children.add(new Property("name", "string", "A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name));
3924        children.add(new Property("title", "string", "A short, descriptive, user-friendly title for the measure.", 0, 1, title));
3925        children.add(new Property("subtitle", "string", "An explanatory or alternate title for the measure giving additional information about its content.", 0, 1, subtitle));
3926        children.add(new Property("status", "code", "The status of this measure. Enables tracking the life-cycle of the content.", 0, 1, status));
3927        children.add(new Property("experimental", "boolean", "A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental));
3928        children.add(new Property("subject[x]", "CodeableConcept|Reference(Group)", "The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.", 0, 1, subject));
3929        children.add(new Property("date", "dateTime", "The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.", 0, 1, date));
3930        children.add(new Property("publisher", "string", "The name of the organization or individual that published the measure.", 0, 1, publisher));
3931        children.add(new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact));
3932        children.add(new Property("description", "markdown", "A free text natural language description of the measure from a consumer's perspective.", 0, 1, description));
3933        children.add(new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate measure instances.", 0, java.lang.Integer.MAX_VALUE, useContext));
3934        children.add(new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the measure is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction));
3935        children.add(new Property("purpose", "markdown", "Explanation of why this measure is needed and why it has been designed as it has.", 0, 1, purpose));
3936        children.add(new Property("usage", "string", "A detailed description, from a clinical perspective, of how the measure is used.", 0, 1, usage));
3937        children.add(new Property("copyright", "markdown", "A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.", 0, 1, copyright));
3938        children.add(new Property("approvalDate", "date", "The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.", 0, 1, approvalDate));
3939        children.add(new Property("lastReviewDate", "date", "The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.", 0, 1, lastReviewDate));
3940        children.add(new Property("effectivePeriod", "Period", "The period during which the measure content was or is planned to be in active use.", 0, 1, effectivePeriod));
3941        children.add(new Property("topic", "CodeableConcept", "Descriptive topics related to the content of the measure. Topics provide a high-level categorization grouping types of measures that can be useful for filtering and searching.", 0, java.lang.Integer.MAX_VALUE, topic));
3942        children.add(new Property("author", "ContactDetail", "An individiual or organization primarily involved in the creation and maintenance of the content.", 0, java.lang.Integer.MAX_VALUE, author));
3943        children.add(new Property("editor", "ContactDetail", "An individual or organization primarily responsible for internal coherence of the content.", 0, java.lang.Integer.MAX_VALUE, editor));
3944        children.add(new Property("reviewer", "ContactDetail", "An individual or organization primarily responsible for review of some aspect of the content.", 0, java.lang.Integer.MAX_VALUE, reviewer));
3945        children.add(new Property("endorser", "ContactDetail", "An individual or organization responsible for officially endorsing the content for use in some setting.", 0, java.lang.Integer.MAX_VALUE, endorser));
3946        children.add(new Property("relatedArtifact", "RelatedArtifact", "Related artifacts such as additional documentation, justification, or bibliographic references.", 0, java.lang.Integer.MAX_VALUE, relatedArtifact));
3947        children.add(new Property("library", "canonical(Library)", "A reference to a Library resource containing the formal logic used by the measure.", 0, java.lang.Integer.MAX_VALUE, library));
3948        children.add(new Property("disclaimer", "markdown", "Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.", 0, 1, disclaimer));
3949        children.add(new Property("scoring", "CodeableConcept", "Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented.", 0, 1, scoring));
3950        children.add(new Property("compositeScoring", "CodeableConcept", "If this is a composite measure, the scoring method used to combine the component measures to determine the composite score.", 0, 1, compositeScoring));
3951        children.add(new Property("type", "CodeableConcept", "Indicates whether the measure is used to examine a process, an outcome over time, a patient-reported outcome, or a structure measure such as utilization.", 0, java.lang.Integer.MAX_VALUE, type));
3952        children.add(new Property("riskAdjustment", "string", "A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.", 0, 1, riskAdjustment));
3953        children.add(new Property("rateAggregation", "string", "Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.", 0, 1, rateAggregation));
3954        children.add(new Property("rationale", "markdown", "Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.", 0, 1, rationale));
3955        children.add(new Property("clinicalRecommendationStatement", "markdown", "Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.", 0, 1, clinicalRecommendationStatement));
3956        children.add(new Property("improvementNotation", "CodeableConcept", "Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range).", 0, 1, improvementNotation));
3957        children.add(new Property("definition", "markdown", "Provides a description of an individual term used within the measure.", 0, java.lang.Integer.MAX_VALUE, definition));
3958        children.add(new Property("guidance", "markdown", "Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.", 0, 1, guidance));
3959        children.add(new Property("group", "", "A group of population criteria for the measure.", 0, java.lang.Integer.MAX_VALUE, group));
3960        children.add(new Property("supplementalData", "", "The supplemental data criteria for the measure report, specified as either the name of a valid CQL expression within a referenced library, or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, supplementalData));
3961      }
3962
3963      @Override
3964      public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3965        switch (_hash) {
3966        case 116079: /*url*/  return new Property("url", "uri", "An absolute URI that is used to identify this measure when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this measure is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the measure is stored on different servers.", 0, 1, url);
3967        case -1618432855: /*identifier*/  return new Property("identifier", "Identifier", "A formal identifier that is used to identify this measure when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier);
3968        case 351608024: /*version*/  return new Property("version", "string", "The identifier that is used to identify this version of the measure when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the measure author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. To provide a version consistent with the Decision Support Service specification, use the format Major.Minor.Revision (e.g. 1.0.0). For more information on versioning knowledge assets, refer to the Decision Support Service specification. Note that a version is required for non-experimental active artifacts.", 0, 1, version);
3969        case 3373707: /*name*/  return new Property("name", "string", "A natural language name identifying the measure. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 0, 1, name);
3970        case 110371416: /*title*/  return new Property("title", "string", "A short, descriptive, user-friendly title for the measure.", 0, 1, title);
3971        case -2060497896: /*subtitle*/  return new Property("subtitle", "string", "An explanatory or alternate title for the measure giving additional information about its content.", 0, 1, subtitle);
3972        case -892481550: /*status*/  return new Property("status", "code", "The status of this measure. Enables tracking the life-cycle of the content.", 0, 1, status);
3973        case -404562712: /*experimental*/  return new Property("experimental", "boolean", "A Boolean value to indicate that this measure is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 0, 1, experimental);
3974        case -573640748: /*subject[x]*/  return new Property("subject[x]", "CodeableConcept|Reference(Group)", "The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.", 0, 1, subject);
3975        case -1867885268: /*subject*/  return new Property("subject[x]", "CodeableConcept|Reference(Group)", "The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.", 0, 1, subject);
3976        case -1257122603: /*subjectCodeableConcept*/  return new Property("subject[x]", "CodeableConcept|Reference(Group)", "The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.", 0, 1, subject);
3977        case 772938623: /*subjectReference*/  return new Property("subject[x]", "CodeableConcept|Reference(Group)", "The intended subjects for the measure. If this element is not provided, a Patient subject is assumed, but the subject of the measure can be anything.", 0, 1, subject);
3978        case 3076014: /*date*/  return new Property("date", "dateTime", "The date  (and optionally time) when the measure was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the measure changes.", 0, 1, date);
3979        case 1447404028: /*publisher*/  return new Property("publisher", "string", "The name of the organization or individual that published the measure.", 0, 1, publisher);
3980        case 951526432: /*contact*/  return new Property("contact", "ContactDetail", "Contact details to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact);
3981        case -1724546052: /*description*/  return new Property("description", "markdown", "A free text natural language description of the measure from a consumer's perspective.", 0, 1, description);
3982        case -669707736: /*useContext*/  return new Property("useContext", "UsageContext", "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate measure instances.", 0, java.lang.Integer.MAX_VALUE, useContext);
3983        case -507075711: /*jurisdiction*/  return new Property("jurisdiction", "CodeableConcept", "A legal or geographic region in which the measure is intended to be used.", 0, java.lang.Integer.MAX_VALUE, jurisdiction);
3984        case -220463842: /*purpose*/  return new Property("purpose", "markdown", "Explanation of why this measure is needed and why it has been designed as it has.", 0, 1, purpose);
3985        case 111574433: /*usage*/  return new Property("usage", "string", "A detailed description, from a clinical perspective, of how the measure is used.", 0, 1, usage);
3986        case 1522889671: /*copyright*/  return new Property("copyright", "markdown", "A copyright statement relating to the measure and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the measure.", 0, 1, copyright);
3987        case 223539345: /*approvalDate*/  return new Property("approvalDate", "date", "The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage.", 0, 1, approvalDate);
3988        case -1687512484: /*lastReviewDate*/  return new Property("lastReviewDate", "date", "The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date.", 0, 1, lastReviewDate);
3989        case -403934648: /*effectivePeriod*/  return new Property("effectivePeriod", "Period", "The period during which the measure content was or is planned to be in active use.", 0, 1, effectivePeriod);
3990        case 110546223: /*topic*/  return new Property("topic", "CodeableConcept", "Descriptive topics related to the content of the measure. Topics provide a high-level categorization grouping types of measures that can be useful for filtering and searching.", 0, java.lang.Integer.MAX_VALUE, topic);
3991        case -1406328437: /*author*/  return new Property("author", "ContactDetail", "An individiual or organization primarily involved in the creation and maintenance of the content.", 0, java.lang.Integer.MAX_VALUE, author);
3992        case -1307827859: /*editor*/  return new Property("editor", "ContactDetail", "An individual or organization primarily responsible for internal coherence of the content.", 0, java.lang.Integer.MAX_VALUE, editor);
3993        case -261190139: /*reviewer*/  return new Property("reviewer", "ContactDetail", "An individual or organization primarily responsible for review of some aspect of the content.", 0, java.lang.Integer.MAX_VALUE, reviewer);
3994        case 1740277666: /*endorser*/  return new Property("endorser", "ContactDetail", "An individual or organization responsible for officially endorsing the content for use in some setting.", 0, java.lang.Integer.MAX_VALUE, endorser);
3995        case 666807069: /*relatedArtifact*/  return new Property("relatedArtifact", "RelatedArtifact", "Related artifacts such as additional documentation, justification, or bibliographic references.", 0, java.lang.Integer.MAX_VALUE, relatedArtifact);
3996        case 166208699: /*library*/  return new Property("library", "canonical(Library)", "A reference to a Library resource containing the formal logic used by the measure.", 0, java.lang.Integer.MAX_VALUE, library);
3997        case 432371099: /*disclaimer*/  return new Property("disclaimer", "markdown", "Notices and disclaimers regarding the use of the measure or related to intellectual property (such as code systems) referenced by the measure.", 0, 1, disclaimer);
3998        case 1924005583: /*scoring*/  return new Property("scoring", "CodeableConcept", "Indicates how the calculation is performed for the measure, including proportion, ratio, continuous-variable, and cohort. The value set is extensible, allowing additional measure scoring types to be represented.", 0, 1, scoring);
3999        case 569347656: /*compositeScoring*/  return new Property("compositeScoring", "CodeableConcept", "If this is a composite measure, the scoring method used to combine the component measures to determine the composite score.", 0, 1, compositeScoring);
4000        case 3575610: /*type*/  return new Property("type", "CodeableConcept", "Indicates whether the measure is used to examine a process, an outcome over time, a patient-reported outcome, or a structure measure such as utilization.", 0, java.lang.Integer.MAX_VALUE, type);
4001        case 93273500: /*riskAdjustment*/  return new Property("riskAdjustment", "string", "A description of the risk adjustment factors that may impact the resulting score for the measure and how they may be accounted for when computing and reporting measure results.", 0, 1, riskAdjustment);
4002        case 1254503906: /*rateAggregation*/  return new Property("rateAggregation", "string", "Describes how to combine the information calculated, based on logic in each of several populations, into one summarized result.", 0, 1, rateAggregation);
4003        case 345689335: /*rationale*/  return new Property("rationale", "markdown", "Provides a succinct statement of the need for the measure. Usually includes statements pertaining to importance criterion: impact, gap in care, and evidence.", 0, 1, rationale);
4004        case -18631389: /*clinicalRecommendationStatement*/  return new Property("clinicalRecommendationStatement", "markdown", "Provides a summary of relevant clinical guidelines or other clinical recommendations supporting the measure.", 0, 1, clinicalRecommendationStatement);
4005        case -2085456136: /*improvementNotation*/  return new Property("improvementNotation", "CodeableConcept", "Information on whether an increase or decrease in score is the preferred result (e.g., a higher score indicates better quality OR a lower score indicates better quality OR quality is within a range).", 0, 1, improvementNotation);
4006        case -1014418093: /*definition*/  return new Property("definition", "markdown", "Provides a description of an individual term used within the measure.", 0, java.lang.Integer.MAX_VALUE, definition);
4007        case -1314002088: /*guidance*/  return new Property("guidance", "markdown", "Additional guidance for the measure including how it can be used in a clinical context, and the intent of the measure.", 0, 1, guidance);
4008        case 98629247: /*group*/  return new Property("group", "", "A group of population criteria for the measure.", 0, java.lang.Integer.MAX_VALUE, group);
4009        case 1447496814: /*supplementalData*/  return new Property("supplementalData", "", "The supplemental data criteria for the measure report, specified as either the name of a valid CQL expression within a referenced library, or a valid FHIR Resource Path.", 0, java.lang.Integer.MAX_VALUE, supplementalData);
4010        default: return super.getNamedProperty(_hash, _name, _checkValid);
4011        }
4012
4013      }
4014
4015      @Override
4016      public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
4017        switch (hash) {
4018        case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType
4019        case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier
4020        case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // StringType
4021        case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType
4022        case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType
4023        case -2060497896: /*subtitle*/ return this.subtitle == null ? new Base[0] : new Base[] {this.subtitle}; // StringType
4024        case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<PublicationStatus>
4025        case -404562712: /*experimental*/ return this.experimental == null ? new Base[0] : new Base[] {this.experimental}; // BooleanType
4026        case -1867885268: /*subject*/ return this.subject == null ? new Base[0] : new Base[] {this.subject}; // Type
4027        case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType
4028        case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // StringType
4029        case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail
4030        case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // MarkdownType
4031        case -669707736: /*useContext*/ return this.useContext == null ? new Base[0] : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext
4032        case -507075711: /*jurisdiction*/ return this.jurisdiction == null ? new Base[0] : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept
4033        case -220463842: /*purpose*/ return this.purpose == null ? new Base[0] : new Base[] {this.purpose}; // MarkdownType
4034        case 111574433: /*usage*/ return this.usage == null ? new Base[0] : new Base[] {this.usage}; // StringType
4035        case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType
4036        case 223539345: /*approvalDate*/ return this.approvalDate == null ? new Base[0] : new Base[] {this.approvalDate}; // DateType
4037        case -1687512484: /*lastReviewDate*/ return this.lastReviewDate == null ? new Base[0] : new Base[] {this.lastReviewDate}; // DateType
4038        case -403934648: /*effectivePeriod*/ return this.effectivePeriod == null ? new Base[0] : new Base[] {this.effectivePeriod}; // Period
4039        case 110546223: /*topic*/ return this.topic == null ? new Base[0] : this.topic.toArray(new Base[this.topic.size()]); // CodeableConcept
4040        case -1406328437: /*author*/ return this.author == null ? new Base[0] : this.author.toArray(new Base[this.author.size()]); // ContactDetail
4041        case -1307827859: /*editor*/ return this.editor == null ? new Base[0] : this.editor.toArray(new Base[this.editor.size()]); // ContactDetail
4042        case -261190139: /*reviewer*/ return this.reviewer == null ? new Base[0] : this.reviewer.toArray(new Base[this.reviewer.size()]); // ContactDetail
4043        case 1740277666: /*endorser*/ return this.endorser == null ? new Base[0] : this.endorser.toArray(new Base[this.endorser.size()]); // ContactDetail
4044        case 666807069: /*relatedArtifact*/ return this.relatedArtifact == null ? new Base[0] : this.relatedArtifact.toArray(new Base[this.relatedArtifact.size()]); // RelatedArtifact
4045        case 166208699: /*library*/ return this.library == null ? new Base[0] : this.library.toArray(new Base[this.library.size()]); // CanonicalType
4046        case 432371099: /*disclaimer*/ return this.disclaimer == null ? new Base[0] : new Base[] {this.disclaimer}; // MarkdownType
4047        case 1924005583: /*scoring*/ return this.scoring == null ? new Base[0] : new Base[] {this.scoring}; // CodeableConcept
4048        case 569347656: /*compositeScoring*/ return this.compositeScoring == null ? new Base[0] : new Base[] {this.compositeScoring}; // CodeableConcept
4049        case 3575610: /*type*/ return this.type == null ? new Base[0] : this.type.toArray(new Base[this.type.size()]); // CodeableConcept
4050        case 93273500: /*riskAdjustment*/ return this.riskAdjustment == null ? new Base[0] : new Base[] {this.riskAdjustment}; // StringType
4051        case 1254503906: /*rateAggregation*/ return this.rateAggregation == null ? new Base[0] : new Base[] {this.rateAggregation}; // StringType
4052        case 345689335: /*rationale*/ return this.rationale == null ? new Base[0] : new Base[] {this.rationale}; // MarkdownType
4053        case -18631389: /*clinicalRecommendationStatement*/ return this.clinicalRecommendationStatement == null ? new Base[0] : new Base[] {this.clinicalRecommendationStatement}; // MarkdownType
4054        case -2085456136: /*improvementNotation*/ return this.improvementNotation == null ? new Base[0] : new Base[] {this.improvementNotation}; // CodeableConcept
4055        case -1014418093: /*definition*/ return this.definition == null ? new Base[0] : this.definition.toArray(new Base[this.definition.size()]); // MarkdownType
4056        case -1314002088: /*guidance*/ return this.guidance == null ? new Base[0] : new Base[] {this.guidance}; // MarkdownType
4057        case 98629247: /*group*/ return this.group == null ? new Base[0] : this.group.toArray(new Base[this.group.size()]); // MeasureGroupComponent
4058        case 1447496814: /*supplementalData*/ return this.supplementalData == null ? new Base[0] : this.supplementalData.toArray(new Base[this.supplementalData.size()]); // MeasureSupplementalDataComponent
4059        default: return super.getProperty(hash, name, checkValid);
4060        }
4061
4062      }
4063
4064      @Override
4065      public Base setProperty(int hash, String name, Base value) throws FHIRException {
4066        switch (hash) {
4067        case 116079: // url
4068          this.url = castToUri(value); // UriType
4069          return value;
4070        case -1618432855: // identifier
4071          this.getIdentifier().add(castToIdentifier(value)); // Identifier
4072          return value;
4073        case 351608024: // version
4074          this.version = castToString(value); // StringType
4075          return value;
4076        case 3373707: // name
4077          this.name = castToString(value); // StringType
4078          return value;
4079        case 110371416: // title
4080          this.title = castToString(value); // StringType
4081          return value;
4082        case -2060497896: // subtitle
4083          this.subtitle = castToString(value); // StringType
4084          return value;
4085        case -892481550: // status
4086          value = new PublicationStatusEnumFactory().fromType(castToCode(value));
4087          this.status = (Enumeration) value; // Enumeration<PublicationStatus>
4088          return value;
4089        case -404562712: // experimental
4090          this.experimental = castToBoolean(value); // BooleanType
4091          return value;
4092        case -1867885268: // subject
4093          this.subject = castToType(value); // Type
4094          return value;
4095        case 3076014: // date
4096          this.date = castToDateTime(value); // DateTimeType
4097          return value;
4098        case 1447404028: // publisher
4099          this.publisher = castToString(value); // StringType
4100          return value;
4101        case 951526432: // contact
4102          this.getContact().add(castToContactDetail(value)); // ContactDetail
4103          return value;
4104        case -1724546052: // description
4105          this.description = castToMarkdown(value); // MarkdownType
4106          return value;
4107        case -669707736: // useContext
4108          this.getUseContext().add(castToUsageContext(value)); // UsageContext
4109          return value;
4110        case -507075711: // jurisdiction
4111          this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept
4112          return value;
4113        case -220463842: // purpose
4114          this.purpose = castToMarkdown(value); // MarkdownType
4115          return value;
4116        case 111574433: // usage
4117          this.usage = castToString(value); // StringType
4118          return value;
4119        case 1522889671: // copyright
4120          this.copyright = castToMarkdown(value); // MarkdownType
4121          return value;
4122        case 223539345: // approvalDate
4123          this.approvalDate = castToDate(value); // DateType
4124          return value;
4125        case -1687512484: // lastReviewDate
4126          this.lastReviewDate = castToDate(value); // DateType
4127          return value;
4128        case -403934648: // effectivePeriod
4129          this.effectivePeriod = castToPeriod(value); // Period
4130          return value;
4131        case 110546223: // topic
4132          this.getTopic().add(castToCodeableConcept(value)); // CodeableConcept
4133          return value;
4134        case -1406328437: // author
4135          this.getAuthor().add(castToContactDetail(value)); // ContactDetail
4136          return value;
4137        case -1307827859: // editor
4138          this.getEditor().add(castToContactDetail(value)); // ContactDetail
4139          return value;
4140        case -261190139: // reviewer
4141          this.getReviewer().add(castToContactDetail(value)); // ContactDetail
4142          return value;
4143        case 1740277666: // endorser
4144          this.getEndorser().add(castToContactDetail(value)); // ContactDetail
4145          return value;
4146        case 666807069: // relatedArtifact
4147          this.getRelatedArtifact().add(castToRelatedArtifact(value)); // RelatedArtifact
4148          return value;
4149        case 166208699: // library
4150          this.getLibrary().add(castToCanonical(value)); // CanonicalType
4151          return value;
4152        case 432371099: // disclaimer
4153          this.disclaimer = castToMarkdown(value); // MarkdownType
4154          return value;
4155        case 1924005583: // scoring
4156          this.scoring = castToCodeableConcept(value); // CodeableConcept
4157          return value;
4158        case 569347656: // compositeScoring
4159          this.compositeScoring = castToCodeableConcept(value); // CodeableConcept
4160          return value;
4161        case 3575610: // type
4162          this.getType().add(castToCodeableConcept(value)); // CodeableConcept
4163          return value;
4164        case 93273500: // riskAdjustment
4165          this.riskAdjustment = castToString(value); // StringType
4166          return value;
4167        case 1254503906: // rateAggregation
4168          this.rateAggregation = castToString(value); // StringType
4169          return value;
4170        case 345689335: // rationale
4171          this.rationale = castToMarkdown(value); // MarkdownType
4172          return value;
4173        case -18631389: // clinicalRecommendationStatement
4174          this.clinicalRecommendationStatement = castToMarkdown(value); // MarkdownType
4175          return value;
4176        case -2085456136: // improvementNotation
4177          this.improvementNotation = castToCodeableConcept(value); // CodeableConcept
4178          return value;
4179        case -1014418093: // definition
4180          this.getDefinition().add(castToMarkdown(value)); // MarkdownType
4181          return value;
4182        case -1314002088: // guidance
4183          this.guidance = castToMarkdown(value); // MarkdownType
4184          return value;
4185        case 98629247: // group
4186          this.getGroup().add((MeasureGroupComponent) value); // MeasureGroupComponent
4187          return value;
4188        case 1447496814: // supplementalData
4189          this.getSupplementalData().add((MeasureSupplementalDataComponent) value); // MeasureSupplementalDataComponent
4190          return value;
4191        default: return super.setProperty(hash, name, value);
4192        }
4193
4194      }
4195
4196      @Override
4197      public Base setProperty(String name, Base value) throws FHIRException {
4198        if (name.equals("url")) {
4199          this.url = castToUri(value); // UriType
4200        } else if (name.equals("identifier")) {
4201          this.getIdentifier().add(castToIdentifier(value));
4202        } else if (name.equals("version")) {
4203          this.version = castToString(value); // StringType
4204        } else if (name.equals("name")) {
4205          this.name = castToString(value); // StringType
4206        } else if (name.equals("title")) {
4207          this.title = castToString(value); // StringType
4208        } else if (name.equals("subtitle")) {
4209          this.subtitle = castToString(value); // StringType
4210        } else if (name.equals("status")) {
4211          value = new PublicationStatusEnumFactory().fromType(castToCode(value));
4212          this.status = (Enumeration) value; // Enumeration<PublicationStatus>
4213        } else if (name.equals("experimental")) {
4214          this.experimental = castToBoolean(value); // BooleanType
4215        } else if (name.equals("subject[x]")) {
4216          this.subject = castToType(value); // Type
4217        } else if (name.equals("date")) {
4218          this.date = castToDateTime(value); // DateTimeType
4219        } else if (name.equals("publisher")) {
4220          this.publisher = castToString(value); // StringType
4221        } else if (name.equals("contact")) {
4222          this.getContact().add(castToContactDetail(value));
4223        } else if (name.equals("description")) {
4224          this.description = castToMarkdown(value); // MarkdownType
4225        } else if (name.equals("useContext")) {
4226          this.getUseContext().add(castToUsageContext(value));
4227        } else if (name.equals("jurisdiction")) {
4228          this.getJurisdiction().add(castToCodeableConcept(value));
4229        } else if (name.equals("purpose")) {
4230          this.purpose = castToMarkdown(value); // MarkdownType
4231        } else if (name.equals("usage")) {
4232          this.usage = castToString(value); // StringType
4233        } else if (name.equals("copyright")) {
4234          this.copyright = castToMarkdown(value); // MarkdownType
4235        } else if (name.equals("approvalDate")) {
4236          this.approvalDate = castToDate(value); // DateType
4237        } else if (name.equals("lastReviewDate")) {
4238          this.lastReviewDate = castToDate(value); // DateType
4239        } else if (name.equals("effectivePeriod")) {
4240          this.effectivePeriod = castToPeriod(value); // Period
4241        } else if (name.equals("topic")) {
4242          this.getTopic().add(castToCodeableConcept(value));
4243        } else if (name.equals("author")) {
4244          this.getAuthor().add(castToContactDetail(value));
4245        } else if (name.equals("editor")) {
4246          this.getEditor().add(castToContactDetail(value));
4247        } else if (name.equals("reviewer")) {
4248          this.getReviewer().add(castToContactDetail(value));
4249        } else if (name.equals("endorser")) {
4250          this.getEndorser().add(castToContactDetail(value));
4251        } else if (name.equals("relatedArtifact")) {
4252          this.getRelatedArtifact().add(castToRelatedArtifact(value));
4253        } else if (name.equals("library")) {
4254          this.getLibrary().add(castToCanonical(value));
4255        } else if (name.equals("disclaimer")) {
4256          this.disclaimer = castToMarkdown(value); // MarkdownType
4257        } else if (name.equals("scoring")) {
4258          this.scoring = castToCodeableConcept(value); // CodeableConcept
4259        } else if (name.equals("compositeScoring")) {
4260          this.compositeScoring = castToCodeableConcept(value); // CodeableConcept
4261        } else if (name.equals("type")) {
4262          this.getType().add(castToCodeableConcept(value));
4263        } else if (name.equals("riskAdjustment")) {
4264          this.riskAdjustment = castToString(value); // StringType
4265        } else if (name.equals("rateAggregation")) {
4266          this.rateAggregation = castToString(value); // StringType
4267        } else if (name.equals("rationale")) {
4268          this.rationale = castToMarkdown(value); // MarkdownType
4269        } else if (name.equals("clinicalRecommendationStatement")) {
4270          this.clinicalRecommendationStatement = castToMarkdown(value); // MarkdownType
4271        } else if (name.equals("improvementNotation")) {
4272          this.improvementNotation = castToCodeableConcept(value); // CodeableConcept
4273        } else if (name.equals("definition")) {
4274          this.getDefinition().add(castToMarkdown(value));
4275        } else if (name.equals("guidance")) {
4276          this.guidance = castToMarkdown(value); // MarkdownType
4277        } else if (name.equals("group")) {
4278          this.getGroup().add((MeasureGroupComponent) value);
4279        } else if (name.equals("supplementalData")) {
4280          this.getSupplementalData().add((MeasureSupplementalDataComponent) value);
4281        } else
4282          return super.setProperty(name, value);
4283        return value;
4284      }
4285
4286      @Override
4287      public Base makeProperty(int hash, String name) throws FHIRException {
4288        switch (hash) {
4289        case 116079:  return getUrlElement();
4290        case -1618432855:  return addIdentifier(); 
4291        case 351608024:  return getVersionElement();
4292        case 3373707:  return getNameElement();
4293        case 110371416:  return getTitleElement();
4294        case -2060497896:  return getSubtitleElement();
4295        case -892481550:  return getStatusElement();
4296        case -404562712:  return getExperimentalElement();
4297        case -573640748:  return getSubject(); 
4298        case -1867885268:  return getSubject(); 
4299        case 3076014:  return getDateElement();
4300        case 1447404028:  return getPublisherElement();
4301        case 951526432:  return addContact(); 
4302        case -1724546052:  return getDescriptionElement();
4303        case -669707736:  return addUseContext(); 
4304        case -507075711:  return addJurisdiction(); 
4305        case -220463842:  return getPurposeElement();
4306        case 111574433:  return getUsageElement();
4307        case 1522889671:  return getCopyrightElement();
4308        case 223539345:  return getApprovalDateElement();
4309        case -1687512484:  return getLastReviewDateElement();
4310        case -403934648:  return getEffectivePeriod(); 
4311        case 110546223:  return addTopic(); 
4312        case -1406328437:  return addAuthor(); 
4313        case -1307827859:  return addEditor(); 
4314        case -261190139:  return addReviewer(); 
4315        case 1740277666:  return addEndorser(); 
4316        case 666807069:  return addRelatedArtifact(); 
4317        case 166208699:  return addLibraryElement();
4318        case 432371099:  return getDisclaimerElement();
4319        case 1924005583:  return getScoring(); 
4320        case 569347656:  return getCompositeScoring(); 
4321        case 3575610:  return addType(); 
4322        case 93273500:  return getRiskAdjustmentElement();
4323        case 1254503906:  return getRateAggregationElement();
4324        case 345689335:  return getRationaleElement();
4325        case -18631389:  return getClinicalRecommendationStatementElement();
4326        case -2085456136:  return getImprovementNotation(); 
4327        case -1014418093:  return addDefinitionElement();
4328        case -1314002088:  return getGuidanceElement();
4329        case 98629247:  return addGroup(); 
4330        case 1447496814:  return addSupplementalData(); 
4331        default: return super.makeProperty(hash, name);
4332        }
4333
4334      }
4335
4336      @Override
4337      public String[] getTypesForProperty(int hash, String name) throws FHIRException {
4338        switch (hash) {
4339        case 116079: /*url*/ return new String[] {"uri"};
4340        case -1618432855: /*identifier*/ return new String[] {"Identifier"};
4341        case 351608024: /*version*/ return new String[] {"string"};
4342        case 3373707: /*name*/ return new String[] {"string"};
4343        case 110371416: /*title*/ return new String[] {"string"};
4344        case -2060497896: /*subtitle*/ return new String[] {"string"};
4345        case -892481550: /*status*/ return new String[] {"code"};
4346        case -404562712: /*experimental*/ return new String[] {"boolean"};
4347        case -1867885268: /*subject*/ return new String[] {"CodeableConcept", "Reference"};
4348        case 3076014: /*date*/ return new String[] {"dateTime"};
4349        case 1447404028: /*publisher*/ return new String[] {"string"};
4350        case 951526432: /*contact*/ return new String[] {"ContactDetail"};
4351        case -1724546052: /*description*/ return new String[] {"markdown"};
4352        case -669707736: /*useContext*/ return new String[] {"UsageContext"};
4353        case -507075711: /*jurisdiction*/ return new String[] {"CodeableConcept"};
4354        case -220463842: /*purpose*/ return new String[] {"markdown"};
4355        case 111574433: /*usage*/ return new String[] {"string"};
4356        case 1522889671: /*copyright*/ return new String[] {"markdown"};
4357        case 223539345: /*approvalDate*/ return new String[] {"date"};
4358        case -1687512484: /*lastReviewDate*/ return new String[] {"date"};
4359        case -403934648: /*effectivePeriod*/ return new String[] {"Period"};
4360        case 110546223: /*topic*/ return new String[] {"CodeableConcept"};
4361        case -1406328437: /*author*/ return new String[] {"ContactDetail"};
4362        case -1307827859: /*editor*/ return new String[] {"ContactDetail"};
4363        case -261190139: /*reviewer*/ return new String[] {"ContactDetail"};
4364        case 1740277666: /*endorser*/ return new String[] {"ContactDetail"};
4365        case 666807069: /*relatedArtifact*/ return new String[] {"RelatedArtifact"};
4366        case 166208699: /*library*/ return new String[] {"canonical"};
4367        case 432371099: /*disclaimer*/ return new String[] {"markdown"};
4368        case 1924005583: /*scoring*/ return new String[] {"CodeableConcept"};
4369        case 569347656: /*compositeScoring*/ return new String[] {"CodeableConcept"};
4370        case 3575610: /*type*/ return new String[] {"CodeableConcept"};
4371        case 93273500: /*riskAdjustment*/ return new String[] {"string"};
4372        case 1254503906: /*rateAggregation*/ return new String[] {"string"};
4373        case 345689335: /*rationale*/ return new String[] {"markdown"};
4374        case -18631389: /*clinicalRecommendationStatement*/ return new String[] {"markdown"};
4375        case -2085456136: /*improvementNotation*/ return new String[] {"CodeableConcept"};
4376        case -1014418093: /*definition*/ return new String[] {"markdown"};
4377        case -1314002088: /*guidance*/ return new String[] {"markdown"};
4378        case 98629247: /*group*/ return new String[] {};
4379        case 1447496814: /*supplementalData*/ return new String[] {};
4380        default: return super.getTypesForProperty(hash, name);
4381        }
4382
4383      }
4384
4385      @Override
4386      public Base addChild(String name) throws FHIRException {
4387        if (name.equals("url")) {
4388          throw new FHIRException("Cannot call addChild on a primitive type Measure.url");
4389        }
4390        else if (name.equals("identifier")) {
4391          return addIdentifier();
4392        }
4393        else if (name.equals("version")) {
4394          throw new FHIRException("Cannot call addChild on a primitive type Measure.version");
4395        }
4396        else if (name.equals("name")) {
4397          throw new FHIRException("Cannot call addChild on a primitive type Measure.name");
4398        }
4399        else if (name.equals("title")) {
4400          throw new FHIRException("Cannot call addChild on a primitive type Measure.title");
4401        }
4402        else if (name.equals("subtitle")) {
4403          throw new FHIRException("Cannot call addChild on a primitive type Measure.subtitle");
4404        }
4405        else if (name.equals("status")) {
4406          throw new FHIRException("Cannot call addChild on a primitive type Measure.status");
4407        }
4408        else if (name.equals("experimental")) {
4409          throw new FHIRException("Cannot call addChild on a primitive type Measure.experimental");
4410        }
4411        else if (name.equals("subjectCodeableConcept")) {
4412          this.subject = new CodeableConcept();
4413          return this.subject;
4414        }
4415        else if (name.equals("subjectReference")) {
4416          this.subject = new Reference();
4417          return this.subject;
4418        }
4419        else if (name.equals("date")) {
4420          throw new FHIRException("Cannot call addChild on a primitive type Measure.date");
4421        }
4422        else if (name.equals("publisher")) {
4423          throw new FHIRException("Cannot call addChild on a primitive type Measure.publisher");
4424        }
4425        else if (name.equals("contact")) {
4426          return addContact();
4427        }
4428        else if (name.equals("description")) {
4429          throw new FHIRException("Cannot call addChild on a primitive type Measure.description");
4430        }
4431        else if (name.equals("useContext")) {
4432          return addUseContext();
4433        }
4434        else if (name.equals("jurisdiction")) {
4435          return addJurisdiction();
4436        }
4437        else if (name.equals("purpose")) {
4438          throw new FHIRException("Cannot call addChild on a primitive type Measure.purpose");
4439        }
4440        else if (name.equals("usage")) {
4441          throw new FHIRException("Cannot call addChild on a primitive type Measure.usage");
4442        }
4443        else if (name.equals("copyright")) {
4444          throw new FHIRException("Cannot call addChild on a primitive type Measure.copyright");
4445        }
4446        else if (name.equals("approvalDate")) {
4447          throw new FHIRException("Cannot call addChild on a primitive type Measure.approvalDate");
4448        }
4449        else if (name.equals("lastReviewDate")) {
4450          throw new FHIRException("Cannot call addChild on a primitive type Measure.lastReviewDate");
4451        }
4452        else if (name.equals("effectivePeriod")) {
4453          this.effectivePeriod = new Period();
4454          return this.effectivePeriod;
4455        }
4456        else if (name.equals("topic")) {
4457          return addTopic();
4458        }
4459        else if (name.equals("author")) {
4460          return addAuthor();
4461        }
4462        else if (name.equals("editor")) {
4463          return addEditor();
4464        }
4465        else if (name.equals("reviewer")) {
4466          return addReviewer();
4467        }
4468        else if (name.equals("endorser")) {
4469          return addEndorser();
4470        }
4471        else if (name.equals("relatedArtifact")) {
4472          return addRelatedArtifact();
4473        }
4474        else if (name.equals("library")) {
4475          throw new FHIRException("Cannot call addChild on a primitive type Measure.library");
4476        }
4477        else if (name.equals("disclaimer")) {
4478          throw new FHIRException("Cannot call addChild on a primitive type Measure.disclaimer");
4479        }
4480        else if (name.equals("scoring")) {
4481          this.scoring = new CodeableConcept();
4482          return this.scoring;
4483        }
4484        else if (name.equals("compositeScoring")) {
4485          this.compositeScoring = new CodeableConcept();
4486          return this.compositeScoring;
4487        }
4488        else if (name.equals("type")) {
4489          return addType();
4490        }
4491        else if (name.equals("riskAdjustment")) {
4492          throw new FHIRException("Cannot call addChild on a primitive type Measure.riskAdjustment");
4493        }
4494        else if (name.equals("rateAggregation")) {
4495          throw new FHIRException("Cannot call addChild on a primitive type Measure.rateAggregation");
4496        }
4497        else if (name.equals("rationale")) {
4498          throw new FHIRException("Cannot call addChild on a primitive type Measure.rationale");
4499        }
4500        else if (name.equals("clinicalRecommendationStatement")) {
4501          throw new FHIRException("Cannot call addChild on a primitive type Measure.clinicalRecommendationStatement");
4502        }
4503        else if (name.equals("improvementNotation")) {
4504          this.improvementNotation = new CodeableConcept();
4505          return this.improvementNotation;
4506        }
4507        else if (name.equals("definition")) {
4508          throw new FHIRException("Cannot call addChild on a primitive type Measure.definition");
4509        }
4510        else if (name.equals("guidance")) {
4511          throw new FHIRException("Cannot call addChild on a primitive type Measure.guidance");
4512        }
4513        else if (name.equals("group")) {
4514          return addGroup();
4515        }
4516        else if (name.equals("supplementalData")) {
4517          return addSupplementalData();
4518        }
4519        else
4520          return super.addChild(name);
4521      }
4522
4523  public String fhirType() {
4524    return "Measure";
4525
4526  }
4527
4528      public Measure copy() {
4529        Measure dst = new Measure();
4530        copyValues(dst);
4531        dst.url = url == null ? null : url.copy();
4532        if (identifier != null) {
4533          dst.identifier = new ArrayList<Identifier>();
4534          for (Identifier i : identifier)
4535            dst.identifier.add(i.copy());
4536        };
4537        dst.version = version == null ? null : version.copy();
4538        dst.name = name == null ? null : name.copy();
4539        dst.title = title == null ? null : title.copy();
4540        dst.subtitle = subtitle == null ? null : subtitle.copy();
4541        dst.status = status == null ? null : status.copy();
4542        dst.experimental = experimental == null ? null : experimental.copy();
4543        dst.subject = subject == null ? null : subject.copy();
4544        dst.date = date == null ? null : date.copy();
4545        dst.publisher = publisher == null ? null : publisher.copy();
4546        if (contact != null) {
4547          dst.contact = new ArrayList<ContactDetail>();
4548          for (ContactDetail i : contact)
4549            dst.contact.add(i.copy());
4550        };
4551        dst.description = description == null ? null : description.copy();
4552        if (useContext != null) {
4553          dst.useContext = new ArrayList<UsageContext>();
4554          for (UsageContext i : useContext)
4555            dst.useContext.add(i.copy());
4556        };
4557        if (jurisdiction != null) {
4558          dst.jurisdiction = new ArrayList<CodeableConcept>();
4559          for (CodeableConcept i : jurisdiction)
4560            dst.jurisdiction.add(i.copy());
4561        };
4562        dst.purpose = purpose == null ? null : purpose.copy();
4563        dst.usage = usage == null ? null : usage.copy();
4564        dst.copyright = copyright == null ? null : copyright.copy();
4565        dst.approvalDate = approvalDate == null ? null : approvalDate.copy();
4566        dst.lastReviewDate = lastReviewDate == null ? null : lastReviewDate.copy();
4567        dst.effectivePeriod = effectivePeriod == null ? null : effectivePeriod.copy();
4568        if (topic != null) {
4569          dst.topic = new ArrayList<CodeableConcept>();
4570          for (CodeableConcept i : topic)
4571            dst.topic.add(i.copy());
4572        };
4573        if (author != null) {
4574          dst.author = new ArrayList<ContactDetail>();
4575          for (ContactDetail i : author)
4576            dst.author.add(i.copy());
4577        };
4578        if (editor != null) {
4579          dst.editor = new ArrayList<ContactDetail>();
4580          for (ContactDetail i : editor)
4581            dst.editor.add(i.copy());
4582        };
4583        if (reviewer != null) {
4584          dst.reviewer = new ArrayList<ContactDetail>();
4585          for (ContactDetail i : reviewer)
4586            dst.reviewer.add(i.copy());
4587        };
4588        if (endorser != null) {
4589          dst.endorser = new ArrayList<ContactDetail>();
4590          for (ContactDetail i : endorser)
4591            dst.endorser.add(i.copy());
4592        };
4593        if (relatedArtifact != null) {
4594          dst.relatedArtifact = new ArrayList<RelatedArtifact>();
4595          for (RelatedArtifact i : relatedArtifact)
4596            dst.relatedArtifact.add(i.copy());
4597        };
4598        if (library != null) {
4599          dst.library = new ArrayList<CanonicalType>();
4600          for (CanonicalType i : library)
4601            dst.library.add(i.copy());
4602        };
4603        dst.disclaimer = disclaimer == null ? null : disclaimer.copy();
4604        dst.scoring = scoring == null ? null : scoring.copy();
4605        dst.compositeScoring = compositeScoring == null ? null : compositeScoring.copy();
4606        if (type != null) {
4607          dst.type = new ArrayList<CodeableConcept>();
4608          for (CodeableConcept i : type)
4609            dst.type.add(i.copy());
4610        };
4611        dst.riskAdjustment = riskAdjustment == null ? null : riskAdjustment.copy();
4612        dst.rateAggregation = rateAggregation == null ? null : rateAggregation.copy();
4613        dst.rationale = rationale == null ? null : rationale.copy();
4614        dst.clinicalRecommendationStatement = clinicalRecommendationStatement == null ? null : clinicalRecommendationStatement.copy();
4615        dst.improvementNotation = improvementNotation == null ? null : improvementNotation.copy();
4616        if (definition != null) {
4617          dst.definition = new ArrayList<MarkdownType>();
4618          for (MarkdownType i : definition)
4619            dst.definition.add(i.copy());
4620        };
4621        dst.guidance = guidance == null ? null : guidance.copy();
4622        if (group != null) {
4623          dst.group = new ArrayList<MeasureGroupComponent>();
4624          for (MeasureGroupComponent i : group)
4625            dst.group.add(i.copy());
4626        };
4627        if (supplementalData != null) {
4628          dst.supplementalData = new ArrayList<MeasureSupplementalDataComponent>();
4629          for (MeasureSupplementalDataComponent i : supplementalData)
4630            dst.supplementalData.add(i.copy());
4631        };
4632        return dst;
4633      }
4634
4635      protected Measure typedCopy() {
4636        return copy();
4637      }
4638
4639      @Override
4640      public boolean equalsDeep(Base other_) {
4641        if (!super.equalsDeep(other_))
4642          return false;
4643        if (!(other_ instanceof Measure))
4644          return false;
4645        Measure o = (Measure) other_;
4646        return compareDeep(identifier, o.identifier, true) && compareDeep(subtitle, o.subtitle, true) && compareDeep(subject, o.subject, true)
4647           && compareDeep(purpose, o.purpose, true) && compareDeep(usage, o.usage, true) && compareDeep(copyright, o.copyright, true)
4648           && compareDeep(approvalDate, o.approvalDate, true) && compareDeep(lastReviewDate, o.lastReviewDate, true)
4649           && compareDeep(effectivePeriod, o.effectivePeriod, true) && compareDeep(topic, o.topic, true) && compareDeep(author, o.author, true)
4650           && compareDeep(editor, o.editor, true) && compareDeep(reviewer, o.reviewer, true) && compareDeep(endorser, o.endorser, true)
4651           && compareDeep(relatedArtifact, o.relatedArtifact, true) && compareDeep(library, o.library, true)
4652           && compareDeep(disclaimer, o.disclaimer, true) && compareDeep(scoring, o.scoring, true) && compareDeep(compositeScoring, o.compositeScoring, true)
4653           && compareDeep(type, o.type, true) && compareDeep(riskAdjustment, o.riskAdjustment, true) && compareDeep(rateAggregation, o.rateAggregation, true)
4654           && compareDeep(rationale, o.rationale, true) && compareDeep(clinicalRecommendationStatement, o.clinicalRecommendationStatement, true)
4655           && compareDeep(improvementNotation, o.improvementNotation, true) && compareDeep(definition, o.definition, true)
4656           && compareDeep(guidance, o.guidance, true) && compareDeep(group, o.group, true) && compareDeep(supplementalData, o.supplementalData, true)
4657          ;
4658      }
4659
4660      @Override
4661      public boolean equalsShallow(Base other_) {
4662        if (!super.equalsShallow(other_))
4663          return false;
4664        if (!(other_ instanceof Measure))
4665          return false;
4666        Measure o = (Measure) other_;
4667        return compareValues(subtitle, o.subtitle, true) && compareValues(purpose, o.purpose, true) && compareValues(usage, o.usage, true)
4668           && compareValues(copyright, o.copyright, true) && compareValues(approvalDate, o.approvalDate, true)
4669           && compareValues(lastReviewDate, o.lastReviewDate, true) && compareValues(disclaimer, o.disclaimer, true)
4670           && compareValues(riskAdjustment, o.riskAdjustment, true) && compareValues(rateAggregation, o.rateAggregation, true)
4671           && compareValues(rationale, o.rationale, true) && compareValues(clinicalRecommendationStatement, o.clinicalRecommendationStatement, true)
4672           && compareValues(definition, o.definition, true) && compareValues(guidance, o.guidance, true);
4673      }
4674
4675      public boolean isEmpty() {
4676        return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, subtitle, subject
4677          , purpose, usage, copyright, approvalDate, lastReviewDate, effectivePeriod, topic
4678          , author, editor, reviewer, endorser, relatedArtifact, library, disclaimer, scoring
4679          , compositeScoring, type, riskAdjustment, rateAggregation, rationale, clinicalRecommendationStatement
4680          , improvementNotation, definition, guidance, group, supplementalData);
4681      }
4682
4683  @Override
4684  public ResourceType getResourceType() {
4685    return ResourceType.Measure;
4686   }
4687
4688 /**
4689   * Search parameter: <b>date</b>
4690   * <p>
4691   * Description: <b>The measure publication date</b><br>
4692   * Type: <b>date</b><br>
4693   * Path: <b>Measure.date</b><br>
4694   * </p>
4695   */
4696  @SearchParamDefinition(name="date", path="Measure.date", description="The measure publication date", type="date" )
4697  public static final String SP_DATE = "date";
4698 /**
4699   * <b>Fluent Client</b> search parameter constant for <b>date</b>
4700   * <p>
4701   * Description: <b>The measure publication date</b><br>
4702   * Type: <b>date</b><br>
4703   * Path: <b>Measure.date</b><br>
4704   * </p>
4705   */
4706  public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE);
4707
4708 /**
4709   * Search parameter: <b>identifier</b>
4710   * <p>
4711   * Description: <b>External identifier for the measure</b><br>
4712   * Type: <b>token</b><br>
4713   * Path: <b>Measure.identifier</b><br>
4714   * </p>
4715   */
4716  @SearchParamDefinition(name="identifier", path="Measure.identifier", description="External identifier for the measure", type="token" )
4717  public static final String SP_IDENTIFIER = "identifier";
4718 /**
4719   * <b>Fluent Client</b> search parameter constant for <b>identifier</b>
4720   * <p>
4721   * Description: <b>External identifier for the measure</b><br>
4722   * Type: <b>token</b><br>
4723   * Path: <b>Measure.identifier</b><br>
4724   * </p>
4725   */
4726  public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER);
4727
4728 /**
4729   * Search parameter: <b>successor</b>
4730   * <p>
4731   * Description: <b>What resource is being referenced</b><br>
4732   * Type: <b>reference</b><br>
4733   * Path: <b>Measure.relatedArtifact.resource</b><br>
4734   * </p>
4735   */
4736  @SearchParamDefinition(name="successor", path="Measure.relatedArtifact.where(type='successor').resource", description="What resource is being referenced", type="reference" )
4737  public static final String SP_SUCCESSOR = "successor";
4738 /**
4739   * <b>Fluent Client</b> search parameter constant for <b>successor</b>
4740   * <p>
4741   * Description: <b>What resource is being referenced</b><br>
4742   * Type: <b>reference</b><br>
4743   * Path: <b>Measure.relatedArtifact.resource</b><br>
4744   * </p>
4745   */
4746  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUCCESSOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUCCESSOR);
4747
4748/**
4749   * Constant for fluent queries to be used to add include statements. Specifies
4750   * the path value of "<b>Measure:successor</b>".
4751   */
4752  public static final ca.uhn.fhir.model.api.Include INCLUDE_SUCCESSOR = new ca.uhn.fhir.model.api.Include("Measure:successor").toLocked();
4753
4754 /**
4755   * Search parameter: <b>context-type-value</b>
4756   * <p>
4757   * Description: <b>A use context type and value assigned to the measure</b><br>
4758   * Type: <b>composite</b><br>
4759   * Path: <b></b><br>
4760   * </p>
4761   */
4762  @SearchParamDefinition(name="context-type-value", path="Measure.useContext", description="A use context type and value assigned to the measure", type="composite", compositeOf={"context-type", "context"} )
4763  public static final String SP_CONTEXT_TYPE_VALUE = "context-type-value";
4764 /**
4765   * <b>Fluent Client</b> search parameter constant for <b>context-type-value</b>
4766   * <p>
4767   * Description: <b>A use context type and value assigned to the measure</b><br>
4768   * Type: <b>composite</b><br>
4769   * Path: <b></b><br>
4770   * </p>
4771   */
4772  public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> CONTEXT_TYPE_VALUE = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>(SP_CONTEXT_TYPE_VALUE);
4773
4774 /**
4775   * Search parameter: <b>jurisdiction</b>
4776   * <p>
4777   * Description: <b>Intended jurisdiction for the measure</b><br>
4778   * Type: <b>token</b><br>
4779   * Path: <b>Measure.jurisdiction</b><br>
4780   * </p>
4781   */
4782  @SearchParamDefinition(name="jurisdiction", path="Measure.jurisdiction", description="Intended jurisdiction for the measure", type="token" )
4783  public static final String SP_JURISDICTION = "jurisdiction";
4784 /**
4785   * <b>Fluent Client</b> search parameter constant for <b>jurisdiction</b>
4786   * <p>
4787   * Description: <b>Intended jurisdiction for the measure</b><br>
4788   * Type: <b>token</b><br>
4789   * Path: <b>Measure.jurisdiction</b><br>
4790   * </p>
4791   */
4792  public static final ca.uhn.fhir.rest.gclient.TokenClientParam JURISDICTION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_JURISDICTION);
4793
4794 /**
4795   * Search parameter: <b>description</b>
4796   * <p>
4797   * Description: <b>The description of the measure</b><br>
4798   * Type: <b>string</b><br>
4799   * Path: <b>Measure.description</b><br>
4800   * </p>
4801   */
4802  @SearchParamDefinition(name="description", path="Measure.description", description="The description of the measure", type="string" )
4803  public static final String SP_DESCRIPTION = "description";
4804 /**
4805   * <b>Fluent Client</b> search parameter constant for <b>description</b>
4806   * <p>
4807   * Description: <b>The description of the measure</b><br>
4808   * Type: <b>string</b><br>
4809   * Path: <b>Measure.description</b><br>
4810   * </p>
4811   */
4812  public static final ca.uhn.fhir.rest.gclient.StringClientParam DESCRIPTION = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DESCRIPTION);
4813
4814 /**
4815   * Search parameter: <b>derived-from</b>
4816   * <p>
4817   * Description: <b>What resource is being referenced</b><br>
4818   * Type: <b>reference</b><br>
4819   * Path: <b>Measure.relatedArtifact.resource</b><br>
4820   * </p>
4821   */
4822  @SearchParamDefinition(name="derived-from", path="Measure.relatedArtifact.where(type='derived-from').resource", description="What resource is being referenced", type="reference" )
4823  public static final String SP_DERIVED_FROM = "derived-from";
4824 /**
4825   * <b>Fluent Client</b> search parameter constant for <b>derived-from</b>
4826   * <p>
4827   * Description: <b>What resource is being referenced</b><br>
4828   * Type: <b>reference</b><br>
4829   * Path: <b>Measure.relatedArtifact.resource</b><br>
4830   * </p>
4831   */
4832  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam DERIVED_FROM = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_DERIVED_FROM);
4833
4834/**
4835   * Constant for fluent queries to be used to add include statements. Specifies
4836   * the path value of "<b>Measure:derived-from</b>".
4837   */
4838  public static final ca.uhn.fhir.model.api.Include INCLUDE_DERIVED_FROM = new ca.uhn.fhir.model.api.Include("Measure:derived-from").toLocked();
4839
4840 /**
4841   * Search parameter: <b>context-type</b>
4842   * <p>
4843   * Description: <b>A type of use context assigned to the measure</b><br>
4844   * Type: <b>token</b><br>
4845   * Path: <b>Measure.useContext.code</b><br>
4846   * </p>
4847   */
4848  @SearchParamDefinition(name="context-type", path="Measure.useContext.code", description="A type of use context assigned to the measure", type="token" )
4849  public static final String SP_CONTEXT_TYPE = "context-type";
4850 /**
4851   * <b>Fluent Client</b> search parameter constant for <b>context-type</b>
4852   * <p>
4853   * Description: <b>A type of use context assigned to the measure</b><br>
4854   * Type: <b>token</b><br>
4855   * Path: <b>Measure.useContext.code</b><br>
4856   * </p>
4857   */
4858  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT_TYPE);
4859
4860 /**
4861   * Search parameter: <b>predecessor</b>
4862   * <p>
4863   * Description: <b>What resource is being referenced</b><br>
4864   * Type: <b>reference</b><br>
4865   * Path: <b>Measure.relatedArtifact.resource</b><br>
4866   * </p>
4867   */
4868  @SearchParamDefinition(name="predecessor", path="Measure.relatedArtifact.where(type='predecessor').resource", description="What resource is being referenced", type="reference" )
4869  public static final String SP_PREDECESSOR = "predecessor";
4870 /**
4871   * <b>Fluent Client</b> search parameter constant for <b>predecessor</b>
4872   * <p>
4873   * Description: <b>What resource is being referenced</b><br>
4874   * Type: <b>reference</b><br>
4875   * Path: <b>Measure.relatedArtifact.resource</b><br>
4876   * </p>
4877   */
4878  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PREDECESSOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PREDECESSOR);
4879
4880/**
4881   * Constant for fluent queries to be used to add include statements. Specifies
4882   * the path value of "<b>Measure:predecessor</b>".
4883   */
4884  public static final ca.uhn.fhir.model.api.Include INCLUDE_PREDECESSOR = new ca.uhn.fhir.model.api.Include("Measure:predecessor").toLocked();
4885
4886 /**
4887   * Search parameter: <b>title</b>
4888   * <p>
4889   * Description: <b>The human-friendly name of the measure</b><br>
4890   * Type: <b>string</b><br>
4891   * Path: <b>Measure.title</b><br>
4892   * </p>
4893   */
4894  @SearchParamDefinition(name="title", path="Measure.title", description="The human-friendly name of the measure", type="string" )
4895  public static final String SP_TITLE = "title";
4896 /**
4897   * <b>Fluent Client</b> search parameter constant for <b>title</b>
4898   * <p>
4899   * Description: <b>The human-friendly name of the measure</b><br>
4900   * Type: <b>string</b><br>
4901   * Path: <b>Measure.title</b><br>
4902   * </p>
4903   */
4904  public static final ca.uhn.fhir.rest.gclient.StringClientParam TITLE = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_TITLE);
4905
4906 /**
4907   * Search parameter: <b>composed-of</b>
4908   * <p>
4909   * Description: <b>What resource is being referenced</b><br>
4910   * Type: <b>reference</b><br>
4911   * Path: <b>Measure.relatedArtifact.resource</b><br>
4912   * </p>
4913   */
4914  @SearchParamDefinition(name="composed-of", path="Measure.relatedArtifact.where(type='composed-of').resource", description="What resource is being referenced", type="reference" )
4915  public static final String SP_COMPOSED_OF = "composed-of";
4916 /**
4917   * <b>Fluent Client</b> search parameter constant for <b>composed-of</b>
4918   * <p>
4919   * Description: <b>What resource is being referenced</b><br>
4920   * Type: <b>reference</b><br>
4921   * Path: <b>Measure.relatedArtifact.resource</b><br>
4922   * </p>
4923   */
4924  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam COMPOSED_OF = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_COMPOSED_OF);
4925
4926/**
4927   * Constant for fluent queries to be used to add include statements. Specifies
4928   * the path value of "<b>Measure:composed-of</b>".
4929   */
4930  public static final ca.uhn.fhir.model.api.Include INCLUDE_COMPOSED_OF = new ca.uhn.fhir.model.api.Include("Measure:composed-of").toLocked();
4931
4932 /**
4933   * Search parameter: <b>version</b>
4934   * <p>
4935   * Description: <b>The business version of the measure</b><br>
4936   * Type: <b>token</b><br>
4937   * Path: <b>Measure.version</b><br>
4938   * </p>
4939   */
4940  @SearchParamDefinition(name="version", path="Measure.version", description="The business version of the measure", type="token" )
4941  public static final String SP_VERSION = "version";
4942 /**
4943   * <b>Fluent Client</b> search parameter constant for <b>version</b>
4944   * <p>
4945   * Description: <b>The business version of the measure</b><br>
4946   * Type: <b>token</b><br>
4947   * Path: <b>Measure.version</b><br>
4948   * </p>
4949   */
4950  public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERSION);
4951
4952 /**
4953   * Search parameter: <b>url</b>
4954   * <p>
4955   * Description: <b>The uri that identifies the measure</b><br>
4956   * Type: <b>uri</b><br>
4957   * Path: <b>Measure.url</b><br>
4958   * </p>
4959   */
4960  @SearchParamDefinition(name="url", path="Measure.url", description="The uri that identifies the measure", type="uri" )
4961  public static final String SP_URL = "url";
4962 /**
4963   * <b>Fluent Client</b> search parameter constant for <b>url</b>
4964   * <p>
4965   * Description: <b>The uri that identifies the measure</b><br>
4966   * Type: <b>uri</b><br>
4967   * Path: <b>Measure.url</b><br>
4968   * </p>
4969   */
4970  public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL);
4971
4972 /**
4973   * Search parameter: <b>context-quantity</b>
4974   * <p>
4975   * Description: <b>A quantity- or range-valued use context assigned to the measure</b><br>
4976   * Type: <b>quantity</b><br>
4977   * Path: <b>Measure.useContext.valueQuantity, Measure.useContext.valueRange</b><br>
4978   * </p>
4979   */
4980  @SearchParamDefinition(name="context-quantity", path="(Measure.useContext.value as Quantity) | (Measure.useContext.value as Range)", description="A quantity- or range-valued use context assigned to the measure", type="quantity" )
4981  public static final String SP_CONTEXT_QUANTITY = "context-quantity";
4982 /**
4983   * <b>Fluent Client</b> search parameter constant for <b>context-quantity</b>
4984   * <p>
4985   * Description: <b>A quantity- or range-valued use context assigned to the measure</b><br>
4986   * Type: <b>quantity</b><br>
4987   * Path: <b>Measure.useContext.valueQuantity, Measure.useContext.valueRange</b><br>
4988   * </p>
4989   */
4990  public static final ca.uhn.fhir.rest.gclient.QuantityClientParam CONTEXT_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(SP_CONTEXT_QUANTITY);
4991
4992 /**
4993   * Search parameter: <b>effective</b>
4994   * <p>
4995   * Description: <b>The time during which the measure is intended to be in use</b><br>
4996   * Type: <b>date</b><br>
4997   * Path: <b>Measure.effectivePeriod</b><br>
4998   * </p>
4999   */
5000  @SearchParamDefinition(name="effective", path="Measure.effectivePeriod", description="The time during which the measure is intended to be in use", type="date" )
5001  public static final String SP_EFFECTIVE = "effective";
5002 /**
5003   * <b>Fluent Client</b> search parameter constant for <b>effective</b>
5004   * <p>
5005   * Description: <b>The time during which the measure is intended to be in use</b><br>
5006   * Type: <b>date</b><br>
5007   * Path: <b>Measure.effectivePeriod</b><br>
5008   * </p>
5009   */
5010  public static final ca.uhn.fhir.rest.gclient.DateClientParam EFFECTIVE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_EFFECTIVE);
5011
5012 /**
5013   * Search parameter: <b>depends-on</b>
5014   * <p>
5015   * Description: <b>What resource is being referenced</b><br>
5016   * Type: <b>reference</b><br>
5017   * Path: <b>Measure.relatedArtifact.resource, Measure.library</b><br>
5018   * </p>
5019   */
5020  @SearchParamDefinition(name="depends-on", path="Measure.relatedArtifact.where(type='depends-on').resource | Measure.library", description="What resource is being referenced", type="reference" )
5021  public static final String SP_DEPENDS_ON = "depends-on";
5022 /**
5023   * <b>Fluent Client</b> search parameter constant for <b>depends-on</b>
5024   * <p>
5025   * Description: <b>What resource is being referenced</b><br>
5026   * Type: <b>reference</b><br>
5027   * Path: <b>Measure.relatedArtifact.resource, Measure.library</b><br>
5028   * </p>
5029   */
5030  public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam DEPENDS_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_DEPENDS_ON);
5031
5032/**
5033   * Constant for fluent queries to be used to add include statements. Specifies
5034   * the path value of "<b>Measure:depends-on</b>".
5035   */
5036  public static final ca.uhn.fhir.model.api.Include INCLUDE_DEPENDS_ON = new ca.uhn.fhir.model.api.Include("Measure:depends-on").toLocked();
5037
5038 /**
5039   * Search parameter: <b>name</b>
5040   * <p>
5041   * Description: <b>Computationally friendly name of the measure</b><br>
5042   * Type: <b>string</b><br>
5043   * Path: <b>Measure.name</b><br>
5044   * </p>
5045   */
5046  @SearchParamDefinition(name="name", path="Measure.name", description="Computationally friendly name of the measure", type="string" )
5047  public static final String SP_NAME = "name";
5048 /**
5049   * <b>Fluent Client</b> search parameter constant for <b>name</b>
5050   * <p>
5051   * Description: <b>Computationally friendly name of the measure</b><br>
5052   * Type: <b>string</b><br>
5053   * Path: <b>Measure.name</b><br>
5054   * </p>
5055   */
5056  public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME);
5057
5058 /**
5059   * Search parameter: <b>context</b>
5060   * <p>
5061   * Description: <b>A use context assigned to the measure</b><br>
5062   * Type: <b>token</b><br>
5063   * Path: <b>Measure.useContext.valueCodeableConcept</b><br>
5064   * </p>
5065   */
5066  @SearchParamDefinition(name="context", path="(Measure.useContext.value as CodeableConcept)", description="A use context assigned to the measure", type="token" )
5067  public static final String SP_CONTEXT = "context";
5068 /**
5069   * <b>Fluent Client</b> search parameter constant for <b>context</b>
5070   * <p>
5071   * Description: <b>A use context assigned to the measure</b><br>
5072   * Type: <b>token</b><br>
5073   * Path: <b>Measure.useContext.valueCodeableConcept</b><br>
5074   * </p>
5075   */
5076  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT);
5077
5078 /**
5079   * Search parameter: <b>publisher</b>
5080   * <p>
5081   * Description: <b>Name of the publisher of the measure</b><br>
5082   * Type: <b>string</b><br>
5083   * Path: <b>Measure.publisher</b><br>
5084   * </p>
5085   */
5086  @SearchParamDefinition(name="publisher", path="Measure.publisher", description="Name of the publisher of the measure", type="string" )
5087  public static final String SP_PUBLISHER = "publisher";
5088 /**
5089   * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
5090   * <p>
5091   * Description: <b>Name of the publisher of the measure</b><br>
5092   * Type: <b>string</b><br>
5093   * Path: <b>Measure.publisher</b><br>
5094   * </p>
5095   */
5096  public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PUBLISHER);
5097
5098 /**
5099   * Search parameter: <b>topic</b>
5100   * <p>
5101   * Description: <b>Topics associated with the measure</b><br>
5102   * Type: <b>token</b><br>
5103   * Path: <b>Measure.topic</b><br>
5104   * </p>
5105   */
5106  @SearchParamDefinition(name="topic", path="Measure.topic", description="Topics associated with the measure", type="token" )
5107  public static final String SP_TOPIC = "topic";
5108 /**
5109   * <b>Fluent Client</b> search parameter constant for <b>topic</b>
5110   * <p>
5111   * Description: <b>Topics associated with the measure</b><br>
5112   * Type: <b>token</b><br>
5113   * Path: <b>Measure.topic</b><br>
5114   * </p>
5115   */
5116  public static final ca.uhn.fhir.rest.gclient.TokenClientParam TOPIC = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TOPIC);
5117
5118 /**
5119   * Search parameter: <b>context-type-quantity</b>
5120   * <p>
5121   * Description: <b>A use context type and quantity- or range-based value assigned to the measure</b><br>
5122   * Type: <b>composite</b><br>
5123   * Path: <b></b><br>
5124   * </p>
5125   */
5126  @SearchParamDefinition(name="context-type-quantity", path="Measure.useContext", description="A use context type and quantity- or range-based value assigned to the measure", type="composite", compositeOf={"context-type", "context-quantity"} )
5127  public static final String SP_CONTEXT_TYPE_QUANTITY = "context-type-quantity";
5128 /**
5129   * <b>Fluent Client</b> search parameter constant for <b>context-type-quantity</b>
5130   * <p>
5131   * Description: <b>A use context type and quantity- or range-based value assigned to the measure</b><br>
5132   * Type: <b>composite</b><br>
5133   * Path: <b></b><br>
5134   * </p>
5135   */
5136  public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> CONTEXT_TYPE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>(SP_CONTEXT_TYPE_QUANTITY);
5137
5138 /**
5139   * Search parameter: <b>status</b>
5140   * <p>
5141   * Description: <b>The current status of the measure</b><br>
5142   * Type: <b>token</b><br>
5143   * Path: <b>Measure.status</b><br>
5144   * </p>
5145   */
5146  @SearchParamDefinition(name="status", path="Measure.status", description="The current status of the measure", type="token" )
5147  public static final String SP_STATUS = "status";
5148 /**
5149   * <b>Fluent Client</b> search parameter constant for <b>status</b>
5150   * <p>
5151   * Description: <b>The current status of the measure</b><br>
5152   * Type: <b>token</b><br>
5153   * Path: <b>Measure.status</b><br>
5154   * </p>
5155   */
5156  public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS);
5157
5158
5159}
5160