001package org.hl7.fhir.dstu2016may.model; 002 003 004 005 006/* 007 Copyright (c) 2011+, HL7, Inc. 008 All rights reserved. 009 010 Redistribution and use in source and binary forms, with or without modification, 011 are permitted provided that the following conditions are met: 012 013 * Redistributions of source code must retain the above copyright notice, this 014 list of conditions and the following disclaimer. 015 * Redistributions in binary form must reproduce the above copyright notice, 016 this list of conditions and the following disclaimer in the documentation 017 and/or other materials provided with the distribution. 018 * Neither the name of HL7 nor the names of its contributors may be used to 019 endorse or promote products derived from this software without specific 020 prior written permission. 021 022 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 023 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 024 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 025 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 026 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 027 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 028 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 029 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 030 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 031 POSSIBILITY OF SUCH DAMAGE. 032 033*/ 034 035// Generated on Sun, May 8, 2016 03:05+1000 for FHIR v1.4.0 036import java.util.ArrayList; 037import java.util.Date; 038import java.util.List; 039 040import org.hl7.fhir.dstu2016may.model.Enumerations.ConformanceResourceStatus; 041import org.hl7.fhir.dstu2016may.model.Enumerations.ConformanceResourceStatusEnumFactory; 042import org.hl7.fhir.exceptions.FHIRException; 043import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 044import org.hl7.fhir.utilities.Utilities; 045 046import ca.uhn.fhir.model.api.annotation.Block; 047import ca.uhn.fhir.model.api.annotation.Child; 048import ca.uhn.fhir.model.api.annotation.Description; 049import ca.uhn.fhir.model.api.annotation.ResourceDef; 050import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 051/** 052 * A definition of a FHIR structure. This resource is used to describe the underlying resources, data types defined in FHIR, and also for describing extensions, and constraints on resources and data types. 053 */ 054@ResourceDef(name="StructureDefinition", profile="http://hl7.org/fhir/Profile/StructureDefinition") 055public class StructureDefinition extends DomainResource { 056 057 public enum StructureDefinitionKind { 058 /** 059 * A data type - either a primitive or complex structure that defines a set of data elements. These can be used throughout Resource and extension definitions. 060 */ 061 DATATYPE, 062 /** 063 * A resource defined by the FHIR specification. 064 */ 065 RESOURCE, 066 /** 067 * A logical model - a conceptual package of data that will be mapped to resources for implementation. 068 */ 069 LOGICAL, 070 /** 071 * added to help the parsers 072 */ 073 NULL; 074 public static StructureDefinitionKind fromCode(String codeString) throws FHIRException { 075 if (codeString == null || "".equals(codeString)) 076 return null; 077 if ("datatype".equals(codeString)) 078 return DATATYPE; 079 if ("resource".equals(codeString)) 080 return RESOURCE; 081 if ("logical".equals(codeString)) 082 return LOGICAL; 083 throw new FHIRException("Unknown StructureDefinitionKind code '"+codeString+"'"); 084 } 085 public String toCode() { 086 switch (this) { 087 case DATATYPE: return "datatype"; 088 case RESOURCE: return "resource"; 089 case LOGICAL: return "logical"; 090 case NULL: return null; 091 default: return "?"; 092 } 093 } 094 public String getSystem() { 095 switch (this) { 096 case DATATYPE: return "http://hl7.org/fhir/structure-definition-kind"; 097 case RESOURCE: return "http://hl7.org/fhir/structure-definition-kind"; 098 case LOGICAL: return "http://hl7.org/fhir/structure-definition-kind"; 099 case NULL: return null; 100 default: return "?"; 101 } 102 } 103 public String getDefinition() { 104 switch (this) { 105 case DATATYPE: return "A data type - either a primitive or complex structure that defines a set of data elements. These can be used throughout Resource and extension definitions."; 106 case RESOURCE: return "A resource defined by the FHIR specification."; 107 case LOGICAL: return "A logical model - a conceptual package of data that will be mapped to resources for implementation."; 108 case NULL: return null; 109 default: return "?"; 110 } 111 } 112 public String getDisplay() { 113 switch (this) { 114 case DATATYPE: return "Data Type"; 115 case RESOURCE: return "Resource"; 116 case LOGICAL: return "Logical Model"; 117 case NULL: return null; 118 default: return "?"; 119 } 120 } 121 } 122 123 public static class StructureDefinitionKindEnumFactory implements EnumFactory<StructureDefinitionKind> { 124 public StructureDefinitionKind fromCode(String codeString) throws IllegalArgumentException { 125 if (codeString == null || "".equals(codeString)) 126 if (codeString == null || "".equals(codeString)) 127 return null; 128 if ("datatype".equals(codeString)) 129 return StructureDefinitionKind.DATATYPE; 130 if ("resource".equals(codeString)) 131 return StructureDefinitionKind.RESOURCE; 132 if ("logical".equals(codeString)) 133 return StructureDefinitionKind.LOGICAL; 134 throw new IllegalArgumentException("Unknown StructureDefinitionKind code '"+codeString+"'"); 135 } 136 public Enumeration<StructureDefinitionKind> fromType(Base code) throws FHIRException { 137 if (code == null || code.isEmpty()) 138 return null; 139 String codeString = ((PrimitiveType) code).asStringValue(); 140 if (codeString == null || "".equals(codeString)) 141 return null; 142 if ("datatype".equals(codeString)) 143 return new Enumeration<StructureDefinitionKind>(this, StructureDefinitionKind.DATATYPE); 144 if ("resource".equals(codeString)) 145 return new Enumeration<StructureDefinitionKind>(this, StructureDefinitionKind.RESOURCE); 146 if ("logical".equals(codeString)) 147 return new Enumeration<StructureDefinitionKind>(this, StructureDefinitionKind.LOGICAL); 148 throw new FHIRException("Unknown StructureDefinitionKind code '"+codeString+"'"); 149 } 150 public String toCode(StructureDefinitionKind code) { 151 if (code == StructureDefinitionKind.DATATYPE) 152 return "datatype"; 153 if (code == StructureDefinitionKind.RESOURCE) 154 return "resource"; 155 if (code == StructureDefinitionKind.LOGICAL) 156 return "logical"; 157 return "?"; 158 } 159 public String toSystem(StructureDefinitionKind code) { 160 return code.getSystem(); 161 } 162 } 163 164 public enum ExtensionContext { 165 /** 166 * The context is all elements matching a particular resource element path. 167 */ 168 RESOURCE, 169 /** 170 * The context is all nodes matching a particular data type element path (root or repeating element) or all elements referencing a particular primitive data type (expressed as the datatype name). 171 */ 172 DATATYPE, 173 /** 174 * The context is a particular extension from a particular profile, a uri that identifies the extension definition. 175 */ 176 EXTENSION, 177 /** 178 * added to help the parsers 179 */ 180 NULL; 181 public static ExtensionContext fromCode(String codeString) throws FHIRException { 182 if (codeString == null || "".equals(codeString)) 183 return null; 184 if ("resource".equals(codeString)) 185 return RESOURCE; 186 if ("datatype".equals(codeString)) 187 return DATATYPE; 188 if ("extension".equals(codeString)) 189 return EXTENSION; 190 throw new FHIRException("Unknown ExtensionContext code '"+codeString+"'"); 191 } 192 public String toCode() { 193 switch (this) { 194 case RESOURCE: return "resource"; 195 case DATATYPE: return "datatype"; 196 case EXTENSION: return "extension"; 197 case NULL: return null; 198 default: return "?"; 199 } 200 } 201 public String getSystem() { 202 switch (this) { 203 case RESOURCE: return "http://hl7.org/fhir/extension-context"; 204 case DATATYPE: return "http://hl7.org/fhir/extension-context"; 205 case EXTENSION: return "http://hl7.org/fhir/extension-context"; 206 case NULL: return null; 207 default: return "?"; 208 } 209 } 210 public String getDefinition() { 211 switch (this) { 212 case RESOURCE: return "The context is all elements matching a particular resource element path."; 213 case DATATYPE: return "The context is all nodes matching a particular data type element path (root or repeating element) or all elements referencing a particular primitive data type (expressed as the datatype name)."; 214 case EXTENSION: return "The context is a particular extension from a particular profile, a uri that identifies the extension definition."; 215 case NULL: return null; 216 default: return "?"; 217 } 218 } 219 public String getDisplay() { 220 switch (this) { 221 case RESOURCE: return "Resource"; 222 case DATATYPE: return "Datatype"; 223 case EXTENSION: return "Extension"; 224 case NULL: return null; 225 default: return "?"; 226 } 227 } 228 } 229 230 public static class ExtensionContextEnumFactory implements EnumFactory<ExtensionContext> { 231 public ExtensionContext fromCode(String codeString) throws IllegalArgumentException { 232 if (codeString == null || "".equals(codeString)) 233 if (codeString == null || "".equals(codeString)) 234 return null; 235 if ("resource".equals(codeString)) 236 return ExtensionContext.RESOURCE; 237 if ("datatype".equals(codeString)) 238 return ExtensionContext.DATATYPE; 239 if ("extension".equals(codeString)) 240 return ExtensionContext.EXTENSION; 241 throw new IllegalArgumentException("Unknown ExtensionContext code '"+codeString+"'"); 242 } 243 public Enumeration<ExtensionContext> fromType(Base code) throws FHIRException { 244 if (code == null || code.isEmpty()) 245 return null; 246 String codeString = ((PrimitiveType) code).asStringValue(); 247 if (codeString == null || "".equals(codeString)) 248 return null; 249 if ("resource".equals(codeString)) 250 return new Enumeration<ExtensionContext>(this, ExtensionContext.RESOURCE); 251 if ("datatype".equals(codeString)) 252 return new Enumeration<ExtensionContext>(this, ExtensionContext.DATATYPE); 253 if ("extension".equals(codeString)) 254 return new Enumeration<ExtensionContext>(this, ExtensionContext.EXTENSION); 255 throw new FHIRException("Unknown ExtensionContext code '"+codeString+"'"); 256 } 257 public String toCode(ExtensionContext code) { 258 if (code == ExtensionContext.RESOURCE) 259 return "resource"; 260 if (code == ExtensionContext.DATATYPE) 261 return "datatype"; 262 if (code == ExtensionContext.EXTENSION) 263 return "extension"; 264 return "?"; 265 } 266 public String toSystem(ExtensionContext code) { 267 return code.getSystem(); 268 } 269 } 270 271 public enum TypeDerivationRule { 272 /** 273 * This definition defines a new type that adds additional elements to the base type 274 */ 275 SPECIALIZATION, 276 /** 277 * This definition adds additional rules to an existing concrete type 278 */ 279 CONSTRAINT, 280 /** 281 * added to help the parsers 282 */ 283 NULL; 284 public static TypeDerivationRule fromCode(String codeString) throws FHIRException { 285 if (codeString == null || "".equals(codeString)) 286 return null; 287 if ("specialization".equals(codeString)) 288 return SPECIALIZATION; 289 if ("constraint".equals(codeString)) 290 return CONSTRAINT; 291 throw new FHIRException("Unknown TypeDerivationRule code '"+codeString+"'"); 292 } 293 public String toCode() { 294 switch (this) { 295 case SPECIALIZATION: return "specialization"; 296 case CONSTRAINT: return "constraint"; 297 case NULL: return null; 298 default: return "?"; 299 } 300 } 301 public String getSystem() { 302 switch (this) { 303 case SPECIALIZATION: return "http://hl7.org/fhir/type-derivation-rule"; 304 case CONSTRAINT: return "http://hl7.org/fhir/type-derivation-rule"; 305 case NULL: return null; 306 default: return "?"; 307 } 308 } 309 public String getDefinition() { 310 switch (this) { 311 case SPECIALIZATION: return "This definition defines a new type that adds additional elements to the base type"; 312 case CONSTRAINT: return "This definition adds additional rules to an existing concrete type"; 313 case NULL: return null; 314 default: return "?"; 315 } 316 } 317 public String getDisplay() { 318 switch (this) { 319 case SPECIALIZATION: return "Specialization"; 320 case CONSTRAINT: return "Constraint"; 321 case NULL: return null; 322 default: return "?"; 323 } 324 } 325 } 326 327 public static class TypeDerivationRuleEnumFactory implements EnumFactory<TypeDerivationRule> { 328 public TypeDerivationRule fromCode(String codeString) throws IllegalArgumentException { 329 if (codeString == null || "".equals(codeString)) 330 if (codeString == null || "".equals(codeString)) 331 return null; 332 if ("specialization".equals(codeString)) 333 return TypeDerivationRule.SPECIALIZATION; 334 if ("constraint".equals(codeString)) 335 return TypeDerivationRule.CONSTRAINT; 336 throw new IllegalArgumentException("Unknown TypeDerivationRule code '"+codeString+"'"); 337 } 338 public Enumeration<TypeDerivationRule> fromType(Base code) throws FHIRException { 339 if (code == null || code.isEmpty()) 340 return null; 341 String codeString = ((PrimitiveType) code).asStringValue(); 342 if (codeString == null || "".equals(codeString)) 343 return null; 344 if ("specialization".equals(codeString)) 345 return new Enumeration<TypeDerivationRule>(this, TypeDerivationRule.SPECIALIZATION); 346 if ("constraint".equals(codeString)) 347 return new Enumeration<TypeDerivationRule>(this, TypeDerivationRule.CONSTRAINT); 348 throw new FHIRException("Unknown TypeDerivationRule code '"+codeString+"'"); 349 } 350 public String toCode(TypeDerivationRule code) { 351 if (code == TypeDerivationRule.SPECIALIZATION) 352 return "specialization"; 353 if (code == TypeDerivationRule.CONSTRAINT) 354 return "constraint"; 355 return "?"; 356 } 357 public String toSystem(TypeDerivationRule code) { 358 return code.getSystem(); 359 } 360 } 361 362 @Block() 363 public static class StructureDefinitionContactComponent extends BackboneElement implements IBaseBackboneElement { 364 /** 365 * The name of an individual to contact regarding the structure definition. 366 */ 367 @Child(name = "name", type = {StringType.class}, order=1, min=0, max=1, modifier=false, summary=true) 368 @Description(shortDefinition="Name of an individual to contact", formalDefinition="The name of an individual to contact regarding the structure definition." ) 369 protected StringType name; 370 371 /** 372 * Contact details for individual (if a name was provided) or the publisher. 373 */ 374 @Child(name = "telecom", type = {ContactPoint.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 375 @Description(shortDefinition="Contact details for individual or publisher", formalDefinition="Contact details for individual (if a name was provided) or the publisher." ) 376 protected List<ContactPoint> telecom; 377 378 private static final long serialVersionUID = -1179697803L; 379 380 /** 381 * Constructor 382 */ 383 public StructureDefinitionContactComponent() { 384 super(); 385 } 386 387 /** 388 * @return {@link #name} (The name of an individual to contact regarding the structure definition.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 389 */ 390 public StringType getNameElement() { 391 if (this.name == null) 392 if (Configuration.errorOnAutoCreate()) 393 throw new Error("Attempt to auto-create StructureDefinitionContactComponent.name"); 394 else if (Configuration.doAutoCreate()) 395 this.name = new StringType(); // bb 396 return this.name; 397 } 398 399 public boolean hasNameElement() { 400 return this.name != null && !this.name.isEmpty(); 401 } 402 403 public boolean hasName() { 404 return this.name != null && !this.name.isEmpty(); 405 } 406 407 /** 408 * @param value {@link #name} (The name of an individual to contact regarding the structure definition.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 409 */ 410 public StructureDefinitionContactComponent setNameElement(StringType value) { 411 this.name = value; 412 return this; 413 } 414 415 /** 416 * @return The name of an individual to contact regarding the structure definition. 417 */ 418 public String getName() { 419 return this.name == null ? null : this.name.getValue(); 420 } 421 422 /** 423 * @param value The name of an individual to contact regarding the structure definition. 424 */ 425 public StructureDefinitionContactComponent setName(String value) { 426 if (Utilities.noString(value)) 427 this.name = null; 428 else { 429 if (this.name == null) 430 this.name = new StringType(); 431 this.name.setValue(value); 432 } 433 return this; 434 } 435 436 /** 437 * @return {@link #telecom} (Contact details for individual (if a name was provided) or the publisher.) 438 */ 439 public List<ContactPoint> getTelecom() { 440 if (this.telecom == null) 441 this.telecom = new ArrayList<ContactPoint>(); 442 return this.telecom; 443 } 444 445 public boolean hasTelecom() { 446 if (this.telecom == null) 447 return false; 448 for (ContactPoint item : this.telecom) 449 if (!item.isEmpty()) 450 return true; 451 return false; 452 } 453 454 /** 455 * @return {@link #telecom} (Contact details for individual (if a name was provided) or the publisher.) 456 */ 457 // syntactic sugar 458 public ContactPoint addTelecom() { //3 459 ContactPoint t = new ContactPoint(); 460 if (this.telecom == null) 461 this.telecom = new ArrayList<ContactPoint>(); 462 this.telecom.add(t); 463 return t; 464 } 465 466 // syntactic sugar 467 public StructureDefinitionContactComponent addTelecom(ContactPoint t) { //3 468 if (t == null) 469 return this; 470 if (this.telecom == null) 471 this.telecom = new ArrayList<ContactPoint>(); 472 this.telecom.add(t); 473 return this; 474 } 475 476 protected void listChildren(List<Property> childrenList) { 477 super.listChildren(childrenList); 478 childrenList.add(new Property("name", "string", "The name of an individual to contact regarding the structure definition.", 0, java.lang.Integer.MAX_VALUE, name)); 479 childrenList.add(new Property("telecom", "ContactPoint", "Contact details for individual (if a name was provided) or the publisher.", 0, java.lang.Integer.MAX_VALUE, telecom)); 480 } 481 482 @Override 483 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 484 switch (hash) { 485 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 486 case -1429363305: /*telecom*/ return this.telecom == null ? new Base[0] : this.telecom.toArray(new Base[this.telecom.size()]); // ContactPoint 487 default: return super.getProperty(hash, name, checkValid); 488 } 489 490 } 491 492 @Override 493 public void setProperty(int hash, String name, Base value) throws FHIRException { 494 switch (hash) { 495 case 3373707: // name 496 this.name = castToString(value); // StringType 497 break; 498 case -1429363305: // telecom 499 this.getTelecom().add(castToContactPoint(value)); // ContactPoint 500 break; 501 default: super.setProperty(hash, name, value); 502 } 503 504 } 505 506 @Override 507 public void setProperty(String name, Base value) throws FHIRException { 508 if (name.equals("name")) 509 this.name = castToString(value); // StringType 510 else if (name.equals("telecom")) 511 this.getTelecom().add(castToContactPoint(value)); 512 else 513 super.setProperty(name, value); 514 } 515 516 @Override 517 public Base makeProperty(int hash, String name) throws FHIRException { 518 switch (hash) { 519 case 3373707: throw new FHIRException("Cannot make property name as it is not a complex type"); // StringType 520 case -1429363305: return addTelecom(); // ContactPoint 521 default: return super.makeProperty(hash, name); 522 } 523 524 } 525 526 @Override 527 public Base addChild(String name) throws FHIRException { 528 if (name.equals("name")) { 529 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.name"); 530 } 531 else if (name.equals("telecom")) { 532 return addTelecom(); 533 } 534 else 535 return super.addChild(name); 536 } 537 538 public StructureDefinitionContactComponent copy() { 539 StructureDefinitionContactComponent dst = new StructureDefinitionContactComponent(); 540 copyValues(dst); 541 dst.name = name == null ? null : name.copy(); 542 if (telecom != null) { 543 dst.telecom = new ArrayList<ContactPoint>(); 544 for (ContactPoint i : telecom) 545 dst.telecom.add(i.copy()); 546 }; 547 return dst; 548 } 549 550 @Override 551 public boolean equalsDeep(Base other) { 552 if (!super.equalsDeep(other)) 553 return false; 554 if (!(other instanceof StructureDefinitionContactComponent)) 555 return false; 556 StructureDefinitionContactComponent o = (StructureDefinitionContactComponent) other; 557 return compareDeep(name, o.name, true) && compareDeep(telecom, o.telecom, true); 558 } 559 560 @Override 561 public boolean equalsShallow(Base other) { 562 if (!super.equalsShallow(other)) 563 return false; 564 if (!(other instanceof StructureDefinitionContactComponent)) 565 return false; 566 StructureDefinitionContactComponent o = (StructureDefinitionContactComponent) other; 567 return compareValues(name, o.name, true); 568 } 569 570 public boolean isEmpty() { 571 return super.isEmpty() && (name == null || name.isEmpty()) && (telecom == null || telecom.isEmpty()) 572 ; 573 } 574 575 public String fhirType() { 576 return "StructureDefinition.contact"; 577 578 } 579 580 } 581 582 @Block() 583 public static class StructureDefinitionMappingComponent extends BackboneElement implements IBaseBackboneElement { 584 /** 585 * An Internal id that is used to identify this mapping set when specific mappings are made. 586 */ 587 @Child(name = "identity", type = {IdType.class}, order=1, min=1, max=1, modifier=false, summary=false) 588 @Description(shortDefinition="Internal id when this mapping is used", formalDefinition="An Internal id that is used to identify this mapping set when specific mappings are made." ) 589 protected IdType identity; 590 591 /** 592 * An absolute URI that identifies the specification that this mapping is expressed to. 593 */ 594 @Child(name = "uri", type = {UriType.class}, order=2, min=0, max=1, modifier=false, summary=false) 595 @Description(shortDefinition="Identifies what this mapping refers to", formalDefinition="An absolute URI that identifies the specification that this mapping is expressed to." ) 596 protected UriType uri; 597 598 /** 599 * A name for the specification that is being mapped to. 600 */ 601 @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 602 @Description(shortDefinition="Names what this mapping refers to", formalDefinition="A name for the specification that is being mapped to." ) 603 protected StringType name; 604 605 /** 606 * Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage. 607 */ 608 @Child(name = "comments", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false) 609 @Description(shortDefinition="Versions, Issues, Scope limitations etc.", formalDefinition="Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage." ) 610 protected StringType comments; 611 612 private static final long serialVersionUID = 299630820L; 613 614 /** 615 * Constructor 616 */ 617 public StructureDefinitionMappingComponent() { 618 super(); 619 } 620 621 /** 622 * Constructor 623 */ 624 public StructureDefinitionMappingComponent(IdType identity) { 625 super(); 626 this.identity = identity; 627 } 628 629 /** 630 * @return {@link #identity} (An Internal id that is used to identify this mapping set when specific mappings are made.). This is the underlying object with id, value and extensions. The accessor "getIdentity" gives direct access to the value 631 */ 632 public IdType getIdentityElement() { 633 if (this.identity == null) 634 if (Configuration.errorOnAutoCreate()) 635 throw new Error("Attempt to auto-create StructureDefinitionMappingComponent.identity"); 636 else if (Configuration.doAutoCreate()) 637 this.identity = new IdType(); // bb 638 return this.identity; 639 } 640 641 public boolean hasIdentityElement() { 642 return this.identity != null && !this.identity.isEmpty(); 643 } 644 645 public boolean hasIdentity() { 646 return this.identity != null && !this.identity.isEmpty(); 647 } 648 649 /** 650 * @param value {@link #identity} (An Internal id that is used to identify this mapping set when specific mappings are made.). This is the underlying object with id, value and extensions. The accessor "getIdentity" gives direct access to the value 651 */ 652 public StructureDefinitionMappingComponent setIdentityElement(IdType value) { 653 this.identity = value; 654 return this; 655 } 656 657 /** 658 * @return An Internal id that is used to identify this mapping set when specific mappings are made. 659 */ 660 public String getIdentity() { 661 return this.identity == null ? null : this.identity.getValue(); 662 } 663 664 /** 665 * @param value An Internal id that is used to identify this mapping set when specific mappings are made. 666 */ 667 public StructureDefinitionMappingComponent setIdentity(String value) { 668 if (this.identity == null) 669 this.identity = new IdType(); 670 this.identity.setValue(value); 671 return this; 672 } 673 674 /** 675 * @return {@link #uri} (An absolute URI that identifies the specification that this mapping is expressed to.). This is the underlying object with id, value and extensions. The accessor "getUri" gives direct access to the value 676 */ 677 public UriType getUriElement() { 678 if (this.uri == null) 679 if (Configuration.errorOnAutoCreate()) 680 throw new Error("Attempt to auto-create StructureDefinitionMappingComponent.uri"); 681 else if (Configuration.doAutoCreate()) 682 this.uri = new UriType(); // bb 683 return this.uri; 684 } 685 686 public boolean hasUriElement() { 687 return this.uri != null && !this.uri.isEmpty(); 688 } 689 690 public boolean hasUri() { 691 return this.uri != null && !this.uri.isEmpty(); 692 } 693 694 /** 695 * @param value {@link #uri} (An absolute URI that identifies the specification that this mapping is expressed to.). This is the underlying object with id, value and extensions. The accessor "getUri" gives direct access to the value 696 */ 697 public StructureDefinitionMappingComponent setUriElement(UriType value) { 698 this.uri = value; 699 return this; 700 } 701 702 /** 703 * @return An absolute URI that identifies the specification that this mapping is expressed to. 704 */ 705 public String getUri() { 706 return this.uri == null ? null : this.uri.getValue(); 707 } 708 709 /** 710 * @param value An absolute URI that identifies the specification that this mapping is expressed to. 711 */ 712 public StructureDefinitionMappingComponent setUri(String value) { 713 if (Utilities.noString(value)) 714 this.uri = null; 715 else { 716 if (this.uri == null) 717 this.uri = new UriType(); 718 this.uri.setValue(value); 719 } 720 return this; 721 } 722 723 /** 724 * @return {@link #name} (A name for the specification that is being mapped to.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 725 */ 726 public StringType getNameElement() { 727 if (this.name == null) 728 if (Configuration.errorOnAutoCreate()) 729 throw new Error("Attempt to auto-create StructureDefinitionMappingComponent.name"); 730 else if (Configuration.doAutoCreate()) 731 this.name = new StringType(); // bb 732 return this.name; 733 } 734 735 public boolean hasNameElement() { 736 return this.name != null && !this.name.isEmpty(); 737 } 738 739 public boolean hasName() { 740 return this.name != null && !this.name.isEmpty(); 741 } 742 743 /** 744 * @param value {@link #name} (A name for the specification that is being mapped to.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 745 */ 746 public StructureDefinitionMappingComponent setNameElement(StringType value) { 747 this.name = value; 748 return this; 749 } 750 751 /** 752 * @return A name for the specification that is being mapped to. 753 */ 754 public String getName() { 755 return this.name == null ? null : this.name.getValue(); 756 } 757 758 /** 759 * @param value A name for the specification that is being mapped to. 760 */ 761 public StructureDefinitionMappingComponent setName(String value) { 762 if (Utilities.noString(value)) 763 this.name = null; 764 else { 765 if (this.name == null) 766 this.name = new StringType(); 767 this.name.setValue(value); 768 } 769 return this; 770 } 771 772 /** 773 * @return {@link #comments} (Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage.). This is the underlying object with id, value and extensions. The accessor "getComments" gives direct access to the value 774 */ 775 public StringType getCommentsElement() { 776 if (this.comments == null) 777 if (Configuration.errorOnAutoCreate()) 778 throw new Error("Attempt to auto-create StructureDefinitionMappingComponent.comments"); 779 else if (Configuration.doAutoCreate()) 780 this.comments = new StringType(); // bb 781 return this.comments; 782 } 783 784 public boolean hasCommentsElement() { 785 return this.comments != null && !this.comments.isEmpty(); 786 } 787 788 public boolean hasComments() { 789 return this.comments != null && !this.comments.isEmpty(); 790 } 791 792 /** 793 * @param value {@link #comments} (Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage.). This is the underlying object with id, value and extensions. The accessor "getComments" gives direct access to the value 794 */ 795 public StructureDefinitionMappingComponent setCommentsElement(StringType value) { 796 this.comments = value; 797 return this; 798 } 799 800 /** 801 * @return Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage. 802 */ 803 public String getComments() { 804 return this.comments == null ? null : this.comments.getValue(); 805 } 806 807 /** 808 * @param value Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage. 809 */ 810 public StructureDefinitionMappingComponent setComments(String value) { 811 if (Utilities.noString(value)) 812 this.comments = null; 813 else { 814 if (this.comments == null) 815 this.comments = new StringType(); 816 this.comments.setValue(value); 817 } 818 return this; 819 } 820 821 protected void listChildren(List<Property> childrenList) { 822 super.listChildren(childrenList); 823 childrenList.add(new Property("identity", "id", "An Internal id that is used to identify this mapping set when specific mappings are made.", 0, java.lang.Integer.MAX_VALUE, identity)); 824 childrenList.add(new Property("uri", "uri", "An absolute URI that identifies the specification that this mapping is expressed to.", 0, java.lang.Integer.MAX_VALUE, uri)); 825 childrenList.add(new Property("name", "string", "A name for the specification that is being mapped to.", 0, java.lang.Integer.MAX_VALUE, name)); 826 childrenList.add(new Property("comments", "string", "Comments about this mapping, including version notes, issues, scope limitations, and other important notes for usage.", 0, java.lang.Integer.MAX_VALUE, comments)); 827 } 828 829 @Override 830 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 831 switch (hash) { 832 case -135761730: /*identity*/ return this.identity == null ? new Base[0] : new Base[] {this.identity}; // IdType 833 case 116076: /*uri*/ return this.uri == null ? new Base[0] : new Base[] {this.uri}; // UriType 834 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 835 case -602415628: /*comments*/ return this.comments == null ? new Base[0] : new Base[] {this.comments}; // StringType 836 default: return super.getProperty(hash, name, checkValid); 837 } 838 839 } 840 841 @Override 842 public void setProperty(int hash, String name, Base value) throws FHIRException { 843 switch (hash) { 844 case -135761730: // identity 845 this.identity = castToId(value); // IdType 846 break; 847 case 116076: // uri 848 this.uri = castToUri(value); // UriType 849 break; 850 case 3373707: // name 851 this.name = castToString(value); // StringType 852 break; 853 case -602415628: // comments 854 this.comments = castToString(value); // StringType 855 break; 856 default: super.setProperty(hash, name, value); 857 } 858 859 } 860 861 @Override 862 public void setProperty(String name, Base value) throws FHIRException { 863 if (name.equals("identity")) 864 this.identity = castToId(value); // IdType 865 else if (name.equals("uri")) 866 this.uri = castToUri(value); // UriType 867 else if (name.equals("name")) 868 this.name = castToString(value); // StringType 869 else if (name.equals("comments")) 870 this.comments = castToString(value); // StringType 871 else 872 super.setProperty(name, value); 873 } 874 875 @Override 876 public Base makeProperty(int hash, String name) throws FHIRException { 877 switch (hash) { 878 case -135761730: throw new FHIRException("Cannot make property identity as it is not a complex type"); // IdType 879 case 116076: throw new FHIRException("Cannot make property uri as it is not a complex type"); // UriType 880 case 3373707: throw new FHIRException("Cannot make property name as it is not a complex type"); // StringType 881 case -602415628: throw new FHIRException("Cannot make property comments as it is not a complex type"); // StringType 882 default: return super.makeProperty(hash, name); 883 } 884 885 } 886 887 @Override 888 public Base addChild(String name) throws FHIRException { 889 if (name.equals("identity")) { 890 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.identity"); 891 } 892 else if (name.equals("uri")) { 893 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.uri"); 894 } 895 else if (name.equals("name")) { 896 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.name"); 897 } 898 else if (name.equals("comments")) { 899 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.comments"); 900 } 901 else 902 return super.addChild(name); 903 } 904 905 public StructureDefinitionMappingComponent copy() { 906 StructureDefinitionMappingComponent dst = new StructureDefinitionMappingComponent(); 907 copyValues(dst); 908 dst.identity = identity == null ? null : identity.copy(); 909 dst.uri = uri == null ? null : uri.copy(); 910 dst.name = name == null ? null : name.copy(); 911 dst.comments = comments == null ? null : comments.copy(); 912 return dst; 913 } 914 915 @Override 916 public boolean equalsDeep(Base other) { 917 if (!super.equalsDeep(other)) 918 return false; 919 if (!(other instanceof StructureDefinitionMappingComponent)) 920 return false; 921 StructureDefinitionMappingComponent o = (StructureDefinitionMappingComponent) other; 922 return compareDeep(identity, o.identity, true) && compareDeep(uri, o.uri, true) && compareDeep(name, o.name, true) 923 && compareDeep(comments, o.comments, true); 924 } 925 926 @Override 927 public boolean equalsShallow(Base other) { 928 if (!super.equalsShallow(other)) 929 return false; 930 if (!(other instanceof StructureDefinitionMappingComponent)) 931 return false; 932 StructureDefinitionMappingComponent o = (StructureDefinitionMappingComponent) other; 933 return compareValues(identity, o.identity, true) && compareValues(uri, o.uri, true) && compareValues(name, o.name, true) 934 && compareValues(comments, o.comments, true); 935 } 936 937 public boolean isEmpty() { 938 return super.isEmpty() && (identity == null || identity.isEmpty()) && (uri == null || uri.isEmpty()) 939 && (name == null || name.isEmpty()) && (comments == null || comments.isEmpty()); 940 } 941 942 public String fhirType() { 943 return "StructureDefinition.mapping"; 944 945 } 946 947 } 948 949 @Block() 950 public static class StructureDefinitionSnapshotComponent extends BackboneElement implements IBaseBackboneElement { 951 /** 952 * Captures constraints on each element within the resource. 953 */ 954 @Child(name = "element", type = {ElementDefinition.class}, order=1, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 955 @Description(shortDefinition="Definition of elements in the resource (if no StructureDefinition)", formalDefinition="Captures constraints on each element within the resource." ) 956 protected List<ElementDefinition> element; 957 958 private static final long serialVersionUID = 53896641L; 959 960 /** 961 * Constructor 962 */ 963 public StructureDefinitionSnapshotComponent() { 964 super(); 965 } 966 967 /** 968 * @return {@link #element} (Captures constraints on each element within the resource.) 969 */ 970 public List<ElementDefinition> getElement() { 971 if (this.element == null) 972 this.element = new ArrayList<ElementDefinition>(); 973 return this.element; 974 } 975 976 public boolean hasElement() { 977 if (this.element == null) 978 return false; 979 for (ElementDefinition item : this.element) 980 if (!item.isEmpty()) 981 return true; 982 return false; 983 } 984 985 /** 986 * @return {@link #element} (Captures constraints on each element within the resource.) 987 */ 988 // syntactic sugar 989 public ElementDefinition addElement() { //3 990 ElementDefinition t = new ElementDefinition(); 991 if (this.element == null) 992 this.element = new ArrayList<ElementDefinition>(); 993 this.element.add(t); 994 return t; 995 } 996 997 // syntactic sugar 998 public StructureDefinitionSnapshotComponent addElement(ElementDefinition t) { //3 999 if (t == null) 1000 return this; 1001 if (this.element == null) 1002 this.element = new ArrayList<ElementDefinition>(); 1003 this.element.add(t); 1004 return this; 1005 } 1006 1007 protected void listChildren(List<Property> childrenList) { 1008 super.listChildren(childrenList); 1009 childrenList.add(new Property("element", "ElementDefinition", "Captures constraints on each element within the resource.", 0, java.lang.Integer.MAX_VALUE, element)); 1010 } 1011 1012 @Override 1013 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1014 switch (hash) { 1015 case -1662836996: /*element*/ return this.element == null ? new Base[0] : this.element.toArray(new Base[this.element.size()]); // ElementDefinition 1016 default: return super.getProperty(hash, name, checkValid); 1017 } 1018 1019 } 1020 1021 @Override 1022 public void setProperty(int hash, String name, Base value) throws FHIRException { 1023 switch (hash) { 1024 case -1662836996: // element 1025 this.getElement().add(castToElementDefinition(value)); // ElementDefinition 1026 break; 1027 default: super.setProperty(hash, name, value); 1028 } 1029 1030 } 1031 1032 @Override 1033 public void setProperty(String name, Base value) throws FHIRException { 1034 if (name.equals("element")) 1035 this.getElement().add(castToElementDefinition(value)); 1036 else 1037 super.setProperty(name, value); 1038 } 1039 1040 @Override 1041 public Base makeProperty(int hash, String name) throws FHIRException { 1042 switch (hash) { 1043 case -1662836996: return addElement(); // ElementDefinition 1044 default: return super.makeProperty(hash, name); 1045 } 1046 1047 } 1048 1049 @Override 1050 public Base addChild(String name) throws FHIRException { 1051 if (name.equals("element")) { 1052 return addElement(); 1053 } 1054 else 1055 return super.addChild(name); 1056 } 1057 1058 public StructureDefinitionSnapshotComponent copy() { 1059 StructureDefinitionSnapshotComponent dst = new StructureDefinitionSnapshotComponent(); 1060 copyValues(dst); 1061 if (element != null) { 1062 dst.element = new ArrayList<ElementDefinition>(); 1063 for (ElementDefinition i : element) 1064 dst.element.add(i.copy()); 1065 }; 1066 return dst; 1067 } 1068 1069 @Override 1070 public boolean equalsDeep(Base other) { 1071 if (!super.equalsDeep(other)) 1072 return false; 1073 if (!(other instanceof StructureDefinitionSnapshotComponent)) 1074 return false; 1075 StructureDefinitionSnapshotComponent o = (StructureDefinitionSnapshotComponent) other; 1076 return compareDeep(element, o.element, true); 1077 } 1078 1079 @Override 1080 public boolean equalsShallow(Base other) { 1081 if (!super.equalsShallow(other)) 1082 return false; 1083 if (!(other instanceof StructureDefinitionSnapshotComponent)) 1084 return false; 1085 StructureDefinitionSnapshotComponent o = (StructureDefinitionSnapshotComponent) other; 1086 return true; 1087 } 1088 1089 public boolean isEmpty() { 1090 return super.isEmpty() && (element == null || element.isEmpty()); 1091 } 1092 1093 public String fhirType() { 1094 return "StructureDefinition.snapshot"; 1095 1096 } 1097 1098 } 1099 1100 @Block() 1101 public static class StructureDefinitionDifferentialComponent extends BackboneElement implements IBaseBackboneElement { 1102 /** 1103 * Captures constraints on each element within the resource. 1104 */ 1105 @Child(name = "element", type = {ElementDefinition.class}, order=1, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1106 @Description(shortDefinition="Definition of elements in the resource (if no StructureDefinition)", formalDefinition="Captures constraints on each element within the resource." ) 1107 protected List<ElementDefinition> element; 1108 1109 private static final long serialVersionUID = 53896641L; 1110 1111 /** 1112 * Constructor 1113 */ 1114 public StructureDefinitionDifferentialComponent() { 1115 super(); 1116 } 1117 1118 /** 1119 * @return {@link #element} (Captures constraints on each element within the resource.) 1120 */ 1121 public List<ElementDefinition> getElement() { 1122 if (this.element == null) 1123 this.element = new ArrayList<ElementDefinition>(); 1124 return this.element; 1125 } 1126 1127 public boolean hasElement() { 1128 if (this.element == null) 1129 return false; 1130 for (ElementDefinition item : this.element) 1131 if (!item.isEmpty()) 1132 return true; 1133 return false; 1134 } 1135 1136 /** 1137 * @return {@link #element} (Captures constraints on each element within the resource.) 1138 */ 1139 // syntactic sugar 1140 public ElementDefinition addElement() { //3 1141 ElementDefinition t = new ElementDefinition(); 1142 if (this.element == null) 1143 this.element = new ArrayList<ElementDefinition>(); 1144 this.element.add(t); 1145 return t; 1146 } 1147 1148 // syntactic sugar 1149 public StructureDefinitionDifferentialComponent addElement(ElementDefinition t) { //3 1150 if (t == null) 1151 return this; 1152 if (this.element == null) 1153 this.element = new ArrayList<ElementDefinition>(); 1154 this.element.add(t); 1155 return this; 1156 } 1157 1158 protected void listChildren(List<Property> childrenList) { 1159 super.listChildren(childrenList); 1160 childrenList.add(new Property("element", "ElementDefinition", "Captures constraints on each element within the resource.", 0, java.lang.Integer.MAX_VALUE, element)); 1161 } 1162 1163 @Override 1164 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1165 switch (hash) { 1166 case -1662836996: /*element*/ return this.element == null ? new Base[0] : this.element.toArray(new Base[this.element.size()]); // ElementDefinition 1167 default: return super.getProperty(hash, name, checkValid); 1168 } 1169 1170 } 1171 1172 @Override 1173 public void setProperty(int hash, String name, Base value) throws FHIRException { 1174 switch (hash) { 1175 case -1662836996: // element 1176 this.getElement().add(castToElementDefinition(value)); // ElementDefinition 1177 break; 1178 default: super.setProperty(hash, name, value); 1179 } 1180 1181 } 1182 1183 @Override 1184 public void setProperty(String name, Base value) throws FHIRException { 1185 if (name.equals("element")) 1186 this.getElement().add(castToElementDefinition(value)); 1187 else 1188 super.setProperty(name, value); 1189 } 1190 1191 @Override 1192 public Base makeProperty(int hash, String name) throws FHIRException { 1193 switch (hash) { 1194 case -1662836996: return addElement(); // ElementDefinition 1195 default: return super.makeProperty(hash, name); 1196 } 1197 1198 } 1199 1200 @Override 1201 public Base addChild(String name) throws FHIRException { 1202 if (name.equals("element")) { 1203 return addElement(); 1204 } 1205 else 1206 return super.addChild(name); 1207 } 1208 1209 public StructureDefinitionDifferentialComponent copy() { 1210 StructureDefinitionDifferentialComponent dst = new StructureDefinitionDifferentialComponent(); 1211 copyValues(dst); 1212 if (element != null) { 1213 dst.element = new ArrayList<ElementDefinition>(); 1214 for (ElementDefinition i : element) 1215 dst.element.add(i.copy()); 1216 }; 1217 return dst; 1218 } 1219 1220 @Override 1221 public boolean equalsDeep(Base other) { 1222 if (!super.equalsDeep(other)) 1223 return false; 1224 if (!(other instanceof StructureDefinitionDifferentialComponent)) 1225 return false; 1226 StructureDefinitionDifferentialComponent o = (StructureDefinitionDifferentialComponent) other; 1227 return compareDeep(element, o.element, true); 1228 } 1229 1230 @Override 1231 public boolean equalsShallow(Base other) { 1232 if (!super.equalsShallow(other)) 1233 return false; 1234 if (!(other instanceof StructureDefinitionDifferentialComponent)) 1235 return false; 1236 StructureDefinitionDifferentialComponent o = (StructureDefinitionDifferentialComponent) other; 1237 return true; 1238 } 1239 1240 public boolean isEmpty() { 1241 return super.isEmpty() && (element == null || element.isEmpty()); 1242 } 1243 1244 public String fhirType() { 1245 return "StructureDefinition.differential"; 1246 1247 } 1248 1249 } 1250 1251 /** 1252 * An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published. 1253 */ 1254 @Child(name = "url", type = {UriType.class}, order=0, min=1, max=1, modifier=false, summary=true) 1255 @Description(shortDefinition="Absolute URL used to reference this StructureDefinition", formalDefinition="An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published." ) 1256 protected UriType url; 1257 1258 /** 1259 * Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI). 1260 */ 1261 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1262 @Description(shortDefinition="Other identifiers for the StructureDefinition", formalDefinition="Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI)." ) 1263 protected List<Identifier> identifier; 1264 1265 /** 1266 * The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually. 1267 */ 1268 @Child(name = "version", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=true) 1269 @Description(shortDefinition="Logical id for this version of the StructureDefinition", formalDefinition="The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually." ) 1270 protected StringType version; 1271 1272 /** 1273 * A free text natural language name identifying the StructureDefinition. 1274 */ 1275 @Child(name = "name", type = {StringType.class}, order=3, min=1, max=1, modifier=false, summary=true) 1276 @Description(shortDefinition="Informal name for this StructureDefinition", formalDefinition="A free text natural language name identifying the StructureDefinition." ) 1277 protected StringType name; 1278 1279 /** 1280 * Defined so that applications can use this name when displaying the value of the extension to the user. 1281 */ 1282 @Child(name = "display", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=true) 1283 @Description(shortDefinition="Use this name when displaying the value", formalDefinition="Defined so that applications can use this name when displaying the value of the extension to the user." ) 1284 protected StringType display; 1285 1286 /** 1287 * The status of the StructureDefinition. 1288 */ 1289 @Child(name = "status", type = {CodeType.class}, order=5, min=1, max=1, modifier=true, summary=true) 1290 @Description(shortDefinition="draft | active | retired", formalDefinition="The status of the StructureDefinition." ) 1291 protected Enumeration<ConformanceResourceStatus> status; 1292 1293 /** 1294 * This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 1295 */ 1296 @Child(name = "experimental", type = {BooleanType.class}, order=6, min=0, max=1, modifier=false, summary=true) 1297 @Description(shortDefinition="If for testing purposes, not real usage", formalDefinition="This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage." ) 1298 protected BooleanType experimental; 1299 1300 /** 1301 * The name of the individual or organization that published the structure definition. 1302 */ 1303 @Child(name = "publisher", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=true) 1304 @Description(shortDefinition="Name of the publisher (Organization or individual)", formalDefinition="The name of the individual or organization that published the structure definition." ) 1305 protected StringType publisher; 1306 1307 /** 1308 * Contacts to assist a user in finding and communicating with the publisher. 1309 */ 1310 @Child(name = "contact", type = {}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1311 @Description(shortDefinition="Contact details of the publisher", formalDefinition="Contacts to assist a user in finding and communicating with the publisher." ) 1312 protected List<StructureDefinitionContactComponent> contact; 1313 1314 /** 1315 * The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes. 1316 */ 1317 @Child(name = "date", type = {DateTimeType.class}, order=9, min=0, max=1, modifier=false, summary=true) 1318 @Description(shortDefinition="Date for this version of the StructureDefinition", formalDefinition="The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes." ) 1319 protected DateTimeType date; 1320 1321 /** 1322 * A free text natural language description of the StructureDefinition and its use. 1323 */ 1324 @Child(name = "description", type = {StringType.class}, order=10, min=0, max=1, modifier=false, summary=true) 1325 @Description(shortDefinition="Natural language description of the StructureDefinition", formalDefinition="A free text natural language description of the StructureDefinition and its use." ) 1326 protected StringType description; 1327 1328 /** 1329 * The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions. 1330 */ 1331 @Child(name = "useContext", type = {CodeableConcept.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1332 @Description(shortDefinition="Content intends to support these contexts", formalDefinition="The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions." ) 1333 protected List<CodeableConcept> useContext; 1334 1335 /** 1336 * Explains why this structure definition is needed and why it's been constrained as it has. 1337 */ 1338 @Child(name = "requirements", type = {StringType.class}, order=12, min=0, max=1, modifier=false, summary=false) 1339 @Description(shortDefinition="Scope and Usage this structure definition is for", formalDefinition="Explains why this structure definition is needed and why it's been constrained as it has." ) 1340 protected StringType requirements; 1341 1342 /** 1343 * A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings. 1344 */ 1345 @Child(name = "copyright", type = {StringType.class}, order=13, min=0, max=1, modifier=false, summary=false) 1346 @Description(shortDefinition="Use and/or publishing restrictions", formalDefinition="A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings." ) 1347 protected StringType copyright; 1348 1349 /** 1350 * A set of terms from external terminologies that may be used to assist with indexing and searching of templates. 1351 */ 1352 @Child(name = "code", type = {Coding.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1353 @Description(shortDefinition="Assist with indexing and finding", formalDefinition="A set of terms from external terminologies that may be used to assist with indexing and searching of templates." ) 1354 protected List<Coding> code; 1355 1356 /** 1357 * The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version. 1358 */ 1359 @Child(name = "fhirVersion", type = {IdType.class}, order=15, min=0, max=1, modifier=false, summary=true) 1360 @Description(shortDefinition="FHIR Version this StructureDefinition targets", formalDefinition="The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version." ) 1361 protected IdType fhirVersion; 1362 1363 /** 1364 * An external specification that the content is mapped to. 1365 */ 1366 @Child(name = "mapping", type = {}, order=16, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1367 @Description(shortDefinition="External specification that the content is mapped to", formalDefinition="An external specification that the content is mapped to." ) 1368 protected List<StructureDefinitionMappingComponent> mapping; 1369 1370 /** 1371 * Defines the kind of structure that this definition is describing. 1372 */ 1373 @Child(name = "kind", type = {CodeType.class}, order=17, min=1, max=1, modifier=false, summary=true) 1374 @Description(shortDefinition="datatype | resource | logical", formalDefinition="Defines the kind of structure that this definition is describing." ) 1375 protected Enumeration<StructureDefinitionKind> kind; 1376 1377 /** 1378 * Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type. 1379 */ 1380 @Child(name = "abstract", type = {BooleanType.class}, order=18, min=1, max=1, modifier=false, summary=true) 1381 @Description(shortDefinition="Whether the structure is abstract", formalDefinition="Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type." ) 1382 protected BooleanType abstract_; 1383 1384 /** 1385 * If this is an extension, Identifies the context within FHIR resources where the extension can be used. 1386 */ 1387 @Child(name = "contextType", type = {CodeType.class}, order=19, min=0, max=1, modifier=false, summary=true) 1388 @Description(shortDefinition="resource | datatype | extension", formalDefinition="If this is an extension, Identifies the context within FHIR resources where the extension can be used." ) 1389 protected Enumeration<ExtensionContext> contextType; 1390 1391 /** 1392 * Identifies the types of resource or data type elements to which the extension can be applied. 1393 */ 1394 @Child(name = "context", type = {StringType.class}, order=20, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1395 @Description(shortDefinition="Where the extension can be used in instances", formalDefinition="Identifies the types of resource or data type elements to which the extension can be applied." ) 1396 protected List<StringType> context; 1397 1398 /** 1399 * The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure. 1400 */ 1401 @Child(name = "baseType", type = {CodeType.class}, order=21, min=0, max=1, modifier=false, summary=true) 1402 @Description(shortDefinition="Any datatype or resource, including abstract ones", formalDefinition="The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure." ) 1403 protected CodeType baseType; 1404 1405 /** 1406 * An absolute URI that is the base structure from which this type is derived, either by specialization or constraint. 1407 */ 1408 @Child(name = "baseDefinition", type = {UriType.class}, order=22, min=0, max=1, modifier=false, summary=true) 1409 @Description(shortDefinition="Definition that this type is constrained/specialized from", formalDefinition="An absolute URI that is the base structure from which this type is derived, either by specialization or constraint." ) 1410 protected UriType baseDefinition; 1411 1412 /** 1413 * How the type relates to the baseDefinition. 1414 */ 1415 @Child(name = "derivation", type = {CodeType.class}, order=23, min=0, max=1, modifier=false, summary=true) 1416 @Description(shortDefinition="specialization | constraint - How relates to base definition", formalDefinition="How the type relates to the baseDefinition." ) 1417 protected Enumeration<TypeDerivationRule> derivation; 1418 1419 /** 1420 * A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition. 1421 */ 1422 @Child(name = "snapshot", type = {}, order=24, min=0, max=1, modifier=false, summary=false) 1423 @Description(shortDefinition="Snapshot view of the structure", formalDefinition="A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition." ) 1424 protected StructureDefinitionSnapshotComponent snapshot; 1425 1426 /** 1427 * A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies. 1428 */ 1429 @Child(name = "differential", type = {}, order=25, min=0, max=1, modifier=false, summary=false) 1430 @Description(shortDefinition="Differential view of the structure", formalDefinition="A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies." ) 1431 protected StructureDefinitionDifferentialComponent differential; 1432 1433 private static final long serialVersionUID = -1505153076L; 1434 1435 /** 1436 * Constructor 1437 */ 1438 public StructureDefinition() { 1439 super(); 1440 } 1441 1442 /** 1443 * Constructor 1444 */ 1445 public StructureDefinition(UriType url, StringType name, Enumeration<ConformanceResourceStatus> status, Enumeration<StructureDefinitionKind> kind, BooleanType abstract_) { 1446 super(); 1447 this.url = url; 1448 this.name = name; 1449 this.status = status; 1450 this.kind = kind; 1451 this.abstract_ = abstract_; 1452 } 1453 1454 /** 1455 * @return {@link #url} (An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 1456 */ 1457 public UriType getUrlElement() { 1458 if (this.url == null) 1459 if (Configuration.errorOnAutoCreate()) 1460 throw new Error("Attempt to auto-create StructureDefinition.url"); 1461 else if (Configuration.doAutoCreate()) 1462 this.url = new UriType(); // bb 1463 return this.url; 1464 } 1465 1466 public boolean hasUrlElement() { 1467 return this.url != null && !this.url.isEmpty(); 1468 } 1469 1470 public boolean hasUrl() { 1471 return this.url != null && !this.url.isEmpty(); 1472 } 1473 1474 /** 1475 * @param value {@link #url} (An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 1476 */ 1477 public StructureDefinition setUrlElement(UriType value) { 1478 this.url = value; 1479 return this; 1480 } 1481 1482 /** 1483 * @return An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published. 1484 */ 1485 public String getUrl() { 1486 return this.url == null ? null : this.url.getValue(); 1487 } 1488 1489 /** 1490 * @param value An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published. 1491 */ 1492 public StructureDefinition setUrl(String value) { 1493 if (this.url == null) 1494 this.url = new UriType(); 1495 this.url.setValue(value); 1496 return this; 1497 } 1498 1499 /** 1500 * @return {@link #identifier} (Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI).) 1501 */ 1502 public List<Identifier> getIdentifier() { 1503 if (this.identifier == null) 1504 this.identifier = new ArrayList<Identifier>(); 1505 return this.identifier; 1506 } 1507 1508 public boolean hasIdentifier() { 1509 if (this.identifier == null) 1510 return false; 1511 for (Identifier item : this.identifier) 1512 if (!item.isEmpty()) 1513 return true; 1514 return false; 1515 } 1516 1517 /** 1518 * @return {@link #identifier} (Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI).) 1519 */ 1520 // syntactic sugar 1521 public Identifier addIdentifier() { //3 1522 Identifier t = new Identifier(); 1523 if (this.identifier == null) 1524 this.identifier = new ArrayList<Identifier>(); 1525 this.identifier.add(t); 1526 return t; 1527 } 1528 1529 // syntactic sugar 1530 public StructureDefinition addIdentifier(Identifier t) { //3 1531 if (t == null) 1532 return this; 1533 if (this.identifier == null) 1534 this.identifier = new ArrayList<Identifier>(); 1535 this.identifier.add(t); 1536 return this; 1537 } 1538 1539 /** 1540 * @return {@link #version} (The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 1541 */ 1542 public StringType getVersionElement() { 1543 if (this.version == null) 1544 if (Configuration.errorOnAutoCreate()) 1545 throw new Error("Attempt to auto-create StructureDefinition.version"); 1546 else if (Configuration.doAutoCreate()) 1547 this.version = new StringType(); // bb 1548 return this.version; 1549 } 1550 1551 public boolean hasVersionElement() { 1552 return this.version != null && !this.version.isEmpty(); 1553 } 1554 1555 public boolean hasVersion() { 1556 return this.version != null && !this.version.isEmpty(); 1557 } 1558 1559 /** 1560 * @param value {@link #version} (The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 1561 */ 1562 public StructureDefinition setVersionElement(StringType value) { 1563 this.version = value; 1564 return this; 1565 } 1566 1567 /** 1568 * @return The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually. 1569 */ 1570 public String getVersion() { 1571 return this.version == null ? null : this.version.getValue(); 1572 } 1573 1574 /** 1575 * @param value The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually. 1576 */ 1577 public StructureDefinition setVersion(String value) { 1578 if (Utilities.noString(value)) 1579 this.version = null; 1580 else { 1581 if (this.version == null) 1582 this.version = new StringType(); 1583 this.version.setValue(value); 1584 } 1585 return this; 1586 } 1587 1588 /** 1589 * @return {@link #name} (A free text natural language name identifying the StructureDefinition.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 1590 */ 1591 public StringType getNameElement() { 1592 if (this.name == null) 1593 if (Configuration.errorOnAutoCreate()) 1594 throw new Error("Attempt to auto-create StructureDefinition.name"); 1595 else if (Configuration.doAutoCreate()) 1596 this.name = new StringType(); // bb 1597 return this.name; 1598 } 1599 1600 public boolean hasNameElement() { 1601 return this.name != null && !this.name.isEmpty(); 1602 } 1603 1604 public boolean hasName() { 1605 return this.name != null && !this.name.isEmpty(); 1606 } 1607 1608 /** 1609 * @param value {@link #name} (A free text natural language name identifying the StructureDefinition.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 1610 */ 1611 public StructureDefinition setNameElement(StringType value) { 1612 this.name = value; 1613 return this; 1614 } 1615 1616 /** 1617 * @return A free text natural language name identifying the StructureDefinition. 1618 */ 1619 public String getName() { 1620 return this.name == null ? null : this.name.getValue(); 1621 } 1622 1623 /** 1624 * @param value A free text natural language name identifying the StructureDefinition. 1625 */ 1626 public StructureDefinition setName(String value) { 1627 if (this.name == null) 1628 this.name = new StringType(); 1629 this.name.setValue(value); 1630 return this; 1631 } 1632 1633 /** 1634 * @return {@link #display} (Defined so that applications can use this name when displaying the value of the extension to the user.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 1635 */ 1636 public StringType getDisplayElement() { 1637 if (this.display == null) 1638 if (Configuration.errorOnAutoCreate()) 1639 throw new Error("Attempt to auto-create StructureDefinition.display"); 1640 else if (Configuration.doAutoCreate()) 1641 this.display = new StringType(); // bb 1642 return this.display; 1643 } 1644 1645 public boolean hasDisplayElement() { 1646 return this.display != null && !this.display.isEmpty(); 1647 } 1648 1649 public boolean hasDisplay() { 1650 return this.display != null && !this.display.isEmpty(); 1651 } 1652 1653 /** 1654 * @param value {@link #display} (Defined so that applications can use this name when displaying the value of the extension to the user.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 1655 */ 1656 public StructureDefinition setDisplayElement(StringType value) { 1657 this.display = value; 1658 return this; 1659 } 1660 1661 /** 1662 * @return Defined so that applications can use this name when displaying the value of the extension to the user. 1663 */ 1664 public String getDisplay() { 1665 return this.display == null ? null : this.display.getValue(); 1666 } 1667 1668 /** 1669 * @param value Defined so that applications can use this name when displaying the value of the extension to the user. 1670 */ 1671 public StructureDefinition setDisplay(String value) { 1672 if (Utilities.noString(value)) 1673 this.display = null; 1674 else { 1675 if (this.display == null) 1676 this.display = new StringType(); 1677 this.display.setValue(value); 1678 } 1679 return this; 1680 } 1681 1682 /** 1683 * @return {@link #status} (The status of the StructureDefinition.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1684 */ 1685 public Enumeration<ConformanceResourceStatus> getStatusElement() { 1686 if (this.status == null) 1687 if (Configuration.errorOnAutoCreate()) 1688 throw new Error("Attempt to auto-create StructureDefinition.status"); 1689 else if (Configuration.doAutoCreate()) 1690 this.status = new Enumeration<ConformanceResourceStatus>(new ConformanceResourceStatusEnumFactory()); // bb 1691 return this.status; 1692 } 1693 1694 public boolean hasStatusElement() { 1695 return this.status != null && !this.status.isEmpty(); 1696 } 1697 1698 public boolean hasStatus() { 1699 return this.status != null && !this.status.isEmpty(); 1700 } 1701 1702 /** 1703 * @param value {@link #status} (The status of the StructureDefinition.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1704 */ 1705 public StructureDefinition setStatusElement(Enumeration<ConformanceResourceStatus> value) { 1706 this.status = value; 1707 return this; 1708 } 1709 1710 /** 1711 * @return The status of the StructureDefinition. 1712 */ 1713 public ConformanceResourceStatus getStatus() { 1714 return this.status == null ? null : this.status.getValue(); 1715 } 1716 1717 /** 1718 * @param value The status of the StructureDefinition. 1719 */ 1720 public StructureDefinition setStatus(ConformanceResourceStatus value) { 1721 if (this.status == null) 1722 this.status = new Enumeration<ConformanceResourceStatus>(new ConformanceResourceStatusEnumFactory()); 1723 this.status.setValue(value); 1724 return this; 1725 } 1726 1727 /** 1728 * @return {@link #experimental} (This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value 1729 */ 1730 public BooleanType getExperimentalElement() { 1731 if (this.experimental == null) 1732 if (Configuration.errorOnAutoCreate()) 1733 throw new Error("Attempt to auto-create StructureDefinition.experimental"); 1734 else if (Configuration.doAutoCreate()) 1735 this.experimental = new BooleanType(); // bb 1736 return this.experimental; 1737 } 1738 1739 public boolean hasExperimentalElement() { 1740 return this.experimental != null && !this.experimental.isEmpty(); 1741 } 1742 1743 public boolean hasExperimental() { 1744 return this.experimental != null && !this.experimental.isEmpty(); 1745 } 1746 1747 /** 1748 * @param value {@link #experimental} (This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage.). This is the underlying object with id, value and extensions. The accessor "getExperimental" gives direct access to the value 1749 */ 1750 public StructureDefinition setExperimentalElement(BooleanType value) { 1751 this.experimental = value; 1752 return this; 1753 } 1754 1755 /** 1756 * @return This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 1757 */ 1758 public boolean getExperimental() { 1759 return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue(); 1760 } 1761 1762 /** 1763 * @param value This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage. 1764 */ 1765 public StructureDefinition setExperimental(boolean value) { 1766 if (this.experimental == null) 1767 this.experimental = new BooleanType(); 1768 this.experimental.setValue(value); 1769 return this; 1770 } 1771 1772 /** 1773 * @return {@link #publisher} (The name of the individual or organization that published the structure definition.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value 1774 */ 1775 public StringType getPublisherElement() { 1776 if (this.publisher == null) 1777 if (Configuration.errorOnAutoCreate()) 1778 throw new Error("Attempt to auto-create StructureDefinition.publisher"); 1779 else if (Configuration.doAutoCreate()) 1780 this.publisher = new StringType(); // bb 1781 return this.publisher; 1782 } 1783 1784 public boolean hasPublisherElement() { 1785 return this.publisher != null && !this.publisher.isEmpty(); 1786 } 1787 1788 public boolean hasPublisher() { 1789 return this.publisher != null && !this.publisher.isEmpty(); 1790 } 1791 1792 /** 1793 * @param value {@link #publisher} (The name of the individual or organization that published the structure definition.). This is the underlying object with id, value and extensions. The accessor "getPublisher" gives direct access to the value 1794 */ 1795 public StructureDefinition setPublisherElement(StringType value) { 1796 this.publisher = value; 1797 return this; 1798 } 1799 1800 /** 1801 * @return The name of the individual or organization that published the structure definition. 1802 */ 1803 public String getPublisher() { 1804 return this.publisher == null ? null : this.publisher.getValue(); 1805 } 1806 1807 /** 1808 * @param value The name of the individual or organization that published the structure definition. 1809 */ 1810 public StructureDefinition setPublisher(String value) { 1811 if (Utilities.noString(value)) 1812 this.publisher = null; 1813 else { 1814 if (this.publisher == null) 1815 this.publisher = new StringType(); 1816 this.publisher.setValue(value); 1817 } 1818 return this; 1819 } 1820 1821 /** 1822 * @return {@link #contact} (Contacts to assist a user in finding and communicating with the publisher.) 1823 */ 1824 public List<StructureDefinitionContactComponent> getContact() { 1825 if (this.contact == null) 1826 this.contact = new ArrayList<StructureDefinitionContactComponent>(); 1827 return this.contact; 1828 } 1829 1830 public boolean hasContact() { 1831 if (this.contact == null) 1832 return false; 1833 for (StructureDefinitionContactComponent item : this.contact) 1834 if (!item.isEmpty()) 1835 return true; 1836 return false; 1837 } 1838 1839 /** 1840 * @return {@link #contact} (Contacts to assist a user in finding and communicating with the publisher.) 1841 */ 1842 // syntactic sugar 1843 public StructureDefinitionContactComponent addContact() { //3 1844 StructureDefinitionContactComponent t = new StructureDefinitionContactComponent(); 1845 if (this.contact == null) 1846 this.contact = new ArrayList<StructureDefinitionContactComponent>(); 1847 this.contact.add(t); 1848 return t; 1849 } 1850 1851 // syntactic sugar 1852 public StructureDefinition addContact(StructureDefinitionContactComponent t) { //3 1853 if (t == null) 1854 return this; 1855 if (this.contact == null) 1856 this.contact = new ArrayList<StructureDefinitionContactComponent>(); 1857 this.contact.add(t); 1858 return this; 1859 } 1860 1861 /** 1862 * @return {@link #date} (The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 1863 */ 1864 public DateTimeType getDateElement() { 1865 if (this.date == null) 1866 if (Configuration.errorOnAutoCreate()) 1867 throw new Error("Attempt to auto-create StructureDefinition.date"); 1868 else if (Configuration.doAutoCreate()) 1869 this.date = new DateTimeType(); // bb 1870 return this.date; 1871 } 1872 1873 public boolean hasDateElement() { 1874 return this.date != null && !this.date.isEmpty(); 1875 } 1876 1877 public boolean hasDate() { 1878 return this.date != null && !this.date.isEmpty(); 1879 } 1880 1881 /** 1882 * @param value {@link #date} (The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes.). This is the underlying object with id, value and extensions. The accessor "getDate" gives direct access to the value 1883 */ 1884 public StructureDefinition setDateElement(DateTimeType value) { 1885 this.date = value; 1886 return this; 1887 } 1888 1889 /** 1890 * @return The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes. 1891 */ 1892 public Date getDate() { 1893 return this.date == null ? null : this.date.getValue(); 1894 } 1895 1896 /** 1897 * @param value The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes. 1898 */ 1899 public StructureDefinition setDate(Date value) { 1900 if (value == null) 1901 this.date = null; 1902 else { 1903 if (this.date == null) 1904 this.date = new DateTimeType(); 1905 this.date.setValue(value); 1906 } 1907 return this; 1908 } 1909 1910 /** 1911 * @return {@link #description} (A free text natural language description of the StructureDefinition and its use.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1912 */ 1913 public StringType getDescriptionElement() { 1914 if (this.description == null) 1915 if (Configuration.errorOnAutoCreate()) 1916 throw new Error("Attempt to auto-create StructureDefinition.description"); 1917 else if (Configuration.doAutoCreate()) 1918 this.description = new StringType(); // bb 1919 return this.description; 1920 } 1921 1922 public boolean hasDescriptionElement() { 1923 return this.description != null && !this.description.isEmpty(); 1924 } 1925 1926 public boolean hasDescription() { 1927 return this.description != null && !this.description.isEmpty(); 1928 } 1929 1930 /** 1931 * @param value {@link #description} (A free text natural language description of the StructureDefinition and its use.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1932 */ 1933 public StructureDefinition setDescriptionElement(StringType value) { 1934 this.description = value; 1935 return this; 1936 } 1937 1938 /** 1939 * @return A free text natural language description of the StructureDefinition and its use. 1940 */ 1941 public String getDescription() { 1942 return this.description == null ? null : this.description.getValue(); 1943 } 1944 1945 /** 1946 * @param value A free text natural language description of the StructureDefinition and its use. 1947 */ 1948 public StructureDefinition setDescription(String value) { 1949 if (Utilities.noString(value)) 1950 this.description = null; 1951 else { 1952 if (this.description == null) 1953 this.description = new StringType(); 1954 this.description.setValue(value); 1955 } 1956 return this; 1957 } 1958 1959 /** 1960 * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.) 1961 */ 1962 public List<CodeableConcept> getUseContext() { 1963 if (this.useContext == null) 1964 this.useContext = new ArrayList<CodeableConcept>(); 1965 return this.useContext; 1966 } 1967 1968 public boolean hasUseContext() { 1969 if (this.useContext == null) 1970 return false; 1971 for (CodeableConcept item : this.useContext) 1972 if (!item.isEmpty()) 1973 return true; 1974 return false; 1975 } 1976 1977 /** 1978 * @return {@link #useContext} (The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.) 1979 */ 1980 // syntactic sugar 1981 public CodeableConcept addUseContext() { //3 1982 CodeableConcept t = new CodeableConcept(); 1983 if (this.useContext == null) 1984 this.useContext = new ArrayList<CodeableConcept>(); 1985 this.useContext.add(t); 1986 return t; 1987 } 1988 1989 // syntactic sugar 1990 public StructureDefinition addUseContext(CodeableConcept t) { //3 1991 if (t == null) 1992 return this; 1993 if (this.useContext == null) 1994 this.useContext = new ArrayList<CodeableConcept>(); 1995 this.useContext.add(t); 1996 return this; 1997 } 1998 1999 /** 2000 * @return {@link #requirements} (Explains why this structure definition is needed and why it's been constrained as it has.). This is the underlying object with id, value and extensions. The accessor "getRequirements" gives direct access to the value 2001 */ 2002 public StringType getRequirementsElement() { 2003 if (this.requirements == null) 2004 if (Configuration.errorOnAutoCreate()) 2005 throw new Error("Attempt to auto-create StructureDefinition.requirements"); 2006 else if (Configuration.doAutoCreate()) 2007 this.requirements = new StringType(); // bb 2008 return this.requirements; 2009 } 2010 2011 public boolean hasRequirementsElement() { 2012 return this.requirements != null && !this.requirements.isEmpty(); 2013 } 2014 2015 public boolean hasRequirements() { 2016 return this.requirements != null && !this.requirements.isEmpty(); 2017 } 2018 2019 /** 2020 * @param value {@link #requirements} (Explains why this structure definition is needed and why it's been constrained as it has.). This is the underlying object with id, value and extensions. The accessor "getRequirements" gives direct access to the value 2021 */ 2022 public StructureDefinition setRequirementsElement(StringType value) { 2023 this.requirements = value; 2024 return this; 2025 } 2026 2027 /** 2028 * @return Explains why this structure definition is needed and why it's been constrained as it has. 2029 */ 2030 public String getRequirements() { 2031 return this.requirements == null ? null : this.requirements.getValue(); 2032 } 2033 2034 /** 2035 * @param value Explains why this structure definition is needed and why it's been constrained as it has. 2036 */ 2037 public StructureDefinition setRequirements(String value) { 2038 if (Utilities.noString(value)) 2039 this.requirements = null; 2040 else { 2041 if (this.requirements == null) 2042 this.requirements = new StringType(); 2043 this.requirements.setValue(value); 2044 } 2045 return this; 2046 } 2047 2048 /** 2049 * @return {@link #copyright} (A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 2050 */ 2051 public StringType getCopyrightElement() { 2052 if (this.copyright == null) 2053 if (Configuration.errorOnAutoCreate()) 2054 throw new Error("Attempt to auto-create StructureDefinition.copyright"); 2055 else if (Configuration.doAutoCreate()) 2056 this.copyright = new StringType(); // bb 2057 return this.copyright; 2058 } 2059 2060 public boolean hasCopyrightElement() { 2061 return this.copyright != null && !this.copyright.isEmpty(); 2062 } 2063 2064 public boolean hasCopyright() { 2065 return this.copyright != null && !this.copyright.isEmpty(); 2066 } 2067 2068 /** 2069 * @param value {@link #copyright} (A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 2070 */ 2071 public StructureDefinition setCopyrightElement(StringType value) { 2072 this.copyright = value; 2073 return this; 2074 } 2075 2076 /** 2077 * @return A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings. 2078 */ 2079 public String getCopyright() { 2080 return this.copyright == null ? null : this.copyright.getValue(); 2081 } 2082 2083 /** 2084 * @param value A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings. 2085 */ 2086 public StructureDefinition setCopyright(String value) { 2087 if (Utilities.noString(value)) 2088 this.copyright = null; 2089 else { 2090 if (this.copyright == null) 2091 this.copyright = new StringType(); 2092 this.copyright.setValue(value); 2093 } 2094 return this; 2095 } 2096 2097 /** 2098 * @return {@link #code} (A set of terms from external terminologies that may be used to assist with indexing and searching of templates.) 2099 */ 2100 public List<Coding> getCode() { 2101 if (this.code == null) 2102 this.code = new ArrayList<Coding>(); 2103 return this.code; 2104 } 2105 2106 public boolean hasCode() { 2107 if (this.code == null) 2108 return false; 2109 for (Coding item : this.code) 2110 if (!item.isEmpty()) 2111 return true; 2112 return false; 2113 } 2114 2115 /** 2116 * @return {@link #code} (A set of terms from external terminologies that may be used to assist with indexing and searching of templates.) 2117 */ 2118 // syntactic sugar 2119 public Coding addCode() { //3 2120 Coding t = new Coding(); 2121 if (this.code == null) 2122 this.code = new ArrayList<Coding>(); 2123 this.code.add(t); 2124 return t; 2125 } 2126 2127 // syntactic sugar 2128 public StructureDefinition addCode(Coding t) { //3 2129 if (t == null) 2130 return this; 2131 if (this.code == null) 2132 this.code = new ArrayList<Coding>(); 2133 this.code.add(t); 2134 return this; 2135 } 2136 2137 /** 2138 * @return {@link #fhirVersion} (The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version.). This is the underlying object with id, value and extensions. The accessor "getFhirVersion" gives direct access to the value 2139 */ 2140 public IdType getFhirVersionElement() { 2141 if (this.fhirVersion == null) 2142 if (Configuration.errorOnAutoCreate()) 2143 throw new Error("Attempt to auto-create StructureDefinition.fhirVersion"); 2144 else if (Configuration.doAutoCreate()) 2145 this.fhirVersion = new IdType(); // bb 2146 return this.fhirVersion; 2147 } 2148 2149 public boolean hasFhirVersionElement() { 2150 return this.fhirVersion != null && !this.fhirVersion.isEmpty(); 2151 } 2152 2153 public boolean hasFhirVersion() { 2154 return this.fhirVersion != null && !this.fhirVersion.isEmpty(); 2155 } 2156 2157 /** 2158 * @param value {@link #fhirVersion} (The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version.). This is the underlying object with id, value and extensions. The accessor "getFhirVersion" gives direct access to the value 2159 */ 2160 public StructureDefinition setFhirVersionElement(IdType value) { 2161 this.fhirVersion = value; 2162 return this; 2163 } 2164 2165 /** 2166 * @return The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version. 2167 */ 2168 public String getFhirVersion() { 2169 return this.fhirVersion == null ? null : this.fhirVersion.getValue(); 2170 } 2171 2172 /** 2173 * @param value The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version. 2174 */ 2175 public StructureDefinition setFhirVersion(String value) { 2176 if (Utilities.noString(value)) 2177 this.fhirVersion = null; 2178 else { 2179 if (this.fhirVersion == null) 2180 this.fhirVersion = new IdType(); 2181 this.fhirVersion.setValue(value); 2182 } 2183 return this; 2184 } 2185 2186 /** 2187 * @return {@link #mapping} (An external specification that the content is mapped to.) 2188 */ 2189 public List<StructureDefinitionMappingComponent> getMapping() { 2190 if (this.mapping == null) 2191 this.mapping = new ArrayList<StructureDefinitionMappingComponent>(); 2192 return this.mapping; 2193 } 2194 2195 public boolean hasMapping() { 2196 if (this.mapping == null) 2197 return false; 2198 for (StructureDefinitionMappingComponent item : this.mapping) 2199 if (!item.isEmpty()) 2200 return true; 2201 return false; 2202 } 2203 2204 /** 2205 * @return {@link #mapping} (An external specification that the content is mapped to.) 2206 */ 2207 // syntactic sugar 2208 public StructureDefinitionMappingComponent addMapping() { //3 2209 StructureDefinitionMappingComponent t = new StructureDefinitionMappingComponent(); 2210 if (this.mapping == null) 2211 this.mapping = new ArrayList<StructureDefinitionMappingComponent>(); 2212 this.mapping.add(t); 2213 return t; 2214 } 2215 2216 // syntactic sugar 2217 public StructureDefinition addMapping(StructureDefinitionMappingComponent t) { //3 2218 if (t == null) 2219 return this; 2220 if (this.mapping == null) 2221 this.mapping = new ArrayList<StructureDefinitionMappingComponent>(); 2222 this.mapping.add(t); 2223 return this; 2224 } 2225 2226 /** 2227 * @return {@link #kind} (Defines the kind of structure that this definition is describing.). This is the underlying object with id, value and extensions. The accessor "getKind" gives direct access to the value 2228 */ 2229 public Enumeration<StructureDefinitionKind> getKindElement() { 2230 if (this.kind == null) 2231 if (Configuration.errorOnAutoCreate()) 2232 throw new Error("Attempt to auto-create StructureDefinition.kind"); 2233 else if (Configuration.doAutoCreate()) 2234 this.kind = new Enumeration<StructureDefinitionKind>(new StructureDefinitionKindEnumFactory()); // bb 2235 return this.kind; 2236 } 2237 2238 public boolean hasKindElement() { 2239 return this.kind != null && !this.kind.isEmpty(); 2240 } 2241 2242 public boolean hasKind() { 2243 return this.kind != null && !this.kind.isEmpty(); 2244 } 2245 2246 /** 2247 * @param value {@link #kind} (Defines the kind of structure that this definition is describing.). This is the underlying object with id, value and extensions. The accessor "getKind" gives direct access to the value 2248 */ 2249 public StructureDefinition setKindElement(Enumeration<StructureDefinitionKind> value) { 2250 this.kind = value; 2251 return this; 2252 } 2253 2254 /** 2255 * @return Defines the kind of structure that this definition is describing. 2256 */ 2257 public StructureDefinitionKind getKind() { 2258 return this.kind == null ? null : this.kind.getValue(); 2259 } 2260 2261 /** 2262 * @param value Defines the kind of structure that this definition is describing. 2263 */ 2264 public StructureDefinition setKind(StructureDefinitionKind value) { 2265 if (this.kind == null) 2266 this.kind = new Enumeration<StructureDefinitionKind>(new StructureDefinitionKindEnumFactory()); 2267 this.kind.setValue(value); 2268 return this; 2269 } 2270 2271 /** 2272 * @return {@link #abstract_} (Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type.). This is the underlying object with id, value and extensions. The accessor "getAbstract" gives direct access to the value 2273 */ 2274 public BooleanType getAbstractElement() { 2275 if (this.abstract_ == null) 2276 if (Configuration.errorOnAutoCreate()) 2277 throw new Error("Attempt to auto-create StructureDefinition.abstract_"); 2278 else if (Configuration.doAutoCreate()) 2279 this.abstract_ = new BooleanType(); // bb 2280 return this.abstract_; 2281 } 2282 2283 public boolean hasAbstractElement() { 2284 return this.abstract_ != null && !this.abstract_.isEmpty(); 2285 } 2286 2287 public boolean hasAbstract() { 2288 return this.abstract_ != null && !this.abstract_.isEmpty(); 2289 } 2290 2291 /** 2292 * @param value {@link #abstract_} (Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type.). This is the underlying object with id, value and extensions. The accessor "getAbstract" gives direct access to the value 2293 */ 2294 public StructureDefinition setAbstractElement(BooleanType value) { 2295 this.abstract_ = value; 2296 return this; 2297 } 2298 2299 /** 2300 * @return Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type. 2301 */ 2302 public boolean getAbstract() { 2303 return this.abstract_ == null || this.abstract_.isEmpty() ? false : this.abstract_.getValue(); 2304 } 2305 2306 /** 2307 * @param value Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type. 2308 */ 2309 public StructureDefinition setAbstract(boolean value) { 2310 if (this.abstract_ == null) 2311 this.abstract_ = new BooleanType(); 2312 this.abstract_.setValue(value); 2313 return this; 2314 } 2315 2316 /** 2317 * @return {@link #contextType} (If this is an extension, Identifies the context within FHIR resources where the extension can be used.). This is the underlying object with id, value and extensions. The accessor "getContextType" gives direct access to the value 2318 */ 2319 public Enumeration<ExtensionContext> getContextTypeElement() { 2320 if (this.contextType == null) 2321 if (Configuration.errorOnAutoCreate()) 2322 throw new Error("Attempt to auto-create StructureDefinition.contextType"); 2323 else if (Configuration.doAutoCreate()) 2324 this.contextType = new Enumeration<ExtensionContext>(new ExtensionContextEnumFactory()); // bb 2325 return this.contextType; 2326 } 2327 2328 public boolean hasContextTypeElement() { 2329 return this.contextType != null && !this.contextType.isEmpty(); 2330 } 2331 2332 public boolean hasContextType() { 2333 return this.contextType != null && !this.contextType.isEmpty(); 2334 } 2335 2336 /** 2337 * @param value {@link #contextType} (If this is an extension, Identifies the context within FHIR resources where the extension can be used.). This is the underlying object with id, value and extensions. The accessor "getContextType" gives direct access to the value 2338 */ 2339 public StructureDefinition setContextTypeElement(Enumeration<ExtensionContext> value) { 2340 this.contextType = value; 2341 return this; 2342 } 2343 2344 /** 2345 * @return If this is an extension, Identifies the context within FHIR resources where the extension can be used. 2346 */ 2347 public ExtensionContext getContextType() { 2348 return this.contextType == null ? null : this.contextType.getValue(); 2349 } 2350 2351 /** 2352 * @param value If this is an extension, Identifies the context within FHIR resources where the extension can be used. 2353 */ 2354 public StructureDefinition setContextType(ExtensionContext value) { 2355 if (value == null) 2356 this.contextType = null; 2357 else { 2358 if (this.contextType == null) 2359 this.contextType = new Enumeration<ExtensionContext>(new ExtensionContextEnumFactory()); 2360 this.contextType.setValue(value); 2361 } 2362 return this; 2363 } 2364 2365 /** 2366 * @return {@link #context} (Identifies the types of resource or data type elements to which the extension can be applied.) 2367 */ 2368 public List<StringType> getContext() { 2369 if (this.context == null) 2370 this.context = new ArrayList<StringType>(); 2371 return this.context; 2372 } 2373 2374 public boolean hasContext() { 2375 if (this.context == null) 2376 return false; 2377 for (StringType item : this.context) 2378 if (!item.isEmpty()) 2379 return true; 2380 return false; 2381 } 2382 2383 /** 2384 * @return {@link #context} (Identifies the types of resource or data type elements to which the extension can be applied.) 2385 */ 2386 // syntactic sugar 2387 public StringType addContextElement() {//2 2388 StringType t = new StringType(); 2389 if (this.context == null) 2390 this.context = new ArrayList<StringType>(); 2391 this.context.add(t); 2392 return t; 2393 } 2394 2395 /** 2396 * @param value {@link #context} (Identifies the types of resource or data type elements to which the extension can be applied.) 2397 */ 2398 public StructureDefinition addContext(String value) { //1 2399 StringType t = new StringType(); 2400 t.setValue(value); 2401 if (this.context == null) 2402 this.context = new ArrayList<StringType>(); 2403 this.context.add(t); 2404 return this; 2405 } 2406 2407 /** 2408 * @param value {@link #context} (Identifies the types of resource or data type elements to which the extension can be applied.) 2409 */ 2410 public boolean hasContext(String value) { 2411 if (this.context == null) 2412 return false; 2413 for (StringType v : this.context) 2414 if (v.equals(value)) // string 2415 return true; 2416 return false; 2417 } 2418 2419 /** 2420 * @return {@link #baseType} (The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure.). This is the underlying object with id, value and extensions. The accessor "getBaseType" gives direct access to the value 2421 */ 2422 public CodeType getBaseTypeElement() { 2423 if (this.baseType == null) 2424 if (Configuration.errorOnAutoCreate()) 2425 throw new Error("Attempt to auto-create StructureDefinition.baseType"); 2426 else if (Configuration.doAutoCreate()) 2427 this.baseType = new CodeType(); // bb 2428 return this.baseType; 2429 } 2430 2431 public boolean hasBaseTypeElement() { 2432 return this.baseType != null && !this.baseType.isEmpty(); 2433 } 2434 2435 public boolean hasBaseType() { 2436 return this.baseType != null && !this.baseType.isEmpty(); 2437 } 2438 2439 /** 2440 * @param value {@link #baseType} (The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure.). This is the underlying object with id, value and extensions. The accessor "getBaseType" gives direct access to the value 2441 */ 2442 public StructureDefinition setBaseTypeElement(CodeType value) { 2443 this.baseType = value; 2444 return this; 2445 } 2446 2447 /** 2448 * @return The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure. 2449 */ 2450 public String getBaseType() { 2451 return this.baseType == null ? null : this.baseType.getValue(); 2452 } 2453 2454 /** 2455 * @param value The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure. 2456 */ 2457 public StructureDefinition setBaseType(String value) { 2458 if (Utilities.noString(value)) 2459 this.baseType = null; 2460 else { 2461 if (this.baseType == null) 2462 this.baseType = new CodeType(); 2463 this.baseType.setValue(value); 2464 } 2465 return this; 2466 } 2467 2468 /** 2469 * @return {@link #baseDefinition} (An absolute URI that is the base structure from which this type is derived, either by specialization or constraint.). This is the underlying object with id, value and extensions. The accessor "getBaseDefinition" gives direct access to the value 2470 */ 2471 public UriType getBaseDefinitionElement() { 2472 if (this.baseDefinition == null) 2473 if (Configuration.errorOnAutoCreate()) 2474 throw new Error("Attempt to auto-create StructureDefinition.baseDefinition"); 2475 else if (Configuration.doAutoCreate()) 2476 this.baseDefinition = new UriType(); // bb 2477 return this.baseDefinition; 2478 } 2479 2480 public boolean hasBaseDefinitionElement() { 2481 return this.baseDefinition != null && !this.baseDefinition.isEmpty(); 2482 } 2483 2484 public boolean hasBaseDefinition() { 2485 return this.baseDefinition != null && !this.baseDefinition.isEmpty(); 2486 } 2487 2488 /** 2489 * @param value {@link #baseDefinition} (An absolute URI that is the base structure from which this type is derived, either by specialization or constraint.). This is the underlying object with id, value and extensions. The accessor "getBaseDefinition" gives direct access to the value 2490 */ 2491 public StructureDefinition setBaseDefinitionElement(UriType value) { 2492 this.baseDefinition = value; 2493 return this; 2494 } 2495 2496 /** 2497 * @return An absolute URI that is the base structure from which this type is derived, either by specialization or constraint. 2498 */ 2499 public String getBaseDefinition() { 2500 return this.baseDefinition == null ? null : this.baseDefinition.getValue(); 2501 } 2502 2503 /** 2504 * @param value An absolute URI that is the base structure from which this type is derived, either by specialization or constraint. 2505 */ 2506 public StructureDefinition setBaseDefinition(String value) { 2507 if (Utilities.noString(value)) 2508 this.baseDefinition = null; 2509 else { 2510 if (this.baseDefinition == null) 2511 this.baseDefinition = new UriType(); 2512 this.baseDefinition.setValue(value); 2513 } 2514 return this; 2515 } 2516 2517 /** 2518 * @return {@link #derivation} (How the type relates to the baseDefinition.). This is the underlying object with id, value and extensions. The accessor "getDerivation" gives direct access to the value 2519 */ 2520 public Enumeration<TypeDerivationRule> getDerivationElement() { 2521 if (this.derivation == null) 2522 if (Configuration.errorOnAutoCreate()) 2523 throw new Error("Attempt to auto-create StructureDefinition.derivation"); 2524 else if (Configuration.doAutoCreate()) 2525 this.derivation = new Enumeration<TypeDerivationRule>(new TypeDerivationRuleEnumFactory()); // bb 2526 return this.derivation; 2527 } 2528 2529 public boolean hasDerivationElement() { 2530 return this.derivation != null && !this.derivation.isEmpty(); 2531 } 2532 2533 public boolean hasDerivation() { 2534 return this.derivation != null && !this.derivation.isEmpty(); 2535 } 2536 2537 /** 2538 * @param value {@link #derivation} (How the type relates to the baseDefinition.). This is the underlying object with id, value and extensions. The accessor "getDerivation" gives direct access to the value 2539 */ 2540 public StructureDefinition setDerivationElement(Enumeration<TypeDerivationRule> value) { 2541 this.derivation = value; 2542 return this; 2543 } 2544 2545 /** 2546 * @return How the type relates to the baseDefinition. 2547 */ 2548 public TypeDerivationRule getDerivation() { 2549 return this.derivation == null ? null : this.derivation.getValue(); 2550 } 2551 2552 /** 2553 * @param value How the type relates to the baseDefinition. 2554 */ 2555 public StructureDefinition setDerivation(TypeDerivationRule value) { 2556 if (value == null) 2557 this.derivation = null; 2558 else { 2559 if (this.derivation == null) 2560 this.derivation = new Enumeration<TypeDerivationRule>(new TypeDerivationRuleEnumFactory()); 2561 this.derivation.setValue(value); 2562 } 2563 return this; 2564 } 2565 2566 /** 2567 * @return {@link #snapshot} (A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition.) 2568 */ 2569 public StructureDefinitionSnapshotComponent getSnapshot() { 2570 if (this.snapshot == null) 2571 if (Configuration.errorOnAutoCreate()) 2572 throw new Error("Attempt to auto-create StructureDefinition.snapshot"); 2573 else if (Configuration.doAutoCreate()) 2574 this.snapshot = new StructureDefinitionSnapshotComponent(); // cc 2575 return this.snapshot; 2576 } 2577 2578 public boolean hasSnapshot() { 2579 return this.snapshot != null && !this.snapshot.isEmpty(); 2580 } 2581 2582 /** 2583 * @param value {@link #snapshot} (A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition.) 2584 */ 2585 public StructureDefinition setSnapshot(StructureDefinitionSnapshotComponent value) { 2586 this.snapshot = value; 2587 return this; 2588 } 2589 2590 /** 2591 * @return {@link #differential} (A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies.) 2592 */ 2593 public StructureDefinitionDifferentialComponent getDifferential() { 2594 if (this.differential == null) 2595 if (Configuration.errorOnAutoCreate()) 2596 throw new Error("Attempt to auto-create StructureDefinition.differential"); 2597 else if (Configuration.doAutoCreate()) 2598 this.differential = new StructureDefinitionDifferentialComponent(); // cc 2599 return this.differential; 2600 } 2601 2602 public boolean hasDifferential() { 2603 return this.differential != null && !this.differential.isEmpty(); 2604 } 2605 2606 /** 2607 * @param value {@link #differential} (A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies.) 2608 */ 2609 public StructureDefinition setDifferential(StructureDefinitionDifferentialComponent value) { 2610 this.differential = value; 2611 return this; 2612 } 2613 2614 protected void listChildren(List<Property> childrenList) { 2615 super.listChildren(childrenList); 2616 childrenList.add(new Property("url", "uri", "An absolute URL that is used to identify this structure definition when it is referenced in a specification, model, design or an instance. This SHALL be a URL, SHOULD be globally unique, and SHOULD be an address at which this structure definition is (or will be) published.", 0, java.lang.Integer.MAX_VALUE, url)); 2617 childrenList.add(new Property("identifier", "Identifier", "Formal identifier that is used to identify this StructureDefinition when it is represented in other formats, or referenced in a specification, model, design or an instance (should be globally unique OID, UUID, or URI), (if it's not possible to use the literal URI).", 0, java.lang.Integer.MAX_VALUE, identifier)); 2618 childrenList.add(new Property("version", "string", "The identifier that is used to identify this version of the StructureDefinition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the StructureDefinition author manually.", 0, java.lang.Integer.MAX_VALUE, version)); 2619 childrenList.add(new Property("name", "string", "A free text natural language name identifying the StructureDefinition.", 0, java.lang.Integer.MAX_VALUE, name)); 2620 childrenList.add(new Property("display", "string", "Defined so that applications can use this name when displaying the value of the extension to the user.", 0, java.lang.Integer.MAX_VALUE, display)); 2621 childrenList.add(new Property("status", "code", "The status of the StructureDefinition.", 0, java.lang.Integer.MAX_VALUE, status)); 2622 childrenList.add(new Property("experimental", "boolean", "This StructureDefinition was authored for testing purposes (or education/evaluation/marketing), and is not intended to be used for genuine usage.", 0, java.lang.Integer.MAX_VALUE, experimental)); 2623 childrenList.add(new Property("publisher", "string", "The name of the individual or organization that published the structure definition.", 0, java.lang.Integer.MAX_VALUE, publisher)); 2624 childrenList.add(new Property("contact", "", "Contacts to assist a user in finding and communicating with the publisher.", 0, java.lang.Integer.MAX_VALUE, contact)); 2625 childrenList.add(new Property("date", "dateTime", "The date this version of the structure definition was published. The date must change when the business version changes, if it does, and it must change if the status code changes. In addition, it should change when the substantive content of the structure definition changes.", 0, java.lang.Integer.MAX_VALUE, date)); 2626 childrenList.add(new Property("description", "string", "A free text natural language description of the StructureDefinition and its use.", 0, java.lang.Integer.MAX_VALUE, description)); 2627 childrenList.add(new Property("useContext", "CodeableConcept", "The content was developed with a focus and intent of supporting the contexts that are listed. These terms may be used to assist with indexing and searching of structure definitions.", 0, java.lang.Integer.MAX_VALUE, useContext)); 2628 childrenList.add(new Property("requirements", "string", "Explains why this structure definition is needed and why it's been constrained as it has.", 0, java.lang.Integer.MAX_VALUE, requirements)); 2629 childrenList.add(new Property("copyright", "string", "A copyright statement relating to the structure definition and/or its contents. Copyright statements are generally legal restrictions on the use and publishing of the details of the constraints and mappings.", 0, java.lang.Integer.MAX_VALUE, copyright)); 2630 childrenList.add(new Property("code", "Coding", "A set of terms from external terminologies that may be used to assist with indexing and searching of templates.", 0, java.lang.Integer.MAX_VALUE, code)); 2631 childrenList.add(new Property("fhirVersion", "id", "The version of the FHIR specification on which this StructureDefinition is based - this is the formal version of the specification, without the revision number, e.g. [publication].[major].[minor], which is 1.4.0 for this version.", 0, java.lang.Integer.MAX_VALUE, fhirVersion)); 2632 childrenList.add(new Property("mapping", "", "An external specification that the content is mapped to.", 0, java.lang.Integer.MAX_VALUE, mapping)); 2633 childrenList.add(new Property("kind", "code", "Defines the kind of structure that this definition is describing.", 0, java.lang.Integer.MAX_VALUE, kind)); 2634 childrenList.add(new Property("abstract", "boolean", "Whether structure this definition describes is abstract or not - that is, whether an actual exchanged item can ever be of this type.", 0, java.lang.Integer.MAX_VALUE, abstract_)); 2635 childrenList.add(new Property("contextType", "code", "If this is an extension, Identifies the context within FHIR resources where the extension can be used.", 0, java.lang.Integer.MAX_VALUE, contextType)); 2636 childrenList.add(new Property("context", "string", "Identifies the types of resource or data type elements to which the extension can be applied.", 0, java.lang.Integer.MAX_VALUE, context)); 2637 childrenList.add(new Property("baseType", "code", "The type of type that this structure is derived from - a data type, an extension, a resource, including abstract ones. If this field is present, it indicates that the structure definition is deriving from this type. If it is not present, then the structure definition is the definition of a base abstract structure.", 0, java.lang.Integer.MAX_VALUE, baseType)); 2638 childrenList.add(new Property("baseDefinition", "uri", "An absolute URI that is the base structure from which this type is derived, either by specialization or constraint.", 0, java.lang.Integer.MAX_VALUE, baseDefinition)); 2639 childrenList.add(new Property("derivation", "code", "How the type relates to the baseDefinition.", 0, java.lang.Integer.MAX_VALUE, derivation)); 2640 childrenList.add(new Property("snapshot", "", "A snapshot view is expressed in a stand alone form that can be used and interpreted without considering the base StructureDefinition.", 0, java.lang.Integer.MAX_VALUE, snapshot)); 2641 childrenList.add(new Property("differential", "", "A differential view is expressed relative to the base StructureDefinition - a statement of differences that it applies.", 0, java.lang.Integer.MAX_VALUE, differential)); 2642 } 2643 2644 @Override 2645 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2646 switch (hash) { 2647 case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType 2648 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 2649 case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // StringType 2650 case 3373707: /*name*/ return this.name == null ? new Base[0] : new Base[] {this.name}; // StringType 2651 case 1671764162: /*display*/ return this.display == null ? new Base[0] : new Base[] {this.display}; // StringType 2652 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<ConformanceResourceStatus> 2653 case -404562712: /*experimental*/ return this.experimental == null ? new Base[0] : new Base[] {this.experimental}; // BooleanType 2654 case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // StringType 2655 case 951526432: /*contact*/ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // StructureDefinitionContactComponent 2656 case 3076014: /*date*/ return this.date == null ? new Base[0] : new Base[] {this.date}; // DateTimeType 2657 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 2658 case -669707736: /*useContext*/ return this.useContext == null ? new Base[0] : this.useContext.toArray(new Base[this.useContext.size()]); // CodeableConcept 2659 case -1619874672: /*requirements*/ return this.requirements == null ? new Base[0] : new Base[] {this.requirements}; // StringType 2660 case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // StringType 2661 case 3059181: /*code*/ return this.code == null ? new Base[0] : this.code.toArray(new Base[this.code.size()]); // Coding 2662 case 461006061: /*fhirVersion*/ return this.fhirVersion == null ? new Base[0] : new Base[] {this.fhirVersion}; // IdType 2663 case 837556430: /*mapping*/ return this.mapping == null ? new Base[0] : this.mapping.toArray(new Base[this.mapping.size()]); // StructureDefinitionMappingComponent 2664 case 3292052: /*kind*/ return this.kind == null ? new Base[0] : new Base[] {this.kind}; // Enumeration<StructureDefinitionKind> 2665 case 1732898850: /*abstract*/ return this.abstract_ == null ? new Base[0] : new Base[] {this.abstract_}; // BooleanType 2666 case -102839927: /*contextType*/ return this.contextType == null ? new Base[0] : new Base[] {this.contextType}; // Enumeration<ExtensionContext> 2667 case 951530927: /*context*/ return this.context == null ? new Base[0] : this.context.toArray(new Base[this.context.size()]); // StringType 2668 case -1721484885: /*baseType*/ return this.baseType == null ? new Base[0] : new Base[] {this.baseType}; // CodeType 2669 case 1139771140: /*baseDefinition*/ return this.baseDefinition == null ? new Base[0] : new Base[] {this.baseDefinition}; // UriType 2670 case -1353885513: /*derivation*/ return this.derivation == null ? new Base[0] : new Base[] {this.derivation}; // Enumeration<TypeDerivationRule> 2671 case 284874180: /*snapshot*/ return this.snapshot == null ? new Base[0] : new Base[] {this.snapshot}; // StructureDefinitionSnapshotComponent 2672 case -1196150917: /*differential*/ return this.differential == null ? new Base[0] : new Base[] {this.differential}; // StructureDefinitionDifferentialComponent 2673 default: return super.getProperty(hash, name, checkValid); 2674 } 2675 2676 } 2677 2678 @Override 2679 public void setProperty(int hash, String name, Base value) throws FHIRException { 2680 switch (hash) { 2681 case 116079: // url 2682 this.url = castToUri(value); // UriType 2683 break; 2684 case -1618432855: // identifier 2685 this.getIdentifier().add(castToIdentifier(value)); // Identifier 2686 break; 2687 case 351608024: // version 2688 this.version = castToString(value); // StringType 2689 break; 2690 case 3373707: // name 2691 this.name = castToString(value); // StringType 2692 break; 2693 case 1671764162: // display 2694 this.display = castToString(value); // StringType 2695 break; 2696 case -892481550: // status 2697 this.status = new ConformanceResourceStatusEnumFactory().fromType(value); // Enumeration<ConformanceResourceStatus> 2698 break; 2699 case -404562712: // experimental 2700 this.experimental = castToBoolean(value); // BooleanType 2701 break; 2702 case 1447404028: // publisher 2703 this.publisher = castToString(value); // StringType 2704 break; 2705 case 951526432: // contact 2706 this.getContact().add((StructureDefinitionContactComponent) value); // StructureDefinitionContactComponent 2707 break; 2708 case 3076014: // date 2709 this.date = castToDateTime(value); // DateTimeType 2710 break; 2711 case -1724546052: // description 2712 this.description = castToString(value); // StringType 2713 break; 2714 case -669707736: // useContext 2715 this.getUseContext().add(castToCodeableConcept(value)); // CodeableConcept 2716 break; 2717 case -1619874672: // requirements 2718 this.requirements = castToString(value); // StringType 2719 break; 2720 case 1522889671: // copyright 2721 this.copyright = castToString(value); // StringType 2722 break; 2723 case 3059181: // code 2724 this.getCode().add(castToCoding(value)); // Coding 2725 break; 2726 case 461006061: // fhirVersion 2727 this.fhirVersion = castToId(value); // IdType 2728 break; 2729 case 837556430: // mapping 2730 this.getMapping().add((StructureDefinitionMappingComponent) value); // StructureDefinitionMappingComponent 2731 break; 2732 case 3292052: // kind 2733 this.kind = new StructureDefinitionKindEnumFactory().fromType(value); // Enumeration<StructureDefinitionKind> 2734 break; 2735 case 1732898850: // abstract 2736 this.abstract_ = castToBoolean(value); // BooleanType 2737 break; 2738 case -102839927: // contextType 2739 this.contextType = new ExtensionContextEnumFactory().fromType(value); // Enumeration<ExtensionContext> 2740 break; 2741 case 951530927: // context 2742 this.getContext().add(castToString(value)); // StringType 2743 break; 2744 case -1721484885: // baseType 2745 this.baseType = castToCode(value); // CodeType 2746 break; 2747 case 1139771140: // baseDefinition 2748 this.baseDefinition = castToUri(value); // UriType 2749 break; 2750 case -1353885513: // derivation 2751 this.derivation = new TypeDerivationRuleEnumFactory().fromType(value); // Enumeration<TypeDerivationRule> 2752 break; 2753 case 284874180: // snapshot 2754 this.snapshot = (StructureDefinitionSnapshotComponent) value; // StructureDefinitionSnapshotComponent 2755 break; 2756 case -1196150917: // differential 2757 this.differential = (StructureDefinitionDifferentialComponent) value; // StructureDefinitionDifferentialComponent 2758 break; 2759 default: super.setProperty(hash, name, value); 2760 } 2761 2762 } 2763 2764 @Override 2765 public void setProperty(String name, Base value) throws FHIRException { 2766 if (name.equals("url")) 2767 this.url = castToUri(value); // UriType 2768 else if (name.equals("identifier")) 2769 this.getIdentifier().add(castToIdentifier(value)); 2770 else if (name.equals("version")) 2771 this.version = castToString(value); // StringType 2772 else if (name.equals("name")) 2773 this.name = castToString(value); // StringType 2774 else if (name.equals("display")) 2775 this.display = castToString(value); // StringType 2776 else if (name.equals("status")) 2777 this.status = new ConformanceResourceStatusEnumFactory().fromType(value); // Enumeration<ConformanceResourceStatus> 2778 else if (name.equals("experimental")) 2779 this.experimental = castToBoolean(value); // BooleanType 2780 else if (name.equals("publisher")) 2781 this.publisher = castToString(value); // StringType 2782 else if (name.equals("contact")) 2783 this.getContact().add((StructureDefinitionContactComponent) value); 2784 else if (name.equals("date")) 2785 this.date = castToDateTime(value); // DateTimeType 2786 else if (name.equals("description")) 2787 this.description = castToString(value); // StringType 2788 else if (name.equals("useContext")) 2789 this.getUseContext().add(castToCodeableConcept(value)); 2790 else if (name.equals("requirements")) 2791 this.requirements = castToString(value); // StringType 2792 else if (name.equals("copyright")) 2793 this.copyright = castToString(value); // StringType 2794 else if (name.equals("code")) 2795 this.getCode().add(castToCoding(value)); 2796 else if (name.equals("fhirVersion")) 2797 this.fhirVersion = castToId(value); // IdType 2798 else if (name.equals("mapping")) 2799 this.getMapping().add((StructureDefinitionMappingComponent) value); 2800 else if (name.equals("kind")) 2801 this.kind = new StructureDefinitionKindEnumFactory().fromType(value); // Enumeration<StructureDefinitionKind> 2802 else if (name.equals("abstract")) 2803 this.abstract_ = castToBoolean(value); // BooleanType 2804 else if (name.equals("contextType")) 2805 this.contextType = new ExtensionContextEnumFactory().fromType(value); // Enumeration<ExtensionContext> 2806 else if (name.equals("context")) 2807 this.getContext().add(castToString(value)); 2808 else if (name.equals("baseType")) 2809 this.baseType = castToCode(value); // CodeType 2810 else if (name.equals("baseDefinition")) 2811 this.baseDefinition = castToUri(value); // UriType 2812 else if (name.equals("derivation")) 2813 this.derivation = new TypeDerivationRuleEnumFactory().fromType(value); // Enumeration<TypeDerivationRule> 2814 else if (name.equals("snapshot")) 2815 this.snapshot = (StructureDefinitionSnapshotComponent) value; // StructureDefinitionSnapshotComponent 2816 else if (name.equals("differential")) 2817 this.differential = (StructureDefinitionDifferentialComponent) value; // StructureDefinitionDifferentialComponent 2818 else 2819 super.setProperty(name, value); 2820 } 2821 2822 @Override 2823 public Base makeProperty(int hash, String name) throws FHIRException { 2824 switch (hash) { 2825 case 116079: throw new FHIRException("Cannot make property url as it is not a complex type"); // UriType 2826 case -1618432855: return addIdentifier(); // Identifier 2827 case 351608024: throw new FHIRException("Cannot make property version as it is not a complex type"); // StringType 2828 case 3373707: throw new FHIRException("Cannot make property name as it is not a complex type"); // StringType 2829 case 1671764162: throw new FHIRException("Cannot make property display as it is not a complex type"); // StringType 2830 case -892481550: throw new FHIRException("Cannot make property status as it is not a complex type"); // Enumeration<ConformanceResourceStatus> 2831 case -404562712: throw new FHIRException("Cannot make property experimental as it is not a complex type"); // BooleanType 2832 case 1447404028: throw new FHIRException("Cannot make property publisher as it is not a complex type"); // StringType 2833 case 951526432: return addContact(); // StructureDefinitionContactComponent 2834 case 3076014: throw new FHIRException("Cannot make property date as it is not a complex type"); // DateTimeType 2835 case -1724546052: throw new FHIRException("Cannot make property description as it is not a complex type"); // StringType 2836 case -669707736: return addUseContext(); // CodeableConcept 2837 case -1619874672: throw new FHIRException("Cannot make property requirements as it is not a complex type"); // StringType 2838 case 1522889671: throw new FHIRException("Cannot make property copyright as it is not a complex type"); // StringType 2839 case 3059181: return addCode(); // Coding 2840 case 461006061: throw new FHIRException("Cannot make property fhirVersion as it is not a complex type"); // IdType 2841 case 837556430: return addMapping(); // StructureDefinitionMappingComponent 2842 case 3292052: throw new FHIRException("Cannot make property kind as it is not a complex type"); // Enumeration<StructureDefinitionKind> 2843 case 1732898850: throw new FHIRException("Cannot make property abstract as it is not a complex type"); // BooleanType 2844 case -102839927: throw new FHIRException("Cannot make property contextType as it is not a complex type"); // Enumeration<ExtensionContext> 2845 case 951530927: throw new FHIRException("Cannot make property context as it is not a complex type"); // StringType 2846 case -1721484885: throw new FHIRException("Cannot make property baseType as it is not a complex type"); // CodeType 2847 case 1139771140: throw new FHIRException("Cannot make property baseDefinition as it is not a complex type"); // UriType 2848 case -1353885513: throw new FHIRException("Cannot make property derivation as it is not a complex type"); // Enumeration<TypeDerivationRule> 2849 case 284874180: return getSnapshot(); // StructureDefinitionSnapshotComponent 2850 case -1196150917: return getDifferential(); // StructureDefinitionDifferentialComponent 2851 default: return super.makeProperty(hash, name); 2852 } 2853 2854 } 2855 2856 @Override 2857 public Base addChild(String name) throws FHIRException { 2858 if (name.equals("url")) { 2859 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.url"); 2860 } 2861 else if (name.equals("identifier")) { 2862 return addIdentifier(); 2863 } 2864 else if (name.equals("version")) { 2865 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.version"); 2866 } 2867 else if (name.equals("name")) { 2868 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.name"); 2869 } 2870 else if (name.equals("display")) { 2871 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.display"); 2872 } 2873 else if (name.equals("status")) { 2874 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.status"); 2875 } 2876 else if (name.equals("experimental")) { 2877 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.experimental"); 2878 } 2879 else if (name.equals("publisher")) { 2880 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.publisher"); 2881 } 2882 else if (name.equals("contact")) { 2883 return addContact(); 2884 } 2885 else if (name.equals("date")) { 2886 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.date"); 2887 } 2888 else if (name.equals("description")) { 2889 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.description"); 2890 } 2891 else if (name.equals("useContext")) { 2892 return addUseContext(); 2893 } 2894 else if (name.equals("requirements")) { 2895 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.requirements"); 2896 } 2897 else if (name.equals("copyright")) { 2898 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.copyright"); 2899 } 2900 else if (name.equals("code")) { 2901 return addCode(); 2902 } 2903 else if (name.equals("fhirVersion")) { 2904 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.fhirVersion"); 2905 } 2906 else if (name.equals("mapping")) { 2907 return addMapping(); 2908 } 2909 else if (name.equals("kind")) { 2910 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.kind"); 2911 } 2912 else if (name.equals("abstract")) { 2913 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.abstract"); 2914 } 2915 else if (name.equals("contextType")) { 2916 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.contextType"); 2917 } 2918 else if (name.equals("context")) { 2919 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.context"); 2920 } 2921 else if (name.equals("baseType")) { 2922 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.baseType"); 2923 } 2924 else if (name.equals("baseDefinition")) { 2925 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.baseDefinition"); 2926 } 2927 else if (name.equals("derivation")) { 2928 throw new FHIRException("Cannot call addChild on a primitive type StructureDefinition.derivation"); 2929 } 2930 else if (name.equals("snapshot")) { 2931 this.snapshot = new StructureDefinitionSnapshotComponent(); 2932 return this.snapshot; 2933 } 2934 else if (name.equals("differential")) { 2935 this.differential = new StructureDefinitionDifferentialComponent(); 2936 return this.differential; 2937 } 2938 else 2939 return super.addChild(name); 2940 } 2941 2942 public String fhirType() { 2943 return "StructureDefinition"; 2944 2945 } 2946 2947 public StructureDefinition copy() { 2948 StructureDefinition dst = new StructureDefinition(); 2949 copyValues(dst); 2950 dst.url = url == null ? null : url.copy(); 2951 if (identifier != null) { 2952 dst.identifier = new ArrayList<Identifier>(); 2953 for (Identifier i : identifier) 2954 dst.identifier.add(i.copy()); 2955 }; 2956 dst.version = version == null ? null : version.copy(); 2957 dst.name = name == null ? null : name.copy(); 2958 dst.display = display == null ? null : display.copy(); 2959 dst.status = status == null ? null : status.copy(); 2960 dst.experimental = experimental == null ? null : experimental.copy(); 2961 dst.publisher = publisher == null ? null : publisher.copy(); 2962 if (contact != null) { 2963 dst.contact = new ArrayList<StructureDefinitionContactComponent>(); 2964 for (StructureDefinitionContactComponent i : contact) 2965 dst.contact.add(i.copy()); 2966 }; 2967 dst.date = date == null ? null : date.copy(); 2968 dst.description = description == null ? null : description.copy(); 2969 if (useContext != null) { 2970 dst.useContext = new ArrayList<CodeableConcept>(); 2971 for (CodeableConcept i : useContext) 2972 dst.useContext.add(i.copy()); 2973 }; 2974 dst.requirements = requirements == null ? null : requirements.copy(); 2975 dst.copyright = copyright == null ? null : copyright.copy(); 2976 if (code != null) { 2977 dst.code = new ArrayList<Coding>(); 2978 for (Coding i : code) 2979 dst.code.add(i.copy()); 2980 }; 2981 dst.fhirVersion = fhirVersion == null ? null : fhirVersion.copy(); 2982 if (mapping != null) { 2983 dst.mapping = new ArrayList<StructureDefinitionMappingComponent>(); 2984 for (StructureDefinitionMappingComponent i : mapping) 2985 dst.mapping.add(i.copy()); 2986 }; 2987 dst.kind = kind == null ? null : kind.copy(); 2988 dst.abstract_ = abstract_ == null ? null : abstract_.copy(); 2989 dst.contextType = contextType == null ? null : contextType.copy(); 2990 if (context != null) { 2991 dst.context = new ArrayList<StringType>(); 2992 for (StringType i : context) 2993 dst.context.add(i.copy()); 2994 }; 2995 dst.baseType = baseType == null ? null : baseType.copy(); 2996 dst.baseDefinition = baseDefinition == null ? null : baseDefinition.copy(); 2997 dst.derivation = derivation == null ? null : derivation.copy(); 2998 dst.snapshot = snapshot == null ? null : snapshot.copy(); 2999 dst.differential = differential == null ? null : differential.copy(); 3000 return dst; 3001 } 3002 3003 protected StructureDefinition typedCopy() { 3004 return copy(); 3005 } 3006 3007 @Override 3008 public boolean equalsDeep(Base other) { 3009 if (!super.equalsDeep(other)) 3010 return false; 3011 if (!(other instanceof StructureDefinition)) 3012 return false; 3013 StructureDefinition o = (StructureDefinition) other; 3014 return compareDeep(url, o.url, true) && compareDeep(identifier, o.identifier, true) && compareDeep(version, o.version, true) 3015 && compareDeep(name, o.name, true) && compareDeep(display, o.display, true) && compareDeep(status, o.status, true) 3016 && compareDeep(experimental, o.experimental, true) && compareDeep(publisher, o.publisher, true) 3017 && compareDeep(contact, o.contact, true) && compareDeep(date, o.date, true) && compareDeep(description, o.description, true) 3018 && compareDeep(useContext, o.useContext, true) && compareDeep(requirements, o.requirements, true) 3019 && compareDeep(copyright, o.copyright, true) && compareDeep(code, o.code, true) && compareDeep(fhirVersion, o.fhirVersion, true) 3020 && compareDeep(mapping, o.mapping, true) && compareDeep(kind, o.kind, true) && compareDeep(abstract_, o.abstract_, true) 3021 && compareDeep(contextType, o.contextType, true) && compareDeep(context, o.context, true) && compareDeep(baseType, o.baseType, true) 3022 && compareDeep(baseDefinition, o.baseDefinition, true) && compareDeep(derivation, o.derivation, true) 3023 && compareDeep(snapshot, o.snapshot, true) && compareDeep(differential, o.differential, true); 3024 } 3025 3026 @Override 3027 public boolean equalsShallow(Base other) { 3028 if (!super.equalsShallow(other)) 3029 return false; 3030 if (!(other instanceof StructureDefinition)) 3031 return false; 3032 StructureDefinition o = (StructureDefinition) other; 3033 return compareValues(url, o.url, true) && compareValues(version, o.version, true) && compareValues(name, o.name, true) 3034 && compareValues(display, o.display, true) && compareValues(status, o.status, true) && compareValues(experimental, o.experimental, true) 3035 && compareValues(publisher, o.publisher, true) && compareValues(date, o.date, true) && compareValues(description, o.description, true) 3036 && compareValues(requirements, o.requirements, true) && compareValues(copyright, o.copyright, true) 3037 && compareValues(fhirVersion, o.fhirVersion, true) && compareValues(kind, o.kind, true) && compareValues(abstract_, o.abstract_, true) 3038 && compareValues(contextType, o.contextType, true) && compareValues(context, o.context, true) && compareValues(baseType, o.baseType, true) 3039 && compareValues(baseDefinition, o.baseDefinition, true) && compareValues(derivation, o.derivation, true) 3040 ; 3041 } 3042 3043 public boolean isEmpty() { 3044 return super.isEmpty() && (url == null || url.isEmpty()) && (identifier == null || identifier.isEmpty()) 3045 && (version == null || version.isEmpty()) && (name == null || name.isEmpty()) && (display == null || display.isEmpty()) 3046 && (status == null || status.isEmpty()) && (experimental == null || experimental.isEmpty()) 3047 && (publisher == null || publisher.isEmpty()) && (contact == null || contact.isEmpty()) && (date == null || date.isEmpty()) 3048 && (description == null || description.isEmpty()) && (useContext == null || useContext.isEmpty()) 3049 && (requirements == null || requirements.isEmpty()) && (copyright == null || copyright.isEmpty()) 3050 && (code == null || code.isEmpty()) && (fhirVersion == null || fhirVersion.isEmpty()) && (mapping == null || mapping.isEmpty()) 3051 && (kind == null || kind.isEmpty()) && (abstract_ == null || abstract_.isEmpty()) && (contextType == null || contextType.isEmpty()) 3052 && (context == null || context.isEmpty()) && (baseType == null || baseType.isEmpty()) && (baseDefinition == null || baseDefinition.isEmpty()) 3053 && (derivation == null || derivation.isEmpty()) && (snapshot == null || snapshot.isEmpty()) 3054 && (differential == null || differential.isEmpty()); 3055 } 3056 3057 @Override 3058 public ResourceType getResourceType() { 3059 return ResourceType.StructureDefinition; 3060 } 3061 3062 /** 3063 * Search parameter: <b>abstract</b> 3064 * <p> 3065 * Description: <b>Whether the structure is abstract</b><br> 3066 * Type: <b>token</b><br> 3067 * Path: <b>StructureDefinition.abstract</b><br> 3068 * </p> 3069 */ 3070 @SearchParamDefinition(name="abstract", path="StructureDefinition.abstract", description="Whether the structure is abstract", type="token" ) 3071 public static final String SP_ABSTRACT = "abstract"; 3072 /** 3073 * <b>Fluent Client</b> search parameter constant for <b>abstract</b> 3074 * <p> 3075 * Description: <b>Whether the structure is abstract</b><br> 3076 * Type: <b>token</b><br> 3077 * Path: <b>StructureDefinition.abstract</b><br> 3078 * </p> 3079 */ 3080 public static final ca.uhn.fhir.rest.gclient.TokenClientParam ABSTRACT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_ABSTRACT); 3081 3082 /** 3083 * Search parameter: <b>status</b> 3084 * <p> 3085 * Description: <b>The current status of the profile</b><br> 3086 * Type: <b>token</b><br> 3087 * Path: <b>StructureDefinition.status</b><br> 3088 * </p> 3089 */ 3090 @SearchParamDefinition(name="status", path="StructureDefinition.status", description="The current status of the profile", type="token" ) 3091 public static final String SP_STATUS = "status"; 3092 /** 3093 * <b>Fluent Client</b> search parameter constant for <b>status</b> 3094 * <p> 3095 * Description: <b>The current status of the profile</b><br> 3096 * Type: <b>token</b><br> 3097 * Path: <b>StructureDefinition.status</b><br> 3098 * </p> 3099 */ 3100 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 3101 3102 /** 3103 * Search parameter: <b>experimental</b> 3104 * <p> 3105 * Description: <b>If for testing purposes, not real usage</b><br> 3106 * Type: <b>token</b><br> 3107 * Path: <b>StructureDefinition.experimental</b><br> 3108 * </p> 3109 */ 3110 @SearchParamDefinition(name="experimental", path="StructureDefinition.experimental", description="If for testing purposes, not real usage", type="token" ) 3111 public static final String SP_EXPERIMENTAL = "experimental"; 3112 /** 3113 * <b>Fluent Client</b> search parameter constant for <b>experimental</b> 3114 * <p> 3115 * Description: <b>If for testing purposes, not real usage</b><br> 3116 * Type: <b>token</b><br> 3117 * Path: <b>StructureDefinition.experimental</b><br> 3118 * </p> 3119 */ 3120 public static final ca.uhn.fhir.rest.gclient.TokenClientParam EXPERIMENTAL = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_EXPERIMENTAL); 3121 3122 /** 3123 * Search parameter: <b>display</b> 3124 * <p> 3125 * Description: <b>Use this name when displaying the value</b><br> 3126 * Type: <b>string</b><br> 3127 * Path: <b>StructureDefinition.display</b><br> 3128 * </p> 3129 */ 3130 @SearchParamDefinition(name="display", path="StructureDefinition.display", description="Use this name when displaying the value", type="string" ) 3131 public static final String SP_DISPLAY = "display"; 3132 /** 3133 * <b>Fluent Client</b> search parameter constant for <b>display</b> 3134 * <p> 3135 * Description: <b>Use this name when displaying the value</b><br> 3136 * Type: <b>string</b><br> 3137 * Path: <b>StructureDefinition.display</b><br> 3138 * </p> 3139 */ 3140 public static final ca.uhn.fhir.rest.gclient.StringClientParam DISPLAY = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DISPLAY); 3141 3142 /** 3143 * Search parameter: <b>ext-context</b> 3144 * <p> 3145 * Description: <b>Where the extension can be used in instances</b><br> 3146 * Type: <b>string</b><br> 3147 * Path: <b>StructureDefinition.context</b><br> 3148 * </p> 3149 */ 3150 @SearchParamDefinition(name="ext-context", path="StructureDefinition.context", description="Where the extension can be used in instances", type="string" ) 3151 public static final String SP_EXT_CONTEXT = "ext-context"; 3152 /** 3153 * <b>Fluent Client</b> search parameter constant for <b>ext-context</b> 3154 * <p> 3155 * Description: <b>Where the extension can be used in instances</b><br> 3156 * Type: <b>string</b><br> 3157 * Path: <b>StructureDefinition.context</b><br> 3158 * </p> 3159 */ 3160 public static final ca.uhn.fhir.rest.gclient.StringClientParam EXT_CONTEXT = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_EXT_CONTEXT); 3161 3162 /** 3163 * Search parameter: <b>code</b> 3164 * <p> 3165 * Description: <b>A code for the profile</b><br> 3166 * Type: <b>token</b><br> 3167 * Path: <b>StructureDefinition.code</b><br> 3168 * </p> 3169 */ 3170 @SearchParamDefinition(name="code", path="StructureDefinition.code", description="A code for the profile", type="token" ) 3171 public static final String SP_CODE = "code"; 3172 /** 3173 * <b>Fluent Client</b> search parameter constant for <b>code</b> 3174 * <p> 3175 * Description: <b>A code for the profile</b><br> 3176 * Type: <b>token</b><br> 3177 * Path: <b>StructureDefinition.code</b><br> 3178 * </p> 3179 */ 3180 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 3181 3182 /** 3183 * Search parameter: <b>date</b> 3184 * <p> 3185 * Description: <b>The profile publication date</b><br> 3186 * Type: <b>date</b><br> 3187 * Path: <b>StructureDefinition.date</b><br> 3188 * </p> 3189 */ 3190 @SearchParamDefinition(name="date", path="StructureDefinition.date", description="The profile publication date", type="date" ) 3191 public static final String SP_DATE = "date"; 3192 /** 3193 * <b>Fluent Client</b> search parameter constant for <b>date</b> 3194 * <p> 3195 * Description: <b>The profile publication date</b><br> 3196 * Type: <b>date</b><br> 3197 * Path: <b>StructureDefinition.date</b><br> 3198 * </p> 3199 */ 3200 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 3201 3202 /** 3203 * Search parameter: <b>type</b> 3204 * <p> 3205 * Description: <b>Any datatype or resource, including abstract ones</b><br> 3206 * Type: <b>token</b><br> 3207 * Path: <b>StructureDefinition.baseType</b><br> 3208 * </p> 3209 */ 3210 @SearchParamDefinition(name="type", path="StructureDefinition.baseType", description="Any datatype or resource, including abstract ones", type="token" ) 3211 public static final String SP_TYPE = "type"; 3212 /** 3213 * <b>Fluent Client</b> search parameter constant for <b>type</b> 3214 * <p> 3215 * Description: <b>Any datatype or resource, including abstract ones</b><br> 3216 * Type: <b>token</b><br> 3217 * Path: <b>StructureDefinition.baseType</b><br> 3218 * </p> 3219 */ 3220 public static final ca.uhn.fhir.rest.gclient.TokenClientParam TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_TYPE); 3221 3222 /** 3223 * Search parameter: <b>url</b> 3224 * <p> 3225 * Description: <b>Absolute URL used to reference this StructureDefinition</b><br> 3226 * Type: <b>uri</b><br> 3227 * Path: <b>StructureDefinition.url</b><br> 3228 * </p> 3229 */ 3230 @SearchParamDefinition(name="url", path="StructureDefinition.url", description="Absolute URL used to reference this StructureDefinition", type="uri" ) 3231 public static final String SP_URL = "url"; 3232 /** 3233 * <b>Fluent Client</b> search parameter constant for <b>url</b> 3234 * <p> 3235 * Description: <b>Absolute URL used to reference this StructureDefinition</b><br> 3236 * Type: <b>uri</b><br> 3237 * Path: <b>StructureDefinition.url</b><br> 3238 * </p> 3239 */ 3240 public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL); 3241 3242 /** 3243 * Search parameter: <b>kind</b> 3244 * <p> 3245 * Description: <b>datatype | resource | logical</b><br> 3246 * Type: <b>token</b><br> 3247 * Path: <b>StructureDefinition.kind</b><br> 3248 * </p> 3249 */ 3250 @SearchParamDefinition(name="kind", path="StructureDefinition.kind", description="datatype | resource | logical", type="token" ) 3251 public static final String SP_KIND = "kind"; 3252 /** 3253 * <b>Fluent Client</b> search parameter constant for <b>kind</b> 3254 * <p> 3255 * Description: <b>datatype | resource | logical</b><br> 3256 * Type: <b>token</b><br> 3257 * Path: <b>StructureDefinition.kind</b><br> 3258 * </p> 3259 */ 3260 public static final ca.uhn.fhir.rest.gclient.TokenClientParam KIND = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_KIND); 3261 3262 /** 3263 * Search parameter: <b>version</b> 3264 * <p> 3265 * Description: <b>The version identifier of the profile</b><br> 3266 * Type: <b>token</b><br> 3267 * Path: <b>StructureDefinition.version</b><br> 3268 * </p> 3269 */ 3270 @SearchParamDefinition(name="version", path="StructureDefinition.version", description="The version identifier of the profile", type="token" ) 3271 public static final String SP_VERSION = "version"; 3272 /** 3273 * <b>Fluent Client</b> search parameter constant for <b>version</b> 3274 * <p> 3275 * Description: <b>The version identifier of the profile</b><br> 3276 * Type: <b>token</b><br> 3277 * Path: <b>StructureDefinition.version</b><br> 3278 * </p> 3279 */ 3280 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_VERSION); 3281 3282 /** 3283 * Search parameter: <b>publisher</b> 3284 * <p> 3285 * Description: <b>Name of the publisher of the profile</b><br> 3286 * Type: <b>string</b><br> 3287 * Path: <b>StructureDefinition.publisher</b><br> 3288 * </p> 3289 */ 3290 @SearchParamDefinition(name="publisher", path="StructureDefinition.publisher", description="Name of the publisher of the profile", type="string" ) 3291 public static final String SP_PUBLISHER = "publisher"; 3292 /** 3293 * <b>Fluent Client</b> search parameter constant for <b>publisher</b> 3294 * <p> 3295 * Description: <b>Name of the publisher of the profile</b><br> 3296 * Type: <b>string</b><br> 3297 * Path: <b>StructureDefinition.publisher</b><br> 3298 * </p> 3299 */ 3300 public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_PUBLISHER); 3301 3302 /** 3303 * Search parameter: <b>derivation</b> 3304 * <p> 3305 * Description: <b>specialization | constraint - How relates to base definition</b><br> 3306 * Type: <b>token</b><br> 3307 * Path: <b>StructureDefinition.derivation</b><br> 3308 * </p> 3309 */ 3310 @SearchParamDefinition(name="derivation", path="StructureDefinition.derivation", description="specialization | constraint - How relates to base definition", type="token" ) 3311 public static final String SP_DERIVATION = "derivation"; 3312 /** 3313 * <b>Fluent Client</b> search parameter constant for <b>derivation</b> 3314 * <p> 3315 * Description: <b>specialization | constraint - How relates to base definition</b><br> 3316 * Type: <b>token</b><br> 3317 * Path: <b>StructureDefinition.derivation</b><br> 3318 * </p> 3319 */ 3320 public static final ca.uhn.fhir.rest.gclient.TokenClientParam DERIVATION = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_DERIVATION); 3321 3322 /** 3323 * Search parameter: <b>base-path</b> 3324 * <p> 3325 * Description: <b>Path that identifies the base element</b><br> 3326 * Type: <b>token</b><br> 3327 * Path: <b>StructureDefinition.snapshot.element.base.path, StructureDefinition.differential.element.base.path</b><br> 3328 * </p> 3329 */ 3330 @SearchParamDefinition(name="base-path", path="StructureDefinition.snapshot.element.base.path | StructureDefinition.differential.element.base.path", description="Path that identifies the base element", type="token" ) 3331 public static final String SP_BASE_PATH = "base-path"; 3332 /** 3333 * <b>Fluent Client</b> search parameter constant for <b>base-path</b> 3334 * <p> 3335 * Description: <b>Path that identifies the base element</b><br> 3336 * Type: <b>token</b><br> 3337 * Path: <b>StructureDefinition.snapshot.element.base.path, StructureDefinition.differential.element.base.path</b><br> 3338 * </p> 3339 */ 3340 public static final ca.uhn.fhir.rest.gclient.TokenClientParam BASE_PATH = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_BASE_PATH); 3341 3342 /** 3343 * Search parameter: <b>valueset</b> 3344 * <p> 3345 * Description: <b>A vocabulary binding reference</b><br> 3346 * Type: <b>reference</b><br> 3347 * Path: <b>StructureDefinition.snapshot.element.binding.valueSet[x]</b><br> 3348 * </p> 3349 */ 3350 @SearchParamDefinition(name="valueset", path="StructureDefinition.snapshot.element.binding.valueSet", description="A vocabulary binding reference", type="reference" ) 3351 public static final String SP_VALUESET = "valueset"; 3352 /** 3353 * <b>Fluent Client</b> search parameter constant for <b>valueset</b> 3354 * <p> 3355 * Description: <b>A vocabulary binding reference</b><br> 3356 * Type: <b>reference</b><br> 3357 * Path: <b>StructureDefinition.snapshot.element.binding.valueSet[x]</b><br> 3358 * </p> 3359 */ 3360 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam VALUESET = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_VALUESET); 3361 3362/** 3363 * Constant for fluent queries to be used to add include statements. Specifies 3364 * the path value of "<b>StructureDefinition:valueset</b>". 3365 */ 3366 public static final ca.uhn.fhir.model.api.Include INCLUDE_VALUESET = new ca.uhn.fhir.model.api.Include("StructureDefinition:valueset").toLocked(); 3367 3368 /** 3369 * Search parameter: <b>context-type</b> 3370 * <p> 3371 * Description: <b>resource | datatype | extension</b><br> 3372 * Type: <b>token</b><br> 3373 * Path: <b>StructureDefinition.contextType</b><br> 3374 * </p> 3375 */ 3376 @SearchParamDefinition(name="context-type", path="StructureDefinition.contextType", description="resource | datatype | extension", type="token" ) 3377 public static final String SP_CONTEXT_TYPE = "context-type"; 3378 /** 3379 * <b>Fluent Client</b> search parameter constant for <b>context-type</b> 3380 * <p> 3381 * Description: <b>resource | datatype | extension</b><br> 3382 * Type: <b>token</b><br> 3383 * Path: <b>StructureDefinition.contextType</b><br> 3384 * </p> 3385 */ 3386 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT_TYPE); 3387 3388 /** 3389 * Search parameter: <b>description</b> 3390 * <p> 3391 * Description: <b>Text search in the description of the profile</b><br> 3392 * Type: <b>string</b><br> 3393 * Path: <b>StructureDefinition.description</b><br> 3394 * </p> 3395 */ 3396 @SearchParamDefinition(name="description", path="StructureDefinition.description", description="Text search in the description of the profile", type="string" ) 3397 public static final String SP_DESCRIPTION = "description"; 3398 /** 3399 * <b>Fluent Client</b> search parameter constant for <b>description</b> 3400 * <p> 3401 * Description: <b>Text search in the description of the profile</b><br> 3402 * Type: <b>string</b><br> 3403 * Path: <b>StructureDefinition.description</b><br> 3404 * </p> 3405 */ 3406 public static final ca.uhn.fhir.rest.gclient.StringClientParam DESCRIPTION = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_DESCRIPTION); 3407 3408 /** 3409 * Search parameter: <b>name</b> 3410 * <p> 3411 * Description: <b>Name of the profile</b><br> 3412 * Type: <b>string</b><br> 3413 * Path: <b>StructureDefinition.name</b><br> 3414 * </p> 3415 */ 3416 @SearchParamDefinition(name="name", path="StructureDefinition.name", description="Name of the profile", type="string" ) 3417 public static final String SP_NAME = "name"; 3418 /** 3419 * <b>Fluent Client</b> search parameter constant for <b>name</b> 3420 * <p> 3421 * Description: <b>Name of the profile</b><br> 3422 * Type: <b>string</b><br> 3423 * Path: <b>StructureDefinition.name</b><br> 3424 * </p> 3425 */ 3426 public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam(SP_NAME); 3427 3428 /** 3429 * Search parameter: <b>base</b> 3430 * <p> 3431 * Description: <b>Definition that this type is constrained/specialized from</b><br> 3432 * Type: <b>uri</b><br> 3433 * Path: <b>StructureDefinition.baseDefinition</b><br> 3434 * </p> 3435 */ 3436 @SearchParamDefinition(name="base", path="StructureDefinition.baseDefinition", description="Definition that this type is constrained/specialized from", type="uri" ) 3437 public static final String SP_BASE = "base"; 3438 /** 3439 * <b>Fluent Client</b> search parameter constant for <b>base</b> 3440 * <p> 3441 * Description: <b>Definition that this type is constrained/specialized from</b><br> 3442 * Type: <b>uri</b><br> 3443 * Path: <b>StructureDefinition.baseDefinition</b><br> 3444 * </p> 3445 */ 3446 public static final ca.uhn.fhir.rest.gclient.UriClientParam BASE = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_BASE); 3447 3448 /** 3449 * Search parameter: <b>context</b> 3450 * <p> 3451 * Description: <b>A use context assigned to the structure</b><br> 3452 * Type: <b>token</b><br> 3453 * Path: <b>StructureDefinition.useContext</b><br> 3454 * </p> 3455 */ 3456 @SearchParamDefinition(name="context", path="StructureDefinition.useContext", description="A use context assigned to the structure", type="token" ) 3457 public static final String SP_CONTEXT = "context"; 3458 /** 3459 * <b>Fluent Client</b> search parameter constant for <b>context</b> 3460 * <p> 3461 * Description: <b>A use context assigned to the structure</b><br> 3462 * Type: <b>token</b><br> 3463 * Path: <b>StructureDefinition.useContext</b><br> 3464 * </p> 3465 */ 3466 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CONTEXT); 3467 3468 /** 3469 * Search parameter: <b>path</b> 3470 * <p> 3471 * Description: <b>A path that is constrained in the profile</b><br> 3472 * Type: <b>token</b><br> 3473 * Path: <b>StructureDefinition.snapshot.element.path, StructureDefinition.differential.element.path</b><br> 3474 * </p> 3475 */ 3476 @SearchParamDefinition(name="path", path="StructureDefinition.snapshot.element.path | StructureDefinition.differential.element.path", description="A path that is constrained in the profile", type="token" ) 3477 public static final String SP_PATH = "path"; 3478 /** 3479 * <b>Fluent Client</b> search parameter constant for <b>path</b> 3480 * <p> 3481 * Description: <b>A path that is constrained in the profile</b><br> 3482 * Type: <b>token</b><br> 3483 * Path: <b>StructureDefinition.snapshot.element.path, StructureDefinition.differential.element.path</b><br> 3484 * </p> 3485 */ 3486 public static final ca.uhn.fhir.rest.gclient.TokenClientParam PATH = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PATH); 3487 3488 /** 3489 * Search parameter: <b>identifier</b> 3490 * <p> 3491 * Description: <b>The identifier of the profile</b><br> 3492 * Type: <b>token</b><br> 3493 * Path: <b>StructureDefinition.identifier</b><br> 3494 * </p> 3495 */ 3496 @SearchParamDefinition(name="identifier", path="StructureDefinition.identifier", description="The identifier of the profile", type="token" ) 3497 public static final String SP_IDENTIFIER = "identifier"; 3498 /** 3499 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 3500 * <p> 3501 * Description: <b>The identifier of the profile</b><br> 3502 * Type: <b>token</b><br> 3503 * Path: <b>StructureDefinition.identifier</b><br> 3504 * </p> 3505 */ 3506 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 3507 3508 3509}