001package org.hl7.fhir.r4.model;
002
003/*
004  Copyright (c) 2011+, HL7, Inc.
005  All rights reserved.
006  
007  Redistribution and use in source and binary forms, with or without modification, 
008  are permitted provided that the following conditions are met:
009  
010   * Redistributions of source code must retain the above copyright notice, this 
011     list of conditions and the following disclaimer.
012   * Redistributions in binary form must reproduce the above copyright notice, 
013     this list of conditions and the following disclaimer in the documentation 
014     and/or other materials provided with the distribution.
015   * Neither the name of HL7 nor the names of its contributors may be used to 
016     endorse or promote products derived from this software without specific 
017     prior written permission.
018  
019  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 
020  ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
021  WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 
022  IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 
023  INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 
024  NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 
025  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 
026  WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 
027  ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 
028  POSSIBILITY OF SUCH DAMAGE.
029  
030*/
031
032// Generated on Tue, May 12, 2020 07:26+1000 for FHIR v4.0.1
033import java.util.ArrayList;
034import java.util.Date;
035import java.util.List;
036
037import org.hl7.fhir.exceptions.FHIRException;
038import org.hl7.fhir.instance.model.api.IBaseBackboneElement;
039import org.hl7.fhir.r4.model.Enumerations.PublicationStatus;
040import org.hl7.fhir.r4.model.Enumerations.PublicationStatusEnumFactory;
041import org.hl7.fhir.utilities.Utilities;
042
043import ca.uhn.fhir.model.api.annotation.Block;
044import ca.uhn.fhir.model.api.annotation.Child;
045import ca.uhn.fhir.model.api.annotation.ChildOrder;
046import ca.uhn.fhir.model.api.annotation.Description;
047import ca.uhn.fhir.model.api.annotation.ResourceDef;
048import ca.uhn.fhir.model.api.annotation.SearchParamDefinition;
049
050/**
051 * A TerminologyCapabilities resource documents a set of capabilities
052 * (behaviors) of a FHIR Terminology Server that may be used as a statement of
053 * actual server functionality or a statement of required or desired server
054 * implementation.
055 */
056@ResourceDef(name = "TerminologyCapabilities", profile = "http://hl7.org/fhir/StructureDefinition/TerminologyCapabilities")
057@ChildOrder(names = { "url", "version", "name", "title", "status", "experimental", "date", "publisher", "contact",
058    "description", "useContext", "jurisdiction", "purpose", "copyright", "kind", "software", "implementation",
059    "lockedDate", "codeSystem", "expansion", "codeSearch", "validateCode", "translation", "closure" })
060public class TerminologyCapabilities extends MetadataResource {
061
062  public enum CapabilityStatementKind {
063    /**
064     * The CapabilityStatement instance represents the present capabilities of a
065     * specific system instance. This is the kind returned by /metadata for a FHIR
066     * server end-point.
067     */
068    INSTANCE,
069    /**
070     * The CapabilityStatement instance represents the capabilities of a system or
071     * piece of software, independent of a particular installation.
072     */
073    CAPABILITY,
074    /**
075     * The CapabilityStatement instance represents a set of requirements for other
076     * systems to meet; e.g. as part of an implementation guide or 'request for
077     * proposal'.
078     */
079    REQUIREMENTS,
080    /**
081     * added to help the parsers with the generic types
082     */
083    NULL;
084
085    public static CapabilityStatementKind fromCode(String codeString) throws FHIRException {
086      if (codeString == null || "".equals(codeString))
087        return null;
088      if ("instance".equals(codeString))
089        return INSTANCE;
090      if ("capability".equals(codeString))
091        return CAPABILITY;
092      if ("requirements".equals(codeString))
093        return REQUIREMENTS;
094      if (Configuration.isAcceptInvalidEnums())
095        return null;
096      else
097        throw new FHIRException("Unknown CapabilityStatementKind code '" + codeString + "'");
098    }
099
100    public String toCode() {
101      switch (this) {
102      case INSTANCE:
103        return "instance";
104      case CAPABILITY:
105        return "capability";
106      case REQUIREMENTS:
107        return "requirements";
108      case NULL:
109        return null;
110      default:
111        return "?";
112      }
113    }
114
115    public String getSystem() {
116      switch (this) {
117      case INSTANCE:
118        return "http://hl7.org/fhir/capability-statement-kind";
119      case CAPABILITY:
120        return "http://hl7.org/fhir/capability-statement-kind";
121      case REQUIREMENTS:
122        return "http://hl7.org/fhir/capability-statement-kind";
123      case NULL:
124        return null;
125      default:
126        return "?";
127      }
128    }
129
130    public String getDefinition() {
131      switch (this) {
132      case INSTANCE:
133        return "The CapabilityStatement instance represents the present capabilities of a specific system instance.  This is the kind returned by /metadata for a FHIR server end-point.";
134      case CAPABILITY:
135        return "The CapabilityStatement instance represents the capabilities of a system or piece of software, independent of a particular installation.";
136      case REQUIREMENTS:
137        return "The CapabilityStatement instance represents a set of requirements for other systems to meet; e.g. as part of an implementation guide or 'request for proposal'.";
138      case NULL:
139        return null;
140      default:
141        return "?";
142      }
143    }
144
145    public String getDisplay() {
146      switch (this) {
147      case INSTANCE:
148        return "Instance";
149      case CAPABILITY:
150        return "Capability";
151      case REQUIREMENTS:
152        return "Requirements";
153      case NULL:
154        return null;
155      default:
156        return "?";
157      }
158    }
159  }
160
161  public static class CapabilityStatementKindEnumFactory implements EnumFactory<CapabilityStatementKind> {
162    public CapabilityStatementKind fromCode(String codeString) throws IllegalArgumentException {
163      if (codeString == null || "".equals(codeString))
164        if (codeString == null || "".equals(codeString))
165          return null;
166      if ("instance".equals(codeString))
167        return CapabilityStatementKind.INSTANCE;
168      if ("capability".equals(codeString))
169        return CapabilityStatementKind.CAPABILITY;
170      if ("requirements".equals(codeString))
171        return CapabilityStatementKind.REQUIREMENTS;
172      throw new IllegalArgumentException("Unknown CapabilityStatementKind code '" + codeString + "'");
173    }
174
175    public Enumeration<CapabilityStatementKind> fromType(PrimitiveType<?> code) throws FHIRException {
176      if (code == null)
177        return null;
178      if (code.isEmpty())
179        return new Enumeration<CapabilityStatementKind>(this, CapabilityStatementKind.NULL, code);
180      String codeString = code.asStringValue();
181      if (codeString == null || "".equals(codeString))
182        return new Enumeration<CapabilityStatementKind>(this, CapabilityStatementKind.NULL, code);
183      if ("instance".equals(codeString))
184        return new Enumeration<CapabilityStatementKind>(this, CapabilityStatementKind.INSTANCE, code);
185      if ("capability".equals(codeString))
186        return new Enumeration<CapabilityStatementKind>(this, CapabilityStatementKind.CAPABILITY, code);
187      if ("requirements".equals(codeString))
188        return new Enumeration<CapabilityStatementKind>(this, CapabilityStatementKind.REQUIREMENTS, code);
189      throw new FHIRException("Unknown CapabilityStatementKind code '" + codeString + "'");
190    }
191
192    public String toCode(CapabilityStatementKind code) {
193      if (code == CapabilityStatementKind.INSTANCE)
194        return "instance";
195      if (code == CapabilityStatementKind.CAPABILITY)
196        return "capability";
197      if (code == CapabilityStatementKind.REQUIREMENTS)
198        return "requirements";
199      return "?";
200    }
201
202    public String toSystem(CapabilityStatementKind code) {
203      return code.getSystem();
204    }
205  }
206
207  public enum CodeSearchSupport {
208    /**
209     * The search for code on ValueSet only includes codes explicitly detailed on
210     * includes or expansions.
211     */
212    EXPLICIT,
213    /**
214     * The search for code on ValueSet only includes all codes based on the
215     * expansion of the value set.
216     */
217    ALL,
218    /**
219     * added to help the parsers with the generic types
220     */
221    NULL;
222
223    public static CodeSearchSupport fromCode(String codeString) throws FHIRException {
224      if (codeString == null || "".equals(codeString))
225        return null;
226      if ("explicit".equals(codeString))
227        return EXPLICIT;
228      if ("all".equals(codeString))
229        return ALL;
230      if (Configuration.isAcceptInvalidEnums())
231        return null;
232      else
233        throw new FHIRException("Unknown CodeSearchSupport code '" + codeString + "'");
234    }
235
236    public String toCode() {
237      switch (this) {
238      case EXPLICIT:
239        return "explicit";
240      case ALL:
241        return "all";
242      case NULL:
243        return null;
244      default:
245        return "?";
246      }
247    }
248
249    public String getSystem() {
250      switch (this) {
251      case EXPLICIT:
252        return "http://hl7.org/fhir/code-search-support";
253      case ALL:
254        return "http://hl7.org/fhir/code-search-support";
255      case NULL:
256        return null;
257      default:
258        return "?";
259      }
260    }
261
262    public String getDefinition() {
263      switch (this) {
264      case EXPLICIT:
265        return "The search for code on ValueSet only includes codes explicitly detailed on includes or expansions.";
266      case ALL:
267        return "The search for code on ValueSet only includes all codes based on the expansion of the value set.";
268      case NULL:
269        return null;
270      default:
271        return "?";
272      }
273    }
274
275    public String getDisplay() {
276      switch (this) {
277      case EXPLICIT:
278        return "Explicit Codes";
279      case ALL:
280        return "Implicit Codes";
281      case NULL:
282        return null;
283      default:
284        return "?";
285      }
286    }
287  }
288
289  public static class CodeSearchSupportEnumFactory implements EnumFactory<CodeSearchSupport> {
290    public CodeSearchSupport fromCode(String codeString) throws IllegalArgumentException {
291      if (codeString == null || "".equals(codeString))
292        if (codeString == null || "".equals(codeString))
293          return null;
294      if ("explicit".equals(codeString))
295        return CodeSearchSupport.EXPLICIT;
296      if ("all".equals(codeString))
297        return CodeSearchSupport.ALL;
298      throw new IllegalArgumentException("Unknown CodeSearchSupport code '" + codeString + "'");
299    }
300
301    public Enumeration<CodeSearchSupport> fromType(PrimitiveType<?> code) throws FHIRException {
302      if (code == null)
303        return null;
304      if (code.isEmpty())
305        return new Enumeration<CodeSearchSupport>(this, CodeSearchSupport.NULL, code);
306      String codeString = code.asStringValue();
307      if (codeString == null || "".equals(codeString))
308        return new Enumeration<CodeSearchSupport>(this, CodeSearchSupport.NULL, code);
309      if ("explicit".equals(codeString))
310        return new Enumeration<CodeSearchSupport>(this, CodeSearchSupport.EXPLICIT, code);
311      if ("all".equals(codeString))
312        return new Enumeration<CodeSearchSupport>(this, CodeSearchSupport.ALL, code);
313      throw new FHIRException("Unknown CodeSearchSupport code '" + codeString + "'");
314    }
315
316    public String toCode(CodeSearchSupport code) {
317      if (code == CodeSearchSupport.EXPLICIT)
318        return "explicit";
319      if (code == CodeSearchSupport.ALL)
320        return "all";
321      return "?";
322    }
323
324    public String toSystem(CodeSearchSupport code) {
325      return code.getSystem();
326    }
327  }
328
329  @Block()
330  public static class TerminologyCapabilitiesSoftwareComponent extends BackboneElement implements IBaseBackboneElement {
331    /**
332     * Name the software is known by.
333     */
334    @Child(name = "name", type = { StringType.class }, order = 1, min = 1, max = 1, modifier = false, summary = true)
335    @Description(shortDefinition = "A name the software is known by", formalDefinition = "Name the software is known by.")
336    protected StringType name;
337
338    /**
339     * The version identifier for the software covered by this statement.
340     */
341    @Child(name = "version", type = { StringType.class }, order = 2, min = 0, max = 1, modifier = false, summary = true)
342    @Description(shortDefinition = "Version covered by this statement", formalDefinition = "The version identifier for the software covered by this statement.")
343    protected StringType version;
344
345    private static final long serialVersionUID = -790299911L;
346
347    /**
348     * Constructor
349     */
350    public TerminologyCapabilitiesSoftwareComponent() {
351      super();
352    }
353
354    /**
355     * Constructor
356     */
357    public TerminologyCapabilitiesSoftwareComponent(StringType name) {
358      super();
359      this.name = name;
360    }
361
362    /**
363     * @return {@link #name} (Name the software is known by.). This is the
364     *         underlying object with id, value and extensions. The accessor
365     *         "getName" gives direct access to the value
366     */
367    public StringType getNameElement() {
368      if (this.name == null)
369        if (Configuration.errorOnAutoCreate())
370          throw new Error("Attempt to auto-create TerminologyCapabilitiesSoftwareComponent.name");
371        else if (Configuration.doAutoCreate())
372          this.name = new StringType(); // bb
373      return this.name;
374    }
375
376    public boolean hasNameElement() {
377      return this.name != null && !this.name.isEmpty();
378    }
379
380    public boolean hasName() {
381      return this.name != null && !this.name.isEmpty();
382    }
383
384    /**
385     * @param value {@link #name} (Name the software is known by.). This is the
386     *              underlying object with id, value and extensions. The accessor
387     *              "getName" gives direct access to the value
388     */
389    public TerminologyCapabilitiesSoftwareComponent setNameElement(StringType value) {
390      this.name = value;
391      return this;
392    }
393
394    /**
395     * @return Name the software is known by.
396     */
397    public String getName() {
398      return this.name == null ? null : this.name.getValue();
399    }
400
401    /**
402     * @param value Name the software is known by.
403     */
404    public TerminologyCapabilitiesSoftwareComponent setName(String value) {
405      if (this.name == null)
406        this.name = new StringType();
407      this.name.setValue(value);
408      return this;
409    }
410
411    /**
412     * @return {@link #version} (The version identifier for the software covered by
413     *         this statement.). This is the underlying object with id, value and
414     *         extensions. The accessor "getVersion" gives direct access to the
415     *         value
416     */
417    public StringType getVersionElement() {
418      if (this.version == null)
419        if (Configuration.errorOnAutoCreate())
420          throw new Error("Attempt to auto-create TerminologyCapabilitiesSoftwareComponent.version");
421        else if (Configuration.doAutoCreate())
422          this.version = new StringType(); // bb
423      return this.version;
424    }
425
426    public boolean hasVersionElement() {
427      return this.version != null && !this.version.isEmpty();
428    }
429
430    public boolean hasVersion() {
431      return this.version != null && !this.version.isEmpty();
432    }
433
434    /**
435     * @param value {@link #version} (The version identifier for the software
436     *              covered by this statement.). This is the underlying object with
437     *              id, value and extensions. The accessor "getVersion" gives direct
438     *              access to the value
439     */
440    public TerminologyCapabilitiesSoftwareComponent setVersionElement(StringType value) {
441      this.version = value;
442      return this;
443    }
444
445    /**
446     * @return The version identifier for the software covered by this statement.
447     */
448    public String getVersion() {
449      return this.version == null ? null : this.version.getValue();
450    }
451
452    /**
453     * @param value The version identifier for the software covered by this
454     *              statement.
455     */
456    public TerminologyCapabilitiesSoftwareComponent setVersion(String value) {
457      if (Utilities.noString(value))
458        this.version = null;
459      else {
460        if (this.version == null)
461          this.version = new StringType();
462        this.version.setValue(value);
463      }
464      return this;
465    }
466
467    protected void listChildren(List<Property> children) {
468      super.listChildren(children);
469      children.add(new Property("name", "string", "Name the software is known by.", 0, 1, name));
470      children.add(new Property("version", "string",
471          "The version identifier for the software covered by this statement.", 0, 1, version));
472    }
473
474    @Override
475    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
476      switch (_hash) {
477      case 3373707:
478        /* name */ return new Property("name", "string", "Name the software is known by.", 0, 1, name);
479      case 351608024:
480        /* version */ return new Property("version", "string",
481            "The version identifier for the software covered by this statement.", 0, 1, version);
482      default:
483        return super.getNamedProperty(_hash, _name, _checkValid);
484      }
485
486    }
487
488    @Override
489    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
490      switch (hash) {
491      case 3373707:
492        /* name */ return this.name == null ? new Base[0] : new Base[] { this.name }; // StringType
493      case 351608024:
494        /* version */ return this.version == null ? new Base[0] : new Base[] { this.version }; // StringType
495      default:
496        return super.getProperty(hash, name, checkValid);
497      }
498
499    }
500
501    @Override
502    public Base setProperty(int hash, String name, Base value) throws FHIRException {
503      switch (hash) {
504      case 3373707: // name
505        this.name = castToString(value); // StringType
506        return value;
507      case 351608024: // version
508        this.version = castToString(value); // StringType
509        return value;
510      default:
511        return super.setProperty(hash, name, value);
512      }
513
514    }
515
516    @Override
517    public Base setProperty(String name, Base value) throws FHIRException {
518      if (name.equals("name")) {
519        this.name = castToString(value); // StringType
520      } else if (name.equals("version")) {
521        this.version = castToString(value); // StringType
522      } else
523        return super.setProperty(name, value);
524      return value;
525    }
526
527  @Override
528  public void removeChild(String name, Base value) throws FHIRException {
529      if (name.equals("name")) {
530        this.name = null;
531      } else if (name.equals("version")) {
532        this.version = null;
533      } else
534        super.removeChild(name, value);
535      
536    }
537
538    @Override
539    public Base makeProperty(int hash, String name) throws FHIRException {
540      switch (hash) {
541      case 3373707:
542        return getNameElement();
543      case 351608024:
544        return getVersionElement();
545      default:
546        return super.makeProperty(hash, name);
547      }
548
549    }
550
551    @Override
552    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
553      switch (hash) {
554      case 3373707:
555        /* name */ return new String[] { "string" };
556      case 351608024:
557        /* version */ return new String[] { "string" };
558      default:
559        return super.getTypesForProperty(hash, name);
560      }
561
562    }
563
564    @Override
565    public Base addChild(String name) throws FHIRException {
566      if (name.equals("name")) {
567        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.name");
568      } else if (name.equals("version")) {
569        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.version");
570      } else
571        return super.addChild(name);
572    }
573
574    public TerminologyCapabilitiesSoftwareComponent copy() {
575      TerminologyCapabilitiesSoftwareComponent dst = new TerminologyCapabilitiesSoftwareComponent();
576      copyValues(dst);
577      return dst;
578    }
579
580    public void copyValues(TerminologyCapabilitiesSoftwareComponent dst) {
581      super.copyValues(dst);
582      dst.name = name == null ? null : name.copy();
583      dst.version = version == null ? null : version.copy();
584    }
585
586    @Override
587    public boolean equalsDeep(Base other_) {
588      if (!super.equalsDeep(other_))
589        return false;
590      if (!(other_ instanceof TerminologyCapabilitiesSoftwareComponent))
591        return false;
592      TerminologyCapabilitiesSoftwareComponent o = (TerminologyCapabilitiesSoftwareComponent) other_;
593      return compareDeep(name, o.name, true) && compareDeep(version, o.version, true);
594    }
595
596    @Override
597    public boolean equalsShallow(Base other_) {
598      if (!super.equalsShallow(other_))
599        return false;
600      if (!(other_ instanceof TerminologyCapabilitiesSoftwareComponent))
601        return false;
602      TerminologyCapabilitiesSoftwareComponent o = (TerminologyCapabilitiesSoftwareComponent) other_;
603      return compareValues(name, o.name, true) && compareValues(version, o.version, true);
604    }
605
606    public boolean isEmpty() {
607      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(name, version);
608    }
609
610    public String fhirType() {
611      return "TerminologyCapabilities.software";
612
613    }
614
615  }
616
617  @Block()
618  public static class TerminologyCapabilitiesImplementationComponent extends BackboneElement
619      implements IBaseBackboneElement {
620    /**
621     * Information about the specific installation that this terminology capability
622     * statement relates to.
623     */
624    @Child(name = "description", type = {
625        StringType.class }, order = 1, min = 1, max = 1, modifier = false, summary = true)
626    @Description(shortDefinition = "Describes this specific instance", formalDefinition = "Information about the specific installation that this terminology capability statement relates to.")
627    protected StringType description;
628
629    /**
630     * An absolute base URL for the implementation.
631     */
632    @Child(name = "url", type = { UrlType.class }, order = 2, min = 0, max = 1, modifier = false, summary = true)
633    @Description(shortDefinition = "Base URL for the implementation", formalDefinition = "An absolute base URL for the implementation.")
634    protected UrlType url;
635
636    private static final long serialVersionUID = 98009649L;
637
638    /**
639     * Constructor
640     */
641    public TerminologyCapabilitiesImplementationComponent() {
642      super();
643    }
644
645    /**
646     * Constructor
647     */
648    public TerminologyCapabilitiesImplementationComponent(StringType description) {
649      super();
650      this.description = description;
651    }
652
653    /**
654     * @return {@link #description} (Information about the specific installation
655     *         that this terminology capability statement relates to.). This is the
656     *         underlying object with id, value and extensions. The accessor
657     *         "getDescription" gives direct access to the value
658     */
659    public StringType getDescriptionElement() {
660      if (this.description == null)
661        if (Configuration.errorOnAutoCreate())
662          throw new Error("Attempt to auto-create TerminologyCapabilitiesImplementationComponent.description");
663        else if (Configuration.doAutoCreate())
664          this.description = new StringType(); // bb
665      return this.description;
666    }
667
668    public boolean hasDescriptionElement() {
669      return this.description != null && !this.description.isEmpty();
670    }
671
672    public boolean hasDescription() {
673      return this.description != null && !this.description.isEmpty();
674    }
675
676    /**
677     * @param value {@link #description} (Information about the specific
678     *              installation that this terminology capability statement relates
679     *              to.). This is the underlying object with id, value and
680     *              extensions. The accessor "getDescription" gives direct access to
681     *              the value
682     */
683    public TerminologyCapabilitiesImplementationComponent setDescriptionElement(StringType value) {
684      this.description = value;
685      return this;
686    }
687
688    /**
689     * @return Information about the specific installation that this terminology
690     *         capability statement relates to.
691     */
692    public String getDescription() {
693      return this.description == null ? null : this.description.getValue();
694    }
695
696    /**
697     * @param value Information about the specific installation that this
698     *              terminology capability statement relates to.
699     */
700    public TerminologyCapabilitiesImplementationComponent setDescription(String value) {
701      if (this.description == null)
702        this.description = new StringType();
703      this.description.setValue(value);
704      return this;
705    }
706
707    /**
708     * @return {@link #url} (An absolute base URL for the implementation.). This is
709     *         the underlying object with id, value and extensions. The accessor
710     *         "getUrl" gives direct access to the value
711     */
712    public UrlType getUrlElement() {
713      if (this.url == null)
714        if (Configuration.errorOnAutoCreate())
715          throw new Error("Attempt to auto-create TerminologyCapabilitiesImplementationComponent.url");
716        else if (Configuration.doAutoCreate())
717          this.url = new UrlType(); // bb
718      return this.url;
719    }
720
721    public boolean hasUrlElement() {
722      return this.url != null && !this.url.isEmpty();
723    }
724
725    public boolean hasUrl() {
726      return this.url != null && !this.url.isEmpty();
727    }
728
729    /**
730     * @param value {@link #url} (An absolute base URL for the implementation.).
731     *              This is the underlying object with id, value and extensions. The
732     *              accessor "getUrl" gives direct access to the value
733     */
734    public TerminologyCapabilitiesImplementationComponent setUrlElement(UrlType value) {
735      this.url = value;
736      return this;
737    }
738
739    /**
740     * @return An absolute base URL for the implementation.
741     */
742    public String getUrl() {
743      return this.url == null ? null : this.url.getValue();
744    }
745
746    /**
747     * @param value An absolute base URL for the implementation.
748     */
749    public TerminologyCapabilitiesImplementationComponent setUrl(String value) {
750      if (Utilities.noString(value))
751        this.url = null;
752      else {
753        if (this.url == null)
754          this.url = new UrlType();
755        this.url.setValue(value);
756      }
757      return this;
758    }
759
760    protected void listChildren(List<Property> children) {
761      super.listChildren(children);
762      children.add(new Property("description", "string",
763          "Information about the specific installation that this terminology capability statement relates to.", 0, 1,
764          description));
765      children.add(new Property("url", "url", "An absolute base URL for the implementation.", 0, 1, url));
766    }
767
768    @Override
769    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
770      switch (_hash) {
771      case -1724546052:
772        /* description */ return new Property("description", "string",
773            "Information about the specific installation that this terminology capability statement relates to.", 0, 1,
774            description);
775      case 116079:
776        /* url */ return new Property("url", "url", "An absolute base URL for the implementation.", 0, 1, url);
777      default:
778        return super.getNamedProperty(_hash, _name, _checkValid);
779      }
780
781    }
782
783    @Override
784    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
785      switch (hash) {
786      case -1724546052:
787        /* description */ return this.description == null ? new Base[0] : new Base[] { this.description }; // StringType
788      case 116079:
789        /* url */ return this.url == null ? new Base[0] : new Base[] { this.url }; // UrlType
790      default:
791        return super.getProperty(hash, name, checkValid);
792      }
793
794    }
795
796    @Override
797    public Base setProperty(int hash, String name, Base value) throws FHIRException {
798      switch (hash) {
799      case -1724546052: // description
800        this.description = castToString(value); // StringType
801        return value;
802      case 116079: // url
803        this.url = castToUrl(value); // UrlType
804        return value;
805      default:
806        return super.setProperty(hash, name, value);
807      }
808
809    }
810
811    @Override
812    public Base setProperty(String name, Base value) throws FHIRException {
813      if (name.equals("description")) {
814        this.description = castToString(value); // StringType
815      } else if (name.equals("url")) {
816        this.url = castToUrl(value); // UrlType
817      } else
818        return super.setProperty(name, value);
819      return value;
820    }
821
822  @Override
823  public void removeChild(String name, Base value) throws FHIRException {
824      if (name.equals("description")) {
825        this.description = null;
826      } else if (name.equals("url")) {
827        this.url = null;
828      } else
829        super.removeChild(name, value);
830      
831    }
832
833    @Override
834    public Base makeProperty(int hash, String name) throws FHIRException {
835      switch (hash) {
836      case -1724546052:
837        return getDescriptionElement();
838      case 116079:
839        return getUrlElement();
840      default:
841        return super.makeProperty(hash, name);
842      }
843
844    }
845
846    @Override
847    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
848      switch (hash) {
849      case -1724546052:
850        /* description */ return new String[] { "string" };
851      case 116079:
852        /* url */ return new String[] { "url" };
853      default:
854        return super.getTypesForProperty(hash, name);
855      }
856
857    }
858
859    @Override
860    public Base addChild(String name) throws FHIRException {
861      if (name.equals("description")) {
862        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.description");
863      } else if (name.equals("url")) {
864        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.url");
865      } else
866        return super.addChild(name);
867    }
868
869    public TerminologyCapabilitiesImplementationComponent copy() {
870      TerminologyCapabilitiesImplementationComponent dst = new TerminologyCapabilitiesImplementationComponent();
871      copyValues(dst);
872      return dst;
873    }
874
875    public void copyValues(TerminologyCapabilitiesImplementationComponent dst) {
876      super.copyValues(dst);
877      dst.description = description == null ? null : description.copy();
878      dst.url = url == null ? null : url.copy();
879    }
880
881    @Override
882    public boolean equalsDeep(Base other_) {
883      if (!super.equalsDeep(other_))
884        return false;
885      if (!(other_ instanceof TerminologyCapabilitiesImplementationComponent))
886        return false;
887      TerminologyCapabilitiesImplementationComponent o = (TerminologyCapabilitiesImplementationComponent) other_;
888      return compareDeep(description, o.description, true) && compareDeep(url, o.url, true);
889    }
890
891    @Override
892    public boolean equalsShallow(Base other_) {
893      if (!super.equalsShallow(other_))
894        return false;
895      if (!(other_ instanceof TerminologyCapabilitiesImplementationComponent))
896        return false;
897      TerminologyCapabilitiesImplementationComponent o = (TerminologyCapabilitiesImplementationComponent) other_;
898      return compareValues(description, o.description, true) && compareValues(url, o.url, true);
899    }
900
901    public boolean isEmpty() {
902      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(description, url);
903    }
904
905    public String fhirType() {
906      return "TerminologyCapabilities.implementation";
907
908    }
909
910  }
911
912  @Block()
913  public static class TerminologyCapabilitiesCodeSystemComponent extends BackboneElement
914      implements IBaseBackboneElement {
915    /**
916     * URI for the Code System.
917     */
918    @Child(name = "uri", type = { CanonicalType.class }, order = 1, min = 0, max = 1, modifier = false, summary = false)
919    @Description(shortDefinition = "URI for the Code System", formalDefinition = "URI for the Code System.")
920    protected CanonicalType uri;
921
922    /**
923     * For the code system, a list of versions that are supported by the server.
924     */
925    @Child(name = "version", type = {}, order = 2, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
926    @Description(shortDefinition = "Version of Code System supported", formalDefinition = "For the code system, a list of versions that are supported by the server.")
927    protected List<TerminologyCapabilitiesCodeSystemVersionComponent> version;
928
929    /**
930     * True if subsumption is supported for this version of the code system.
931     */
932    @Child(name = "subsumption", type = {
933        BooleanType.class }, order = 3, min = 0, max = 1, modifier = false, summary = false)
934    @Description(shortDefinition = "Whether subsumption is supported", formalDefinition = "True if subsumption is supported for this version of the code system.")
935    protected BooleanType subsumption;
936
937    private static final long serialVersionUID = -1593622817L;
938
939    /**
940     * Constructor
941     */
942    public TerminologyCapabilitiesCodeSystemComponent() {
943      super();
944    }
945
946    /**
947     * @return {@link #uri} (URI for the Code System.). This is the underlying
948     *         object with id, value and extensions. The accessor "getUri" gives
949     *         direct access to the value
950     */
951    public CanonicalType getUriElement() {
952      if (this.uri == null)
953        if (Configuration.errorOnAutoCreate())
954          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemComponent.uri");
955        else if (Configuration.doAutoCreate())
956          this.uri = new CanonicalType(); // bb
957      return this.uri;
958    }
959
960    public boolean hasUriElement() {
961      return this.uri != null && !this.uri.isEmpty();
962    }
963
964    public boolean hasUri() {
965      return this.uri != null && !this.uri.isEmpty();
966    }
967
968    /**
969     * @param value {@link #uri} (URI for the Code System.). This is the underlying
970     *              object with id, value and extensions. The accessor "getUri"
971     *              gives direct access to the value
972     */
973    public TerminologyCapabilitiesCodeSystemComponent setUriElement(CanonicalType value) {
974      this.uri = value;
975      return this;
976    }
977
978    /**
979     * @return URI for the Code System.
980     */
981    public String getUri() {
982      return this.uri == null ? null : this.uri.getValue();
983    }
984
985    /**
986     * @param value URI for the Code System.
987     */
988    public TerminologyCapabilitiesCodeSystemComponent setUri(String value) {
989      if (Utilities.noString(value))
990        this.uri = null;
991      else {
992        if (this.uri == null)
993          this.uri = new CanonicalType();
994        this.uri.setValue(value);
995      }
996      return this;
997    }
998
999    /**
1000     * @return {@link #version} (For the code system, a list of versions that are
1001     *         supported by the server.)
1002     */
1003    public List<TerminologyCapabilitiesCodeSystemVersionComponent> getVersion() {
1004      if (this.version == null)
1005        this.version = new ArrayList<TerminologyCapabilitiesCodeSystemVersionComponent>();
1006      return this.version;
1007    }
1008
1009    /**
1010     * @return Returns a reference to <code>this</code> for easy method chaining
1011     */
1012    public TerminologyCapabilitiesCodeSystemComponent setVersion(
1013        List<TerminologyCapabilitiesCodeSystemVersionComponent> theVersion) {
1014      this.version = theVersion;
1015      return this;
1016    }
1017
1018    public boolean hasVersion() {
1019      if (this.version == null)
1020        return false;
1021      for (TerminologyCapabilitiesCodeSystemVersionComponent item : this.version)
1022        if (!item.isEmpty())
1023          return true;
1024      return false;
1025    }
1026
1027    public TerminologyCapabilitiesCodeSystemVersionComponent addVersion() { // 3
1028      TerminologyCapabilitiesCodeSystemVersionComponent t = new TerminologyCapabilitiesCodeSystemVersionComponent();
1029      if (this.version == null)
1030        this.version = new ArrayList<TerminologyCapabilitiesCodeSystemVersionComponent>();
1031      this.version.add(t);
1032      return t;
1033    }
1034
1035    public TerminologyCapabilitiesCodeSystemComponent addVersion(TerminologyCapabilitiesCodeSystemVersionComponent t) { // 3
1036      if (t == null)
1037        return this;
1038      if (this.version == null)
1039        this.version = new ArrayList<TerminologyCapabilitiesCodeSystemVersionComponent>();
1040      this.version.add(t);
1041      return this;
1042    }
1043
1044    /**
1045     * @return The first repetition of repeating field {@link #version}, creating it
1046     *         if it does not already exist
1047     */
1048    public TerminologyCapabilitiesCodeSystemVersionComponent getVersionFirstRep() {
1049      if (getVersion().isEmpty()) {
1050        addVersion();
1051      }
1052      return getVersion().get(0);
1053    }
1054
1055    /**
1056     * @return {@link #subsumption} (True if subsumption is supported for this
1057     *         version of the code system.). This is the underlying object with id,
1058     *         value and extensions. The accessor "getSubsumption" gives direct
1059     *         access to the value
1060     */
1061    public BooleanType getSubsumptionElement() {
1062      if (this.subsumption == null)
1063        if (Configuration.errorOnAutoCreate())
1064          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemComponent.subsumption");
1065        else if (Configuration.doAutoCreate())
1066          this.subsumption = new BooleanType(); // bb
1067      return this.subsumption;
1068    }
1069
1070    public boolean hasSubsumptionElement() {
1071      return this.subsumption != null && !this.subsumption.isEmpty();
1072    }
1073
1074    public boolean hasSubsumption() {
1075      return this.subsumption != null && !this.subsumption.isEmpty();
1076    }
1077
1078    /**
1079     * @param value {@link #subsumption} (True if subsumption is supported for this
1080     *              version of the code system.). This is the underlying object with
1081     *              id, value and extensions. The accessor "getSubsumption" gives
1082     *              direct access to the value
1083     */
1084    public TerminologyCapabilitiesCodeSystemComponent setSubsumptionElement(BooleanType value) {
1085      this.subsumption = value;
1086      return this;
1087    }
1088
1089    /**
1090     * @return True if subsumption is supported for this version of the code system.
1091     */
1092    public boolean getSubsumption() {
1093      return this.subsumption == null || this.subsumption.isEmpty() ? false : this.subsumption.getValue();
1094    }
1095
1096    /**
1097     * @param value True if subsumption is supported for this version of the code
1098     *              system.
1099     */
1100    public TerminologyCapabilitiesCodeSystemComponent setSubsumption(boolean value) {
1101      if (this.subsumption == null)
1102        this.subsumption = new BooleanType();
1103      this.subsumption.setValue(value);
1104      return this;
1105    }
1106
1107    protected void listChildren(List<Property> children) {
1108      super.listChildren(children);
1109      children.add(new Property("uri", "canonical(CodeSystem)", "URI for the Code System.", 0, 1, uri));
1110      children
1111          .add(new Property("version", "", "For the code system, a list of versions that are supported by the server.",
1112              0, java.lang.Integer.MAX_VALUE, version));
1113      children.add(new Property("subsumption", "boolean",
1114          "True if subsumption is supported for this version of the code system.", 0, 1, subsumption));
1115    }
1116
1117    @Override
1118    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1119      switch (_hash) {
1120      case 116076:
1121        /* uri */ return new Property("uri", "canonical(CodeSystem)", "URI for the Code System.", 0, 1, uri);
1122      case 351608024:
1123        /* version */ return new Property("version", "",
1124            "For the code system, a list of versions that are supported by the server.", 0, java.lang.Integer.MAX_VALUE,
1125            version);
1126      case -499084711:
1127        /* subsumption */ return new Property("subsumption", "boolean",
1128            "True if subsumption is supported for this version of the code system.", 0, 1, subsumption);
1129      default:
1130        return super.getNamedProperty(_hash, _name, _checkValid);
1131      }
1132
1133    }
1134
1135    @Override
1136    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1137      switch (hash) {
1138      case 116076:
1139        /* uri */ return this.uri == null ? new Base[0] : new Base[] { this.uri }; // CanonicalType
1140      case 351608024:
1141        /* version */ return this.version == null ? new Base[0] : this.version.toArray(new Base[this.version.size()]); // TerminologyCapabilitiesCodeSystemVersionComponent
1142      case -499084711:
1143        /* subsumption */ return this.subsumption == null ? new Base[0] : new Base[] { this.subsumption }; // BooleanType
1144      default:
1145        return super.getProperty(hash, name, checkValid);
1146      }
1147
1148    }
1149
1150    @Override
1151    public Base setProperty(int hash, String name, Base value) throws FHIRException {
1152      switch (hash) {
1153      case 116076: // uri
1154        this.uri = castToCanonical(value); // CanonicalType
1155        return value;
1156      case 351608024: // version
1157        this.getVersion().add((TerminologyCapabilitiesCodeSystemVersionComponent) value); // TerminologyCapabilitiesCodeSystemVersionComponent
1158        return value;
1159      case -499084711: // subsumption
1160        this.subsumption = castToBoolean(value); // BooleanType
1161        return value;
1162      default:
1163        return super.setProperty(hash, name, value);
1164      }
1165
1166    }
1167
1168    @Override
1169    public Base setProperty(String name, Base value) throws FHIRException {
1170      if (name.equals("uri")) {
1171        this.uri = castToCanonical(value); // CanonicalType
1172      } else if (name.equals("version")) {
1173        this.getVersion().add((TerminologyCapabilitiesCodeSystemVersionComponent) value);
1174      } else if (name.equals("subsumption")) {
1175        this.subsumption = castToBoolean(value); // BooleanType
1176      } else
1177        return super.setProperty(name, value);
1178      return value;
1179    }
1180
1181  @Override
1182  public void removeChild(String name, Base value) throws FHIRException {
1183      if (name.equals("uri")) {
1184        this.uri = null;
1185      } else if (name.equals("version")) {
1186        this.getVersion().remove((TerminologyCapabilitiesCodeSystemVersionComponent) value);
1187      } else if (name.equals("subsumption")) {
1188        this.subsumption = null;
1189      } else
1190        super.removeChild(name, value);
1191      
1192    }
1193
1194    @Override
1195    public Base makeProperty(int hash, String name) throws FHIRException {
1196      switch (hash) {
1197      case 116076:
1198        return getUriElement();
1199      case 351608024:
1200        return addVersion();
1201      case -499084711:
1202        return getSubsumptionElement();
1203      default:
1204        return super.makeProperty(hash, name);
1205      }
1206
1207    }
1208
1209    @Override
1210    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1211      switch (hash) {
1212      case 116076:
1213        /* uri */ return new String[] { "canonical" };
1214      case 351608024:
1215        /* version */ return new String[] {};
1216      case -499084711:
1217        /* subsumption */ return new String[] { "boolean" };
1218      default:
1219        return super.getTypesForProperty(hash, name);
1220      }
1221
1222    }
1223
1224    @Override
1225    public Base addChild(String name) throws FHIRException {
1226      if (name.equals("uri")) {
1227        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.uri");
1228      } else if (name.equals("version")) {
1229        return addVersion();
1230      } else if (name.equals("subsumption")) {
1231        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.subsumption");
1232      } else
1233        return super.addChild(name);
1234    }
1235
1236    public TerminologyCapabilitiesCodeSystemComponent copy() {
1237      TerminologyCapabilitiesCodeSystemComponent dst = new TerminologyCapabilitiesCodeSystemComponent();
1238      copyValues(dst);
1239      return dst;
1240    }
1241
1242    public void copyValues(TerminologyCapabilitiesCodeSystemComponent dst) {
1243      super.copyValues(dst);
1244      dst.uri = uri == null ? null : uri.copy();
1245      if (version != null) {
1246        dst.version = new ArrayList<TerminologyCapabilitiesCodeSystemVersionComponent>();
1247        for (TerminologyCapabilitiesCodeSystemVersionComponent i : version)
1248          dst.version.add(i.copy());
1249      }
1250      ;
1251      dst.subsumption = subsumption == null ? null : subsumption.copy();
1252    }
1253
1254    @Override
1255    public boolean equalsDeep(Base other_) {
1256      if (!super.equalsDeep(other_))
1257        return false;
1258      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemComponent))
1259        return false;
1260      TerminologyCapabilitiesCodeSystemComponent o = (TerminologyCapabilitiesCodeSystemComponent) other_;
1261      return compareDeep(uri, o.uri, true) && compareDeep(version, o.version, true)
1262          && compareDeep(subsumption, o.subsumption, true);
1263    }
1264
1265    @Override
1266    public boolean equalsShallow(Base other_) {
1267      if (!super.equalsShallow(other_))
1268        return false;
1269      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemComponent))
1270        return false;
1271      TerminologyCapabilitiesCodeSystemComponent o = (TerminologyCapabilitiesCodeSystemComponent) other_;
1272      return compareValues(subsumption, o.subsumption, true);
1273    }
1274
1275    public boolean isEmpty() {
1276      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(uri, version, subsumption);
1277    }
1278
1279    public String fhirType() {
1280      return "TerminologyCapabilities.codeSystem";
1281
1282    }
1283
1284  }
1285
1286  @Block()
1287  public static class TerminologyCapabilitiesCodeSystemVersionComponent extends BackboneElement
1288      implements IBaseBackboneElement {
1289    /**
1290     * For version-less code systems, there should be a single version with no
1291     * identifier.
1292     */
1293    @Child(name = "code", type = { StringType.class }, order = 1, min = 0, max = 1, modifier = false, summary = true)
1294    @Description(shortDefinition = "Version identifier for this version", formalDefinition = "For version-less code systems, there should be a single version with no identifier.")
1295    protected StringType code;
1296
1297    /**
1298     * If this is the default version for this code system.
1299     */
1300    @Child(name = "isDefault", type = {
1301        BooleanType.class }, order = 2, min = 0, max = 1, modifier = false, summary = true)
1302    @Description(shortDefinition = "If this is the default version for this code system", formalDefinition = "If this is the default version for this code system.")
1303    protected BooleanType isDefault;
1304
1305    /**
1306     * If the compositional grammar defined by the code system is supported.
1307     */
1308    @Child(name = "compositional", type = {
1309        BooleanType.class }, order = 3, min = 0, max = 1, modifier = false, summary = false)
1310    @Description(shortDefinition = "If compositional grammar is supported", formalDefinition = "If the compositional grammar defined by the code system is supported.")
1311    protected BooleanType compositional;
1312
1313    /**
1314     * Language Displays supported.
1315     */
1316    @Child(name = "language", type = {
1317        CodeType.class }, order = 4, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
1318    @Description(shortDefinition = "Language Displays supported", formalDefinition = "Language Displays supported.")
1319    protected List<CodeType> language;
1320
1321    /**
1322     * Filter Properties supported.
1323     */
1324    @Child(name = "filter", type = {}, order = 5, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
1325    @Description(shortDefinition = "Filter Properties supported", formalDefinition = "Filter Properties supported.")
1326    protected List<TerminologyCapabilitiesCodeSystemVersionFilterComponent> filter;
1327
1328    /**
1329     * Properties supported for $lookup.
1330     */
1331    @Child(name = "property", type = {
1332        CodeType.class }, order = 6, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
1333    @Description(shortDefinition = "Properties supported for $lookup", formalDefinition = "Properties supported for $lookup.")
1334    protected List<CodeType> property;
1335
1336    private static final long serialVersionUID = 1857571343L;
1337
1338    /**
1339     * Constructor
1340     */
1341    public TerminologyCapabilitiesCodeSystemVersionComponent() {
1342      super();
1343    }
1344
1345    /**
1346     * @return {@link #code} (For version-less code systems, there should be a
1347     *         single version with no identifier.). This is the underlying object
1348     *         with id, value and extensions. The accessor "getCode" gives direct
1349     *         access to the value
1350     */
1351    public StringType getCodeElement() {
1352      if (this.code == null)
1353        if (Configuration.errorOnAutoCreate())
1354          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemVersionComponent.code");
1355        else if (Configuration.doAutoCreate())
1356          this.code = new StringType(); // bb
1357      return this.code;
1358    }
1359
1360    public boolean hasCodeElement() {
1361      return this.code != null && !this.code.isEmpty();
1362    }
1363
1364    public boolean hasCode() {
1365      return this.code != null && !this.code.isEmpty();
1366    }
1367
1368    /**
1369     * @param value {@link #code} (For version-less code systems, there should be a
1370     *              single version with no identifier.). This is the underlying
1371     *              object with id, value and extensions. The accessor "getCode"
1372     *              gives direct access to the value
1373     */
1374    public TerminologyCapabilitiesCodeSystemVersionComponent setCodeElement(StringType value) {
1375      this.code = value;
1376      return this;
1377    }
1378
1379    /**
1380     * @return For version-less code systems, there should be a single version with
1381     *         no identifier.
1382     */
1383    public String getCode() {
1384      return this.code == null ? null : this.code.getValue();
1385    }
1386
1387    /**
1388     * @param value For version-less code systems, there should be a single version
1389     *              with no identifier.
1390     */
1391    public TerminologyCapabilitiesCodeSystemVersionComponent setCode(String value) {
1392      if (Utilities.noString(value))
1393        this.code = null;
1394      else {
1395        if (this.code == null)
1396          this.code = new StringType();
1397        this.code.setValue(value);
1398      }
1399      return this;
1400    }
1401
1402    /**
1403     * @return {@link #isDefault} (If this is the default version for this code
1404     *         system.). This is the underlying object with id, value and
1405     *         extensions. The accessor "getIsDefault" gives direct access to the
1406     *         value
1407     */
1408    public BooleanType getIsDefaultElement() {
1409      if (this.isDefault == null)
1410        if (Configuration.errorOnAutoCreate())
1411          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemVersionComponent.isDefault");
1412        else if (Configuration.doAutoCreate())
1413          this.isDefault = new BooleanType(); // bb
1414      return this.isDefault;
1415    }
1416
1417    public boolean hasIsDefaultElement() {
1418      return this.isDefault != null && !this.isDefault.isEmpty();
1419    }
1420
1421    public boolean hasIsDefault() {
1422      return this.isDefault != null && !this.isDefault.isEmpty();
1423    }
1424
1425    /**
1426     * @param value {@link #isDefault} (If this is the default version for this code
1427     *              system.). This is the underlying object with id, value and
1428     *              extensions. The accessor "getIsDefault" gives direct access to
1429     *              the value
1430     */
1431    public TerminologyCapabilitiesCodeSystemVersionComponent setIsDefaultElement(BooleanType value) {
1432      this.isDefault = value;
1433      return this;
1434    }
1435
1436    /**
1437     * @return If this is the default version for this code system.
1438     */
1439    public boolean getIsDefault() {
1440      return this.isDefault == null || this.isDefault.isEmpty() ? false : this.isDefault.getValue();
1441    }
1442
1443    /**
1444     * @param value If this is the default version for this code system.
1445     */
1446    public TerminologyCapabilitiesCodeSystemVersionComponent setIsDefault(boolean value) {
1447      if (this.isDefault == null)
1448        this.isDefault = new BooleanType();
1449      this.isDefault.setValue(value);
1450      return this;
1451    }
1452
1453    /**
1454     * @return {@link #compositional} (If the compositional grammar defined by the
1455     *         code system is supported.). This is the underlying object with id,
1456     *         value and extensions. The accessor "getCompositional" gives direct
1457     *         access to the value
1458     */
1459    public BooleanType getCompositionalElement() {
1460      if (this.compositional == null)
1461        if (Configuration.errorOnAutoCreate())
1462          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemVersionComponent.compositional");
1463        else if (Configuration.doAutoCreate())
1464          this.compositional = new BooleanType(); // bb
1465      return this.compositional;
1466    }
1467
1468    public boolean hasCompositionalElement() {
1469      return this.compositional != null && !this.compositional.isEmpty();
1470    }
1471
1472    public boolean hasCompositional() {
1473      return this.compositional != null && !this.compositional.isEmpty();
1474    }
1475
1476    /**
1477     * @param value {@link #compositional} (If the compositional grammar defined by
1478     *              the code system is supported.). This is the underlying object
1479     *              with id, value and extensions. The accessor "getCompositional"
1480     *              gives direct access to the value
1481     */
1482    public TerminologyCapabilitiesCodeSystemVersionComponent setCompositionalElement(BooleanType value) {
1483      this.compositional = value;
1484      return this;
1485    }
1486
1487    /**
1488     * @return If the compositional grammar defined by the code system is supported.
1489     */
1490    public boolean getCompositional() {
1491      return this.compositional == null || this.compositional.isEmpty() ? false : this.compositional.getValue();
1492    }
1493
1494    /**
1495     * @param value If the compositional grammar defined by the code system is
1496     *              supported.
1497     */
1498    public TerminologyCapabilitiesCodeSystemVersionComponent setCompositional(boolean value) {
1499      if (this.compositional == null)
1500        this.compositional = new BooleanType();
1501      this.compositional.setValue(value);
1502      return this;
1503    }
1504
1505    /**
1506     * @return {@link #language} (Language Displays supported.)
1507     */
1508    public List<CodeType> getLanguage() {
1509      if (this.language == null)
1510        this.language = new ArrayList<CodeType>();
1511      return this.language;
1512    }
1513
1514    /**
1515     * @return Returns a reference to <code>this</code> for easy method chaining
1516     */
1517    public TerminologyCapabilitiesCodeSystemVersionComponent setLanguage(List<CodeType> theLanguage) {
1518      this.language = theLanguage;
1519      return this;
1520    }
1521
1522    public boolean hasLanguage() {
1523      if (this.language == null)
1524        return false;
1525      for (CodeType item : this.language)
1526        if (!item.isEmpty())
1527          return true;
1528      return false;
1529    }
1530
1531    /**
1532     * @return {@link #language} (Language Displays supported.)
1533     */
1534    public CodeType addLanguageElement() {// 2
1535      CodeType t = new CodeType();
1536      if (this.language == null)
1537        this.language = new ArrayList<CodeType>();
1538      this.language.add(t);
1539      return t;
1540    }
1541
1542    /**
1543     * @param value {@link #language} (Language Displays supported.)
1544     */
1545    public TerminologyCapabilitiesCodeSystemVersionComponent addLanguage(String value) { // 1
1546      CodeType t = new CodeType();
1547      t.setValue(value);
1548      if (this.language == null)
1549        this.language = new ArrayList<CodeType>();
1550      this.language.add(t);
1551      return this;
1552    }
1553
1554    /**
1555     * @param value {@link #language} (Language Displays supported.)
1556     */
1557    public boolean hasLanguage(String value) {
1558      if (this.language == null)
1559        return false;
1560      for (CodeType v : this.language)
1561        if (v.getValue().equals(value)) // code
1562          return true;
1563      return false;
1564    }
1565
1566    /**
1567     * @return {@link #filter} (Filter Properties supported.)
1568     */
1569    public List<TerminologyCapabilitiesCodeSystemVersionFilterComponent> getFilter() {
1570      if (this.filter == null)
1571        this.filter = new ArrayList<TerminologyCapabilitiesCodeSystemVersionFilterComponent>();
1572      return this.filter;
1573    }
1574
1575    /**
1576     * @return Returns a reference to <code>this</code> for easy method chaining
1577     */
1578    public TerminologyCapabilitiesCodeSystemVersionComponent setFilter(
1579        List<TerminologyCapabilitiesCodeSystemVersionFilterComponent> theFilter) {
1580      this.filter = theFilter;
1581      return this;
1582    }
1583
1584    public boolean hasFilter() {
1585      if (this.filter == null)
1586        return false;
1587      for (TerminologyCapabilitiesCodeSystemVersionFilterComponent item : this.filter)
1588        if (!item.isEmpty())
1589          return true;
1590      return false;
1591    }
1592
1593    public TerminologyCapabilitiesCodeSystemVersionFilterComponent addFilter() { // 3
1594      TerminologyCapabilitiesCodeSystemVersionFilterComponent t = new TerminologyCapabilitiesCodeSystemVersionFilterComponent();
1595      if (this.filter == null)
1596        this.filter = new ArrayList<TerminologyCapabilitiesCodeSystemVersionFilterComponent>();
1597      this.filter.add(t);
1598      return t;
1599    }
1600
1601    public TerminologyCapabilitiesCodeSystemVersionComponent addFilter(
1602        TerminologyCapabilitiesCodeSystemVersionFilterComponent t) { // 3
1603      if (t == null)
1604        return this;
1605      if (this.filter == null)
1606        this.filter = new ArrayList<TerminologyCapabilitiesCodeSystemVersionFilterComponent>();
1607      this.filter.add(t);
1608      return this;
1609    }
1610
1611    /**
1612     * @return The first repetition of repeating field {@link #filter}, creating it
1613     *         if it does not already exist
1614     */
1615    public TerminologyCapabilitiesCodeSystemVersionFilterComponent getFilterFirstRep() {
1616      if (getFilter().isEmpty()) {
1617        addFilter();
1618      }
1619      return getFilter().get(0);
1620    }
1621
1622    /**
1623     * @return {@link #property} (Properties supported for $lookup.)
1624     */
1625    public List<CodeType> getProperty() {
1626      if (this.property == null)
1627        this.property = new ArrayList<CodeType>();
1628      return this.property;
1629    }
1630
1631    /**
1632     * @return Returns a reference to <code>this</code> for easy method chaining
1633     */
1634    public TerminologyCapabilitiesCodeSystemVersionComponent setProperty(List<CodeType> theProperty) {
1635      this.property = theProperty;
1636      return this;
1637    }
1638
1639    public boolean hasProperty() {
1640      if (this.property == null)
1641        return false;
1642      for (CodeType item : this.property)
1643        if (!item.isEmpty())
1644          return true;
1645      return false;
1646    }
1647
1648    /**
1649     * @return {@link #property} (Properties supported for $lookup.)
1650     */
1651    public CodeType addPropertyElement() {// 2
1652      CodeType t = new CodeType();
1653      if (this.property == null)
1654        this.property = new ArrayList<CodeType>();
1655      this.property.add(t);
1656      return t;
1657    }
1658
1659    /**
1660     * @param value {@link #property} (Properties supported for $lookup.)
1661     */
1662    public TerminologyCapabilitiesCodeSystemVersionComponent addProperty(String value) { // 1
1663      CodeType t = new CodeType();
1664      t.setValue(value);
1665      if (this.property == null)
1666        this.property = new ArrayList<CodeType>();
1667      this.property.add(t);
1668      return this;
1669    }
1670
1671    /**
1672     * @param value {@link #property} (Properties supported for $lookup.)
1673     */
1674    public boolean hasProperty(String value) {
1675      if (this.property == null)
1676        return false;
1677      for (CodeType v : this.property)
1678        if (v.getValue().equals(value)) // code
1679          return true;
1680      return false;
1681    }
1682
1683    protected void listChildren(List<Property> children) {
1684      super.listChildren(children);
1685      children.add(new Property("code", "string",
1686          "For version-less code systems, there should be a single version with no identifier.", 0, 1, code));
1687      children.add(new Property("isDefault", "boolean", "If this is the default version for this code system.", 0, 1,
1688          isDefault));
1689      children.add(new Property("compositional", "boolean",
1690          "If the compositional grammar defined by the code system is supported.", 0, 1, compositional));
1691      children.add(
1692          new Property("language", "code", "Language Displays supported.", 0, java.lang.Integer.MAX_VALUE, language));
1693      children.add(new Property("filter", "", "Filter Properties supported.", 0, java.lang.Integer.MAX_VALUE, filter));
1694      children.add(new Property("property", "code", "Properties supported for $lookup.", 0, java.lang.Integer.MAX_VALUE,
1695          property));
1696    }
1697
1698    @Override
1699    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
1700      switch (_hash) {
1701      case 3059181:
1702        /* code */ return new Property("code", "string",
1703            "For version-less code systems, there should be a single version with no identifier.", 0, 1, code);
1704      case 965025207:
1705        /* isDefault */ return new Property("isDefault", "boolean",
1706            "If this is the default version for this code system.", 0, 1, isDefault);
1707      case 1248023381:
1708        /* compositional */ return new Property("compositional", "boolean",
1709            "If the compositional grammar defined by the code system is supported.", 0, 1, compositional);
1710      case -1613589672:
1711        /* language */ return new Property("language", "code", "Language Displays supported.", 0,
1712            java.lang.Integer.MAX_VALUE, language);
1713      case -1274492040:
1714        /* filter */ return new Property("filter", "", "Filter Properties supported.", 0, java.lang.Integer.MAX_VALUE,
1715            filter);
1716      case -993141291:
1717        /* property */ return new Property("property", "code", "Properties supported for $lookup.", 0,
1718            java.lang.Integer.MAX_VALUE, property);
1719      default:
1720        return super.getNamedProperty(_hash, _name, _checkValid);
1721      }
1722
1723    }
1724
1725    @Override
1726    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
1727      switch (hash) {
1728      case 3059181:
1729        /* code */ return this.code == null ? new Base[0] : new Base[] { this.code }; // StringType
1730      case 965025207:
1731        /* isDefault */ return this.isDefault == null ? new Base[0] : new Base[] { this.isDefault }; // BooleanType
1732      case 1248023381:
1733        /* compositional */ return this.compositional == null ? new Base[0] : new Base[] { this.compositional }; // BooleanType
1734      case -1613589672:
1735        /* language */ return this.language == null ? new Base[0]
1736            : this.language.toArray(new Base[this.language.size()]); // CodeType
1737      case -1274492040:
1738        /* filter */ return this.filter == null ? new Base[0] : this.filter.toArray(new Base[this.filter.size()]); // TerminologyCapabilitiesCodeSystemVersionFilterComponent
1739      case -993141291:
1740        /* property */ return this.property == null ? new Base[0]
1741            : this.property.toArray(new Base[this.property.size()]); // CodeType
1742      default:
1743        return super.getProperty(hash, name, checkValid);
1744      }
1745
1746    }
1747
1748    @Override
1749    public Base setProperty(int hash, String name, Base value) throws FHIRException {
1750      switch (hash) {
1751      case 3059181: // code
1752        this.code = castToString(value); // StringType
1753        return value;
1754      case 965025207: // isDefault
1755        this.isDefault = castToBoolean(value); // BooleanType
1756        return value;
1757      case 1248023381: // compositional
1758        this.compositional = castToBoolean(value); // BooleanType
1759        return value;
1760      case -1613589672: // language
1761        this.getLanguage().add(castToCode(value)); // CodeType
1762        return value;
1763      case -1274492040: // filter
1764        this.getFilter().add((TerminologyCapabilitiesCodeSystemVersionFilterComponent) value); // TerminologyCapabilitiesCodeSystemVersionFilterComponent
1765        return value;
1766      case -993141291: // property
1767        this.getProperty().add(castToCode(value)); // CodeType
1768        return value;
1769      default:
1770        return super.setProperty(hash, name, value);
1771      }
1772
1773    }
1774
1775    @Override
1776    public Base setProperty(String name, Base value) throws FHIRException {
1777      if (name.equals("code")) {
1778        this.code = castToString(value); // StringType
1779      } else if (name.equals("isDefault")) {
1780        this.isDefault = castToBoolean(value); // BooleanType
1781      } else if (name.equals("compositional")) {
1782        this.compositional = castToBoolean(value); // BooleanType
1783      } else if (name.equals("language")) {
1784        this.getLanguage().add(castToCode(value));
1785      } else if (name.equals("filter")) {
1786        this.getFilter().add((TerminologyCapabilitiesCodeSystemVersionFilterComponent) value);
1787      } else if (name.equals("property")) {
1788        this.getProperty().add(castToCode(value));
1789      } else
1790        return super.setProperty(name, value);
1791      return value;
1792    }
1793
1794  @Override
1795  public void removeChild(String name, Base value) throws FHIRException {
1796      if (name.equals("code")) {
1797        this.code = null;
1798      } else if (name.equals("isDefault")) {
1799        this.isDefault = null;
1800      } else if (name.equals("compositional")) {
1801        this.compositional = null;
1802      } else if (name.equals("language")) {
1803        this.getLanguage().remove(castToCode(value));
1804      } else if (name.equals("filter")) {
1805        this.getFilter().remove((TerminologyCapabilitiesCodeSystemVersionFilterComponent) value);
1806      } else if (name.equals("property")) {
1807        this.getProperty().remove(castToCode(value));
1808      } else
1809        super.removeChild(name, value);
1810      
1811    }
1812
1813    @Override
1814    public Base makeProperty(int hash, String name) throws FHIRException {
1815      switch (hash) {
1816      case 3059181:
1817        return getCodeElement();
1818      case 965025207:
1819        return getIsDefaultElement();
1820      case 1248023381:
1821        return getCompositionalElement();
1822      case -1613589672:
1823        return addLanguageElement();
1824      case -1274492040:
1825        return addFilter();
1826      case -993141291:
1827        return addPropertyElement();
1828      default:
1829        return super.makeProperty(hash, name);
1830      }
1831
1832    }
1833
1834    @Override
1835    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
1836      switch (hash) {
1837      case 3059181:
1838        /* code */ return new String[] { "string" };
1839      case 965025207:
1840        /* isDefault */ return new String[] { "boolean" };
1841      case 1248023381:
1842        /* compositional */ return new String[] { "boolean" };
1843      case -1613589672:
1844        /* language */ return new String[] { "code" };
1845      case -1274492040:
1846        /* filter */ return new String[] {};
1847      case -993141291:
1848        /* property */ return new String[] { "code" };
1849      default:
1850        return super.getTypesForProperty(hash, name);
1851      }
1852
1853    }
1854
1855    @Override
1856    public Base addChild(String name) throws FHIRException {
1857      if (name.equals("code")) {
1858        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.code");
1859      } else if (name.equals("isDefault")) {
1860        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.isDefault");
1861      } else if (name.equals("compositional")) {
1862        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.compositional");
1863      } else if (name.equals("language")) {
1864        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.language");
1865      } else if (name.equals("filter")) {
1866        return addFilter();
1867      } else if (name.equals("property")) {
1868        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.property");
1869      } else
1870        return super.addChild(name);
1871    }
1872
1873    public TerminologyCapabilitiesCodeSystemVersionComponent copy() {
1874      TerminologyCapabilitiesCodeSystemVersionComponent dst = new TerminologyCapabilitiesCodeSystemVersionComponent();
1875      copyValues(dst);
1876      return dst;
1877    }
1878
1879    public void copyValues(TerminologyCapabilitiesCodeSystemVersionComponent dst) {
1880      super.copyValues(dst);
1881      dst.code = code == null ? null : code.copy();
1882      dst.isDefault = isDefault == null ? null : isDefault.copy();
1883      dst.compositional = compositional == null ? null : compositional.copy();
1884      if (language != null) {
1885        dst.language = new ArrayList<CodeType>();
1886        for (CodeType i : language)
1887          dst.language.add(i.copy());
1888      }
1889      ;
1890      if (filter != null) {
1891        dst.filter = new ArrayList<TerminologyCapabilitiesCodeSystemVersionFilterComponent>();
1892        for (TerminologyCapabilitiesCodeSystemVersionFilterComponent i : filter)
1893          dst.filter.add(i.copy());
1894      }
1895      ;
1896      if (property != null) {
1897        dst.property = new ArrayList<CodeType>();
1898        for (CodeType i : property)
1899          dst.property.add(i.copy());
1900      }
1901      ;
1902    }
1903
1904    @Override
1905    public boolean equalsDeep(Base other_) {
1906      if (!super.equalsDeep(other_))
1907        return false;
1908      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemVersionComponent))
1909        return false;
1910      TerminologyCapabilitiesCodeSystemVersionComponent o = (TerminologyCapabilitiesCodeSystemVersionComponent) other_;
1911      return compareDeep(code, o.code, true) && compareDeep(isDefault, o.isDefault, true)
1912          && compareDeep(compositional, o.compositional, true) && compareDeep(language, o.language, true)
1913          && compareDeep(filter, o.filter, true) && compareDeep(property, o.property, true);
1914    }
1915
1916    @Override
1917    public boolean equalsShallow(Base other_) {
1918      if (!super.equalsShallow(other_))
1919        return false;
1920      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemVersionComponent))
1921        return false;
1922      TerminologyCapabilitiesCodeSystemVersionComponent o = (TerminologyCapabilitiesCodeSystemVersionComponent) other_;
1923      return compareValues(code, o.code, true) && compareValues(isDefault, o.isDefault, true)
1924          && compareValues(compositional, o.compositional, true) && compareValues(language, o.language, true)
1925          && compareValues(property, o.property, true);
1926    }
1927
1928    public boolean isEmpty() {
1929      return super.isEmpty()
1930          && ca.uhn.fhir.util.ElementUtil.isEmpty(code, isDefault, compositional, language, filter, property);
1931    }
1932
1933    public String fhirType() {
1934      return "TerminologyCapabilities.codeSystem.version";
1935
1936    }
1937
1938  }
1939
1940  @Block()
1941  public static class TerminologyCapabilitiesCodeSystemVersionFilterComponent extends BackboneElement
1942      implements IBaseBackboneElement {
1943    /**
1944     * Code of the property supported.
1945     */
1946    @Child(name = "code", type = { CodeType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false)
1947    @Description(shortDefinition = "Code of the property supported", formalDefinition = "Code of the property supported.")
1948    protected CodeType code;
1949
1950    /**
1951     * Operations supported for the property.
1952     */
1953    @Child(name = "op", type = {
1954        CodeType.class }, order = 2, min = 1, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
1955    @Description(shortDefinition = "Operations supported for the property", formalDefinition = "Operations supported for the property.")
1956    protected List<CodeType> op;
1957
1958    private static final long serialVersionUID = -489160282L;
1959
1960    /**
1961     * Constructor
1962     */
1963    public TerminologyCapabilitiesCodeSystemVersionFilterComponent() {
1964      super();
1965    }
1966
1967    /**
1968     * Constructor
1969     */
1970    public TerminologyCapabilitiesCodeSystemVersionFilterComponent(CodeType code) {
1971      super();
1972      this.code = code;
1973    }
1974
1975    /**
1976     * @return {@link #code} (Code of the property supported.). This is the
1977     *         underlying object with id, value and extensions. The accessor
1978     *         "getCode" gives direct access to the value
1979     */
1980    public CodeType getCodeElement() {
1981      if (this.code == null)
1982        if (Configuration.errorOnAutoCreate())
1983          throw new Error("Attempt to auto-create TerminologyCapabilitiesCodeSystemVersionFilterComponent.code");
1984        else if (Configuration.doAutoCreate())
1985          this.code = new CodeType(); // bb
1986      return this.code;
1987    }
1988
1989    public boolean hasCodeElement() {
1990      return this.code != null && !this.code.isEmpty();
1991    }
1992
1993    public boolean hasCode() {
1994      return this.code != null && !this.code.isEmpty();
1995    }
1996
1997    /**
1998     * @param value {@link #code} (Code of the property supported.). This is the
1999     *              underlying object with id, value and extensions. The accessor
2000     *              "getCode" gives direct access to the value
2001     */
2002    public TerminologyCapabilitiesCodeSystemVersionFilterComponent setCodeElement(CodeType value) {
2003      this.code = value;
2004      return this;
2005    }
2006
2007    /**
2008     * @return Code of the property supported.
2009     */
2010    public String getCode() {
2011      return this.code == null ? null : this.code.getValue();
2012    }
2013
2014    /**
2015     * @param value Code of the property supported.
2016     */
2017    public TerminologyCapabilitiesCodeSystemVersionFilterComponent setCode(String value) {
2018      if (this.code == null)
2019        this.code = new CodeType();
2020      this.code.setValue(value);
2021      return this;
2022    }
2023
2024    /**
2025     * @return {@link #op} (Operations supported for the property.)
2026     */
2027    public List<CodeType> getOp() {
2028      if (this.op == null)
2029        this.op = new ArrayList<CodeType>();
2030      return this.op;
2031    }
2032
2033    /**
2034     * @return Returns a reference to <code>this</code> for easy method chaining
2035     */
2036    public TerminologyCapabilitiesCodeSystemVersionFilterComponent setOp(List<CodeType> theOp) {
2037      this.op = theOp;
2038      return this;
2039    }
2040
2041    public boolean hasOp() {
2042      if (this.op == null)
2043        return false;
2044      for (CodeType item : this.op)
2045        if (!item.isEmpty())
2046          return true;
2047      return false;
2048    }
2049
2050    /**
2051     * @return {@link #op} (Operations supported for the property.)
2052     */
2053    public CodeType addOpElement() {// 2
2054      CodeType t = new CodeType();
2055      if (this.op == null)
2056        this.op = new ArrayList<CodeType>();
2057      this.op.add(t);
2058      return t;
2059    }
2060
2061    /**
2062     * @param value {@link #op} (Operations supported for the property.)
2063     */
2064    public TerminologyCapabilitiesCodeSystemVersionFilterComponent addOp(String value) { // 1
2065      CodeType t = new CodeType();
2066      t.setValue(value);
2067      if (this.op == null)
2068        this.op = new ArrayList<CodeType>();
2069      this.op.add(t);
2070      return this;
2071    }
2072
2073    /**
2074     * @param value {@link #op} (Operations supported for the property.)
2075     */
2076    public boolean hasOp(String value) {
2077      if (this.op == null)
2078        return false;
2079      for (CodeType v : this.op)
2080        if (v.getValue().equals(value)) // code
2081          return true;
2082      return false;
2083    }
2084
2085    protected void listChildren(List<Property> children) {
2086      super.listChildren(children);
2087      children.add(new Property("code", "code", "Code of the property supported.", 0, 1, code));
2088      children.add(
2089          new Property("op", "code", "Operations supported for the property.", 0, java.lang.Integer.MAX_VALUE, op));
2090    }
2091
2092    @Override
2093    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
2094      switch (_hash) {
2095      case 3059181:
2096        /* code */ return new Property("code", "code", "Code of the property supported.", 0, 1, code);
2097      case 3553:
2098        /* op */ return new Property("op", "code", "Operations supported for the property.", 0,
2099            java.lang.Integer.MAX_VALUE, op);
2100      default:
2101        return super.getNamedProperty(_hash, _name, _checkValid);
2102      }
2103
2104    }
2105
2106    @Override
2107    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
2108      switch (hash) {
2109      case 3059181:
2110        /* code */ return this.code == null ? new Base[0] : new Base[] { this.code }; // CodeType
2111      case 3553:
2112        /* op */ return this.op == null ? new Base[0] : this.op.toArray(new Base[this.op.size()]); // CodeType
2113      default:
2114        return super.getProperty(hash, name, checkValid);
2115      }
2116
2117    }
2118
2119    @Override
2120    public Base setProperty(int hash, String name, Base value) throws FHIRException {
2121      switch (hash) {
2122      case 3059181: // code
2123        this.code = castToCode(value); // CodeType
2124        return value;
2125      case 3553: // op
2126        this.getOp().add(castToCode(value)); // CodeType
2127        return value;
2128      default:
2129        return super.setProperty(hash, name, value);
2130      }
2131
2132    }
2133
2134    @Override
2135    public Base setProperty(String name, Base value) throws FHIRException {
2136      if (name.equals("code")) {
2137        this.code = castToCode(value); // CodeType
2138      } else if (name.equals("op")) {
2139        this.getOp().add(castToCode(value));
2140      } else
2141        return super.setProperty(name, value);
2142      return value;
2143    }
2144
2145  @Override
2146  public void removeChild(String name, Base value) throws FHIRException {
2147      if (name.equals("code")) {
2148        this.code = null;
2149      } else if (name.equals("op")) {
2150        this.getOp().remove(castToCode(value));
2151      } else
2152        super.removeChild(name, value);
2153      
2154    }
2155
2156    @Override
2157    public Base makeProperty(int hash, String name) throws FHIRException {
2158      switch (hash) {
2159      case 3059181:
2160        return getCodeElement();
2161      case 3553:
2162        return addOpElement();
2163      default:
2164        return super.makeProperty(hash, name);
2165      }
2166
2167    }
2168
2169    @Override
2170    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2171      switch (hash) {
2172      case 3059181:
2173        /* code */ return new String[] { "code" };
2174      case 3553:
2175        /* op */ return new String[] { "code" };
2176      default:
2177        return super.getTypesForProperty(hash, name);
2178      }
2179
2180    }
2181
2182    @Override
2183    public Base addChild(String name) throws FHIRException {
2184      if (name.equals("code")) {
2185        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.code");
2186      } else if (name.equals("op")) {
2187        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.op");
2188      } else
2189        return super.addChild(name);
2190    }
2191
2192    public TerminologyCapabilitiesCodeSystemVersionFilterComponent copy() {
2193      TerminologyCapabilitiesCodeSystemVersionFilterComponent dst = new TerminologyCapabilitiesCodeSystemVersionFilterComponent();
2194      copyValues(dst);
2195      return dst;
2196    }
2197
2198    public void copyValues(TerminologyCapabilitiesCodeSystemVersionFilterComponent dst) {
2199      super.copyValues(dst);
2200      dst.code = code == null ? null : code.copy();
2201      if (op != null) {
2202        dst.op = new ArrayList<CodeType>();
2203        for (CodeType i : op)
2204          dst.op.add(i.copy());
2205      }
2206      ;
2207    }
2208
2209    @Override
2210    public boolean equalsDeep(Base other_) {
2211      if (!super.equalsDeep(other_))
2212        return false;
2213      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemVersionFilterComponent))
2214        return false;
2215      TerminologyCapabilitiesCodeSystemVersionFilterComponent o = (TerminologyCapabilitiesCodeSystemVersionFilterComponent) other_;
2216      return compareDeep(code, o.code, true) && compareDeep(op, o.op, true);
2217    }
2218
2219    @Override
2220    public boolean equalsShallow(Base other_) {
2221      if (!super.equalsShallow(other_))
2222        return false;
2223      if (!(other_ instanceof TerminologyCapabilitiesCodeSystemVersionFilterComponent))
2224        return false;
2225      TerminologyCapabilitiesCodeSystemVersionFilterComponent o = (TerminologyCapabilitiesCodeSystemVersionFilterComponent) other_;
2226      return compareValues(code, o.code, true) && compareValues(op, o.op, true);
2227    }
2228
2229    public boolean isEmpty() {
2230      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(code, op);
2231    }
2232
2233    public String fhirType() {
2234      return "TerminologyCapabilities.codeSystem.version.filter";
2235
2236    }
2237
2238  }
2239
2240  @Block()
2241  public static class TerminologyCapabilitiesExpansionComponent extends BackboneElement
2242      implements IBaseBackboneElement {
2243    /**
2244     * Whether the server can return nested value sets.
2245     */
2246    @Child(name = "hierarchical", type = {
2247        BooleanType.class }, order = 1, min = 0, max = 1, modifier = false, summary = false)
2248    @Description(shortDefinition = "Whether the server can return nested value sets", formalDefinition = "Whether the server can return nested value sets.")
2249    protected BooleanType hierarchical;
2250
2251    /**
2252     * Whether the server supports paging on expansion.
2253     */
2254    @Child(name = "paging", type = {
2255        BooleanType.class }, order = 2, min = 0, max = 1, modifier = false, summary = false)
2256    @Description(shortDefinition = "Whether the server supports paging on expansion", formalDefinition = "Whether the server supports paging on expansion.")
2257    protected BooleanType paging;
2258
2259    /**
2260     * Allow request for incomplete expansions?
2261     */
2262    @Child(name = "incomplete", type = {
2263        BooleanType.class }, order = 3, min = 0, max = 1, modifier = false, summary = false)
2264    @Description(shortDefinition = "Allow request for incomplete expansions?", formalDefinition = "Allow request for incomplete expansions?")
2265    protected BooleanType incomplete;
2266
2267    /**
2268     * Supported expansion parameter.
2269     */
2270    @Child(name = "parameter", type = {}, order = 4, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
2271    @Description(shortDefinition = "Supported expansion parameter", formalDefinition = "Supported expansion parameter.")
2272    protected List<TerminologyCapabilitiesExpansionParameterComponent> parameter;
2273
2274    /**
2275     * Documentation about text searching works.
2276     */
2277    @Child(name = "textFilter", type = {
2278        MarkdownType.class }, order = 5, min = 0, max = 1, modifier = false, summary = false)
2279    @Description(shortDefinition = "Documentation about text searching works", formalDefinition = "Documentation about text searching works.")
2280    protected MarkdownType textFilter;
2281
2282    private static final long serialVersionUID = -1011350616L;
2283
2284    /**
2285     * Constructor
2286     */
2287    public TerminologyCapabilitiesExpansionComponent() {
2288      super();
2289    }
2290
2291    /**
2292     * @return {@link #hierarchical} (Whether the server can return nested value
2293     *         sets.). This is the underlying object with id, value and extensions.
2294     *         The accessor "getHierarchical" gives direct access to the value
2295     */
2296    public BooleanType getHierarchicalElement() {
2297      if (this.hierarchical == null)
2298        if (Configuration.errorOnAutoCreate())
2299          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionComponent.hierarchical");
2300        else if (Configuration.doAutoCreate())
2301          this.hierarchical = new BooleanType(); // bb
2302      return this.hierarchical;
2303    }
2304
2305    public boolean hasHierarchicalElement() {
2306      return this.hierarchical != null && !this.hierarchical.isEmpty();
2307    }
2308
2309    public boolean hasHierarchical() {
2310      return this.hierarchical != null && !this.hierarchical.isEmpty();
2311    }
2312
2313    /**
2314     * @param value {@link #hierarchical} (Whether the server can return nested
2315     *              value sets.). This is the underlying object with id, value and
2316     *              extensions. The accessor "getHierarchical" gives direct access
2317     *              to the value
2318     */
2319    public TerminologyCapabilitiesExpansionComponent setHierarchicalElement(BooleanType value) {
2320      this.hierarchical = value;
2321      return this;
2322    }
2323
2324    /**
2325     * @return Whether the server can return nested value sets.
2326     */
2327    public boolean getHierarchical() {
2328      return this.hierarchical == null || this.hierarchical.isEmpty() ? false : this.hierarchical.getValue();
2329    }
2330
2331    /**
2332     * @param value Whether the server can return nested value sets.
2333     */
2334    public TerminologyCapabilitiesExpansionComponent setHierarchical(boolean value) {
2335      if (this.hierarchical == null)
2336        this.hierarchical = new BooleanType();
2337      this.hierarchical.setValue(value);
2338      return this;
2339    }
2340
2341    /**
2342     * @return {@link #paging} (Whether the server supports paging on expansion.).
2343     *         This is the underlying object with id, value and extensions. The
2344     *         accessor "getPaging" gives direct access to the value
2345     */
2346    public BooleanType getPagingElement() {
2347      if (this.paging == null)
2348        if (Configuration.errorOnAutoCreate())
2349          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionComponent.paging");
2350        else if (Configuration.doAutoCreate())
2351          this.paging = new BooleanType(); // bb
2352      return this.paging;
2353    }
2354
2355    public boolean hasPagingElement() {
2356      return this.paging != null && !this.paging.isEmpty();
2357    }
2358
2359    public boolean hasPaging() {
2360      return this.paging != null && !this.paging.isEmpty();
2361    }
2362
2363    /**
2364     * @param value {@link #paging} (Whether the server supports paging on
2365     *              expansion.). This is the underlying object with id, value and
2366     *              extensions. The accessor "getPaging" gives direct access to the
2367     *              value
2368     */
2369    public TerminologyCapabilitiesExpansionComponent setPagingElement(BooleanType value) {
2370      this.paging = value;
2371      return this;
2372    }
2373
2374    /**
2375     * @return Whether the server supports paging on expansion.
2376     */
2377    public boolean getPaging() {
2378      return this.paging == null || this.paging.isEmpty() ? false : this.paging.getValue();
2379    }
2380
2381    /**
2382     * @param value Whether the server supports paging on expansion.
2383     */
2384    public TerminologyCapabilitiesExpansionComponent setPaging(boolean value) {
2385      if (this.paging == null)
2386        this.paging = new BooleanType();
2387      this.paging.setValue(value);
2388      return this;
2389    }
2390
2391    /**
2392     * @return {@link #incomplete} (Allow request for incomplete expansions?). This
2393     *         is the underlying object with id, value and extensions. The accessor
2394     *         "getIncomplete" gives direct access to the value
2395     */
2396    public BooleanType getIncompleteElement() {
2397      if (this.incomplete == null)
2398        if (Configuration.errorOnAutoCreate())
2399          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionComponent.incomplete");
2400        else if (Configuration.doAutoCreate())
2401          this.incomplete = new BooleanType(); // bb
2402      return this.incomplete;
2403    }
2404
2405    public boolean hasIncompleteElement() {
2406      return this.incomplete != null && !this.incomplete.isEmpty();
2407    }
2408
2409    public boolean hasIncomplete() {
2410      return this.incomplete != null && !this.incomplete.isEmpty();
2411    }
2412
2413    /**
2414     * @param value {@link #incomplete} (Allow request for incomplete expansions?).
2415     *              This is the underlying object with id, value and extensions. The
2416     *              accessor "getIncomplete" gives direct access to the value
2417     */
2418    public TerminologyCapabilitiesExpansionComponent setIncompleteElement(BooleanType value) {
2419      this.incomplete = value;
2420      return this;
2421    }
2422
2423    /**
2424     * @return Allow request for incomplete expansions?
2425     */
2426    public boolean getIncomplete() {
2427      return this.incomplete == null || this.incomplete.isEmpty() ? false : this.incomplete.getValue();
2428    }
2429
2430    /**
2431     * @param value Allow request for incomplete expansions?
2432     */
2433    public TerminologyCapabilitiesExpansionComponent setIncomplete(boolean value) {
2434      if (this.incomplete == null)
2435        this.incomplete = new BooleanType();
2436      this.incomplete.setValue(value);
2437      return this;
2438    }
2439
2440    /**
2441     * @return {@link #parameter} (Supported expansion parameter.)
2442     */
2443    public List<TerminologyCapabilitiesExpansionParameterComponent> getParameter() {
2444      if (this.parameter == null)
2445        this.parameter = new ArrayList<TerminologyCapabilitiesExpansionParameterComponent>();
2446      return this.parameter;
2447    }
2448
2449    /**
2450     * @return Returns a reference to <code>this</code> for easy method chaining
2451     */
2452    public TerminologyCapabilitiesExpansionComponent setParameter(
2453        List<TerminologyCapabilitiesExpansionParameterComponent> theParameter) {
2454      this.parameter = theParameter;
2455      return this;
2456    }
2457
2458    public boolean hasParameter() {
2459      if (this.parameter == null)
2460        return false;
2461      for (TerminologyCapabilitiesExpansionParameterComponent item : this.parameter)
2462        if (!item.isEmpty())
2463          return true;
2464      return false;
2465    }
2466
2467    public TerminologyCapabilitiesExpansionParameterComponent addParameter() { // 3
2468      TerminologyCapabilitiesExpansionParameterComponent t = new TerminologyCapabilitiesExpansionParameterComponent();
2469      if (this.parameter == null)
2470        this.parameter = new ArrayList<TerminologyCapabilitiesExpansionParameterComponent>();
2471      this.parameter.add(t);
2472      return t;
2473    }
2474
2475    public TerminologyCapabilitiesExpansionComponent addParameter(
2476        TerminologyCapabilitiesExpansionParameterComponent t) { // 3
2477      if (t == null)
2478        return this;
2479      if (this.parameter == null)
2480        this.parameter = new ArrayList<TerminologyCapabilitiesExpansionParameterComponent>();
2481      this.parameter.add(t);
2482      return this;
2483    }
2484
2485    /**
2486     * @return The first repetition of repeating field {@link #parameter}, creating
2487     *         it if it does not already exist
2488     */
2489    public TerminologyCapabilitiesExpansionParameterComponent getParameterFirstRep() {
2490      if (getParameter().isEmpty()) {
2491        addParameter();
2492      }
2493      return getParameter().get(0);
2494    }
2495
2496    /**
2497     * @return {@link #textFilter} (Documentation about text searching works.). This
2498     *         is the underlying object with id, value and extensions. The accessor
2499     *         "getTextFilter" gives direct access to the value
2500     */
2501    public MarkdownType getTextFilterElement() {
2502      if (this.textFilter == null)
2503        if (Configuration.errorOnAutoCreate())
2504          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionComponent.textFilter");
2505        else if (Configuration.doAutoCreate())
2506          this.textFilter = new MarkdownType(); // bb
2507      return this.textFilter;
2508    }
2509
2510    public boolean hasTextFilterElement() {
2511      return this.textFilter != null && !this.textFilter.isEmpty();
2512    }
2513
2514    public boolean hasTextFilter() {
2515      return this.textFilter != null && !this.textFilter.isEmpty();
2516    }
2517
2518    /**
2519     * @param value {@link #textFilter} (Documentation about text searching works.).
2520     *              This is the underlying object with id, value and extensions. The
2521     *              accessor "getTextFilter" gives direct access to the value
2522     */
2523    public TerminologyCapabilitiesExpansionComponent setTextFilterElement(MarkdownType value) {
2524      this.textFilter = value;
2525      return this;
2526    }
2527
2528    /**
2529     * @return Documentation about text searching works.
2530     */
2531    public String getTextFilter() {
2532      return this.textFilter == null ? null : this.textFilter.getValue();
2533    }
2534
2535    /**
2536     * @param value Documentation about text searching works.
2537     */
2538    public TerminologyCapabilitiesExpansionComponent setTextFilter(String value) {
2539      if (value == null)
2540        this.textFilter = null;
2541      else {
2542        if (this.textFilter == null)
2543          this.textFilter = new MarkdownType();
2544        this.textFilter.setValue(value);
2545      }
2546      return this;
2547    }
2548
2549    protected void listChildren(List<Property> children) {
2550      super.listChildren(children);
2551      children.add(new Property("hierarchical", "boolean", "Whether the server can return nested value sets.", 0, 1,
2552          hierarchical));
2553      children.add(new Property("paging", "boolean", "Whether the server supports paging on expansion.", 0, 1, paging));
2554      children.add(new Property("incomplete", "boolean", "Allow request for incomplete expansions?", 0, 1, incomplete));
2555      children.add(
2556          new Property("parameter", "", "Supported expansion parameter.", 0, java.lang.Integer.MAX_VALUE, parameter));
2557      children
2558          .add(new Property("textFilter", "markdown", "Documentation about text searching works.", 0, 1, textFilter));
2559    }
2560
2561    @Override
2562    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
2563      switch (_hash) {
2564      case 857636745:
2565        /* hierarchical */ return new Property("hierarchical", "boolean",
2566            "Whether the server can return nested value sets.", 0, 1, hierarchical);
2567      case -995747956:
2568        /* paging */ return new Property("paging", "boolean", "Whether the server supports paging on expansion.", 0, 1,
2569            paging);
2570      case -1010022050:
2571        /* incomplete */ return new Property("incomplete", "boolean", "Allow request for incomplete expansions?", 0, 1,
2572            incomplete);
2573      case 1954460585:
2574        /* parameter */ return new Property("parameter", "", "Supported expansion parameter.", 0,
2575            java.lang.Integer.MAX_VALUE, parameter);
2576      case 1469359877:
2577        /* textFilter */ return new Property("textFilter", "markdown", "Documentation about text searching works.", 0,
2578            1, textFilter);
2579      default:
2580        return super.getNamedProperty(_hash, _name, _checkValid);
2581      }
2582
2583    }
2584
2585    @Override
2586    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
2587      switch (hash) {
2588      case 857636745:
2589        /* hierarchical */ return this.hierarchical == null ? new Base[0] : new Base[] { this.hierarchical }; // BooleanType
2590      case -995747956:
2591        /* paging */ return this.paging == null ? new Base[0] : new Base[] { this.paging }; // BooleanType
2592      case -1010022050:
2593        /* incomplete */ return this.incomplete == null ? new Base[0] : new Base[] { this.incomplete }; // BooleanType
2594      case 1954460585:
2595        /* parameter */ return this.parameter == null ? new Base[0]
2596            : this.parameter.toArray(new Base[this.parameter.size()]); // TerminologyCapabilitiesExpansionParameterComponent
2597      case 1469359877:
2598        /* textFilter */ return this.textFilter == null ? new Base[0] : new Base[] { this.textFilter }; // MarkdownType
2599      default:
2600        return super.getProperty(hash, name, checkValid);
2601      }
2602
2603    }
2604
2605    @Override
2606    public Base setProperty(int hash, String name, Base value) throws FHIRException {
2607      switch (hash) {
2608      case 857636745: // hierarchical
2609        this.hierarchical = castToBoolean(value); // BooleanType
2610        return value;
2611      case -995747956: // paging
2612        this.paging = castToBoolean(value); // BooleanType
2613        return value;
2614      case -1010022050: // incomplete
2615        this.incomplete = castToBoolean(value); // BooleanType
2616        return value;
2617      case 1954460585: // parameter
2618        this.getParameter().add((TerminologyCapabilitiesExpansionParameterComponent) value); // TerminologyCapabilitiesExpansionParameterComponent
2619        return value;
2620      case 1469359877: // textFilter
2621        this.textFilter = castToMarkdown(value); // MarkdownType
2622        return value;
2623      default:
2624        return super.setProperty(hash, name, value);
2625      }
2626
2627    }
2628
2629    @Override
2630    public Base setProperty(String name, Base value) throws FHIRException {
2631      if (name.equals("hierarchical")) {
2632        this.hierarchical = castToBoolean(value); // BooleanType
2633      } else if (name.equals("paging")) {
2634        this.paging = castToBoolean(value); // BooleanType
2635      } else if (name.equals("incomplete")) {
2636        this.incomplete = castToBoolean(value); // BooleanType
2637      } else if (name.equals("parameter")) {
2638        this.getParameter().add((TerminologyCapabilitiesExpansionParameterComponent) value);
2639      } else if (name.equals("textFilter")) {
2640        this.textFilter = castToMarkdown(value); // MarkdownType
2641      } else
2642        return super.setProperty(name, value);
2643      return value;
2644    }
2645
2646  @Override
2647  public void removeChild(String name, Base value) throws FHIRException {
2648      if (name.equals("hierarchical")) {
2649        this.hierarchical = null;
2650      } else if (name.equals("paging")) {
2651        this.paging = null;
2652      } else if (name.equals("incomplete")) {
2653        this.incomplete = null;
2654      } else if (name.equals("parameter")) {
2655        this.getParameter().remove((TerminologyCapabilitiesExpansionParameterComponent) value);
2656      } else if (name.equals("textFilter")) {
2657        this.textFilter = null;
2658      } else
2659        super.removeChild(name, value);
2660      
2661    }
2662
2663    @Override
2664    public Base makeProperty(int hash, String name) throws FHIRException {
2665      switch (hash) {
2666      case 857636745:
2667        return getHierarchicalElement();
2668      case -995747956:
2669        return getPagingElement();
2670      case -1010022050:
2671        return getIncompleteElement();
2672      case 1954460585:
2673        return addParameter();
2674      case 1469359877:
2675        return getTextFilterElement();
2676      default:
2677        return super.makeProperty(hash, name);
2678      }
2679
2680    }
2681
2682    @Override
2683    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2684      switch (hash) {
2685      case 857636745:
2686        /* hierarchical */ return new String[] { "boolean" };
2687      case -995747956:
2688        /* paging */ return new String[] { "boolean" };
2689      case -1010022050:
2690        /* incomplete */ return new String[] { "boolean" };
2691      case 1954460585:
2692        /* parameter */ return new String[] {};
2693      case 1469359877:
2694        /* textFilter */ return new String[] { "markdown" };
2695      default:
2696        return super.getTypesForProperty(hash, name);
2697      }
2698
2699    }
2700
2701    @Override
2702    public Base addChild(String name) throws FHIRException {
2703      if (name.equals("hierarchical")) {
2704        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.hierarchical");
2705      } else if (name.equals("paging")) {
2706        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.paging");
2707      } else if (name.equals("incomplete")) {
2708        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.incomplete");
2709      } else if (name.equals("parameter")) {
2710        return addParameter();
2711      } else if (name.equals("textFilter")) {
2712        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.textFilter");
2713      } else
2714        return super.addChild(name);
2715    }
2716
2717    public TerminologyCapabilitiesExpansionComponent copy() {
2718      TerminologyCapabilitiesExpansionComponent dst = new TerminologyCapabilitiesExpansionComponent();
2719      copyValues(dst);
2720      return dst;
2721    }
2722
2723    public void copyValues(TerminologyCapabilitiesExpansionComponent dst) {
2724      super.copyValues(dst);
2725      dst.hierarchical = hierarchical == null ? null : hierarchical.copy();
2726      dst.paging = paging == null ? null : paging.copy();
2727      dst.incomplete = incomplete == null ? null : incomplete.copy();
2728      if (parameter != null) {
2729        dst.parameter = new ArrayList<TerminologyCapabilitiesExpansionParameterComponent>();
2730        for (TerminologyCapabilitiesExpansionParameterComponent i : parameter)
2731          dst.parameter.add(i.copy());
2732      }
2733      ;
2734      dst.textFilter = textFilter == null ? null : textFilter.copy();
2735    }
2736
2737    @Override
2738    public boolean equalsDeep(Base other_) {
2739      if (!super.equalsDeep(other_))
2740        return false;
2741      if (!(other_ instanceof TerminologyCapabilitiesExpansionComponent))
2742        return false;
2743      TerminologyCapabilitiesExpansionComponent o = (TerminologyCapabilitiesExpansionComponent) other_;
2744      return compareDeep(hierarchical, o.hierarchical, true) && compareDeep(paging, o.paging, true)
2745          && compareDeep(incomplete, o.incomplete, true) && compareDeep(parameter, o.parameter, true)
2746          && compareDeep(textFilter, o.textFilter, true);
2747    }
2748
2749    @Override
2750    public boolean equalsShallow(Base other_) {
2751      if (!super.equalsShallow(other_))
2752        return false;
2753      if (!(other_ instanceof TerminologyCapabilitiesExpansionComponent))
2754        return false;
2755      TerminologyCapabilitiesExpansionComponent o = (TerminologyCapabilitiesExpansionComponent) other_;
2756      return compareValues(hierarchical, o.hierarchical, true) && compareValues(paging, o.paging, true)
2757          && compareValues(incomplete, o.incomplete, true) && compareValues(textFilter, o.textFilter, true);
2758    }
2759
2760    public boolean isEmpty() {
2761      return super.isEmpty()
2762          && ca.uhn.fhir.util.ElementUtil.isEmpty(hierarchical, paging, incomplete, parameter, textFilter);
2763    }
2764
2765    public String fhirType() {
2766      return "TerminologyCapabilities.expansion";
2767
2768    }
2769
2770  }
2771
2772  @Block()
2773  public static class TerminologyCapabilitiesExpansionParameterComponent extends BackboneElement
2774      implements IBaseBackboneElement {
2775    /**
2776     * Expansion Parameter name.
2777     */
2778    @Child(name = "name", type = { CodeType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false)
2779    @Description(shortDefinition = "Expansion Parameter name", formalDefinition = "Expansion Parameter name.")
2780    protected CodeType name;
2781
2782    /**
2783     * Description of support for parameter.
2784     */
2785    @Child(name = "documentation", type = {
2786        StringType.class }, order = 2, min = 0, max = 1, modifier = false, summary = false)
2787    @Description(shortDefinition = "Description of support for parameter", formalDefinition = "Description of support for parameter.")
2788    protected StringType documentation;
2789
2790    private static final long serialVersionUID = -1703372741L;
2791
2792    /**
2793     * Constructor
2794     */
2795    public TerminologyCapabilitiesExpansionParameterComponent() {
2796      super();
2797    }
2798
2799    /**
2800     * Constructor
2801     */
2802    public TerminologyCapabilitiesExpansionParameterComponent(CodeType name) {
2803      super();
2804      this.name = name;
2805    }
2806
2807    /**
2808     * @return {@link #name} (Expansion Parameter name.). This is the underlying
2809     *         object with id, value and extensions. The accessor "getName" gives
2810     *         direct access to the value
2811     */
2812    public CodeType getNameElement() {
2813      if (this.name == null)
2814        if (Configuration.errorOnAutoCreate())
2815          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionParameterComponent.name");
2816        else if (Configuration.doAutoCreate())
2817          this.name = new CodeType(); // bb
2818      return this.name;
2819    }
2820
2821    public boolean hasNameElement() {
2822      return this.name != null && !this.name.isEmpty();
2823    }
2824
2825    public boolean hasName() {
2826      return this.name != null && !this.name.isEmpty();
2827    }
2828
2829    /**
2830     * @param value {@link #name} (Expansion Parameter name.). This is the
2831     *              underlying object with id, value and extensions. The accessor
2832     *              "getName" gives direct access to the value
2833     */
2834    public TerminologyCapabilitiesExpansionParameterComponent setNameElement(CodeType value) {
2835      this.name = value;
2836      return this;
2837    }
2838
2839    /**
2840     * @return Expansion Parameter name.
2841     */
2842    public String getName() {
2843      return this.name == null ? null : this.name.getValue();
2844    }
2845
2846    /**
2847     * @param value Expansion Parameter name.
2848     */
2849    public TerminologyCapabilitiesExpansionParameterComponent setName(String value) {
2850      if (this.name == null)
2851        this.name = new CodeType();
2852      this.name.setValue(value);
2853      return this;
2854    }
2855
2856    /**
2857     * @return {@link #documentation} (Description of support for parameter.). This
2858     *         is the underlying object with id, value and extensions. The accessor
2859     *         "getDocumentation" gives direct access to the value
2860     */
2861    public StringType getDocumentationElement() {
2862      if (this.documentation == null)
2863        if (Configuration.errorOnAutoCreate())
2864          throw new Error("Attempt to auto-create TerminologyCapabilitiesExpansionParameterComponent.documentation");
2865        else if (Configuration.doAutoCreate())
2866          this.documentation = new StringType(); // bb
2867      return this.documentation;
2868    }
2869
2870    public boolean hasDocumentationElement() {
2871      return this.documentation != null && !this.documentation.isEmpty();
2872    }
2873
2874    public boolean hasDocumentation() {
2875      return this.documentation != null && !this.documentation.isEmpty();
2876    }
2877
2878    /**
2879     * @param value {@link #documentation} (Description of support for parameter.).
2880     *              This is the underlying object with id, value and extensions. The
2881     *              accessor "getDocumentation" gives direct access to the value
2882     */
2883    public TerminologyCapabilitiesExpansionParameterComponent setDocumentationElement(StringType value) {
2884      this.documentation = value;
2885      return this;
2886    }
2887
2888    /**
2889     * @return Description of support for parameter.
2890     */
2891    public String getDocumentation() {
2892      return this.documentation == null ? null : this.documentation.getValue();
2893    }
2894
2895    /**
2896     * @param value Description of support for parameter.
2897     */
2898    public TerminologyCapabilitiesExpansionParameterComponent setDocumentation(String value) {
2899      if (Utilities.noString(value))
2900        this.documentation = null;
2901      else {
2902        if (this.documentation == null)
2903          this.documentation = new StringType();
2904        this.documentation.setValue(value);
2905      }
2906      return this;
2907    }
2908
2909    protected void listChildren(List<Property> children) {
2910      super.listChildren(children);
2911      children.add(new Property("name", "code", "Expansion Parameter name.", 0, 1, name));
2912      children
2913          .add(new Property("documentation", "string", "Description of support for parameter.", 0, 1, documentation));
2914    }
2915
2916    @Override
2917    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
2918      switch (_hash) {
2919      case 3373707:
2920        /* name */ return new Property("name", "code", "Expansion Parameter name.", 0, 1, name);
2921      case 1587405498:
2922        /* documentation */ return new Property("documentation", "string", "Description of support for parameter.", 0,
2923            1, documentation);
2924      default:
2925        return super.getNamedProperty(_hash, _name, _checkValid);
2926      }
2927
2928    }
2929
2930    @Override
2931    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
2932      switch (hash) {
2933      case 3373707:
2934        /* name */ return this.name == null ? new Base[0] : new Base[] { this.name }; // CodeType
2935      case 1587405498:
2936        /* documentation */ return this.documentation == null ? new Base[0] : new Base[] { this.documentation }; // StringType
2937      default:
2938        return super.getProperty(hash, name, checkValid);
2939      }
2940
2941    }
2942
2943    @Override
2944    public Base setProperty(int hash, String name, Base value) throws FHIRException {
2945      switch (hash) {
2946      case 3373707: // name
2947        this.name = castToCode(value); // CodeType
2948        return value;
2949      case 1587405498: // documentation
2950        this.documentation = castToString(value); // StringType
2951        return value;
2952      default:
2953        return super.setProperty(hash, name, value);
2954      }
2955
2956    }
2957
2958    @Override
2959    public Base setProperty(String name, Base value) throws FHIRException {
2960      if (name.equals("name")) {
2961        this.name = castToCode(value); // CodeType
2962      } else if (name.equals("documentation")) {
2963        this.documentation = castToString(value); // StringType
2964      } else
2965        return super.setProperty(name, value);
2966      return value;
2967    }
2968
2969  @Override
2970  public void removeChild(String name, Base value) throws FHIRException {
2971      if (name.equals("name")) {
2972        this.name = null;
2973      } else if (name.equals("documentation")) {
2974        this.documentation = null;
2975      } else
2976        super.removeChild(name, value);
2977      
2978    }
2979
2980    @Override
2981    public Base makeProperty(int hash, String name) throws FHIRException {
2982      switch (hash) {
2983      case 3373707:
2984        return getNameElement();
2985      case 1587405498:
2986        return getDocumentationElement();
2987      default:
2988        return super.makeProperty(hash, name);
2989      }
2990
2991    }
2992
2993    @Override
2994    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
2995      switch (hash) {
2996      case 3373707:
2997        /* name */ return new String[] { "code" };
2998      case 1587405498:
2999        /* documentation */ return new String[] { "string" };
3000      default:
3001        return super.getTypesForProperty(hash, name);
3002      }
3003
3004    }
3005
3006    @Override
3007    public Base addChild(String name) throws FHIRException {
3008      if (name.equals("name")) {
3009        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.name");
3010      } else if (name.equals("documentation")) {
3011        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.documentation");
3012      } else
3013        return super.addChild(name);
3014    }
3015
3016    public TerminologyCapabilitiesExpansionParameterComponent copy() {
3017      TerminologyCapabilitiesExpansionParameterComponent dst = new TerminologyCapabilitiesExpansionParameterComponent();
3018      copyValues(dst);
3019      return dst;
3020    }
3021
3022    public void copyValues(TerminologyCapabilitiesExpansionParameterComponent dst) {
3023      super.copyValues(dst);
3024      dst.name = name == null ? null : name.copy();
3025      dst.documentation = documentation == null ? null : documentation.copy();
3026    }
3027
3028    @Override
3029    public boolean equalsDeep(Base other_) {
3030      if (!super.equalsDeep(other_))
3031        return false;
3032      if (!(other_ instanceof TerminologyCapabilitiesExpansionParameterComponent))
3033        return false;
3034      TerminologyCapabilitiesExpansionParameterComponent o = (TerminologyCapabilitiesExpansionParameterComponent) other_;
3035      return compareDeep(name, o.name, true) && compareDeep(documentation, o.documentation, true);
3036    }
3037
3038    @Override
3039    public boolean equalsShallow(Base other_) {
3040      if (!super.equalsShallow(other_))
3041        return false;
3042      if (!(other_ instanceof TerminologyCapabilitiesExpansionParameterComponent))
3043        return false;
3044      TerminologyCapabilitiesExpansionParameterComponent o = (TerminologyCapabilitiesExpansionParameterComponent) other_;
3045      return compareValues(name, o.name, true) && compareValues(documentation, o.documentation, true);
3046    }
3047
3048    public boolean isEmpty() {
3049      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(name, documentation);
3050    }
3051
3052    public String fhirType() {
3053      return "TerminologyCapabilities.expansion.parameter";
3054
3055    }
3056
3057  }
3058
3059  @Block()
3060  public static class TerminologyCapabilitiesValidateCodeComponent extends BackboneElement
3061      implements IBaseBackboneElement {
3062    /**
3063     * Whether translations are validated.
3064     */
3065    @Child(name = "translations", type = {
3066        BooleanType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false)
3067    @Description(shortDefinition = "Whether translations are validated", formalDefinition = "Whether translations are validated.")
3068    protected BooleanType translations;
3069
3070    private static final long serialVersionUID = -1212814906L;
3071
3072    /**
3073     * Constructor
3074     */
3075    public TerminologyCapabilitiesValidateCodeComponent() {
3076      super();
3077    }
3078
3079    /**
3080     * Constructor
3081     */
3082    public TerminologyCapabilitiesValidateCodeComponent(BooleanType translations) {
3083      super();
3084      this.translations = translations;
3085    }
3086
3087    /**
3088     * @return {@link #translations} (Whether translations are validated.). This is
3089     *         the underlying object with id, value and extensions. The accessor
3090     *         "getTranslations" gives direct access to the value
3091     */
3092    public BooleanType getTranslationsElement() {
3093      if (this.translations == null)
3094        if (Configuration.errorOnAutoCreate())
3095          throw new Error("Attempt to auto-create TerminologyCapabilitiesValidateCodeComponent.translations");
3096        else if (Configuration.doAutoCreate())
3097          this.translations = new BooleanType(); // bb
3098      return this.translations;
3099    }
3100
3101    public boolean hasTranslationsElement() {
3102      return this.translations != null && !this.translations.isEmpty();
3103    }
3104
3105    public boolean hasTranslations() {
3106      return this.translations != null && !this.translations.isEmpty();
3107    }
3108
3109    /**
3110     * @param value {@link #translations} (Whether translations are validated.).
3111     *              This is the underlying object with id, value and extensions. The
3112     *              accessor "getTranslations" gives direct access to the value
3113     */
3114    public TerminologyCapabilitiesValidateCodeComponent setTranslationsElement(BooleanType value) {
3115      this.translations = value;
3116      return this;
3117    }
3118
3119    /**
3120     * @return Whether translations are validated.
3121     */
3122    public boolean getTranslations() {
3123      return this.translations == null || this.translations.isEmpty() ? false : this.translations.getValue();
3124    }
3125
3126    /**
3127     * @param value Whether translations are validated.
3128     */
3129    public TerminologyCapabilitiesValidateCodeComponent setTranslations(boolean value) {
3130      if (this.translations == null)
3131        this.translations = new BooleanType();
3132      this.translations.setValue(value);
3133      return this;
3134    }
3135
3136    protected void listChildren(List<Property> children) {
3137      super.listChildren(children);
3138      children.add(new Property("translations", "boolean", "Whether translations are validated.", 0, 1, translations));
3139    }
3140
3141    @Override
3142    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3143      switch (_hash) {
3144      case -1225497630:
3145        /* translations */ return new Property("translations", "boolean", "Whether translations are validated.", 0, 1,
3146            translations);
3147      default:
3148        return super.getNamedProperty(_hash, _name, _checkValid);
3149      }
3150
3151    }
3152
3153    @Override
3154    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3155      switch (hash) {
3156      case -1225497630:
3157        /* translations */ return this.translations == null ? new Base[0] : new Base[] { this.translations }; // BooleanType
3158      default:
3159        return super.getProperty(hash, name, checkValid);
3160      }
3161
3162    }
3163
3164    @Override
3165    public Base setProperty(int hash, String name, Base value) throws FHIRException {
3166      switch (hash) {
3167      case -1225497630: // translations
3168        this.translations = castToBoolean(value); // BooleanType
3169        return value;
3170      default:
3171        return super.setProperty(hash, name, value);
3172      }
3173
3174    }
3175
3176    @Override
3177    public Base setProperty(String name, Base value) throws FHIRException {
3178      if (name.equals("translations")) {
3179        this.translations = castToBoolean(value); // BooleanType
3180      } else
3181        return super.setProperty(name, value);
3182      return value;
3183    }
3184
3185  @Override
3186  public void removeChild(String name, Base value) throws FHIRException {
3187      if (name.equals("translations")) {
3188        this.translations = null;
3189      } else
3190        super.removeChild(name, value);
3191      
3192    }
3193
3194    @Override
3195    public Base makeProperty(int hash, String name) throws FHIRException {
3196      switch (hash) {
3197      case -1225497630:
3198        return getTranslationsElement();
3199      default:
3200        return super.makeProperty(hash, name);
3201      }
3202
3203    }
3204
3205    @Override
3206    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3207      switch (hash) {
3208      case -1225497630:
3209        /* translations */ return new String[] { "boolean" };
3210      default:
3211        return super.getTypesForProperty(hash, name);
3212      }
3213
3214    }
3215
3216    @Override
3217    public Base addChild(String name) throws FHIRException {
3218      if (name.equals("translations")) {
3219        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.translations");
3220      } else
3221        return super.addChild(name);
3222    }
3223
3224    public TerminologyCapabilitiesValidateCodeComponent copy() {
3225      TerminologyCapabilitiesValidateCodeComponent dst = new TerminologyCapabilitiesValidateCodeComponent();
3226      copyValues(dst);
3227      return dst;
3228    }
3229
3230    public void copyValues(TerminologyCapabilitiesValidateCodeComponent dst) {
3231      super.copyValues(dst);
3232      dst.translations = translations == null ? null : translations.copy();
3233    }
3234
3235    @Override
3236    public boolean equalsDeep(Base other_) {
3237      if (!super.equalsDeep(other_))
3238        return false;
3239      if (!(other_ instanceof TerminologyCapabilitiesValidateCodeComponent))
3240        return false;
3241      TerminologyCapabilitiesValidateCodeComponent o = (TerminologyCapabilitiesValidateCodeComponent) other_;
3242      return compareDeep(translations, o.translations, true);
3243    }
3244
3245    @Override
3246    public boolean equalsShallow(Base other_) {
3247      if (!super.equalsShallow(other_))
3248        return false;
3249      if (!(other_ instanceof TerminologyCapabilitiesValidateCodeComponent))
3250        return false;
3251      TerminologyCapabilitiesValidateCodeComponent o = (TerminologyCapabilitiesValidateCodeComponent) other_;
3252      return compareValues(translations, o.translations, true);
3253    }
3254
3255    public boolean isEmpty() {
3256      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(translations);
3257    }
3258
3259    public String fhirType() {
3260      return "TerminologyCapabilities.validateCode";
3261
3262    }
3263
3264  }
3265
3266  @Block()
3267  public static class TerminologyCapabilitiesTranslationComponent extends BackboneElement
3268      implements IBaseBackboneElement {
3269    /**
3270     * Whether the client must identify the map.
3271     */
3272    @Child(name = "needsMap", type = {
3273        BooleanType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false)
3274    @Description(shortDefinition = "Whether the client must identify the map", formalDefinition = "Whether the client must identify the map.")
3275    protected BooleanType needsMap;
3276
3277    private static final long serialVersionUID = -1727843575L;
3278
3279    /**
3280     * Constructor
3281     */
3282    public TerminologyCapabilitiesTranslationComponent() {
3283      super();
3284    }
3285
3286    /**
3287     * Constructor
3288     */
3289    public TerminologyCapabilitiesTranslationComponent(BooleanType needsMap) {
3290      super();
3291      this.needsMap = needsMap;
3292    }
3293
3294    /**
3295     * @return {@link #needsMap} (Whether the client must identify the map.). This
3296     *         is the underlying object with id, value and extensions. The accessor
3297     *         "getNeedsMap" gives direct access to the value
3298     */
3299    public BooleanType getNeedsMapElement() {
3300      if (this.needsMap == null)
3301        if (Configuration.errorOnAutoCreate())
3302          throw new Error("Attempt to auto-create TerminologyCapabilitiesTranslationComponent.needsMap");
3303        else if (Configuration.doAutoCreate())
3304          this.needsMap = new BooleanType(); // bb
3305      return this.needsMap;
3306    }
3307
3308    public boolean hasNeedsMapElement() {
3309      return this.needsMap != null && !this.needsMap.isEmpty();
3310    }
3311
3312    public boolean hasNeedsMap() {
3313      return this.needsMap != null && !this.needsMap.isEmpty();
3314    }
3315
3316    /**
3317     * @param value {@link #needsMap} (Whether the client must identify the map.).
3318     *              This is the underlying object with id, value and extensions. The
3319     *              accessor "getNeedsMap" gives direct access to the value
3320     */
3321    public TerminologyCapabilitiesTranslationComponent setNeedsMapElement(BooleanType value) {
3322      this.needsMap = value;
3323      return this;
3324    }
3325
3326    /**
3327     * @return Whether the client must identify the map.
3328     */
3329    public boolean getNeedsMap() {
3330      return this.needsMap == null || this.needsMap.isEmpty() ? false : this.needsMap.getValue();
3331    }
3332
3333    /**
3334     * @param value Whether the client must identify the map.
3335     */
3336    public TerminologyCapabilitiesTranslationComponent setNeedsMap(boolean value) {
3337      if (this.needsMap == null)
3338        this.needsMap = new BooleanType();
3339      this.needsMap.setValue(value);
3340      return this;
3341    }
3342
3343    protected void listChildren(List<Property> children) {
3344      super.listChildren(children);
3345      children.add(new Property("needsMap", "boolean", "Whether the client must identify the map.", 0, 1, needsMap));
3346    }
3347
3348    @Override
3349    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3350      switch (_hash) {
3351      case 866566527:
3352        /* needsMap */ return new Property("needsMap", "boolean", "Whether the client must identify the map.", 0, 1,
3353            needsMap);
3354      default:
3355        return super.getNamedProperty(_hash, _name, _checkValid);
3356      }
3357
3358    }
3359
3360    @Override
3361    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3362      switch (hash) {
3363      case 866566527:
3364        /* needsMap */ return this.needsMap == null ? new Base[0] : new Base[] { this.needsMap }; // BooleanType
3365      default:
3366        return super.getProperty(hash, name, checkValid);
3367      }
3368
3369    }
3370
3371    @Override
3372    public Base setProperty(int hash, String name, Base value) throws FHIRException {
3373      switch (hash) {
3374      case 866566527: // needsMap
3375        this.needsMap = castToBoolean(value); // BooleanType
3376        return value;
3377      default:
3378        return super.setProperty(hash, name, value);
3379      }
3380
3381    }
3382
3383    @Override
3384    public Base setProperty(String name, Base value) throws FHIRException {
3385      if (name.equals("needsMap")) {
3386        this.needsMap = castToBoolean(value); // BooleanType
3387      } else
3388        return super.setProperty(name, value);
3389      return value;
3390    }
3391
3392  @Override
3393  public void removeChild(String name, Base value) throws FHIRException {
3394      if (name.equals("needsMap")) {
3395        this.needsMap = null;
3396      } else
3397        super.removeChild(name, value);
3398      
3399    }
3400
3401    @Override
3402    public Base makeProperty(int hash, String name) throws FHIRException {
3403      switch (hash) {
3404      case 866566527:
3405        return getNeedsMapElement();
3406      default:
3407        return super.makeProperty(hash, name);
3408      }
3409
3410    }
3411
3412    @Override
3413    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3414      switch (hash) {
3415      case 866566527:
3416        /* needsMap */ return new String[] { "boolean" };
3417      default:
3418        return super.getTypesForProperty(hash, name);
3419      }
3420
3421    }
3422
3423    @Override
3424    public Base addChild(String name) throws FHIRException {
3425      if (name.equals("needsMap")) {
3426        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.needsMap");
3427      } else
3428        return super.addChild(name);
3429    }
3430
3431    public TerminologyCapabilitiesTranslationComponent copy() {
3432      TerminologyCapabilitiesTranslationComponent dst = new TerminologyCapabilitiesTranslationComponent();
3433      copyValues(dst);
3434      return dst;
3435    }
3436
3437    public void copyValues(TerminologyCapabilitiesTranslationComponent dst) {
3438      super.copyValues(dst);
3439      dst.needsMap = needsMap == null ? null : needsMap.copy();
3440    }
3441
3442    @Override
3443    public boolean equalsDeep(Base other_) {
3444      if (!super.equalsDeep(other_))
3445        return false;
3446      if (!(other_ instanceof TerminologyCapabilitiesTranslationComponent))
3447        return false;
3448      TerminologyCapabilitiesTranslationComponent o = (TerminologyCapabilitiesTranslationComponent) other_;
3449      return compareDeep(needsMap, o.needsMap, true);
3450    }
3451
3452    @Override
3453    public boolean equalsShallow(Base other_) {
3454      if (!super.equalsShallow(other_))
3455        return false;
3456      if (!(other_ instanceof TerminologyCapabilitiesTranslationComponent))
3457        return false;
3458      TerminologyCapabilitiesTranslationComponent o = (TerminologyCapabilitiesTranslationComponent) other_;
3459      return compareValues(needsMap, o.needsMap, true);
3460    }
3461
3462    public boolean isEmpty() {
3463      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(needsMap);
3464    }
3465
3466    public String fhirType() {
3467      return "TerminologyCapabilities.translation";
3468
3469    }
3470
3471  }
3472
3473  @Block()
3474  public static class TerminologyCapabilitiesClosureComponent extends BackboneElement implements IBaseBackboneElement {
3475    /**
3476     * If cross-system closure is supported.
3477     */
3478    @Child(name = "translation", type = {
3479        BooleanType.class }, order = 1, min = 0, max = 1, modifier = false, summary = false)
3480    @Description(shortDefinition = "If cross-system closure is supported", formalDefinition = "If cross-system closure is supported.")
3481    protected BooleanType translation;
3482
3483    private static final long serialVersionUID = 1900484343L;
3484
3485    /**
3486     * Constructor
3487     */
3488    public TerminologyCapabilitiesClosureComponent() {
3489      super();
3490    }
3491
3492    /**
3493     * @return {@link #translation} (If cross-system closure is supported.). This is
3494     *         the underlying object with id, value and extensions. The accessor
3495     *         "getTranslation" gives direct access to the value
3496     */
3497    public BooleanType getTranslationElement() {
3498      if (this.translation == null)
3499        if (Configuration.errorOnAutoCreate())
3500          throw new Error("Attempt to auto-create TerminologyCapabilitiesClosureComponent.translation");
3501        else if (Configuration.doAutoCreate())
3502          this.translation = new BooleanType(); // bb
3503      return this.translation;
3504    }
3505
3506    public boolean hasTranslationElement() {
3507      return this.translation != null && !this.translation.isEmpty();
3508    }
3509
3510    public boolean hasTranslation() {
3511      return this.translation != null && !this.translation.isEmpty();
3512    }
3513
3514    /**
3515     * @param value {@link #translation} (If cross-system closure is supported.).
3516     *              This is the underlying object with id, value and extensions. The
3517     *              accessor "getTranslation" gives direct access to the value
3518     */
3519    public TerminologyCapabilitiesClosureComponent setTranslationElement(BooleanType value) {
3520      this.translation = value;
3521      return this;
3522    }
3523
3524    /**
3525     * @return If cross-system closure is supported.
3526     */
3527    public boolean getTranslation() {
3528      return this.translation == null || this.translation.isEmpty() ? false : this.translation.getValue();
3529    }
3530
3531    /**
3532     * @param value If cross-system closure is supported.
3533     */
3534    public TerminologyCapabilitiesClosureComponent setTranslation(boolean value) {
3535      if (this.translation == null)
3536        this.translation = new BooleanType();
3537      this.translation.setValue(value);
3538      return this;
3539    }
3540
3541    protected void listChildren(List<Property> children) {
3542      super.listChildren(children);
3543      children.add(new Property("translation", "boolean", "If cross-system closure is supported.", 0, 1, translation));
3544    }
3545
3546    @Override
3547    public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
3548      switch (_hash) {
3549      case -1840647503:
3550        /* translation */ return new Property("translation", "boolean", "If cross-system closure is supported.", 0, 1,
3551            translation);
3552      default:
3553        return super.getNamedProperty(_hash, _name, _checkValid);
3554      }
3555
3556    }
3557
3558    @Override
3559    public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
3560      switch (hash) {
3561      case -1840647503:
3562        /* translation */ return this.translation == null ? new Base[0] : new Base[] { this.translation }; // BooleanType
3563      default:
3564        return super.getProperty(hash, name, checkValid);
3565      }
3566
3567    }
3568
3569    @Override
3570    public Base setProperty(int hash, String name, Base value) throws FHIRException {
3571      switch (hash) {
3572      case -1840647503: // translation
3573        this.translation = castToBoolean(value); // BooleanType
3574        return value;
3575      default:
3576        return super.setProperty(hash, name, value);
3577      }
3578
3579    }
3580
3581    @Override
3582    public Base setProperty(String name, Base value) throws FHIRException {
3583      if (name.equals("translation")) {
3584        this.translation = castToBoolean(value); // BooleanType
3585      } else
3586        return super.setProperty(name, value);
3587      return value;
3588    }
3589
3590  @Override
3591  public void removeChild(String name, Base value) throws FHIRException {
3592      if (name.equals("translation")) {
3593        this.translation = null;
3594      } else
3595        super.removeChild(name, value);
3596      
3597    }
3598
3599    @Override
3600    public Base makeProperty(int hash, String name) throws FHIRException {
3601      switch (hash) {
3602      case -1840647503:
3603        return getTranslationElement();
3604      default:
3605        return super.makeProperty(hash, name);
3606      }
3607
3608    }
3609
3610    @Override
3611    public String[] getTypesForProperty(int hash, String name) throws FHIRException {
3612      switch (hash) {
3613      case -1840647503:
3614        /* translation */ return new String[] { "boolean" };
3615      default:
3616        return super.getTypesForProperty(hash, name);
3617      }
3618
3619    }
3620
3621    @Override
3622    public Base addChild(String name) throws FHIRException {
3623      if (name.equals("translation")) {
3624        throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.translation");
3625      } else
3626        return super.addChild(name);
3627    }
3628
3629    public TerminologyCapabilitiesClosureComponent copy() {
3630      TerminologyCapabilitiesClosureComponent dst = new TerminologyCapabilitiesClosureComponent();
3631      copyValues(dst);
3632      return dst;
3633    }
3634
3635    public void copyValues(TerminologyCapabilitiesClosureComponent dst) {
3636      super.copyValues(dst);
3637      dst.translation = translation == null ? null : translation.copy();
3638    }
3639
3640    @Override
3641    public boolean equalsDeep(Base other_) {
3642      if (!super.equalsDeep(other_))
3643        return false;
3644      if (!(other_ instanceof TerminologyCapabilitiesClosureComponent))
3645        return false;
3646      TerminologyCapabilitiesClosureComponent o = (TerminologyCapabilitiesClosureComponent) other_;
3647      return compareDeep(translation, o.translation, true);
3648    }
3649
3650    @Override
3651    public boolean equalsShallow(Base other_) {
3652      if (!super.equalsShallow(other_))
3653        return false;
3654      if (!(other_ instanceof TerminologyCapabilitiesClosureComponent))
3655        return false;
3656      TerminologyCapabilitiesClosureComponent o = (TerminologyCapabilitiesClosureComponent) other_;
3657      return compareValues(translation, o.translation, true);
3658    }
3659
3660    public boolean isEmpty() {
3661      return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(translation);
3662    }
3663
3664    public String fhirType() {
3665      return "TerminologyCapabilities.closure";
3666
3667    }
3668
3669  }
3670
3671  /**
3672   * Explanation of why this terminology capabilities is needed and why it has
3673   * been designed as it has.
3674   */
3675  @Child(name = "purpose", type = {
3676      MarkdownType.class }, order = 0, min = 0, max = 1, modifier = false, summary = false)
3677  @Description(shortDefinition = "Why this terminology capabilities is defined", formalDefinition = "Explanation of why this terminology capabilities is needed and why it has been designed as it has.")
3678  protected MarkdownType purpose;
3679
3680  /**
3681   * A copyright statement relating to the terminology capabilities and/or its
3682   * contents. Copyright statements are generally legal restrictions on the use
3683   * and publishing of the terminology capabilities.
3684   */
3685  @Child(name = "copyright", type = {
3686      MarkdownType.class }, order = 1, min = 0, max = 1, modifier = false, summary = true)
3687  @Description(shortDefinition = "Use and/or publishing restrictions", formalDefinition = "A copyright statement relating to the terminology capabilities and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the terminology capabilities.")
3688  protected MarkdownType copyright;
3689
3690  /**
3691   * The way that this statement is intended to be used, to describe an actual
3692   * running instance of software, a particular product (kind, not instance of
3693   * software) or a class of implementation (e.g. a desired purchase).
3694   */
3695  @Child(name = "kind", type = { CodeType.class }, order = 2, min = 1, max = 1, modifier = false, summary = true)
3696  @Description(shortDefinition = "instance | capability | requirements", formalDefinition = "The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind, not instance of software) or a class of implementation (e.g. a desired purchase).")
3697  @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/capability-statement-kind")
3698  protected Enumeration<CapabilityStatementKind> kind;
3699
3700  /**
3701   * Software that is covered by this terminology capability statement. It is used
3702   * when the statement describes the capabilities of a particular software
3703   * version, independent of an installation.
3704   */
3705  @Child(name = "software", type = {}, order = 3, min = 0, max = 1, modifier = false, summary = true)
3706  @Description(shortDefinition = "Software that is covered by this terminology capability statement", formalDefinition = "Software that is covered by this terminology capability statement.  It is used when the statement describes the capabilities of a particular software version, independent of an installation.")
3707  protected TerminologyCapabilitiesSoftwareComponent software;
3708
3709  /**
3710   * Identifies a specific implementation instance that is described by the
3711   * terminology capability statement - i.e. a particular installation, rather
3712   * than the capabilities of a software program.
3713   */
3714  @Child(name = "implementation", type = {}, order = 4, min = 0, max = 1, modifier = false, summary = true)
3715  @Description(shortDefinition = "If this describes a specific instance", formalDefinition = "Identifies a specific implementation instance that is described by the terminology capability statement - i.e. a particular installation, rather than the capabilities of a software program.")
3716  protected TerminologyCapabilitiesImplementationComponent implementation;
3717
3718  /**
3719   * Whether the server supports lockedDate.
3720   */
3721  @Child(name = "lockedDate", type = {
3722      BooleanType.class }, order = 5, min = 0, max = 1, modifier = false, summary = true)
3723  @Description(shortDefinition = "Whether lockedDate is supported", formalDefinition = "Whether the server supports lockedDate.")
3724  protected BooleanType lockedDate;
3725
3726  /**
3727   * Identifies a code system that is supported by the server. If there is a no
3728   * code system URL, then this declares the general assumptions a client can make
3729   * about support for any CodeSystem resource.
3730   */
3731  @Child(name = "codeSystem", type = {}, order = 6, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false)
3732  @Description(shortDefinition = "A code system supported by the server", formalDefinition = "Identifies a code system that is supported by the server. If there is a no code system URL, then this declares the general assumptions a client can make about support for any CodeSystem resource.")
3733  protected List<TerminologyCapabilitiesCodeSystemComponent> codeSystem;
3734
3735  /**
3736   * Information about the [ValueSet/$expand](valueset-operation-expand.html)
3737   * operation.
3738   */
3739  @Child(name = "expansion", type = {}, order = 7, min = 0, max = 1, modifier = false, summary = false)
3740  @Description(shortDefinition = "Information about the [ValueSet/$expand](valueset-operation-expand.html) operation", formalDefinition = "Information about the [ValueSet/$expand](valueset-operation-expand.html) operation.")
3741  protected TerminologyCapabilitiesExpansionComponent expansion;
3742
3743  /**
3744   * The degree to which the server supports the code search parameter on
3745   * ValueSet, if it is supported.
3746   */
3747  @Child(name = "codeSearch", type = { CodeType.class }, order = 8, min = 0, max = 1, modifier = false, summary = false)
3748  @Description(shortDefinition = "explicit | all", formalDefinition = "The degree to which the server supports the code search parameter on ValueSet, if it is supported.")
3749  @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/code-search-support")
3750  protected Enumeration<CodeSearchSupport> codeSearch;
3751
3752  /**
3753   * Information about the
3754   * [ValueSet/$validate-code](valueset-operation-validate-code.html) operation.
3755   */
3756  @Child(name = "validateCode", type = {}, order = 9, min = 0, max = 1, modifier = false, summary = false)
3757  @Description(shortDefinition = "Information about the [ValueSet/$validate-code](valueset-operation-validate-code.html) operation", formalDefinition = "Information about the [ValueSet/$validate-code](valueset-operation-validate-code.html) operation.")
3758  protected TerminologyCapabilitiesValidateCodeComponent validateCode;
3759
3760  /**
3761   * Information about the
3762   * [ConceptMap/$translate](conceptmap-operation-translate.html) operation.
3763   */
3764  @Child(name = "translation", type = {}, order = 10, min = 0, max = 1, modifier = false, summary = false)
3765  @Description(shortDefinition = "Information about the [ConceptMap/$translate](conceptmap-operation-translate.html) operation", formalDefinition = "Information about the [ConceptMap/$translate](conceptmap-operation-translate.html) operation.")
3766  protected TerminologyCapabilitiesTranslationComponent translation;
3767
3768  /**
3769   * Whether the $closure operation is supported.
3770   */
3771  @Child(name = "closure", type = {}, order = 11, min = 0, max = 1, modifier = false, summary = false)
3772  @Description(shortDefinition = "Information about the [ConceptMap/$closure](conceptmap-operation-closure.html) operation", formalDefinition = "Whether the $closure operation is supported.")
3773  protected TerminologyCapabilitiesClosureComponent closure;
3774
3775  private static final long serialVersionUID = -1899106119L;
3776
3777  /**
3778   * Constructor
3779   */
3780  public TerminologyCapabilities() {
3781    super();
3782  }
3783
3784  /**
3785   * Constructor
3786   */
3787  public TerminologyCapabilities(Enumeration<PublicationStatus> status, DateTimeType date,
3788      Enumeration<CapabilityStatementKind> kind) {
3789    super();
3790    this.status = status;
3791    this.date = date;
3792    this.kind = kind;
3793  }
3794
3795  /**
3796   * @return {@link #url} (An absolute URI that is used to identify this
3797   *         terminology capabilities when it is referenced in a specification,
3798   *         model, design or an instance; also called its canonical identifier.
3799   *         This SHOULD be globally unique and SHOULD be a literal address at
3800   *         which at which an authoritative instance of this terminology
3801   *         capabilities is (or will be) published. This URL can be the target of
3802   *         a canonical reference. It SHALL remain the same when the terminology
3803   *         capabilities is stored on different servers.). This is the underlying
3804   *         object with id, value and extensions. The accessor "getUrl" gives
3805   *         direct access to the value
3806   */
3807  public UriType getUrlElement() {
3808    if (this.url == null)
3809      if (Configuration.errorOnAutoCreate())
3810        throw new Error("Attempt to auto-create TerminologyCapabilities.url");
3811      else if (Configuration.doAutoCreate())
3812        this.url = new UriType(); // bb
3813    return this.url;
3814  }
3815
3816  public boolean hasUrlElement() {
3817    return this.url != null && !this.url.isEmpty();
3818  }
3819
3820  public boolean hasUrl() {
3821    return this.url != null && !this.url.isEmpty();
3822  }
3823
3824  /**
3825   * @param value {@link #url} (An absolute URI that is used to identify this
3826   *              terminology capabilities when it is referenced in a
3827   *              specification, model, design or an instance; also called its
3828   *              canonical identifier. This SHOULD be globally unique and SHOULD
3829   *              be a literal address at which at which an authoritative instance
3830   *              of this terminology capabilities is (or will be) published. This
3831   *              URL can be the target of a canonical reference. It SHALL remain
3832   *              the same when the terminology capabilities is stored on
3833   *              different servers.). This is the underlying object with id,
3834   *              value and extensions. The accessor "getUrl" gives direct access
3835   *              to the value
3836   */
3837  public TerminologyCapabilities setUrlElement(UriType value) {
3838    this.url = value;
3839    return this;
3840  }
3841
3842  /**
3843   * @return An absolute URI that is used to identify this terminology
3844   *         capabilities when it is referenced in a specification, model, design
3845   *         or an instance; also called its canonical identifier. This SHOULD be
3846   *         globally unique and SHOULD be a literal address at which at which an
3847   *         authoritative instance of this terminology capabilities is (or will
3848   *         be) published. This URL can be the target of a canonical reference.
3849   *         It SHALL remain the same when the terminology capabilities is stored
3850   *         on different servers.
3851   */
3852  public String getUrl() {
3853    return this.url == null ? null : this.url.getValue();
3854  }
3855
3856  /**
3857   * @param value An absolute URI that is used to identify this terminology
3858   *              capabilities when it is referenced in a specification, model,
3859   *              design or an instance; also called its canonical identifier.
3860   *              This SHOULD be globally unique and SHOULD be a literal address
3861   *              at which at which an authoritative instance of this terminology
3862   *              capabilities is (or will be) published. This URL can be the
3863   *              target of a canonical reference. It SHALL remain the same when
3864   *              the terminology capabilities is stored on different servers.
3865   */
3866  public TerminologyCapabilities setUrl(String value) {
3867    if (Utilities.noString(value))
3868      this.url = null;
3869    else {
3870      if (this.url == null)
3871        this.url = new UriType();
3872      this.url.setValue(value);
3873    }
3874    return this;
3875  }
3876
3877  /**
3878   * @return {@link #version} (The identifier that is used to identify this
3879   *         version of the terminology capabilities when it is referenced in a
3880   *         specification, model, design or instance. This is an arbitrary value
3881   *         managed by the terminology capabilities author and is not expected to
3882   *         be globally unique. For example, it might be a timestamp (e.g.
3883   *         yyyymmdd) if a managed version is not available. There is also no
3884   *         expectation that versions can be placed in a lexicographical
3885   *         sequence.). This is the underlying object with id, value and
3886   *         extensions. The accessor "getVersion" gives direct access to the
3887   *         value
3888   */
3889  public StringType getVersionElement() {
3890    if (this.version == null)
3891      if (Configuration.errorOnAutoCreate())
3892        throw new Error("Attempt to auto-create TerminologyCapabilities.version");
3893      else if (Configuration.doAutoCreate())
3894        this.version = new StringType(); // bb
3895    return this.version;
3896  }
3897
3898  public boolean hasVersionElement() {
3899    return this.version != null && !this.version.isEmpty();
3900  }
3901
3902  public boolean hasVersion() {
3903    return this.version != null && !this.version.isEmpty();
3904  }
3905
3906  /**
3907   * @param value {@link #version} (The identifier that is used to identify this
3908   *              version of the terminology capabilities when it is referenced in
3909   *              a specification, model, design or instance. This is an arbitrary
3910   *              value managed by the terminology capabilities author and is not
3911   *              expected to be globally unique. For example, it might be a
3912   *              timestamp (e.g. yyyymmdd) if a managed version is not available.
3913   *              There is also no expectation that versions can be placed in a
3914   *              lexicographical sequence.). This is the underlying object with
3915   *              id, value and extensions. The accessor "getVersion" gives direct
3916   *              access to the value
3917   */
3918  public TerminologyCapabilities setVersionElement(StringType value) {
3919    this.version = value;
3920    return this;
3921  }
3922
3923  /**
3924   * @return The identifier that is used to identify this version of the
3925   *         terminology capabilities when it is referenced in a specification,
3926   *         model, design or instance. This is an arbitrary value managed by the
3927   *         terminology capabilities author and is not expected to be globally
3928   *         unique. For example, it might be a timestamp (e.g. yyyymmdd) if a
3929   *         managed version is not available. There is also no expectation that
3930   *         versions can be placed in a lexicographical sequence.
3931   */
3932  public String getVersion() {
3933    return this.version == null ? null : this.version.getValue();
3934  }
3935
3936  /**
3937   * @param value The identifier that is used to identify this version of the
3938   *              terminology capabilities when it is referenced in a
3939   *              specification, model, design or instance. This is an arbitrary
3940   *              value managed by the terminology capabilities author and is not
3941   *              expected to be globally unique. For example, it might be a
3942   *              timestamp (e.g. yyyymmdd) if a managed version is not available.
3943   *              There is also no expectation that versions can be placed in a
3944   *              lexicographical sequence.
3945   */
3946  public TerminologyCapabilities setVersion(String value) {
3947    if (Utilities.noString(value))
3948      this.version = null;
3949    else {
3950      if (this.version == null)
3951        this.version = new StringType();
3952      this.version.setValue(value);
3953    }
3954    return this;
3955  }
3956
3957  /**
3958   * @return {@link #name} (A natural language name identifying the terminology
3959   *         capabilities. This name should be usable as an identifier for the
3960   *         module by machine processing applications such as code generation.).
3961   *         This is the underlying object with id, value and extensions. The
3962   *         accessor "getName" gives direct access to the value
3963   */
3964  public StringType getNameElement() {
3965    if (this.name == null)
3966      if (Configuration.errorOnAutoCreate())
3967        throw new Error("Attempt to auto-create TerminologyCapabilities.name");
3968      else if (Configuration.doAutoCreate())
3969        this.name = new StringType(); // bb
3970    return this.name;
3971  }
3972
3973  public boolean hasNameElement() {
3974    return this.name != null && !this.name.isEmpty();
3975  }
3976
3977  public boolean hasName() {
3978    return this.name != null && !this.name.isEmpty();
3979  }
3980
3981  /**
3982   * @param value {@link #name} (A natural language name identifying the
3983   *              terminology capabilities. This name should be usable as an
3984   *              identifier for the module by machine processing applications
3985   *              such as code generation.). This is the underlying object with
3986   *              id, value and extensions. The accessor "getName" gives direct
3987   *              access to the value
3988   */
3989  public TerminologyCapabilities setNameElement(StringType value) {
3990    this.name = value;
3991    return this;
3992  }
3993
3994  /**
3995   * @return A natural language name identifying the terminology capabilities.
3996   *         This name should be usable as an identifier for the module by machine
3997   *         processing applications such as code generation.
3998   */
3999  public String getName() {
4000    return this.name == null ? null : this.name.getValue();
4001  }
4002
4003  /**
4004   * @param value A natural language name identifying the terminology
4005   *              capabilities. This name should be usable as an identifier for
4006   *              the module by machine processing applications such as code
4007   *              generation.
4008   */
4009  public TerminologyCapabilities setName(String value) {
4010    if (Utilities.noString(value))
4011      this.name = null;
4012    else {
4013      if (this.name == null)
4014        this.name = new StringType();
4015      this.name.setValue(value);
4016    }
4017    return this;
4018  }
4019
4020  /**
4021   * @return {@link #title} (A short, descriptive, user-friendly title for the
4022   *         terminology capabilities.). This is the underlying object with id,
4023   *         value and extensions. The accessor "getTitle" gives direct access to
4024   *         the value
4025   */
4026  public StringType getTitleElement() {
4027    if (this.title == null)
4028      if (Configuration.errorOnAutoCreate())
4029        throw new Error("Attempt to auto-create TerminologyCapabilities.title");
4030      else if (Configuration.doAutoCreate())
4031        this.title = new StringType(); // bb
4032    return this.title;
4033  }
4034
4035  public boolean hasTitleElement() {
4036    return this.title != null && !this.title.isEmpty();
4037  }
4038
4039  public boolean hasTitle() {
4040    return this.title != null && !this.title.isEmpty();
4041  }
4042
4043  /**
4044   * @param value {@link #title} (A short, descriptive, user-friendly title for
4045   *              the terminology capabilities.). This is the underlying object
4046   *              with id, value and extensions. The accessor "getTitle" gives
4047   *              direct access to the value
4048   */
4049  public TerminologyCapabilities setTitleElement(StringType value) {
4050    this.title = value;
4051    return this;
4052  }
4053
4054  /**
4055   * @return A short, descriptive, user-friendly title for the terminology
4056   *         capabilities.
4057   */
4058  public String getTitle() {
4059    return this.title == null ? null : this.title.getValue();
4060  }
4061
4062  /**
4063   * @param value A short, descriptive, user-friendly title for the terminology
4064   *              capabilities.
4065   */
4066  public TerminologyCapabilities setTitle(String value) {
4067    if (Utilities.noString(value))
4068      this.title = null;
4069    else {
4070      if (this.title == null)
4071        this.title = new StringType();
4072      this.title.setValue(value);
4073    }
4074    return this;
4075  }
4076
4077  /**
4078   * @return {@link #status} (The status of this terminology capabilities. Enables
4079   *         tracking the life-cycle of the content.). This is the underlying
4080   *         object with id, value and extensions. The accessor "getStatus" gives
4081   *         direct access to the value
4082   */
4083  public Enumeration<PublicationStatus> getStatusElement() {
4084    if (this.status == null)
4085      if (Configuration.errorOnAutoCreate())
4086        throw new Error("Attempt to auto-create TerminologyCapabilities.status");
4087      else if (Configuration.doAutoCreate())
4088        this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb
4089    return this.status;
4090  }
4091
4092  public boolean hasStatusElement() {
4093    return this.status != null && !this.status.isEmpty();
4094  }
4095
4096  public boolean hasStatus() {
4097    return this.status != null && !this.status.isEmpty();
4098  }
4099
4100  /**
4101   * @param value {@link #status} (The status of this terminology capabilities.
4102   *              Enables tracking the life-cycle of the content.). This is the
4103   *              underlying object with id, value and extensions. The accessor
4104   *              "getStatus" gives direct access to the value
4105   */
4106  public TerminologyCapabilities setStatusElement(Enumeration<PublicationStatus> value) {
4107    this.status = value;
4108    return this;
4109  }
4110
4111  /**
4112   * @return The status of this terminology capabilities. Enables tracking the
4113   *         life-cycle of the content.
4114   */
4115  public PublicationStatus getStatus() {
4116    return this.status == null ? null : this.status.getValue();
4117  }
4118
4119  /**
4120   * @param value The status of this terminology capabilities. Enables tracking
4121   *              the life-cycle of the content.
4122   */
4123  public TerminologyCapabilities setStatus(PublicationStatus value) {
4124    if (this.status == null)
4125      this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory());
4126    this.status.setValue(value);
4127    return this;
4128  }
4129
4130  /**
4131   * @return {@link #experimental} (A Boolean value to indicate that this
4132   *         terminology capabilities is authored for testing purposes (or
4133   *         education/evaluation/marketing) and is not intended to be used for
4134   *         genuine usage.). This is the underlying object with id, value and
4135   *         extensions. The accessor "getExperimental" gives direct access to the
4136   *         value
4137   */
4138  public BooleanType getExperimentalElement() {
4139    if (this.experimental == null)
4140      if (Configuration.errorOnAutoCreate())
4141        throw new Error("Attempt to auto-create TerminologyCapabilities.experimental");
4142      else if (Configuration.doAutoCreate())
4143        this.experimental = new BooleanType(); // bb
4144    return this.experimental;
4145  }
4146
4147  public boolean hasExperimentalElement() {
4148    return this.experimental != null && !this.experimental.isEmpty();
4149  }
4150
4151  public boolean hasExperimental() {
4152    return this.experimental != null && !this.experimental.isEmpty();
4153  }
4154
4155  /**
4156   * @param value {@link #experimental} (A Boolean value to indicate that this
4157   *              terminology capabilities is authored for testing purposes (or
4158   *              education/evaluation/marketing) and is not intended to be used
4159   *              for genuine usage.). This is the underlying object with id,
4160   *              value and extensions. The accessor "getExperimental" gives
4161   *              direct access to the value
4162   */
4163  public TerminologyCapabilities setExperimentalElement(BooleanType value) {
4164    this.experimental = value;
4165    return this;
4166  }
4167
4168  /**
4169   * @return A Boolean value to indicate that this terminology capabilities is
4170   *         authored for testing purposes (or education/evaluation/marketing) and
4171   *         is not intended to be used for genuine usage.
4172   */
4173  public boolean getExperimental() {
4174    return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue();
4175  }
4176
4177  /**
4178   * @param value A Boolean value to indicate that this terminology capabilities
4179   *              is authored for testing purposes (or
4180   *              education/evaluation/marketing) and is not intended to be used
4181   *              for genuine usage.
4182   */
4183  public TerminologyCapabilities setExperimental(boolean value) {
4184    if (this.experimental == null)
4185      this.experimental = new BooleanType();
4186    this.experimental.setValue(value);
4187    return this;
4188  }
4189
4190  /**
4191   * @return {@link #date} (The date (and optionally time) when the terminology
4192   *         capabilities was published. The date must change when the business
4193   *         version changes and it must change if the status code changes. In
4194   *         addition, it should change when the substantive content of the
4195   *         terminology capabilities changes.). This is the underlying object
4196   *         with id, value and extensions. The accessor "getDate" gives direct
4197   *         access to the value
4198   */
4199  public DateTimeType getDateElement() {
4200    if (this.date == null)
4201      if (Configuration.errorOnAutoCreate())
4202        throw new Error("Attempt to auto-create TerminologyCapabilities.date");
4203      else if (Configuration.doAutoCreate())
4204        this.date = new DateTimeType(); // bb
4205    return this.date;
4206  }
4207
4208  public boolean hasDateElement() {
4209    return this.date != null && !this.date.isEmpty();
4210  }
4211
4212  public boolean hasDate() {
4213    return this.date != null && !this.date.isEmpty();
4214  }
4215
4216  /**
4217   * @param value {@link #date} (The date (and optionally time) when the
4218   *              terminology capabilities was published. The date must change
4219   *              when the business version changes and it must change if the
4220   *              status code changes. In addition, it should change when the
4221   *              substantive content of the terminology capabilities changes.).
4222   *              This is the underlying object with id, value and extensions. The
4223   *              accessor "getDate" gives direct access to the value
4224   */
4225  public TerminologyCapabilities setDateElement(DateTimeType value) {
4226    this.date = value;
4227    return this;
4228  }
4229
4230  /**
4231   * @return The date (and optionally time) when the terminology capabilities was
4232   *         published. The date must change when the business version changes and
4233   *         it must change if the status code changes. In addition, it should
4234   *         change when the substantive content of the terminology capabilities
4235   *         changes.
4236   */
4237  public Date getDate() {
4238    return this.date == null ? null : this.date.getValue();
4239  }
4240
4241  /**
4242   * @param value The date (and optionally time) when the terminology capabilities
4243   *              was published. The date must change when the business version
4244   *              changes and it must change if the status code changes. In
4245   *              addition, it should change when the substantive content of the
4246   *              terminology capabilities changes.
4247   */
4248  public TerminologyCapabilities setDate(Date value) {
4249    if (this.date == null)
4250      this.date = new DateTimeType();
4251    this.date.setValue(value);
4252    return this;
4253  }
4254
4255  /**
4256   * @return {@link #publisher} (The name of the organization or individual that
4257   *         published the terminology capabilities.). This is the underlying
4258   *         object with id, value and extensions. The accessor "getPublisher"
4259   *         gives direct access to the value
4260   */
4261  public StringType getPublisherElement() {
4262    if (this.publisher == null)
4263      if (Configuration.errorOnAutoCreate())
4264        throw new Error("Attempt to auto-create TerminologyCapabilities.publisher");
4265      else if (Configuration.doAutoCreate())
4266        this.publisher = new StringType(); // bb
4267    return this.publisher;
4268  }
4269
4270  public boolean hasPublisherElement() {
4271    return this.publisher != null && !this.publisher.isEmpty();
4272  }
4273
4274  public boolean hasPublisher() {
4275    return this.publisher != null && !this.publisher.isEmpty();
4276  }
4277
4278  /**
4279   * @param value {@link #publisher} (The name of the organization or individual
4280   *              that published the terminology capabilities.). This is the
4281   *              underlying object with id, value and extensions. The accessor
4282   *              "getPublisher" gives direct access to the value
4283   */
4284  public TerminologyCapabilities setPublisherElement(StringType value) {
4285    this.publisher = value;
4286    return this;
4287  }
4288
4289  /**
4290   * @return The name of the organization or individual that published the
4291   *         terminology capabilities.
4292   */
4293  public String getPublisher() {
4294    return this.publisher == null ? null : this.publisher.getValue();
4295  }
4296
4297  /**
4298   * @param value The name of the organization or individual that published the
4299   *              terminology capabilities.
4300   */
4301  public TerminologyCapabilities setPublisher(String value) {
4302    if (Utilities.noString(value))
4303      this.publisher = null;
4304    else {
4305      if (this.publisher == null)
4306        this.publisher = new StringType();
4307      this.publisher.setValue(value);
4308    }
4309    return this;
4310  }
4311
4312  /**
4313   * @return {@link #contact} (Contact details to assist a user in finding and
4314   *         communicating with the publisher.)
4315   */
4316  public List<ContactDetail> getContact() {
4317    if (this.contact == null)
4318      this.contact = new ArrayList<ContactDetail>();
4319    return this.contact;
4320  }
4321
4322  /**
4323   * @return Returns a reference to <code>this</code> for easy method chaining
4324   */
4325  public TerminologyCapabilities setContact(List<ContactDetail> theContact) {
4326    this.contact = theContact;
4327    return this;
4328  }
4329
4330  public boolean hasContact() {
4331    if (this.contact == null)
4332      return false;
4333    for (ContactDetail item : this.contact)
4334      if (!item.isEmpty())
4335        return true;
4336    return false;
4337  }
4338
4339  public ContactDetail addContact() { // 3
4340    ContactDetail t = new ContactDetail();
4341    if (this.contact == null)
4342      this.contact = new ArrayList<ContactDetail>();
4343    this.contact.add(t);
4344    return t;
4345  }
4346
4347  public TerminologyCapabilities addContact(ContactDetail t) { // 3
4348    if (t == null)
4349      return this;
4350    if (this.contact == null)
4351      this.contact = new ArrayList<ContactDetail>();
4352    this.contact.add(t);
4353    return this;
4354  }
4355
4356  /**
4357   * @return The first repetition of repeating field {@link #contact}, creating it
4358   *         if it does not already exist
4359   */
4360  public ContactDetail getContactFirstRep() {
4361    if (getContact().isEmpty()) {
4362      addContact();
4363    }
4364    return getContact().get(0);
4365  }
4366
4367  /**
4368   * @return {@link #description} (A free text natural language description of the
4369   *         terminology capabilities from a consumer's perspective. Typically,
4370   *         this is used when the capability statement describes a desired rather
4371   *         than an actual solution, for example as a formal expression of
4372   *         requirements as part of an RFP.). This is the underlying object with
4373   *         id, value and extensions. The accessor "getDescription" gives direct
4374   *         access to the value
4375   */
4376  public MarkdownType getDescriptionElement() {
4377    if (this.description == null)
4378      if (Configuration.errorOnAutoCreate())
4379        throw new Error("Attempt to auto-create TerminologyCapabilities.description");
4380      else if (Configuration.doAutoCreate())
4381        this.description = new MarkdownType(); // bb
4382    return this.description;
4383  }
4384
4385  public boolean hasDescriptionElement() {
4386    return this.description != null && !this.description.isEmpty();
4387  }
4388
4389  public boolean hasDescription() {
4390    return this.description != null && !this.description.isEmpty();
4391  }
4392
4393  /**
4394   * @param value {@link #description} (A free text natural language description
4395   *              of the terminology capabilities from a consumer's perspective.
4396   *              Typically, this is used when the capability statement describes
4397   *              a desired rather than an actual solution, for example as a
4398   *              formal expression of requirements as part of an RFP.). This is
4399   *              the underlying object with id, value and extensions. The
4400   *              accessor "getDescription" gives direct access to the value
4401   */
4402  public TerminologyCapabilities setDescriptionElement(MarkdownType value) {
4403    this.description = value;
4404    return this;
4405  }
4406
4407  /**
4408   * @return A free text natural language description of the terminology
4409   *         capabilities from a consumer's perspective. Typically, this is used
4410   *         when the capability statement describes a desired rather than an
4411   *         actual solution, for example as a formal expression of requirements
4412   *         as part of an RFP.
4413   */
4414  public String getDescription() {
4415    return this.description == null ? null : this.description.getValue();
4416  }
4417
4418  /**
4419   * @param value A free text natural language description of the terminology
4420   *              capabilities from a consumer's perspective. Typically, this is
4421   *              used when the capability statement describes a desired rather
4422   *              than an actual solution, for example as a formal expression of
4423   *              requirements as part of an RFP.
4424   */
4425  public TerminologyCapabilities setDescription(String value) {
4426    if (value == null)
4427      this.description = null;
4428    else {
4429      if (this.description == null)
4430        this.description = new MarkdownType();
4431      this.description.setValue(value);
4432    }
4433    return this;
4434  }
4435
4436  /**
4437   * @return {@link #useContext} (The content was developed with a focus and
4438   *         intent of supporting the contexts that are listed. These contexts may
4439   *         be general categories (gender, age, ...) or may be references to
4440   *         specific programs (insurance plans, studies, ...) and may be used to
4441   *         assist with indexing and searching for appropriate terminology
4442   *         capabilities instances.)
4443   */
4444  public List<UsageContext> getUseContext() {
4445    if (this.useContext == null)
4446      this.useContext = new ArrayList<UsageContext>();
4447    return this.useContext;
4448  }
4449
4450  /**
4451   * @return Returns a reference to <code>this</code> for easy method chaining
4452   */
4453  public TerminologyCapabilities setUseContext(List<UsageContext> theUseContext) {
4454    this.useContext = theUseContext;
4455    return this;
4456  }
4457
4458  public boolean hasUseContext() {
4459    if (this.useContext == null)
4460      return false;
4461    for (UsageContext item : this.useContext)
4462      if (!item.isEmpty())
4463        return true;
4464    return false;
4465  }
4466
4467  public UsageContext addUseContext() { // 3
4468    UsageContext t = new UsageContext();
4469    if (this.useContext == null)
4470      this.useContext = new ArrayList<UsageContext>();
4471    this.useContext.add(t);
4472    return t;
4473  }
4474
4475  public TerminologyCapabilities addUseContext(UsageContext t) { // 3
4476    if (t == null)
4477      return this;
4478    if (this.useContext == null)
4479      this.useContext = new ArrayList<UsageContext>();
4480    this.useContext.add(t);
4481    return this;
4482  }
4483
4484  /**
4485   * @return The first repetition of repeating field {@link #useContext}, creating
4486   *         it if it does not already exist
4487   */
4488  public UsageContext getUseContextFirstRep() {
4489    if (getUseContext().isEmpty()) {
4490      addUseContext();
4491    }
4492    return getUseContext().get(0);
4493  }
4494
4495  /**
4496   * @return {@link #jurisdiction} (A legal or geographic region in which the
4497   *         terminology capabilities is intended to be used.)
4498   */
4499  public List<CodeableConcept> getJurisdiction() {
4500    if (this.jurisdiction == null)
4501      this.jurisdiction = new ArrayList<CodeableConcept>();
4502    return this.jurisdiction;
4503  }
4504
4505  /**
4506   * @return Returns a reference to <code>this</code> for easy method chaining
4507   */
4508  public TerminologyCapabilities setJurisdiction(List<CodeableConcept> theJurisdiction) {
4509    this.jurisdiction = theJurisdiction;
4510    return this;
4511  }
4512
4513  public boolean hasJurisdiction() {
4514    if (this.jurisdiction == null)
4515      return false;
4516    for (CodeableConcept item : this.jurisdiction)
4517      if (!item.isEmpty())
4518        return true;
4519    return false;
4520  }
4521
4522  public CodeableConcept addJurisdiction() { // 3
4523    CodeableConcept t = new CodeableConcept();
4524    if (this.jurisdiction == null)
4525      this.jurisdiction = new ArrayList<CodeableConcept>();
4526    this.jurisdiction.add(t);
4527    return t;
4528  }
4529
4530  public TerminologyCapabilities addJurisdiction(CodeableConcept t) { // 3
4531    if (t == null)
4532      return this;
4533    if (this.jurisdiction == null)
4534      this.jurisdiction = new ArrayList<CodeableConcept>();
4535    this.jurisdiction.add(t);
4536    return this;
4537  }
4538
4539  /**
4540   * @return The first repetition of repeating field {@link #jurisdiction},
4541   *         creating it if it does not already exist
4542   */
4543  public CodeableConcept getJurisdictionFirstRep() {
4544    if (getJurisdiction().isEmpty()) {
4545      addJurisdiction();
4546    }
4547    return getJurisdiction().get(0);
4548  }
4549
4550  /**
4551   * @return {@link #purpose} (Explanation of why this terminology capabilities is
4552   *         needed and why it has been designed as it has.). This is the
4553   *         underlying object with id, value and extensions. The accessor
4554   *         "getPurpose" gives direct access to the value
4555   */
4556  public MarkdownType getPurposeElement() {
4557    if (this.purpose == null)
4558      if (Configuration.errorOnAutoCreate())
4559        throw new Error("Attempt to auto-create TerminologyCapabilities.purpose");
4560      else if (Configuration.doAutoCreate())
4561        this.purpose = new MarkdownType(); // bb
4562    return this.purpose;
4563  }
4564
4565  public boolean hasPurposeElement() {
4566    return this.purpose != null && !this.purpose.isEmpty();
4567  }
4568
4569  public boolean hasPurpose() {
4570    return this.purpose != null && !this.purpose.isEmpty();
4571  }
4572
4573  /**
4574   * @param value {@link #purpose} (Explanation of why this terminology
4575   *              capabilities is needed and why it has been designed as it has.).
4576   *              This is the underlying object with id, value and extensions. The
4577   *              accessor "getPurpose" gives direct access to the value
4578   */
4579  public TerminologyCapabilities setPurposeElement(MarkdownType value) {
4580    this.purpose = value;
4581    return this;
4582  }
4583
4584  /**
4585   * @return Explanation of why this terminology capabilities is needed and why it
4586   *         has been designed as it has.
4587   */
4588  public String getPurpose() {
4589    return this.purpose == null ? null : this.purpose.getValue();
4590  }
4591
4592  /**
4593   * @param value Explanation of why this terminology capabilities is needed and
4594   *              why it has been designed as it has.
4595   */
4596  public TerminologyCapabilities setPurpose(String value) {
4597    if (value == null)
4598      this.purpose = null;
4599    else {
4600      if (this.purpose == null)
4601        this.purpose = new MarkdownType();
4602      this.purpose.setValue(value);
4603    }
4604    return this;
4605  }
4606
4607  /**
4608   * @return {@link #copyright} (A copyright statement relating to the terminology
4609   *         capabilities and/or its contents. Copyright statements are generally
4610   *         legal restrictions on the use and publishing of the terminology
4611   *         capabilities.). This is the underlying object with id, value and
4612   *         extensions. The accessor "getCopyright" gives direct access to the
4613   *         value
4614   */
4615  public MarkdownType getCopyrightElement() {
4616    if (this.copyright == null)
4617      if (Configuration.errorOnAutoCreate())
4618        throw new Error("Attempt to auto-create TerminologyCapabilities.copyright");
4619      else if (Configuration.doAutoCreate())
4620        this.copyright = new MarkdownType(); // bb
4621    return this.copyright;
4622  }
4623
4624  public boolean hasCopyrightElement() {
4625    return this.copyright != null && !this.copyright.isEmpty();
4626  }
4627
4628  public boolean hasCopyright() {
4629    return this.copyright != null && !this.copyright.isEmpty();
4630  }
4631
4632  /**
4633   * @param value {@link #copyright} (A copyright statement relating to the
4634   *              terminology capabilities and/or its contents. Copyright
4635   *              statements are generally legal restrictions on the use and
4636   *              publishing of the terminology capabilities.). This is the
4637   *              underlying object with id, value and extensions. The accessor
4638   *              "getCopyright" gives direct access to the value
4639   */
4640  public TerminologyCapabilities setCopyrightElement(MarkdownType value) {
4641    this.copyright = value;
4642    return this;
4643  }
4644
4645  /**
4646   * @return A copyright statement relating to the terminology capabilities and/or
4647   *         its contents. Copyright statements are generally legal restrictions
4648   *         on the use and publishing of the terminology capabilities.
4649   */
4650  public String getCopyright() {
4651    return this.copyright == null ? null : this.copyright.getValue();
4652  }
4653
4654  /**
4655   * @param value A copyright statement relating to the terminology capabilities
4656   *              and/or its contents. Copyright statements are generally legal
4657   *              restrictions on the use and publishing of the terminology
4658   *              capabilities.
4659   */
4660  public TerminologyCapabilities setCopyright(String value) {
4661    if (value == null)
4662      this.copyright = null;
4663    else {
4664      if (this.copyright == null)
4665        this.copyright = new MarkdownType();
4666      this.copyright.setValue(value);
4667    }
4668    return this;
4669  }
4670
4671  /**
4672   * @return {@link #kind} (The way that this statement is intended to be used, to
4673   *         describe an actual running instance of software, a particular product
4674   *         (kind, not instance of software) or a class of implementation (e.g. a
4675   *         desired purchase).). This is the underlying object with id, value and
4676   *         extensions. The accessor "getKind" gives direct access to the value
4677   */
4678  public Enumeration<CapabilityStatementKind> getKindElement() {
4679    if (this.kind == null)
4680      if (Configuration.errorOnAutoCreate())
4681        throw new Error("Attempt to auto-create TerminologyCapabilities.kind");
4682      else if (Configuration.doAutoCreate())
4683        this.kind = new Enumeration<CapabilityStatementKind>(new CapabilityStatementKindEnumFactory()); // bb
4684    return this.kind;
4685  }
4686
4687  public boolean hasKindElement() {
4688    return this.kind != null && !this.kind.isEmpty();
4689  }
4690
4691  public boolean hasKind() {
4692    return this.kind != null && !this.kind.isEmpty();
4693  }
4694
4695  /**
4696   * @param value {@link #kind} (The way that this statement is intended to be
4697   *              used, to describe an actual running instance of software, a
4698   *              particular product (kind, not instance of software) or a class
4699   *              of implementation (e.g. a desired purchase).). This is the
4700   *              underlying object with id, value and extensions. The accessor
4701   *              "getKind" gives direct access to the value
4702   */
4703  public TerminologyCapabilities setKindElement(Enumeration<CapabilityStatementKind> value) {
4704    this.kind = value;
4705    return this;
4706  }
4707
4708  /**
4709   * @return The way that this statement is intended to be used, to describe an
4710   *         actual running instance of software, a particular product (kind, not
4711   *         instance of software) or a class of implementation (e.g. a desired
4712   *         purchase).
4713   */
4714  public CapabilityStatementKind getKind() {
4715    return this.kind == null ? null : this.kind.getValue();
4716  }
4717
4718  /**
4719   * @param value The way that this statement is intended to be used, to describe
4720   *              an actual running instance of software, a particular product
4721   *              (kind, not instance of software) or a class of implementation
4722   *              (e.g. a desired purchase).
4723   */
4724  public TerminologyCapabilities setKind(CapabilityStatementKind value) {
4725    if (this.kind == null)
4726      this.kind = new Enumeration<CapabilityStatementKind>(new CapabilityStatementKindEnumFactory());
4727    this.kind.setValue(value);
4728    return this;
4729  }
4730
4731  /**
4732   * @return {@link #software} (Software that is covered by this terminology
4733   *         capability statement. It is used when the statement describes the
4734   *         capabilities of a particular software version, independent of an
4735   *         installation.)
4736   */
4737  public TerminologyCapabilitiesSoftwareComponent getSoftware() {
4738    if (this.software == null)
4739      if (Configuration.errorOnAutoCreate())
4740        throw new Error("Attempt to auto-create TerminologyCapabilities.software");
4741      else if (Configuration.doAutoCreate())
4742        this.software = new TerminologyCapabilitiesSoftwareComponent(); // cc
4743    return this.software;
4744  }
4745
4746  public boolean hasSoftware() {
4747    return this.software != null && !this.software.isEmpty();
4748  }
4749
4750  /**
4751   * @param value {@link #software} (Software that is covered by this terminology
4752   *              capability statement. It is used when the statement describes
4753   *              the capabilities of a particular software version, independent
4754   *              of an installation.)
4755   */
4756  public TerminologyCapabilities setSoftware(TerminologyCapabilitiesSoftwareComponent value) {
4757    this.software = value;
4758    return this;
4759  }
4760
4761  /**
4762   * @return {@link #implementation} (Identifies a specific implementation
4763   *         instance that is described by the terminology capability statement -
4764   *         i.e. a particular installation, rather than the capabilities of a
4765   *         software program.)
4766   */
4767  public TerminologyCapabilitiesImplementationComponent getImplementation() {
4768    if (this.implementation == null)
4769      if (Configuration.errorOnAutoCreate())
4770        throw new Error("Attempt to auto-create TerminologyCapabilities.implementation");
4771      else if (Configuration.doAutoCreate())
4772        this.implementation = new TerminologyCapabilitiesImplementationComponent(); // cc
4773    return this.implementation;
4774  }
4775
4776  public boolean hasImplementation() {
4777    return this.implementation != null && !this.implementation.isEmpty();
4778  }
4779
4780  /**
4781   * @param value {@link #implementation} (Identifies a specific implementation
4782   *              instance that is described by the terminology capability
4783   *              statement - i.e. a particular installation, rather than the
4784   *              capabilities of a software program.)
4785   */
4786  public TerminologyCapabilities setImplementation(TerminologyCapabilitiesImplementationComponent value) {
4787    this.implementation = value;
4788    return this;
4789  }
4790
4791  /**
4792   * @return {@link #lockedDate} (Whether the server supports lockedDate.). This
4793   *         is the underlying object with id, value and extensions. The accessor
4794   *         "getLockedDate" gives direct access to the value
4795   */
4796  public BooleanType getLockedDateElement() {
4797    if (this.lockedDate == null)
4798      if (Configuration.errorOnAutoCreate())
4799        throw new Error("Attempt to auto-create TerminologyCapabilities.lockedDate");
4800      else if (Configuration.doAutoCreate())
4801        this.lockedDate = new BooleanType(); // bb
4802    return this.lockedDate;
4803  }
4804
4805  public boolean hasLockedDateElement() {
4806    return this.lockedDate != null && !this.lockedDate.isEmpty();
4807  }
4808
4809  public boolean hasLockedDate() {
4810    return this.lockedDate != null && !this.lockedDate.isEmpty();
4811  }
4812
4813  /**
4814   * @param value {@link #lockedDate} (Whether the server supports lockedDate.).
4815   *              This is the underlying object with id, value and extensions. The
4816   *              accessor "getLockedDate" gives direct access to the value
4817   */
4818  public TerminologyCapabilities setLockedDateElement(BooleanType value) {
4819    this.lockedDate = value;
4820    return this;
4821  }
4822
4823  /**
4824   * @return Whether the server supports lockedDate.
4825   */
4826  public boolean getLockedDate() {
4827    return this.lockedDate == null || this.lockedDate.isEmpty() ? false : this.lockedDate.getValue();
4828  }
4829
4830  /**
4831   * @param value Whether the server supports lockedDate.
4832   */
4833  public TerminologyCapabilities setLockedDate(boolean value) {
4834    if (this.lockedDate == null)
4835      this.lockedDate = new BooleanType();
4836    this.lockedDate.setValue(value);
4837    return this;
4838  }
4839
4840  /**
4841   * @return {@link #codeSystem} (Identifies a code system that is supported by
4842   *         the server. If there is a no code system URL, then this declares the
4843   *         general assumptions a client can make about support for any
4844   *         CodeSystem resource.)
4845   */
4846  public List<TerminologyCapabilitiesCodeSystemComponent> getCodeSystem() {
4847    if (this.codeSystem == null)
4848      this.codeSystem = new ArrayList<TerminologyCapabilitiesCodeSystemComponent>();
4849    return this.codeSystem;
4850  }
4851
4852  /**
4853   * @return Returns a reference to <code>this</code> for easy method chaining
4854   */
4855  public TerminologyCapabilities setCodeSystem(List<TerminologyCapabilitiesCodeSystemComponent> theCodeSystem) {
4856    this.codeSystem = theCodeSystem;
4857    return this;
4858  }
4859
4860  public boolean hasCodeSystem() {
4861    if (this.codeSystem == null)
4862      return false;
4863    for (TerminologyCapabilitiesCodeSystemComponent item : this.codeSystem)
4864      if (!item.isEmpty())
4865        return true;
4866    return false;
4867  }
4868
4869  public TerminologyCapabilitiesCodeSystemComponent addCodeSystem() { // 3
4870    TerminologyCapabilitiesCodeSystemComponent t = new TerminologyCapabilitiesCodeSystemComponent();
4871    if (this.codeSystem == null)
4872      this.codeSystem = new ArrayList<TerminologyCapabilitiesCodeSystemComponent>();
4873    this.codeSystem.add(t);
4874    return t;
4875  }
4876
4877  public TerminologyCapabilities addCodeSystem(TerminologyCapabilitiesCodeSystemComponent t) { // 3
4878    if (t == null)
4879      return this;
4880    if (this.codeSystem == null)
4881      this.codeSystem = new ArrayList<TerminologyCapabilitiesCodeSystemComponent>();
4882    this.codeSystem.add(t);
4883    return this;
4884  }
4885
4886  /**
4887   * @return The first repetition of repeating field {@link #codeSystem}, creating
4888   *         it if it does not already exist
4889   */
4890  public TerminologyCapabilitiesCodeSystemComponent getCodeSystemFirstRep() {
4891    if (getCodeSystem().isEmpty()) {
4892      addCodeSystem();
4893    }
4894    return getCodeSystem().get(0);
4895  }
4896
4897  /**
4898   * @return {@link #expansion} (Information about the
4899   *         [ValueSet/$expand](valueset-operation-expand.html) operation.)
4900   */
4901  public TerminologyCapabilitiesExpansionComponent getExpansion() {
4902    if (this.expansion == null)
4903      if (Configuration.errorOnAutoCreate())
4904        throw new Error("Attempt to auto-create TerminologyCapabilities.expansion");
4905      else if (Configuration.doAutoCreate())
4906        this.expansion = new TerminologyCapabilitiesExpansionComponent(); // cc
4907    return this.expansion;
4908  }
4909
4910  public boolean hasExpansion() {
4911    return this.expansion != null && !this.expansion.isEmpty();
4912  }
4913
4914  /**
4915   * @param value {@link #expansion} (Information about the
4916   *              [ValueSet/$expand](valueset-operation-expand.html) operation.)
4917   */
4918  public TerminologyCapabilities setExpansion(TerminologyCapabilitiesExpansionComponent value) {
4919    this.expansion = value;
4920    return this;
4921  }
4922
4923  /**
4924   * @return {@link #codeSearch} (The degree to which the server supports the code
4925   *         search parameter on ValueSet, if it is supported.). This is the
4926   *         underlying object with id, value and extensions. The accessor
4927   *         "getCodeSearch" gives direct access to the value
4928   */
4929  public Enumeration<CodeSearchSupport> getCodeSearchElement() {
4930    if (this.codeSearch == null)
4931      if (Configuration.errorOnAutoCreate())
4932        throw new Error("Attempt to auto-create TerminologyCapabilities.codeSearch");
4933      else if (Configuration.doAutoCreate())
4934        this.codeSearch = new Enumeration<CodeSearchSupport>(new CodeSearchSupportEnumFactory()); // bb
4935    return this.codeSearch;
4936  }
4937
4938  public boolean hasCodeSearchElement() {
4939    return this.codeSearch != null && !this.codeSearch.isEmpty();
4940  }
4941
4942  public boolean hasCodeSearch() {
4943    return this.codeSearch != null && !this.codeSearch.isEmpty();
4944  }
4945
4946  /**
4947   * @param value {@link #codeSearch} (The degree to which the server supports the
4948   *              code search parameter on ValueSet, if it is supported.). This is
4949   *              the underlying object with id, value and extensions. The
4950   *              accessor "getCodeSearch" gives direct access to the value
4951   */
4952  public TerminologyCapabilities setCodeSearchElement(Enumeration<CodeSearchSupport> value) {
4953    this.codeSearch = value;
4954    return this;
4955  }
4956
4957  /**
4958   * @return The degree to which the server supports the code search parameter on
4959   *         ValueSet, if it is supported.
4960   */
4961  public CodeSearchSupport getCodeSearch() {
4962    return this.codeSearch == null ? null : this.codeSearch.getValue();
4963  }
4964
4965  /**
4966   * @param value The degree to which the server supports the code search
4967   *              parameter on ValueSet, if it is supported.
4968   */
4969  public TerminologyCapabilities setCodeSearch(CodeSearchSupport value) {
4970    if (value == null)
4971      this.codeSearch = null;
4972    else {
4973      if (this.codeSearch == null)
4974        this.codeSearch = new Enumeration<CodeSearchSupport>(new CodeSearchSupportEnumFactory());
4975      this.codeSearch.setValue(value);
4976    }
4977    return this;
4978  }
4979
4980  /**
4981   * @return {@link #validateCode} (Information about the
4982   *         [ValueSet/$validate-code](valueset-operation-validate-code.html)
4983   *         operation.)
4984   */
4985  public TerminologyCapabilitiesValidateCodeComponent getValidateCode() {
4986    if (this.validateCode == null)
4987      if (Configuration.errorOnAutoCreate())
4988        throw new Error("Attempt to auto-create TerminologyCapabilities.validateCode");
4989      else if (Configuration.doAutoCreate())
4990        this.validateCode = new TerminologyCapabilitiesValidateCodeComponent(); // cc
4991    return this.validateCode;
4992  }
4993
4994  public boolean hasValidateCode() {
4995    return this.validateCode != null && !this.validateCode.isEmpty();
4996  }
4997
4998  /**
4999   * @param value {@link #validateCode} (Information about the
5000   *              [ValueSet/$validate-code](valueset-operation-validate-code.html)
5001   *              operation.)
5002   */
5003  public TerminologyCapabilities setValidateCode(TerminologyCapabilitiesValidateCodeComponent value) {
5004    this.validateCode = value;
5005    return this;
5006  }
5007
5008  /**
5009   * @return {@link #translation} (Information about the
5010   *         [ConceptMap/$translate](conceptmap-operation-translate.html)
5011   *         operation.)
5012   */
5013  public TerminologyCapabilitiesTranslationComponent getTranslation() {
5014    if (this.translation == null)
5015      if (Configuration.errorOnAutoCreate())
5016        throw new Error("Attempt to auto-create TerminologyCapabilities.translation");
5017      else if (Configuration.doAutoCreate())
5018        this.translation = new TerminologyCapabilitiesTranslationComponent(); // cc
5019    return this.translation;
5020  }
5021
5022  public boolean hasTranslation() {
5023    return this.translation != null && !this.translation.isEmpty();
5024  }
5025
5026  /**
5027   * @param value {@link #translation} (Information about the
5028   *              [ConceptMap/$translate](conceptmap-operation-translate.html)
5029   *              operation.)
5030   */
5031  public TerminologyCapabilities setTranslation(TerminologyCapabilitiesTranslationComponent value) {
5032    this.translation = value;
5033    return this;
5034  }
5035
5036  /**
5037   * @return {@link #closure} (Whether the $closure operation is supported.)
5038   */
5039  public TerminologyCapabilitiesClosureComponent getClosure() {
5040    if (this.closure == null)
5041      if (Configuration.errorOnAutoCreate())
5042        throw new Error("Attempt to auto-create TerminologyCapabilities.closure");
5043      else if (Configuration.doAutoCreate())
5044        this.closure = new TerminologyCapabilitiesClosureComponent(); // cc
5045    return this.closure;
5046  }
5047
5048  public boolean hasClosure() {
5049    return this.closure != null && !this.closure.isEmpty();
5050  }
5051
5052  /**
5053   * @param value {@link #closure} (Whether the $closure operation is supported.)
5054   */
5055  public TerminologyCapabilities setClosure(TerminologyCapabilitiesClosureComponent value) {
5056    this.closure = value;
5057    return this;
5058  }
5059
5060  protected void listChildren(List<Property> children) {
5061    super.listChildren(children);
5062    children.add(new Property("url", "uri",
5063        "An absolute URI that is used to identify this terminology capabilities 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 terminology capabilities is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the terminology capabilities is stored on different servers.",
5064        0, 1, url));
5065    children.add(new Property("version", "string",
5066        "The identifier that is used to identify this version of the terminology capabilities when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the terminology capabilities 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.",
5067        0, 1, version));
5068    children.add(new Property("name", "string",
5069        "A natural language name identifying the terminology capabilities. This name should be usable as an identifier for the module by machine processing applications such as code generation.",
5070        0, 1, name));
5071    children.add(new Property("title", "string",
5072        "A short, descriptive, user-friendly title for the terminology capabilities.", 0, 1, title));
5073    children.add(new Property("status", "code",
5074        "The status of this terminology capabilities. Enables tracking the life-cycle of the content.", 0, 1, status));
5075    children.add(new Property("experimental", "boolean",
5076        "A Boolean value to indicate that this terminology capabilities is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.",
5077        0, 1, experimental));
5078    children.add(new Property("date", "dateTime",
5079        "The date  (and optionally time) when the terminology capabilities 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 terminology capabilities changes.",
5080        0, 1, date));
5081    children.add(new Property("publisher", "string",
5082        "The name of the organization or individual that published the terminology capabilities.", 0, 1, publisher));
5083    children.add(new Property("contact", "ContactDetail",
5084        "Contact details to assist a user in finding and communicating with the publisher.", 0,
5085        java.lang.Integer.MAX_VALUE, contact));
5086    children.add(new Property("description", "markdown",
5087        "A free text natural language description of the terminology capabilities from a consumer's perspective. Typically, this is used when the capability statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP.",
5088        0, 1, description));
5089    children.add(new Property("useContext", "UsageContext",
5090        "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 terminology capabilities instances.",
5091        0, java.lang.Integer.MAX_VALUE, useContext));
5092    children.add(new Property("jurisdiction", "CodeableConcept",
5093        "A legal or geographic region in which the terminology capabilities is intended to be used.", 0,
5094        java.lang.Integer.MAX_VALUE, jurisdiction));
5095    children.add(new Property("purpose", "markdown",
5096        "Explanation of why this terminology capabilities is needed and why it has been designed as it has.", 0, 1,
5097        purpose));
5098    children.add(new Property("copyright", "markdown",
5099        "A copyright statement relating to the terminology capabilities and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the terminology capabilities.",
5100        0, 1, copyright));
5101    children.add(new Property("kind", "code",
5102        "The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind, not instance of software) or a class of implementation (e.g. a desired purchase).",
5103        0, 1, kind));
5104    children.add(new Property("software", "",
5105        "Software that is covered by this terminology capability statement.  It is used when the statement describes the capabilities of a particular software version, independent of an installation.",
5106        0, 1, software));
5107    children.add(new Property("implementation", "",
5108        "Identifies a specific implementation instance that is described by the terminology capability statement - i.e. a particular installation, rather than the capabilities of a software program.",
5109        0, 1, implementation));
5110    children.add(new Property("lockedDate", "boolean", "Whether the server supports lockedDate.", 0, 1, lockedDate));
5111    children.add(new Property("codeSystem", "",
5112        "Identifies a code system that is supported by the server. If there is a no code system URL, then this declares the general assumptions a client can make about support for any CodeSystem resource.",
5113        0, java.lang.Integer.MAX_VALUE, codeSystem));
5114    children.add(new Property("expansion", "",
5115        "Information about the [ValueSet/$expand](valueset-operation-expand.html) operation.", 0, 1, expansion));
5116    children.add(new Property("codeSearch", "code",
5117        "The degree to which the server supports the code search parameter on ValueSet, if it is supported.", 0, 1,
5118        codeSearch));
5119    children.add(new Property("validateCode", "",
5120        "Information about the [ValueSet/$validate-code](valueset-operation-validate-code.html) operation.", 0, 1,
5121        validateCode));
5122    children.add(new Property("translation", "",
5123        "Information about the [ConceptMap/$translate](conceptmap-operation-translate.html) operation.", 0, 1,
5124        translation));
5125    children.add(new Property("closure", "", "Whether the $closure operation is supported.", 0, 1, closure));
5126  }
5127
5128  @Override
5129  public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException {
5130    switch (_hash) {
5131    case 116079:
5132      /* url */ return new Property("url", "uri",
5133          "An absolute URI that is used to identify this terminology capabilities 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 terminology capabilities is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the terminology capabilities is stored on different servers.",
5134          0, 1, url);
5135    case 351608024:
5136      /* version */ return new Property("version", "string",
5137          "The identifier that is used to identify this version of the terminology capabilities when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the terminology capabilities 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.",
5138          0, 1, version);
5139    case 3373707:
5140      /* name */ return new Property("name", "string",
5141          "A natural language name identifying the terminology capabilities. This name should be usable as an identifier for the module by machine processing applications such as code generation.",
5142          0, 1, name);
5143    case 110371416:
5144      /* title */ return new Property("title", "string",
5145          "A short, descriptive, user-friendly title for the terminology capabilities.", 0, 1, title);
5146    case -892481550:
5147      /* status */ return new Property("status", "code",
5148          "The status of this terminology capabilities. Enables tracking the life-cycle of the content.", 0, 1, status);
5149    case -404562712:
5150      /* experimental */ return new Property("experimental", "boolean",
5151          "A Boolean value to indicate that this terminology capabilities is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.",
5152          0, 1, experimental);
5153    case 3076014:
5154      /* date */ return new Property("date", "dateTime",
5155          "The date  (and optionally time) when the terminology capabilities 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 terminology capabilities changes.",
5156          0, 1, date);
5157    case 1447404028:
5158      /* publisher */ return new Property("publisher", "string",
5159          "The name of the organization or individual that published the terminology capabilities.", 0, 1, publisher);
5160    case 951526432:
5161      /* contact */ return new Property("contact", "ContactDetail",
5162          "Contact details to assist a user in finding and communicating with the publisher.", 0,
5163          java.lang.Integer.MAX_VALUE, contact);
5164    case -1724546052:
5165      /* description */ return new Property("description", "markdown",
5166          "A free text natural language description of the terminology capabilities from a consumer's perspective. Typically, this is used when the capability statement describes a desired rather than an actual solution, for example as a formal expression of requirements as part of an RFP.",
5167          0, 1, description);
5168    case -669707736:
5169      /* useContext */ return new Property("useContext", "UsageContext",
5170          "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 terminology capabilities instances.",
5171          0, java.lang.Integer.MAX_VALUE, useContext);
5172    case -507075711:
5173      /* jurisdiction */ return new Property("jurisdiction", "CodeableConcept",
5174          "A legal or geographic region in which the terminology capabilities is intended to be used.", 0,
5175          java.lang.Integer.MAX_VALUE, jurisdiction);
5176    case -220463842:
5177      /* purpose */ return new Property("purpose", "markdown",
5178          "Explanation of why this terminology capabilities is needed and why it has been designed as it has.", 0, 1,
5179          purpose);
5180    case 1522889671:
5181      /* copyright */ return new Property("copyright", "markdown",
5182          "A copyright statement relating to the terminology capabilities and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the terminology capabilities.",
5183          0, 1, copyright);
5184    case 3292052:
5185      /* kind */ return new Property("kind", "code",
5186          "The way that this statement is intended to be used, to describe an actual running instance of software, a particular product (kind, not instance of software) or a class of implementation (e.g. a desired purchase).",
5187          0, 1, kind);
5188    case 1319330215:
5189      /* software */ return new Property("software", "",
5190          "Software that is covered by this terminology capability statement.  It is used when the statement describes the capabilities of a particular software version, independent of an installation.",
5191          0, 1, software);
5192    case 1683336114:
5193      /* implementation */ return new Property("implementation", "",
5194          "Identifies a specific implementation instance that is described by the terminology capability statement - i.e. a particular installation, rather than the capabilities of a software program.",
5195          0, 1, implementation);
5196    case 1391591896:
5197      /* lockedDate */ return new Property("lockedDate", "boolean", "Whether the server supports lockedDate.", 0, 1,
5198          lockedDate);
5199    case -916511108:
5200      /* codeSystem */ return new Property("codeSystem", "",
5201          "Identifies a code system that is supported by the server. If there is a no code system URL, then this declares the general assumptions a client can make about support for any CodeSystem resource.",
5202          0, java.lang.Integer.MAX_VALUE, codeSystem);
5203    case 17878207:
5204      /* expansion */ return new Property("expansion", "",
5205          "Information about the [ValueSet/$expand](valueset-operation-expand.html) operation.", 0, 1, expansion);
5206    case -935519755:
5207      /* codeSearch */ return new Property("codeSearch", "code",
5208          "The degree to which the server supports the code search parameter on ValueSet, if it is supported.", 0, 1,
5209          codeSearch);
5210    case 1080737827:
5211      /* validateCode */ return new Property("validateCode", "",
5212          "Information about the [ValueSet/$validate-code](valueset-operation-validate-code.html) operation.", 0, 1,
5213          validateCode);
5214    case -1840647503:
5215      /* translation */ return new Property("translation", "",
5216          "Information about the [ConceptMap/$translate](conceptmap-operation-translate.html) operation.", 0, 1,
5217          translation);
5218    case 866552379:
5219      /* closure */ return new Property("closure", "", "Whether the $closure operation is supported.", 0, 1, closure);
5220    default:
5221      return super.getNamedProperty(_hash, _name, _checkValid);
5222    }
5223
5224  }
5225
5226  @Override
5227  public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException {
5228    switch (hash) {
5229    case 116079:
5230      /* url */ return this.url == null ? new Base[0] : new Base[] { this.url }; // UriType
5231    case 351608024:
5232      /* version */ return this.version == null ? new Base[0] : new Base[] { this.version }; // StringType
5233    case 3373707:
5234      /* name */ return this.name == null ? new Base[0] : new Base[] { this.name }; // StringType
5235    case 110371416:
5236      /* title */ return this.title == null ? new Base[0] : new Base[] { this.title }; // StringType
5237    case -892481550:
5238      /* status */ return this.status == null ? new Base[0] : new Base[] { this.status }; // Enumeration<PublicationStatus>
5239    case -404562712:
5240      /* experimental */ return this.experimental == null ? new Base[0] : new Base[] { this.experimental }; // BooleanType
5241    case 3076014:
5242      /* date */ return this.date == null ? new Base[0] : new Base[] { this.date }; // DateTimeType
5243    case 1447404028:
5244      /* publisher */ return this.publisher == null ? new Base[0] : new Base[] { this.publisher }; // StringType
5245    case 951526432:
5246      /* contact */ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail
5247    case -1724546052:
5248      /* description */ return this.description == null ? new Base[0] : new Base[] { this.description }; // MarkdownType
5249    case -669707736:
5250      /* useContext */ return this.useContext == null ? new Base[0]
5251          : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext
5252    case -507075711:
5253      /* jurisdiction */ return this.jurisdiction == null ? new Base[0]
5254          : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept
5255    case -220463842:
5256      /* purpose */ return this.purpose == null ? new Base[0] : new Base[] { this.purpose }; // MarkdownType
5257    case 1522889671:
5258      /* copyright */ return this.copyright == null ? new Base[0] : new Base[] { this.copyright }; // MarkdownType
5259    case 3292052:
5260      /* kind */ return this.kind == null ? new Base[0] : new Base[] { this.kind }; // Enumeration<CapabilityStatementKind>
5261    case 1319330215:
5262      /* software */ return this.software == null ? new Base[0] : new Base[] { this.software }; // TerminologyCapabilitiesSoftwareComponent
5263    case 1683336114:
5264      /* implementation */ return this.implementation == null ? new Base[0] : new Base[] { this.implementation }; // TerminologyCapabilitiesImplementationComponent
5265    case 1391591896:
5266      /* lockedDate */ return this.lockedDate == null ? new Base[0] : new Base[] { this.lockedDate }; // BooleanType
5267    case -916511108:
5268      /* codeSystem */ return this.codeSystem == null ? new Base[0]
5269          : this.codeSystem.toArray(new Base[this.codeSystem.size()]); // TerminologyCapabilitiesCodeSystemComponent
5270    case 17878207:
5271      /* expansion */ return this.expansion == null ? new Base[0] : new Base[] { this.expansion }; // TerminologyCapabilitiesExpansionComponent
5272    case -935519755:
5273      /* codeSearch */ return this.codeSearch == null ? new Base[0] : new Base[] { this.codeSearch }; // Enumeration<CodeSearchSupport>
5274    case 1080737827:
5275      /* validateCode */ return this.validateCode == null ? new Base[0] : new Base[] { this.validateCode }; // TerminologyCapabilitiesValidateCodeComponent
5276    case -1840647503:
5277      /* translation */ return this.translation == null ? new Base[0] : new Base[] { this.translation }; // TerminologyCapabilitiesTranslationComponent
5278    case 866552379:
5279      /* closure */ return this.closure == null ? new Base[0] : new Base[] { this.closure }; // TerminologyCapabilitiesClosureComponent
5280    default:
5281      return super.getProperty(hash, name, checkValid);
5282    }
5283
5284  }
5285
5286  @Override
5287  public Base setProperty(int hash, String name, Base value) throws FHIRException {
5288    switch (hash) {
5289    case 116079: // url
5290      this.url = castToUri(value); // UriType
5291      return value;
5292    case 351608024: // version
5293      this.version = castToString(value); // StringType
5294      return value;
5295    case 3373707: // name
5296      this.name = castToString(value); // StringType
5297      return value;
5298    case 110371416: // title
5299      this.title = castToString(value); // StringType
5300      return value;
5301    case -892481550: // status
5302      value = new PublicationStatusEnumFactory().fromType(castToCode(value));
5303      this.status = (Enumeration) value; // Enumeration<PublicationStatus>
5304      return value;
5305    case -404562712: // experimental
5306      this.experimental = castToBoolean(value); // BooleanType
5307      return value;
5308    case 3076014: // date
5309      this.date = castToDateTime(value); // DateTimeType
5310      return value;
5311    case 1447404028: // publisher
5312      this.publisher = castToString(value); // StringType
5313      return value;
5314    case 951526432: // contact
5315      this.getContact().add(castToContactDetail(value)); // ContactDetail
5316      return value;
5317    case -1724546052: // description
5318      this.description = castToMarkdown(value); // MarkdownType
5319      return value;
5320    case -669707736: // useContext
5321      this.getUseContext().add(castToUsageContext(value)); // UsageContext
5322      return value;
5323    case -507075711: // jurisdiction
5324      this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept
5325      return value;
5326    case -220463842: // purpose
5327      this.purpose = castToMarkdown(value); // MarkdownType
5328      return value;
5329    case 1522889671: // copyright
5330      this.copyright = castToMarkdown(value); // MarkdownType
5331      return value;
5332    case 3292052: // kind
5333      value = new CapabilityStatementKindEnumFactory().fromType(castToCode(value));
5334      this.kind = (Enumeration) value; // Enumeration<CapabilityStatementKind>
5335      return value;
5336    case 1319330215: // software
5337      this.software = (TerminologyCapabilitiesSoftwareComponent) value; // TerminologyCapabilitiesSoftwareComponent
5338      return value;
5339    case 1683336114: // implementation
5340      this.implementation = (TerminologyCapabilitiesImplementationComponent) value; // TerminologyCapabilitiesImplementationComponent
5341      return value;
5342    case 1391591896: // lockedDate
5343      this.lockedDate = castToBoolean(value); // BooleanType
5344      return value;
5345    case -916511108: // codeSystem
5346      this.getCodeSystem().add((TerminologyCapabilitiesCodeSystemComponent) value); // TerminologyCapabilitiesCodeSystemComponent
5347      return value;
5348    case 17878207: // expansion
5349      this.expansion = (TerminologyCapabilitiesExpansionComponent) value; // TerminologyCapabilitiesExpansionComponent
5350      return value;
5351    case -935519755: // codeSearch
5352      value = new CodeSearchSupportEnumFactory().fromType(castToCode(value));
5353      this.codeSearch = (Enumeration) value; // Enumeration<CodeSearchSupport>
5354      return value;
5355    case 1080737827: // validateCode
5356      this.validateCode = (TerminologyCapabilitiesValidateCodeComponent) value; // TerminologyCapabilitiesValidateCodeComponent
5357      return value;
5358    case -1840647503: // translation
5359      this.translation = (TerminologyCapabilitiesTranslationComponent) value; // TerminologyCapabilitiesTranslationComponent
5360      return value;
5361    case 866552379: // closure
5362      this.closure = (TerminologyCapabilitiesClosureComponent) value; // TerminologyCapabilitiesClosureComponent
5363      return value;
5364    default:
5365      return super.setProperty(hash, name, value);
5366    }
5367
5368  }
5369
5370  @Override
5371  public Base setProperty(String name, Base value) throws FHIRException {
5372    if (name.equals("url")) {
5373      this.url = castToUri(value); // UriType
5374    } else if (name.equals("version")) {
5375      this.version = castToString(value); // StringType
5376    } else if (name.equals("name")) {
5377      this.name = castToString(value); // StringType
5378    } else if (name.equals("title")) {
5379      this.title = castToString(value); // StringType
5380    } else if (name.equals("status")) {
5381      value = new PublicationStatusEnumFactory().fromType(castToCode(value));
5382      this.status = (Enumeration) value; // Enumeration<PublicationStatus>
5383    } else if (name.equals("experimental")) {
5384      this.experimental = castToBoolean(value); // BooleanType
5385    } else if (name.equals("date")) {
5386      this.date = castToDateTime(value); // DateTimeType
5387    } else if (name.equals("publisher")) {
5388      this.publisher = castToString(value); // StringType
5389    } else if (name.equals("contact")) {
5390      this.getContact().add(castToContactDetail(value));
5391    } else if (name.equals("description")) {
5392      this.description = castToMarkdown(value); // MarkdownType
5393    } else if (name.equals("useContext")) {
5394      this.getUseContext().add(castToUsageContext(value));
5395    } else if (name.equals("jurisdiction")) {
5396      this.getJurisdiction().add(castToCodeableConcept(value));
5397    } else if (name.equals("purpose")) {
5398      this.purpose = castToMarkdown(value); // MarkdownType
5399    } else if (name.equals("copyright")) {
5400      this.copyright = castToMarkdown(value); // MarkdownType
5401    } else if (name.equals("kind")) {
5402      value = new CapabilityStatementKindEnumFactory().fromType(castToCode(value));
5403      this.kind = (Enumeration) value; // Enumeration<CapabilityStatementKind>
5404    } else if (name.equals("software")) {
5405      this.software = (TerminologyCapabilitiesSoftwareComponent) value; // TerminologyCapabilitiesSoftwareComponent
5406    } else if (name.equals("implementation")) {
5407      this.implementation = (TerminologyCapabilitiesImplementationComponent) value; // TerminologyCapabilitiesImplementationComponent
5408    } else if (name.equals("lockedDate")) {
5409      this.lockedDate = castToBoolean(value); // BooleanType
5410    } else if (name.equals("codeSystem")) {
5411      this.getCodeSystem().add((TerminologyCapabilitiesCodeSystemComponent) value);
5412    } else if (name.equals("expansion")) {
5413      this.expansion = (TerminologyCapabilitiesExpansionComponent) value; // TerminologyCapabilitiesExpansionComponent
5414    } else if (name.equals("codeSearch")) {
5415      value = new CodeSearchSupportEnumFactory().fromType(castToCode(value));
5416      this.codeSearch = (Enumeration) value; // Enumeration<CodeSearchSupport>
5417    } else if (name.equals("validateCode")) {
5418      this.validateCode = (TerminologyCapabilitiesValidateCodeComponent) value; // TerminologyCapabilitiesValidateCodeComponent
5419    } else if (name.equals("translation")) {
5420      this.translation = (TerminologyCapabilitiesTranslationComponent) value; // TerminologyCapabilitiesTranslationComponent
5421    } else if (name.equals("closure")) {
5422      this.closure = (TerminologyCapabilitiesClosureComponent) value; // TerminologyCapabilitiesClosureComponent
5423    } else
5424      return super.setProperty(name, value);
5425    return value;
5426  }
5427
5428  @Override
5429  public void removeChild(String name, Base value) throws FHIRException {
5430    if (name.equals("url")) {
5431      this.url = null;
5432    } else if (name.equals("version")) {
5433      this.version = null;
5434    } else if (name.equals("name")) {
5435      this.name = null;
5436    } else if (name.equals("title")) {
5437      this.title = null;
5438    } else if (name.equals("status")) {
5439      this.status = null;
5440    } else if (name.equals("experimental")) {
5441      this.experimental = null;
5442    } else if (name.equals("date")) {
5443      this.date = null;
5444    } else if (name.equals("publisher")) {
5445      this.publisher = null;
5446    } else if (name.equals("contact")) {
5447      this.getContact().remove(castToContactDetail(value));
5448    } else if (name.equals("description")) {
5449      this.description = null;
5450    } else if (name.equals("useContext")) {
5451      this.getUseContext().remove(castToUsageContext(value));
5452    } else if (name.equals("jurisdiction")) {
5453      this.getJurisdiction().remove(castToCodeableConcept(value));
5454    } else if (name.equals("purpose")) {
5455      this.purpose = null;
5456    } else if (name.equals("copyright")) {
5457      this.copyright = null;
5458    } else if (name.equals("kind")) {
5459      this.kind = null;
5460    } else if (name.equals("software")) {
5461      this.software = (TerminologyCapabilitiesSoftwareComponent) value; // TerminologyCapabilitiesSoftwareComponent
5462    } else if (name.equals("implementation")) {
5463      this.implementation = (TerminologyCapabilitiesImplementationComponent) value; // TerminologyCapabilitiesImplementationComponent
5464    } else if (name.equals("lockedDate")) {
5465      this.lockedDate = null;
5466    } else if (name.equals("codeSystem")) {
5467      this.getCodeSystem().remove((TerminologyCapabilitiesCodeSystemComponent) value);
5468    } else if (name.equals("expansion")) {
5469      this.expansion = (TerminologyCapabilitiesExpansionComponent) value; // TerminologyCapabilitiesExpansionComponent
5470    } else if (name.equals("codeSearch")) {
5471      this.codeSearch = null;
5472    } else if (name.equals("validateCode")) {
5473      this.validateCode = (TerminologyCapabilitiesValidateCodeComponent) value; // TerminologyCapabilitiesValidateCodeComponent
5474    } else if (name.equals("translation")) {
5475      this.translation = (TerminologyCapabilitiesTranslationComponent) value; // TerminologyCapabilitiesTranslationComponent
5476    } else if (name.equals("closure")) {
5477      this.closure = (TerminologyCapabilitiesClosureComponent) value; // TerminologyCapabilitiesClosureComponent
5478    } else
5479      super.removeChild(name, value);
5480    
5481  }
5482
5483  @Override
5484  public Base makeProperty(int hash, String name) throws FHIRException {
5485    switch (hash) {
5486    case 116079:
5487      return getUrlElement();
5488    case 351608024:
5489      return getVersionElement();
5490    case 3373707:
5491      return getNameElement();
5492    case 110371416:
5493      return getTitleElement();
5494    case -892481550:
5495      return getStatusElement();
5496    case -404562712:
5497      return getExperimentalElement();
5498    case 3076014:
5499      return getDateElement();
5500    case 1447404028:
5501      return getPublisherElement();
5502    case 951526432:
5503      return addContact();
5504    case -1724546052:
5505      return getDescriptionElement();
5506    case -669707736:
5507      return addUseContext();
5508    case -507075711:
5509      return addJurisdiction();
5510    case -220463842:
5511      return getPurposeElement();
5512    case 1522889671:
5513      return getCopyrightElement();
5514    case 3292052:
5515      return getKindElement();
5516    case 1319330215:
5517      return getSoftware();
5518    case 1683336114:
5519      return getImplementation();
5520    case 1391591896:
5521      return getLockedDateElement();
5522    case -916511108:
5523      return addCodeSystem();
5524    case 17878207:
5525      return getExpansion();
5526    case -935519755:
5527      return getCodeSearchElement();
5528    case 1080737827:
5529      return getValidateCode();
5530    case -1840647503:
5531      return getTranslation();
5532    case 866552379:
5533      return getClosure();
5534    default:
5535      return super.makeProperty(hash, name);
5536    }
5537
5538  }
5539
5540  @Override
5541  public String[] getTypesForProperty(int hash, String name) throws FHIRException {
5542    switch (hash) {
5543    case 116079:
5544      /* url */ return new String[] { "uri" };
5545    case 351608024:
5546      /* version */ return new String[] { "string" };
5547    case 3373707:
5548      /* name */ return new String[] { "string" };
5549    case 110371416:
5550      /* title */ return new String[] { "string" };
5551    case -892481550:
5552      /* status */ return new String[] { "code" };
5553    case -404562712:
5554      /* experimental */ return new String[] { "boolean" };
5555    case 3076014:
5556      /* date */ return new String[] { "dateTime" };
5557    case 1447404028:
5558      /* publisher */ return new String[] { "string" };
5559    case 951526432:
5560      /* contact */ return new String[] { "ContactDetail" };
5561    case -1724546052:
5562      /* description */ return new String[] { "markdown" };
5563    case -669707736:
5564      /* useContext */ return new String[] { "UsageContext" };
5565    case -507075711:
5566      /* jurisdiction */ return new String[] { "CodeableConcept" };
5567    case -220463842:
5568      /* purpose */ return new String[] { "markdown" };
5569    case 1522889671:
5570      /* copyright */ return new String[] { "markdown" };
5571    case 3292052:
5572      /* kind */ return new String[] { "code" };
5573    case 1319330215:
5574      /* software */ return new String[] {};
5575    case 1683336114:
5576      /* implementation */ return new String[] {};
5577    case 1391591896:
5578      /* lockedDate */ return new String[] { "boolean" };
5579    case -916511108:
5580      /* codeSystem */ return new String[] {};
5581    case 17878207:
5582      /* expansion */ return new String[] {};
5583    case -935519755:
5584      /* codeSearch */ return new String[] { "code" };
5585    case 1080737827:
5586      /* validateCode */ return new String[] {};
5587    case -1840647503:
5588      /* translation */ return new String[] {};
5589    case 866552379:
5590      /* closure */ return new String[] {};
5591    default:
5592      return super.getTypesForProperty(hash, name);
5593    }
5594
5595  }
5596
5597  @Override
5598  public Base addChild(String name) throws FHIRException {
5599    if (name.equals("url")) {
5600      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.url");
5601    } else if (name.equals("version")) {
5602      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.version");
5603    } else if (name.equals("name")) {
5604      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.name");
5605    } else if (name.equals("title")) {
5606      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.title");
5607    } else if (name.equals("status")) {
5608      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.status");
5609    } else if (name.equals("experimental")) {
5610      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.experimental");
5611    } else if (name.equals("date")) {
5612      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.date");
5613    } else if (name.equals("publisher")) {
5614      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.publisher");
5615    } else if (name.equals("contact")) {
5616      return addContact();
5617    } else if (name.equals("description")) {
5618      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.description");
5619    } else if (name.equals("useContext")) {
5620      return addUseContext();
5621    } else if (name.equals("jurisdiction")) {
5622      return addJurisdiction();
5623    } else if (name.equals("purpose")) {
5624      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.purpose");
5625    } else if (name.equals("copyright")) {
5626      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.copyright");
5627    } else if (name.equals("kind")) {
5628      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.kind");
5629    } else if (name.equals("software")) {
5630      this.software = new TerminologyCapabilitiesSoftwareComponent();
5631      return this.software;
5632    } else if (name.equals("implementation")) {
5633      this.implementation = new TerminologyCapabilitiesImplementationComponent();
5634      return this.implementation;
5635    } else if (name.equals("lockedDate")) {
5636      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.lockedDate");
5637    } else if (name.equals("codeSystem")) {
5638      return addCodeSystem();
5639    } else if (name.equals("expansion")) {
5640      this.expansion = new TerminologyCapabilitiesExpansionComponent();
5641      return this.expansion;
5642    } else if (name.equals("codeSearch")) {
5643      throw new FHIRException("Cannot call addChild on a singleton property TerminologyCapabilities.codeSearch");
5644    } else if (name.equals("validateCode")) {
5645      this.validateCode = new TerminologyCapabilitiesValidateCodeComponent();
5646      return this.validateCode;
5647    } else if (name.equals("translation")) {
5648      this.translation = new TerminologyCapabilitiesTranslationComponent();
5649      return this.translation;
5650    } else if (name.equals("closure")) {
5651      this.closure = new TerminologyCapabilitiesClosureComponent();
5652      return this.closure;
5653    } else
5654      return super.addChild(name);
5655  }
5656
5657  public String fhirType() {
5658    return "TerminologyCapabilities";
5659
5660  }
5661
5662  public TerminologyCapabilities copy() {
5663    TerminologyCapabilities dst = new TerminologyCapabilities();
5664    copyValues(dst);
5665    return dst;
5666  }
5667
5668  public void copyValues(TerminologyCapabilities dst) {
5669    super.copyValues(dst);
5670    dst.url = url == null ? null : url.copy();
5671    dst.version = version == null ? null : version.copy();
5672    dst.name = name == null ? null : name.copy();
5673    dst.title = title == null ? null : title.copy();
5674    dst.status = status == null ? null : status.copy();
5675    dst.experimental = experimental == null ? null : experimental.copy();
5676    dst.date = date == null ? null : date.copy();
5677    dst.publisher = publisher == null ? null : publisher.copy();
5678    if (contact != null) {
5679      dst.contact = new ArrayList<ContactDetail>();
5680      for (ContactDetail i : contact)
5681        dst.contact.add(i.copy());
5682    }
5683    ;
5684    dst.description = description == null ? null : description.copy();
5685    if (useContext != null) {
5686      dst.useContext = new ArrayList<UsageContext>();
5687      for (UsageContext i : useContext)
5688        dst.useContext.add(i.copy());
5689    }
5690    ;
5691    if (jurisdiction != null) {
5692      dst.jurisdiction = new ArrayList<CodeableConcept>();
5693      for (CodeableConcept i : jurisdiction)
5694        dst.jurisdiction.add(i.copy());
5695    }
5696    ;
5697    dst.purpose = purpose == null ? null : purpose.copy();
5698    dst.copyright = copyright == null ? null : copyright.copy();
5699    dst.kind = kind == null ? null : kind.copy();
5700    dst.software = software == null ? null : software.copy();
5701    dst.implementation = implementation == null ? null : implementation.copy();
5702    dst.lockedDate = lockedDate == null ? null : lockedDate.copy();
5703    if (codeSystem != null) {
5704      dst.codeSystem = new ArrayList<TerminologyCapabilitiesCodeSystemComponent>();
5705      for (TerminologyCapabilitiesCodeSystemComponent i : codeSystem)
5706        dst.codeSystem.add(i.copy());
5707    }
5708    ;
5709    dst.expansion = expansion == null ? null : expansion.copy();
5710    dst.codeSearch = codeSearch == null ? null : codeSearch.copy();
5711    dst.validateCode = validateCode == null ? null : validateCode.copy();
5712    dst.translation = translation == null ? null : translation.copy();
5713    dst.closure = closure == null ? null : closure.copy();
5714  }
5715
5716  protected TerminologyCapabilities typedCopy() {
5717    return copy();
5718  }
5719
5720  @Override
5721  public boolean equalsDeep(Base other_) {
5722    if (!super.equalsDeep(other_))
5723      return false;
5724    if (!(other_ instanceof TerminologyCapabilities))
5725      return false;
5726    TerminologyCapabilities o = (TerminologyCapabilities) other_;
5727    return compareDeep(purpose, o.purpose, true) && compareDeep(copyright, o.copyright, true)
5728        && compareDeep(kind, o.kind, true) && compareDeep(software, o.software, true)
5729        && compareDeep(implementation, o.implementation, true) && compareDeep(lockedDate, o.lockedDate, true)
5730        && compareDeep(codeSystem, o.codeSystem, true) && compareDeep(expansion, o.expansion, true)
5731        && compareDeep(codeSearch, o.codeSearch, true) && compareDeep(validateCode, o.validateCode, true)
5732        && compareDeep(translation, o.translation, true) && compareDeep(closure, o.closure, true);
5733  }
5734
5735  @Override
5736  public boolean equalsShallow(Base other_) {
5737    if (!super.equalsShallow(other_))
5738      return false;
5739    if (!(other_ instanceof TerminologyCapabilities))
5740      return false;
5741    TerminologyCapabilities o = (TerminologyCapabilities) other_;
5742    return compareValues(purpose, o.purpose, true) && compareValues(copyright, o.copyright, true)
5743        && compareValues(kind, o.kind, true) && compareValues(lockedDate, o.lockedDate, true)
5744        && compareValues(codeSearch, o.codeSearch, true);
5745  }
5746
5747  public boolean isEmpty() {
5748    return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(purpose, copyright, kind, software, implementation,
5749        lockedDate, codeSystem, expansion, codeSearch, validateCode, translation, closure);
5750  }
5751
5752  @Override
5753  public ResourceType getResourceType() {
5754    return ResourceType.TerminologyCapabilities;
5755  }
5756
5757  /**
5758   * Search parameter: <b>date</b>
5759   * <p>
5760   * Description: <b>The terminology capabilities publication date</b><br>
5761   * Type: <b>date</b><br>
5762   * Path: <b>TerminologyCapabilities.date</b><br>
5763   * </p>
5764   */
5765  @SearchParamDefinition(name = "date", path = "TerminologyCapabilities.date", description = "The terminology capabilities publication date", type = "date")
5766  public static final String SP_DATE = "date";
5767  /**
5768   * <b>Fluent Client</b> search parameter constant for <b>date</b>
5769   * <p>
5770   * Description: <b>The terminology capabilities publication date</b><br>
5771   * Type: <b>date</b><br>
5772   * Path: <b>TerminologyCapabilities.date</b><br>
5773   * </p>
5774   */
5775  public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(
5776      SP_DATE);
5777
5778  /**
5779   * Search parameter: <b>context-type-value</b>
5780   * <p>
5781   * Description: <b>A use context type and value assigned to the terminology
5782   * capabilities</b><br>
5783   * Type: <b>composite</b><br>
5784   * Path: <b></b><br>
5785   * </p>
5786   */
5787  @SearchParamDefinition(name = "context-type-value", path = "TerminologyCapabilities.useContext", description = "A use context type and value assigned to the terminology capabilities", type = "composite", compositeOf = {
5788      "context-type", "context" })
5789  public static final String SP_CONTEXT_TYPE_VALUE = "context-type-value";
5790  /**
5791   * <b>Fluent Client</b> search parameter constant for <b>context-type-value</b>
5792   * <p>
5793   * Description: <b>A use context type and value assigned to the terminology
5794   * capabilities</b><br>
5795   * Type: <b>composite</b><br>
5796   * Path: <b></b><br>
5797   * </p>
5798   */
5799  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>(
5800      SP_CONTEXT_TYPE_VALUE);
5801
5802  /**
5803   * Search parameter: <b>jurisdiction</b>
5804   * <p>
5805   * Description: <b>Intended jurisdiction for the terminology
5806   * capabilities</b><br>
5807   * Type: <b>token</b><br>
5808   * Path: <b>TerminologyCapabilities.jurisdiction</b><br>
5809   * </p>
5810   */
5811  @SearchParamDefinition(name = "jurisdiction", path = "TerminologyCapabilities.jurisdiction", description = "Intended jurisdiction for the terminology capabilities", type = "token")
5812  public static final String SP_JURISDICTION = "jurisdiction";
5813  /**
5814   * <b>Fluent Client</b> search parameter constant for <b>jurisdiction</b>
5815   * <p>
5816   * Description: <b>Intended jurisdiction for the terminology
5817   * capabilities</b><br>
5818   * Type: <b>token</b><br>
5819   * Path: <b>TerminologyCapabilities.jurisdiction</b><br>
5820   * </p>
5821   */
5822  public static final ca.uhn.fhir.rest.gclient.TokenClientParam JURISDICTION = new ca.uhn.fhir.rest.gclient.TokenClientParam(
5823      SP_JURISDICTION);
5824
5825  /**
5826   * Search parameter: <b>description</b>
5827   * <p>
5828   * Description: <b>The description of the terminology capabilities</b><br>
5829   * Type: <b>string</b><br>
5830   * Path: <b>TerminologyCapabilities.description</b><br>
5831   * </p>
5832   */
5833  @SearchParamDefinition(name = "description", path = "TerminologyCapabilities.description", description = "The description of the terminology capabilities", type = "string")
5834  public static final String SP_DESCRIPTION = "description";
5835  /**
5836   * <b>Fluent Client</b> search parameter constant for <b>description</b>
5837   * <p>
5838   * Description: <b>The description of the terminology capabilities</b><br>
5839   * Type: <b>string</b><br>
5840   * Path: <b>TerminologyCapabilities.description</b><br>
5841   * </p>
5842   */
5843  public static final ca.uhn.fhir.rest.gclient.StringClientParam DESCRIPTION = new ca.uhn.fhir.rest.gclient.StringClientParam(
5844      SP_DESCRIPTION);
5845
5846  /**
5847   * Search parameter: <b>context-type</b>
5848   * <p>
5849   * Description: <b>A type of use context assigned to the terminology
5850   * capabilities</b><br>
5851   * Type: <b>token</b><br>
5852   * Path: <b>TerminologyCapabilities.useContext.code</b><br>
5853   * </p>
5854   */
5855  @SearchParamDefinition(name = "context-type", path = "TerminologyCapabilities.useContext.code", description = "A type of use context assigned to the terminology capabilities", type = "token")
5856  public static final String SP_CONTEXT_TYPE = "context-type";
5857  /**
5858   * <b>Fluent Client</b> search parameter constant for <b>context-type</b>
5859   * <p>
5860   * Description: <b>A type of use context assigned to the terminology
5861   * capabilities</b><br>
5862   * Type: <b>token</b><br>
5863   * Path: <b>TerminologyCapabilities.useContext.code</b><br>
5864   * </p>
5865   */
5866  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(
5867      SP_CONTEXT_TYPE);
5868
5869  /**
5870   * Search parameter: <b>title</b>
5871   * <p>
5872   * Description: <b>The human-friendly name of the terminology
5873   * capabilities</b><br>
5874   * Type: <b>string</b><br>
5875   * Path: <b>TerminologyCapabilities.title</b><br>
5876   * </p>
5877   */
5878  @SearchParamDefinition(name = "title", path = "TerminologyCapabilities.title", description = "The human-friendly name of the terminology capabilities", type = "string")
5879  public static final String SP_TITLE = "title";
5880  /**
5881   * <b>Fluent Client</b> search parameter constant for <b>title</b>
5882   * <p>
5883   * Description: <b>The human-friendly name of the terminology
5884   * capabilities</b><br>
5885   * Type: <b>string</b><br>
5886   * Path: <b>TerminologyCapabilities.title</b><br>
5887   * </p>
5888   */
5889  public static final ca.uhn.fhir.rest.gclient.StringClientParam TITLE = new ca.uhn.fhir.rest.gclient.StringClientParam(
5890      SP_TITLE);
5891
5892  /**
5893   * Search parameter: <b>version</b>
5894   * <p>
5895   * Description: <b>The business version of the terminology capabilities</b><br>
5896   * Type: <b>token</b><br>
5897   * Path: <b>TerminologyCapabilities.version</b><br>
5898   * </p>
5899   */
5900  @SearchParamDefinition(name = "version", path = "TerminologyCapabilities.version", description = "The business version of the terminology capabilities", type = "token")
5901  public static final String SP_VERSION = "version";
5902  /**
5903   * <b>Fluent Client</b> search parameter constant for <b>version</b>
5904   * <p>
5905   * Description: <b>The business version of the terminology capabilities</b><br>
5906   * Type: <b>token</b><br>
5907   * Path: <b>TerminologyCapabilities.version</b><br>
5908   * </p>
5909   */
5910  public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam(
5911      SP_VERSION);
5912
5913  /**
5914   * Search parameter: <b>url</b>
5915   * <p>
5916   * Description: <b>The uri that identifies the terminology capabilities</b><br>
5917   * Type: <b>uri</b><br>
5918   * Path: <b>TerminologyCapabilities.url</b><br>
5919   * </p>
5920   */
5921  @SearchParamDefinition(name = "url", path = "TerminologyCapabilities.url", description = "The uri that identifies the terminology capabilities", type = "uri")
5922  public static final String SP_URL = "url";
5923  /**
5924   * <b>Fluent Client</b> search parameter constant for <b>url</b>
5925   * <p>
5926   * Description: <b>The uri that identifies the terminology capabilities</b><br>
5927   * Type: <b>uri</b><br>
5928   * Path: <b>TerminologyCapabilities.url</b><br>
5929   * </p>
5930   */
5931  public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL);
5932
5933  /**
5934   * Search parameter: <b>context-quantity</b>
5935   * <p>
5936   * Description: <b>A quantity- or range-valued use context assigned to the
5937   * terminology capabilities</b><br>
5938   * Type: <b>quantity</b><br>
5939   * Path: <b>TerminologyCapabilities.useContext.valueQuantity,
5940   * TerminologyCapabilities.useContext.valueRange</b><br>
5941   * </p>
5942   */
5943  @SearchParamDefinition(name = "context-quantity", path = "(TerminologyCapabilities.useContext.value as Quantity) | (TerminologyCapabilities.useContext.value as Range)", description = "A quantity- or range-valued use context assigned to the terminology capabilities", type = "quantity")
5944  public static final String SP_CONTEXT_QUANTITY = "context-quantity";
5945  /**
5946   * <b>Fluent Client</b> search parameter constant for <b>context-quantity</b>
5947   * <p>
5948   * Description: <b>A quantity- or range-valued use context assigned to the
5949   * terminology capabilities</b><br>
5950   * Type: <b>quantity</b><br>
5951   * Path: <b>TerminologyCapabilities.useContext.valueQuantity,
5952   * TerminologyCapabilities.useContext.valueRange</b><br>
5953   * </p>
5954   */
5955  public static final ca.uhn.fhir.rest.gclient.QuantityClientParam CONTEXT_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam(
5956      SP_CONTEXT_QUANTITY);
5957
5958  /**
5959   * Search parameter: <b>name</b>
5960   * <p>
5961   * Description: <b>Computationally friendly name of the terminology
5962   * capabilities</b><br>
5963   * Type: <b>string</b><br>
5964   * Path: <b>TerminologyCapabilities.name</b><br>
5965   * </p>
5966   */
5967  @SearchParamDefinition(name = "name", path = "TerminologyCapabilities.name", description = "Computationally friendly name of the terminology capabilities", type = "string")
5968  public static final String SP_NAME = "name";
5969  /**
5970   * <b>Fluent Client</b> search parameter constant for <b>name</b>
5971   * <p>
5972   * Description: <b>Computationally friendly name of the terminology
5973   * capabilities</b><br>
5974   * Type: <b>string</b><br>
5975   * Path: <b>TerminologyCapabilities.name</b><br>
5976   * </p>
5977   */
5978  public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(
5979      SP_NAME);
5980
5981  /**
5982   * Search parameter: <b>context</b>
5983   * <p>
5984   * Description: <b>A use context assigned to the terminology
5985   * capabilities</b><br>
5986   * Type: <b>token</b><br>
5987   * Path: <b>TerminologyCapabilities.useContext.valueCodeableConcept</b><br>
5988   * </p>
5989   */
5990  @SearchParamDefinition(name = "context", path = "(TerminologyCapabilities.useContext.value as CodeableConcept)", description = "A use context assigned to the terminology capabilities", type = "token")
5991  public static final String SP_CONTEXT = "context";
5992  /**
5993   * <b>Fluent Client</b> search parameter constant for <b>context</b>
5994   * <p>
5995   * Description: <b>A use context assigned to the terminology
5996   * capabilities</b><br>
5997   * Type: <b>token</b><br>
5998   * Path: <b>TerminologyCapabilities.useContext.valueCodeableConcept</b><br>
5999   * </p>
6000   */
6001  public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam(
6002      SP_CONTEXT);
6003
6004  /**
6005   * Search parameter: <b>publisher</b>
6006   * <p>
6007   * Description: <b>Name of the publisher of the terminology capabilities</b><br>
6008   * Type: <b>string</b><br>
6009   * Path: <b>TerminologyCapabilities.publisher</b><br>
6010   * </p>
6011   */
6012  @SearchParamDefinition(name = "publisher", path = "TerminologyCapabilities.publisher", description = "Name of the publisher of the terminology capabilities", type = "string")
6013  public static final String SP_PUBLISHER = "publisher";
6014  /**
6015   * <b>Fluent Client</b> search parameter constant for <b>publisher</b>
6016   * <p>
6017   * Description: <b>Name of the publisher of the terminology capabilities</b><br>
6018   * Type: <b>string</b><br>
6019   * Path: <b>TerminologyCapabilities.publisher</b><br>
6020   * </p>
6021   */
6022  public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam(
6023      SP_PUBLISHER);
6024
6025  /**
6026   * Search parameter: <b>context-type-quantity</b>
6027   * <p>
6028   * Description: <b>A use context type and quantity- or range-based value
6029   * assigned to the terminology capabilities</b><br>
6030   * Type: <b>composite</b><br>
6031   * Path: <b></b><br>
6032   * </p>
6033   */
6034  @SearchParamDefinition(name = "context-type-quantity", path = "TerminologyCapabilities.useContext", description = "A use context type and quantity- or range-based value assigned to the terminology capabilities", type = "composite", compositeOf = {
6035      "context-type", "context-quantity" })
6036  public static final String SP_CONTEXT_TYPE_QUANTITY = "context-type-quantity";
6037  /**
6038   * <b>Fluent Client</b> search parameter constant for
6039   * <b>context-type-quantity</b>
6040   * <p>
6041   * Description: <b>A use context type and quantity- or range-based value
6042   * assigned to the terminology capabilities</b><br>
6043   * Type: <b>composite</b><br>
6044   * Path: <b></b><br>
6045   * </p>
6046   */
6047  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>(
6048      SP_CONTEXT_TYPE_QUANTITY);
6049
6050  /**
6051   * Search parameter: <b>status</b>
6052   * <p>
6053   * Description: <b>The current status of the terminology capabilities</b><br>
6054   * Type: <b>token</b><br>
6055   * Path: <b>TerminologyCapabilities.status</b><br>
6056   * </p>
6057   */
6058  @SearchParamDefinition(name = "status", path = "TerminologyCapabilities.status", description = "The current status of the terminology capabilities", type = "token")
6059  public static final String SP_STATUS = "status";
6060  /**
6061   * <b>Fluent Client</b> search parameter constant for <b>status</b>
6062   * <p>
6063   * Description: <b>The current status of the terminology capabilities</b><br>
6064   * Type: <b>token</b><br>
6065   * Path: <b>TerminologyCapabilities.status</b><br>
6066   * </p>
6067   */
6068  public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(
6069      SP_STATUS);
6070
6071}