001package org.hl7.fhir.r4.model; 002 003/* 004 Copyright (c) 2011+, HL7, Inc. 005 All rights reserved. 006 007 Redistribution and use in source and binary forms, with or without modification, 008 are permitted provided that the following conditions are met: 009 010 * Redistributions of source code must retain the above copyright notice, this 011 list of conditions and the following disclaimer. 012 * Redistributions in binary form must reproduce the above copyright notice, 013 this list of conditions and the following disclaimer in the documentation 014 and/or other materials provided with the distribution. 015 * Neither the name of HL7 nor the names of its contributors may be used to 016 endorse or promote products derived from this software without specific 017 prior written permission. 018 019 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 020 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 021 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 022 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 023 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 024 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 025 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 026 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 027 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 028 POSSIBILITY OF SUCH DAMAGE. 029 030*/ 031 032// Generated on Tue, May 12, 2020 07:26+1000 for FHIR v4.0.1 033import java.util.ArrayList; 034import java.util.Date; 035import java.util.List; 036 037import org.hl7.fhir.exceptions.FHIRException; 038import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 039import org.hl7.fhir.r4.model.Enumerations.PublicationStatus; 040import org.hl7.fhir.r4.model.Enumerations.PublicationStatusEnumFactory; 041import org.hl7.fhir.utilities.Utilities; 042 043import ca.uhn.fhir.model.api.annotation.Block; 044import ca.uhn.fhir.model.api.annotation.Child; 045import ca.uhn.fhir.model.api.annotation.ChildOrder; 046import ca.uhn.fhir.model.api.annotation.Description; 047import ca.uhn.fhir.model.api.annotation.ResourceDef; 048import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 049 050/** 051 * A formal computable definition of a graph of resources - that is, a coherent 052 * set of resources that form a graph by following references. The Graph 053 * Definition resource defines a set and makes rules about the set. 054 */ 055@ResourceDef(name = "GraphDefinition", profile = "http://hl7.org/fhir/StructureDefinition/GraphDefinition") 056@ChildOrder(names = { "url", "version", "name", "status", "experimental", "date", "publisher", "contact", "description", 057 "useContext", "jurisdiction", "purpose", "start", "profile", "link" }) 058public class GraphDefinition extends MetadataResource { 059 060 public enum GraphCompartmentUse { 061 /** 062 * This compartment rule is a condition for whether the rule applies. 063 */ 064 CONDITION, 065 /** 066 * This compartment rule is enforced on any relationships that meet the 067 * conditions. 068 */ 069 REQUIREMENT, 070 /** 071 * added to help the parsers with the generic types 072 */ 073 NULL; 074 075 public static GraphCompartmentUse fromCode(String codeString) throws FHIRException { 076 if (codeString == null || "".equals(codeString)) 077 return null; 078 if ("condition".equals(codeString)) 079 return CONDITION; 080 if ("requirement".equals(codeString)) 081 return REQUIREMENT; 082 if (Configuration.isAcceptInvalidEnums()) 083 return null; 084 else 085 throw new FHIRException("Unknown GraphCompartmentUse code '" + codeString + "'"); 086 } 087 088 public String toCode() { 089 switch (this) { 090 case CONDITION: 091 return "condition"; 092 case REQUIREMENT: 093 return "requirement"; 094 case NULL: 095 return null; 096 default: 097 return "?"; 098 } 099 } 100 101 public String getSystem() { 102 switch (this) { 103 case CONDITION: 104 return "http://hl7.org/fhir/graph-compartment-use"; 105 case REQUIREMENT: 106 return "http://hl7.org/fhir/graph-compartment-use"; 107 case NULL: 108 return null; 109 default: 110 return "?"; 111 } 112 } 113 114 public String getDefinition() { 115 switch (this) { 116 case CONDITION: 117 return "This compartment rule is a condition for whether the rule applies."; 118 case REQUIREMENT: 119 return "This compartment rule is enforced on any relationships that meet the conditions."; 120 case NULL: 121 return null; 122 default: 123 return "?"; 124 } 125 } 126 127 public String getDisplay() { 128 switch (this) { 129 case CONDITION: 130 return "Condition"; 131 case REQUIREMENT: 132 return "Requirement"; 133 case NULL: 134 return null; 135 default: 136 return "?"; 137 } 138 } 139 } 140 141 public static class GraphCompartmentUseEnumFactory implements EnumFactory<GraphCompartmentUse> { 142 public GraphCompartmentUse fromCode(String codeString) throws IllegalArgumentException { 143 if (codeString == null || "".equals(codeString)) 144 if (codeString == null || "".equals(codeString)) 145 return null; 146 if ("condition".equals(codeString)) 147 return GraphCompartmentUse.CONDITION; 148 if ("requirement".equals(codeString)) 149 return GraphCompartmentUse.REQUIREMENT; 150 throw new IllegalArgumentException("Unknown GraphCompartmentUse code '" + codeString + "'"); 151 } 152 153 public Enumeration<GraphCompartmentUse> fromType(PrimitiveType<?> code) throws FHIRException { 154 if (code == null) 155 return null; 156 if (code.isEmpty()) 157 return new Enumeration<GraphCompartmentUse>(this, GraphCompartmentUse.NULL, code); 158 String codeString = code.asStringValue(); 159 if (codeString == null || "".equals(codeString)) 160 return new Enumeration<GraphCompartmentUse>(this, GraphCompartmentUse.NULL, code); 161 if ("condition".equals(codeString)) 162 return new Enumeration<GraphCompartmentUse>(this, GraphCompartmentUse.CONDITION, code); 163 if ("requirement".equals(codeString)) 164 return new Enumeration<GraphCompartmentUse>(this, GraphCompartmentUse.REQUIREMENT, code); 165 throw new FHIRException("Unknown GraphCompartmentUse code '" + codeString + "'"); 166 } 167 168 public String toCode(GraphCompartmentUse code) { 169 if (code == GraphCompartmentUse.CONDITION) 170 return "condition"; 171 if (code == GraphCompartmentUse.REQUIREMENT) 172 return "requirement"; 173 return "?"; 174 } 175 176 public String toSystem(GraphCompartmentUse code) { 177 return code.getSystem(); 178 } 179 } 180 181 public enum CompartmentCode { 182 /** 183 * The compartment definition is for the patient compartment. 184 */ 185 PATIENT, 186 /** 187 * The compartment definition is for the encounter compartment. 188 */ 189 ENCOUNTER, 190 /** 191 * The compartment definition is for the related-person compartment. 192 */ 193 RELATEDPERSON, 194 /** 195 * The compartment definition is for the practitioner compartment. 196 */ 197 PRACTITIONER, 198 /** 199 * The compartment definition is for the device compartment. 200 */ 201 DEVICE, 202 /** 203 * added to help the parsers with the generic types 204 */ 205 NULL; 206 207 public static CompartmentCode fromCode(String codeString) throws FHIRException { 208 if (codeString == null || "".equals(codeString)) 209 return null; 210 if ("Patient".equals(codeString)) 211 return PATIENT; 212 if ("Encounter".equals(codeString)) 213 return ENCOUNTER; 214 if ("RelatedPerson".equals(codeString)) 215 return RELATEDPERSON; 216 if ("Practitioner".equals(codeString)) 217 return PRACTITIONER; 218 if ("Device".equals(codeString)) 219 return DEVICE; 220 if (Configuration.isAcceptInvalidEnums()) 221 return null; 222 else 223 throw new FHIRException("Unknown CompartmentCode code '" + codeString + "'"); 224 } 225 226 public String toCode() { 227 switch (this) { 228 case PATIENT: 229 return "Patient"; 230 case ENCOUNTER: 231 return "Encounter"; 232 case RELATEDPERSON: 233 return "RelatedPerson"; 234 case PRACTITIONER: 235 return "Practitioner"; 236 case DEVICE: 237 return "Device"; 238 case NULL: 239 return null; 240 default: 241 return "?"; 242 } 243 } 244 245 public String getSystem() { 246 switch (this) { 247 case PATIENT: 248 return "http://hl7.org/fhir/compartment-type"; 249 case ENCOUNTER: 250 return "http://hl7.org/fhir/compartment-type"; 251 case RELATEDPERSON: 252 return "http://hl7.org/fhir/compartment-type"; 253 case PRACTITIONER: 254 return "http://hl7.org/fhir/compartment-type"; 255 case DEVICE: 256 return "http://hl7.org/fhir/compartment-type"; 257 case NULL: 258 return null; 259 default: 260 return "?"; 261 } 262 } 263 264 public String getDefinition() { 265 switch (this) { 266 case PATIENT: 267 return "The compartment definition is for the patient compartment."; 268 case ENCOUNTER: 269 return "The compartment definition is for the encounter compartment."; 270 case RELATEDPERSON: 271 return "The compartment definition is for the related-person compartment."; 272 case PRACTITIONER: 273 return "The compartment definition is for the practitioner compartment."; 274 case DEVICE: 275 return "The compartment definition is for the device compartment."; 276 case NULL: 277 return null; 278 default: 279 return "?"; 280 } 281 } 282 283 public String getDisplay() { 284 switch (this) { 285 case PATIENT: 286 return "Patient"; 287 case ENCOUNTER: 288 return "Encounter"; 289 case RELATEDPERSON: 290 return "RelatedPerson"; 291 case PRACTITIONER: 292 return "Practitioner"; 293 case DEVICE: 294 return "Device"; 295 case NULL: 296 return null; 297 default: 298 return "?"; 299 } 300 } 301 } 302 303 public static class CompartmentCodeEnumFactory implements EnumFactory<CompartmentCode> { 304 public CompartmentCode fromCode(String codeString) throws IllegalArgumentException { 305 if (codeString == null || "".equals(codeString)) 306 if (codeString == null || "".equals(codeString)) 307 return null; 308 if ("Patient".equals(codeString)) 309 return CompartmentCode.PATIENT; 310 if ("Encounter".equals(codeString)) 311 return CompartmentCode.ENCOUNTER; 312 if ("RelatedPerson".equals(codeString)) 313 return CompartmentCode.RELATEDPERSON; 314 if ("Practitioner".equals(codeString)) 315 return CompartmentCode.PRACTITIONER; 316 if ("Device".equals(codeString)) 317 return CompartmentCode.DEVICE; 318 throw new IllegalArgumentException("Unknown CompartmentCode code '" + codeString + "'"); 319 } 320 321 public Enumeration<CompartmentCode> fromType(PrimitiveType<?> code) throws FHIRException { 322 if (code == null) 323 return null; 324 if (code.isEmpty()) 325 return new Enumeration<CompartmentCode>(this, CompartmentCode.NULL, code); 326 String codeString = code.asStringValue(); 327 if (codeString == null || "".equals(codeString)) 328 return new Enumeration<CompartmentCode>(this, CompartmentCode.NULL, code); 329 if ("Patient".equals(codeString)) 330 return new Enumeration<CompartmentCode>(this, CompartmentCode.PATIENT, code); 331 if ("Encounter".equals(codeString)) 332 return new Enumeration<CompartmentCode>(this, CompartmentCode.ENCOUNTER, code); 333 if ("RelatedPerson".equals(codeString)) 334 return new Enumeration<CompartmentCode>(this, CompartmentCode.RELATEDPERSON, code); 335 if ("Practitioner".equals(codeString)) 336 return new Enumeration<CompartmentCode>(this, CompartmentCode.PRACTITIONER, code); 337 if ("Device".equals(codeString)) 338 return new Enumeration<CompartmentCode>(this, CompartmentCode.DEVICE, code); 339 throw new FHIRException("Unknown CompartmentCode code '" + codeString + "'"); 340 } 341 342 public String toCode(CompartmentCode code) { 343 if (code == CompartmentCode.PATIENT) 344 return "Patient"; 345 if (code == CompartmentCode.ENCOUNTER) 346 return "Encounter"; 347 if (code == CompartmentCode.RELATEDPERSON) 348 return "RelatedPerson"; 349 if (code == CompartmentCode.PRACTITIONER) 350 return "Practitioner"; 351 if (code == CompartmentCode.DEVICE) 352 return "Device"; 353 return "?"; 354 } 355 356 public String toSystem(CompartmentCode code) { 357 return code.getSystem(); 358 } 359 } 360 361 public enum GraphCompartmentRule { 362 /** 363 * The compartment must be identical (the same literal reference). 364 */ 365 IDENTICAL, 366 /** 367 * The compartment must be the same - the record must be about the same patient, 368 * but the reference may be different. 369 */ 370 MATCHING, 371 /** 372 * The compartment must be different. 373 */ 374 DIFFERENT, 375 /** 376 * The compartment rule is defined in the accompanying FHIRPath expression. 377 */ 378 CUSTOM, 379 /** 380 * added to help the parsers with the generic types 381 */ 382 NULL; 383 384 public static GraphCompartmentRule fromCode(String codeString) throws FHIRException { 385 if (codeString == null || "".equals(codeString)) 386 return null; 387 if ("identical".equals(codeString)) 388 return IDENTICAL; 389 if ("matching".equals(codeString)) 390 return MATCHING; 391 if ("different".equals(codeString)) 392 return DIFFERENT; 393 if ("custom".equals(codeString)) 394 return CUSTOM; 395 if (Configuration.isAcceptInvalidEnums()) 396 return null; 397 else 398 throw new FHIRException("Unknown GraphCompartmentRule code '" + codeString + "'"); 399 } 400 401 public String toCode() { 402 switch (this) { 403 case IDENTICAL: 404 return "identical"; 405 case MATCHING: 406 return "matching"; 407 case DIFFERENT: 408 return "different"; 409 case CUSTOM: 410 return "custom"; 411 case NULL: 412 return null; 413 default: 414 return "?"; 415 } 416 } 417 418 public String getSystem() { 419 switch (this) { 420 case IDENTICAL: 421 return "http://hl7.org/fhir/graph-compartment-rule"; 422 case MATCHING: 423 return "http://hl7.org/fhir/graph-compartment-rule"; 424 case DIFFERENT: 425 return "http://hl7.org/fhir/graph-compartment-rule"; 426 case CUSTOM: 427 return "http://hl7.org/fhir/graph-compartment-rule"; 428 case NULL: 429 return null; 430 default: 431 return "?"; 432 } 433 } 434 435 public String getDefinition() { 436 switch (this) { 437 case IDENTICAL: 438 return "The compartment must be identical (the same literal reference)."; 439 case MATCHING: 440 return "The compartment must be the same - the record must be about the same patient, but the reference may be different."; 441 case DIFFERENT: 442 return "The compartment must be different."; 443 case CUSTOM: 444 return "The compartment rule is defined in the accompanying FHIRPath expression."; 445 case NULL: 446 return null; 447 default: 448 return "?"; 449 } 450 } 451 452 public String getDisplay() { 453 switch (this) { 454 case IDENTICAL: 455 return "Identical"; 456 case MATCHING: 457 return "Matching"; 458 case DIFFERENT: 459 return "Different"; 460 case CUSTOM: 461 return "Custom"; 462 case NULL: 463 return null; 464 default: 465 return "?"; 466 } 467 } 468 } 469 470 public static class GraphCompartmentRuleEnumFactory implements EnumFactory<GraphCompartmentRule> { 471 public GraphCompartmentRule fromCode(String codeString) throws IllegalArgumentException { 472 if (codeString == null || "".equals(codeString)) 473 if (codeString == null || "".equals(codeString)) 474 return null; 475 if ("identical".equals(codeString)) 476 return GraphCompartmentRule.IDENTICAL; 477 if ("matching".equals(codeString)) 478 return GraphCompartmentRule.MATCHING; 479 if ("different".equals(codeString)) 480 return GraphCompartmentRule.DIFFERENT; 481 if ("custom".equals(codeString)) 482 return GraphCompartmentRule.CUSTOM; 483 throw new IllegalArgumentException("Unknown GraphCompartmentRule code '" + codeString + "'"); 484 } 485 486 public Enumeration<GraphCompartmentRule> fromType(PrimitiveType<?> code) throws FHIRException { 487 if (code == null) 488 return null; 489 if (code.isEmpty()) 490 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.NULL, code); 491 String codeString = code.asStringValue(); 492 if (codeString == null || "".equals(codeString)) 493 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.NULL, code); 494 if ("identical".equals(codeString)) 495 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.IDENTICAL, code); 496 if ("matching".equals(codeString)) 497 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.MATCHING, code); 498 if ("different".equals(codeString)) 499 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.DIFFERENT, code); 500 if ("custom".equals(codeString)) 501 return new Enumeration<GraphCompartmentRule>(this, GraphCompartmentRule.CUSTOM, code); 502 throw new FHIRException("Unknown GraphCompartmentRule code '" + codeString + "'"); 503 } 504 505 public String toCode(GraphCompartmentRule code) { 506 if (code == GraphCompartmentRule.IDENTICAL) 507 return "identical"; 508 if (code == GraphCompartmentRule.MATCHING) 509 return "matching"; 510 if (code == GraphCompartmentRule.DIFFERENT) 511 return "different"; 512 if (code == GraphCompartmentRule.CUSTOM) 513 return "custom"; 514 return "?"; 515 } 516 517 public String toSystem(GraphCompartmentRule code) { 518 return code.getSystem(); 519 } 520 } 521 522 @Block() 523 public static class GraphDefinitionLinkComponent extends BackboneElement implements IBaseBackboneElement { 524 /** 525 * A FHIR expression that identifies one of FHIR References to other resources. 526 */ 527 @Child(name = "path", type = { StringType.class }, order = 1, min = 0, max = 1, modifier = false, summary = false) 528 @Description(shortDefinition = "Path in the resource that contains the link", formalDefinition = "A FHIR expression that identifies one of FHIR References to other resources.") 529 protected StringType path; 530 531 /** 532 * Which slice (if profiled). 533 */ 534 @Child(name = "sliceName", type = { 535 StringType.class }, order = 2, min = 0, max = 1, modifier = false, summary = false) 536 @Description(shortDefinition = "Which slice (if profiled)", formalDefinition = "Which slice (if profiled).") 537 protected StringType sliceName; 538 539 /** 540 * Minimum occurrences for this link. 541 */ 542 @Child(name = "min", type = { IntegerType.class }, order = 3, min = 0, max = 1, modifier = false, summary = false) 543 @Description(shortDefinition = "Minimum occurrences for this link", formalDefinition = "Minimum occurrences for this link.") 544 protected IntegerType min; 545 546 /** 547 * Maximum occurrences for this link. 548 */ 549 @Child(name = "max", type = { StringType.class }, order = 4, min = 0, max = 1, modifier = false, summary = false) 550 @Description(shortDefinition = "Maximum occurrences for this link", formalDefinition = "Maximum occurrences for this link.") 551 protected StringType max; 552 553 /** 554 * Information about why this link is of interest in this graph definition. 555 */ 556 @Child(name = "description", type = { 557 StringType.class }, order = 5, min = 0, max = 1, modifier = false, summary = false) 558 @Description(shortDefinition = "Why this link is specified", formalDefinition = "Information about why this link is of interest in this graph definition.") 559 protected StringType description; 560 561 /** 562 * Potential target for the link. 563 */ 564 @Child(name = "target", type = {}, order = 6, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false) 565 @Description(shortDefinition = "Potential target for the link", formalDefinition = "Potential target for the link.") 566 protected List<GraphDefinitionLinkTargetComponent> target; 567 568 private static final long serialVersionUID = -593733346L; 569 570 /** 571 * Constructor 572 */ 573 public GraphDefinitionLinkComponent() { 574 super(); 575 } 576 577 /** 578 * @return {@link #path} (A FHIR expression that identifies one of FHIR 579 * References to other resources.). This is the underlying object with 580 * id, value and extensions. The accessor "getPath" gives direct access 581 * to the value 582 */ 583 public StringType getPathElement() { 584 if (this.path == null) 585 if (Configuration.errorOnAutoCreate()) 586 throw new Error("Attempt to auto-create GraphDefinitionLinkComponent.path"); 587 else if (Configuration.doAutoCreate()) 588 this.path = new StringType(); // bb 589 return this.path; 590 } 591 592 public boolean hasPathElement() { 593 return this.path != null && !this.path.isEmpty(); 594 } 595 596 public boolean hasPath() { 597 return this.path != null && !this.path.isEmpty(); 598 } 599 600 /** 601 * @param value {@link #path} (A FHIR expression that identifies one of FHIR 602 * References to other resources.). This is the underlying object 603 * with id, value and extensions. The accessor "getPath" gives 604 * direct access to the value 605 */ 606 public GraphDefinitionLinkComponent setPathElement(StringType value) { 607 this.path = value; 608 return this; 609 } 610 611 /** 612 * @return A FHIR expression that identifies one of FHIR References to other 613 * resources. 614 */ 615 public String getPath() { 616 return this.path == null ? null : this.path.getValue(); 617 } 618 619 /** 620 * @param value A FHIR expression that identifies one of FHIR References to 621 * other resources. 622 */ 623 public GraphDefinitionLinkComponent setPath(String value) { 624 if (Utilities.noString(value)) 625 this.path = null; 626 else { 627 if (this.path == null) 628 this.path = new StringType(); 629 this.path.setValue(value); 630 } 631 return this; 632 } 633 634 /** 635 * @return {@link #sliceName} (Which slice (if profiled).). This is the 636 * underlying object with id, value and extensions. The accessor 637 * "getSliceName" gives direct access to the value 638 */ 639 public StringType getSliceNameElement() { 640 if (this.sliceName == null) 641 if (Configuration.errorOnAutoCreate()) 642 throw new Error("Attempt to auto-create GraphDefinitionLinkComponent.sliceName"); 643 else if (Configuration.doAutoCreate()) 644 this.sliceName = new StringType(); // bb 645 return this.sliceName; 646 } 647 648 public boolean hasSliceNameElement() { 649 return this.sliceName != null && !this.sliceName.isEmpty(); 650 } 651 652 public boolean hasSliceName() { 653 return this.sliceName != null && !this.sliceName.isEmpty(); 654 } 655 656 /** 657 * @param value {@link #sliceName} (Which slice (if profiled).). This is the 658 * underlying object with id, value and extensions. The accessor 659 * "getSliceName" gives direct access to the value 660 */ 661 public GraphDefinitionLinkComponent setSliceNameElement(StringType value) { 662 this.sliceName = value; 663 return this; 664 } 665 666 /** 667 * @return Which slice (if profiled). 668 */ 669 public String getSliceName() { 670 return this.sliceName == null ? null : this.sliceName.getValue(); 671 } 672 673 /** 674 * @param value Which slice (if profiled). 675 */ 676 public GraphDefinitionLinkComponent setSliceName(String value) { 677 if (Utilities.noString(value)) 678 this.sliceName = null; 679 else { 680 if (this.sliceName == null) 681 this.sliceName = new StringType(); 682 this.sliceName.setValue(value); 683 } 684 return this; 685 } 686 687 /** 688 * @return {@link #min} (Minimum occurrences for this link.). This is the 689 * underlying object with id, value and extensions. The accessor 690 * "getMin" gives direct access to the value 691 */ 692 public IntegerType getMinElement() { 693 if (this.min == null) 694 if (Configuration.errorOnAutoCreate()) 695 throw new Error("Attempt to auto-create GraphDefinitionLinkComponent.min"); 696 else if (Configuration.doAutoCreate()) 697 this.min = new IntegerType(); // bb 698 return this.min; 699 } 700 701 public boolean hasMinElement() { 702 return this.min != null && !this.min.isEmpty(); 703 } 704 705 public boolean hasMin() { 706 return this.min != null && !this.min.isEmpty(); 707 } 708 709 /** 710 * @param value {@link #min} (Minimum occurrences for this link.). This is the 711 * underlying object with id, value and extensions. The accessor 712 * "getMin" gives direct access to the value 713 */ 714 public GraphDefinitionLinkComponent setMinElement(IntegerType value) { 715 this.min = value; 716 return this; 717 } 718 719 /** 720 * @return Minimum occurrences for this link. 721 */ 722 public int getMin() { 723 return this.min == null || this.min.isEmpty() ? 0 : this.min.getValue(); 724 } 725 726 /** 727 * @param value Minimum occurrences for this link. 728 */ 729 public GraphDefinitionLinkComponent setMin(int value) { 730 if (this.min == null) 731 this.min = new IntegerType(); 732 this.min.setValue(value); 733 return this; 734 } 735 736 /** 737 * @return {@link #max} (Maximum occurrences for this link.). This is the 738 * underlying object with id, value and extensions. The accessor 739 * "getMax" gives direct access to the value 740 */ 741 public StringType getMaxElement() { 742 if (this.max == null) 743 if (Configuration.errorOnAutoCreate()) 744 throw new Error("Attempt to auto-create GraphDefinitionLinkComponent.max"); 745 else if (Configuration.doAutoCreate()) 746 this.max = new StringType(); // bb 747 return this.max; 748 } 749 750 public boolean hasMaxElement() { 751 return this.max != null && !this.max.isEmpty(); 752 } 753 754 public boolean hasMax() { 755 return this.max != null && !this.max.isEmpty(); 756 } 757 758 /** 759 * @param value {@link #max} (Maximum occurrences for this link.). This is the 760 * underlying object with id, value and extensions. The accessor 761 * "getMax" gives direct access to the value 762 */ 763 public GraphDefinitionLinkComponent setMaxElement(StringType value) { 764 this.max = value; 765 return this; 766 } 767 768 /** 769 * @return Maximum occurrences for this link. 770 */ 771 public String getMax() { 772 return this.max == null ? null : this.max.getValue(); 773 } 774 775 /** 776 * @param value Maximum occurrences for this link. 777 */ 778 public GraphDefinitionLinkComponent setMax(String value) { 779 if (Utilities.noString(value)) 780 this.max = null; 781 else { 782 if (this.max == null) 783 this.max = new StringType(); 784 this.max.setValue(value); 785 } 786 return this; 787 } 788 789 /** 790 * @return {@link #description} (Information about why this link is of interest 791 * in this graph definition.). This is the underlying object with id, 792 * value and extensions. The accessor "getDescription" gives direct 793 * access to the value 794 */ 795 public StringType getDescriptionElement() { 796 if (this.description == null) 797 if (Configuration.errorOnAutoCreate()) 798 throw new Error("Attempt to auto-create GraphDefinitionLinkComponent.description"); 799 else if (Configuration.doAutoCreate()) 800 this.description = new StringType(); // bb 801 return this.description; 802 } 803 804 public boolean hasDescriptionElement() { 805 return this.description != null && !this.description.isEmpty(); 806 } 807 808 public boolean hasDescription() { 809 return this.description != null && !this.description.isEmpty(); 810 } 811 812 /** 813 * @param value {@link #description} (Information about why this link is of 814 * interest in this graph definition.). This is the underlying 815 * object with id, value and extensions. The accessor 816 * "getDescription" gives direct access to the value 817 */ 818 public GraphDefinitionLinkComponent setDescriptionElement(StringType value) { 819 this.description = value; 820 return this; 821 } 822 823 /** 824 * @return Information about why this link is of interest in this graph 825 * definition. 826 */ 827 public String getDescription() { 828 return this.description == null ? null : this.description.getValue(); 829 } 830 831 /** 832 * @param value Information about why this link is of interest in this graph 833 * definition. 834 */ 835 public GraphDefinitionLinkComponent setDescription(String value) { 836 if (Utilities.noString(value)) 837 this.description = null; 838 else { 839 if (this.description == null) 840 this.description = new StringType(); 841 this.description.setValue(value); 842 } 843 return this; 844 } 845 846 /** 847 * @return {@link #target} (Potential target for the link.) 848 */ 849 public List<GraphDefinitionLinkTargetComponent> getTarget() { 850 if (this.target == null) 851 this.target = new ArrayList<GraphDefinitionLinkTargetComponent>(); 852 return this.target; 853 } 854 855 /** 856 * @return Returns a reference to <code>this</code> for easy method chaining 857 */ 858 public GraphDefinitionLinkComponent setTarget(List<GraphDefinitionLinkTargetComponent> theTarget) { 859 this.target = theTarget; 860 return this; 861 } 862 863 public boolean hasTarget() { 864 if (this.target == null) 865 return false; 866 for (GraphDefinitionLinkTargetComponent item : this.target) 867 if (!item.isEmpty()) 868 return true; 869 return false; 870 } 871 872 public GraphDefinitionLinkTargetComponent addTarget() { // 3 873 GraphDefinitionLinkTargetComponent t = new GraphDefinitionLinkTargetComponent(); 874 if (this.target == null) 875 this.target = new ArrayList<GraphDefinitionLinkTargetComponent>(); 876 this.target.add(t); 877 return t; 878 } 879 880 public GraphDefinitionLinkComponent addTarget(GraphDefinitionLinkTargetComponent t) { // 3 881 if (t == null) 882 return this; 883 if (this.target == null) 884 this.target = new ArrayList<GraphDefinitionLinkTargetComponent>(); 885 this.target.add(t); 886 return this; 887 } 888 889 /** 890 * @return The first repetition of repeating field {@link #target}, creating it 891 * if it does not already exist 892 */ 893 public GraphDefinitionLinkTargetComponent getTargetFirstRep() { 894 if (getTarget().isEmpty()) { 895 addTarget(); 896 } 897 return getTarget().get(0); 898 } 899 900 protected void listChildren(List<Property> children) { 901 super.listChildren(children); 902 children.add(new Property("path", "string", 903 "A FHIR expression that identifies one of FHIR References to other resources.", 0, 1, path)); 904 children.add(new Property("sliceName", "string", "Which slice (if profiled).", 0, 1, sliceName)); 905 children.add(new Property("min", "integer", "Minimum occurrences for this link.", 0, 1, min)); 906 children.add(new Property("max", "string", "Maximum occurrences for this link.", 0, 1, max)); 907 children.add(new Property("description", "string", 908 "Information about why this link is of interest in this graph definition.", 0, 1, description)); 909 children 910 .add(new Property("target", "", "Potential target for the link.", 0, java.lang.Integer.MAX_VALUE, target)); 911 } 912 913 @Override 914 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 915 switch (_hash) { 916 case 3433509: 917 /* path */ return new Property("path", "string", 918 "A FHIR expression that identifies one of FHIR References to other resources.", 0, 1, path); 919 case -825289923: 920 /* sliceName */ return new Property("sliceName", "string", "Which slice (if profiled).", 0, 1, sliceName); 921 case 108114: 922 /* min */ return new Property("min", "integer", "Minimum occurrences for this link.", 0, 1, min); 923 case 107876: 924 /* max */ return new Property("max", "string", "Maximum occurrences for this link.", 0, 1, max); 925 case -1724546052: 926 /* description */ return new Property("description", "string", 927 "Information about why this link is of interest in this graph definition.", 0, 1, description); 928 case -880905839: 929 /* target */ return new Property("target", "", "Potential target for the link.", 0, java.lang.Integer.MAX_VALUE, 930 target); 931 default: 932 return super.getNamedProperty(_hash, _name, _checkValid); 933 } 934 935 } 936 937 @Override 938 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 939 switch (hash) { 940 case 3433509: 941 /* path */ return this.path == null ? new Base[0] : new Base[] { this.path }; // StringType 942 case -825289923: 943 /* sliceName */ return this.sliceName == null ? new Base[0] : new Base[] { this.sliceName }; // StringType 944 case 108114: 945 /* min */ return this.min == null ? new Base[0] : new Base[] { this.min }; // IntegerType 946 case 107876: 947 /* max */ return this.max == null ? new Base[0] : new Base[] { this.max }; // StringType 948 case -1724546052: 949 /* description */ return this.description == null ? new Base[0] : new Base[] { this.description }; // StringType 950 case -880905839: 951 /* target */ return this.target == null ? new Base[0] : this.target.toArray(new Base[this.target.size()]); // GraphDefinitionLinkTargetComponent 952 default: 953 return super.getProperty(hash, name, checkValid); 954 } 955 956 } 957 958 @Override 959 public Base setProperty(int hash, String name, Base value) throws FHIRException { 960 switch (hash) { 961 case 3433509: // path 962 this.path = castToString(value); // StringType 963 return value; 964 case -825289923: // sliceName 965 this.sliceName = castToString(value); // StringType 966 return value; 967 case 108114: // min 968 this.min = castToInteger(value); // IntegerType 969 return value; 970 case 107876: // max 971 this.max = castToString(value); // StringType 972 return value; 973 case -1724546052: // description 974 this.description = castToString(value); // StringType 975 return value; 976 case -880905839: // target 977 this.getTarget().add((GraphDefinitionLinkTargetComponent) value); // GraphDefinitionLinkTargetComponent 978 return value; 979 default: 980 return super.setProperty(hash, name, value); 981 } 982 983 } 984 985 @Override 986 public Base setProperty(String name, Base value) throws FHIRException { 987 if (name.equals("path")) { 988 this.path = castToString(value); // StringType 989 } else if (name.equals("sliceName")) { 990 this.sliceName = castToString(value); // StringType 991 } else if (name.equals("min")) { 992 this.min = castToInteger(value); // IntegerType 993 } else if (name.equals("max")) { 994 this.max = castToString(value); // StringType 995 } else if (name.equals("description")) { 996 this.description = castToString(value); // StringType 997 } else if (name.equals("target")) { 998 this.getTarget().add((GraphDefinitionLinkTargetComponent) value); 999 } else 1000 return super.setProperty(name, value); 1001 return value; 1002 } 1003 1004 @Override 1005 public void removeChild(String name, Base value) throws FHIRException { 1006 if (name.equals("path")) { 1007 this.path = null; 1008 } else if (name.equals("sliceName")) { 1009 this.sliceName = null; 1010 } else if (name.equals("min")) { 1011 this.min = null; 1012 } else if (name.equals("max")) { 1013 this.max = null; 1014 } else if (name.equals("description")) { 1015 this.description = null; 1016 } else if (name.equals("target")) { 1017 this.getTarget().remove((GraphDefinitionLinkTargetComponent) value); 1018 } else 1019 super.removeChild(name, value); 1020 1021 } 1022 1023 @Override 1024 public Base makeProperty(int hash, String name) throws FHIRException { 1025 switch (hash) { 1026 case 3433509: 1027 return getPathElement(); 1028 case -825289923: 1029 return getSliceNameElement(); 1030 case 108114: 1031 return getMinElement(); 1032 case 107876: 1033 return getMaxElement(); 1034 case -1724546052: 1035 return getDescriptionElement(); 1036 case -880905839: 1037 return addTarget(); 1038 default: 1039 return super.makeProperty(hash, name); 1040 } 1041 1042 } 1043 1044 @Override 1045 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1046 switch (hash) { 1047 case 3433509: 1048 /* path */ return new String[] { "string" }; 1049 case -825289923: 1050 /* sliceName */ return new String[] { "string" }; 1051 case 108114: 1052 /* min */ return new String[] { "integer" }; 1053 case 107876: 1054 /* max */ return new String[] { "string" }; 1055 case -1724546052: 1056 /* description */ return new String[] { "string" }; 1057 case -880905839: 1058 /* target */ return new String[] {}; 1059 default: 1060 return super.getTypesForProperty(hash, name); 1061 } 1062 1063 } 1064 1065 @Override 1066 public Base addChild(String name) throws FHIRException { 1067 if (name.equals("path")) { 1068 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.path"); 1069 } else if (name.equals("sliceName")) { 1070 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.sliceName"); 1071 } else if (name.equals("min")) { 1072 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.min"); 1073 } else if (name.equals("max")) { 1074 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.max"); 1075 } else if (name.equals("description")) { 1076 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.description"); 1077 } else if (name.equals("target")) { 1078 return addTarget(); 1079 } else 1080 return super.addChild(name); 1081 } 1082 1083 public GraphDefinitionLinkComponent copy() { 1084 GraphDefinitionLinkComponent dst = new GraphDefinitionLinkComponent(); 1085 copyValues(dst); 1086 return dst; 1087 } 1088 1089 public void copyValues(GraphDefinitionLinkComponent dst) { 1090 super.copyValues(dst); 1091 dst.path = path == null ? null : path.copy(); 1092 dst.sliceName = sliceName == null ? null : sliceName.copy(); 1093 dst.min = min == null ? null : min.copy(); 1094 dst.max = max == null ? null : max.copy(); 1095 dst.description = description == null ? null : description.copy(); 1096 if (target != null) { 1097 dst.target = new ArrayList<GraphDefinitionLinkTargetComponent>(); 1098 for (GraphDefinitionLinkTargetComponent i : target) 1099 dst.target.add(i.copy()); 1100 } 1101 ; 1102 } 1103 1104 @Override 1105 public boolean equalsDeep(Base other_) { 1106 if (!super.equalsDeep(other_)) 1107 return false; 1108 if (!(other_ instanceof GraphDefinitionLinkComponent)) 1109 return false; 1110 GraphDefinitionLinkComponent o = (GraphDefinitionLinkComponent) other_; 1111 return compareDeep(path, o.path, true) && compareDeep(sliceName, o.sliceName, true) 1112 && compareDeep(min, o.min, true) && compareDeep(max, o.max, true) 1113 && compareDeep(description, o.description, true) && compareDeep(target, o.target, true); 1114 } 1115 1116 @Override 1117 public boolean equalsShallow(Base other_) { 1118 if (!super.equalsShallow(other_)) 1119 return false; 1120 if (!(other_ instanceof GraphDefinitionLinkComponent)) 1121 return false; 1122 GraphDefinitionLinkComponent o = (GraphDefinitionLinkComponent) other_; 1123 return compareValues(path, o.path, true) && compareValues(sliceName, o.sliceName, true) 1124 && compareValues(min, o.min, true) && compareValues(max, o.max, true) 1125 && compareValues(description, o.description, true); 1126 } 1127 1128 public boolean isEmpty() { 1129 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(path, sliceName, min, max, description, target); 1130 } 1131 1132 public String fhirType() { 1133 return "GraphDefinition.link"; 1134 1135 } 1136 1137 } 1138 1139 @Block() 1140 public static class GraphDefinitionLinkTargetComponent extends BackboneElement implements IBaseBackboneElement { 1141 /** 1142 * Type of resource this link refers to. 1143 */ 1144 @Child(name = "type", type = { CodeType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false) 1145 @Description(shortDefinition = "Type of resource this link refers to", formalDefinition = "Type of resource this link refers to.") 1146 @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/resource-types") 1147 protected CodeType type; 1148 1149 /** 1150 * A set of parameters to look up. 1151 */ 1152 @Child(name = "params", type = { StringType.class }, order = 2, min = 0, max = 1, modifier = false, summary = false) 1153 @Description(shortDefinition = "Criteria for reverse lookup", formalDefinition = "A set of parameters to look up.") 1154 protected StringType params; 1155 1156 /** 1157 * Profile for the target resource. 1158 */ 1159 @Child(name = "profile", type = { 1160 CanonicalType.class }, order = 3, min = 0, max = 1, modifier = false, summary = false) 1161 @Description(shortDefinition = "Profile for the target resource", formalDefinition = "Profile for the target resource.") 1162 protected CanonicalType profile; 1163 1164 /** 1165 * Compartment Consistency Rules. 1166 */ 1167 @Child(name = "compartment", type = {}, order = 4, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false) 1168 @Description(shortDefinition = "Compartment Consistency Rules", formalDefinition = "Compartment Consistency Rules.") 1169 protected List<GraphDefinitionLinkTargetCompartmentComponent> compartment; 1170 1171 /** 1172 * Additional links from target resource. 1173 */ 1174 @Child(name = "link", type = { 1175 GraphDefinitionLinkComponent.class }, order = 5, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false) 1176 @Description(shortDefinition = "Additional links from target resource", formalDefinition = "Additional links from target resource.") 1177 protected List<GraphDefinitionLinkComponent> link; 1178 1179 private static final long serialVersionUID = -35248998L; 1180 1181 /** 1182 * Constructor 1183 */ 1184 public GraphDefinitionLinkTargetComponent() { 1185 super(); 1186 } 1187 1188 /** 1189 * Constructor 1190 */ 1191 public GraphDefinitionLinkTargetComponent(CodeType type) { 1192 super(); 1193 this.type = type; 1194 } 1195 1196 /** 1197 * @return {@link #type} (Type of resource this link refers to.). This is the 1198 * underlying object with id, value and extensions. The accessor 1199 * "getType" gives direct access to the value 1200 */ 1201 public CodeType getTypeElement() { 1202 if (this.type == null) 1203 if (Configuration.errorOnAutoCreate()) 1204 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetComponent.type"); 1205 else if (Configuration.doAutoCreate()) 1206 this.type = new CodeType(); // bb 1207 return this.type; 1208 } 1209 1210 public boolean hasTypeElement() { 1211 return this.type != null && !this.type.isEmpty(); 1212 } 1213 1214 public boolean hasType() { 1215 return this.type != null && !this.type.isEmpty(); 1216 } 1217 1218 /** 1219 * @param value {@link #type} (Type of resource this link refers to.). This is 1220 * the underlying object with id, value and extensions. The 1221 * accessor "getType" gives direct access to the value 1222 */ 1223 public GraphDefinitionLinkTargetComponent setTypeElement(CodeType value) { 1224 this.type = value; 1225 return this; 1226 } 1227 1228 /** 1229 * @return Type of resource this link refers to. 1230 */ 1231 public String getType() { 1232 return this.type == null ? null : this.type.getValue(); 1233 } 1234 1235 /** 1236 * @param value Type of resource this link refers to. 1237 */ 1238 public GraphDefinitionLinkTargetComponent setType(String value) { 1239 if (this.type == null) 1240 this.type = new CodeType(); 1241 this.type.setValue(value); 1242 return this; 1243 } 1244 1245 /** 1246 * @return {@link #params} (A set of parameters to look up.). This is the 1247 * underlying object with id, value and extensions. The accessor 1248 * "getParams" gives direct access to the value 1249 */ 1250 public StringType getParamsElement() { 1251 if (this.params == null) 1252 if (Configuration.errorOnAutoCreate()) 1253 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetComponent.params"); 1254 else if (Configuration.doAutoCreate()) 1255 this.params = new StringType(); // bb 1256 return this.params; 1257 } 1258 1259 public boolean hasParamsElement() { 1260 return this.params != null && !this.params.isEmpty(); 1261 } 1262 1263 public boolean hasParams() { 1264 return this.params != null && !this.params.isEmpty(); 1265 } 1266 1267 /** 1268 * @param value {@link #params} (A set of parameters to look up.). This is the 1269 * underlying object with id, value and extensions. The accessor 1270 * "getParams" gives direct access to the value 1271 */ 1272 public GraphDefinitionLinkTargetComponent setParamsElement(StringType value) { 1273 this.params = value; 1274 return this; 1275 } 1276 1277 /** 1278 * @return A set of parameters to look up. 1279 */ 1280 public String getParams() { 1281 return this.params == null ? null : this.params.getValue(); 1282 } 1283 1284 /** 1285 * @param value A set of parameters to look up. 1286 */ 1287 public GraphDefinitionLinkTargetComponent setParams(String value) { 1288 if (Utilities.noString(value)) 1289 this.params = null; 1290 else { 1291 if (this.params == null) 1292 this.params = new StringType(); 1293 this.params.setValue(value); 1294 } 1295 return this; 1296 } 1297 1298 /** 1299 * @return {@link #profile} (Profile for the target resource.). This is the 1300 * underlying object with id, value and extensions. The accessor 1301 * "getProfile" gives direct access to the value 1302 */ 1303 public CanonicalType getProfileElement() { 1304 if (this.profile == null) 1305 if (Configuration.errorOnAutoCreate()) 1306 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetComponent.profile"); 1307 else if (Configuration.doAutoCreate()) 1308 this.profile = new CanonicalType(); // bb 1309 return this.profile; 1310 } 1311 1312 public boolean hasProfileElement() { 1313 return this.profile != null && !this.profile.isEmpty(); 1314 } 1315 1316 public boolean hasProfile() { 1317 return this.profile != null && !this.profile.isEmpty(); 1318 } 1319 1320 /** 1321 * @param value {@link #profile} (Profile for the target resource.). This is the 1322 * underlying object with id, value and extensions. The accessor 1323 * "getProfile" gives direct access to the value 1324 */ 1325 public GraphDefinitionLinkTargetComponent setProfileElement(CanonicalType value) { 1326 this.profile = value; 1327 return this; 1328 } 1329 1330 /** 1331 * @return Profile for the target resource. 1332 */ 1333 public String getProfile() { 1334 return this.profile == null ? null : this.profile.getValue(); 1335 } 1336 1337 /** 1338 * @param value Profile for the target resource. 1339 */ 1340 public GraphDefinitionLinkTargetComponent setProfile(String value) { 1341 if (Utilities.noString(value)) 1342 this.profile = null; 1343 else { 1344 if (this.profile == null) 1345 this.profile = new CanonicalType(); 1346 this.profile.setValue(value); 1347 } 1348 return this; 1349 } 1350 1351 /** 1352 * @return {@link #compartment} (Compartment Consistency Rules.) 1353 */ 1354 public List<GraphDefinitionLinkTargetCompartmentComponent> getCompartment() { 1355 if (this.compartment == null) 1356 this.compartment = new ArrayList<GraphDefinitionLinkTargetCompartmentComponent>(); 1357 return this.compartment; 1358 } 1359 1360 /** 1361 * @return Returns a reference to <code>this</code> for easy method chaining 1362 */ 1363 public GraphDefinitionLinkTargetComponent setCompartment( 1364 List<GraphDefinitionLinkTargetCompartmentComponent> theCompartment) { 1365 this.compartment = theCompartment; 1366 return this; 1367 } 1368 1369 public boolean hasCompartment() { 1370 if (this.compartment == null) 1371 return false; 1372 for (GraphDefinitionLinkTargetCompartmentComponent item : this.compartment) 1373 if (!item.isEmpty()) 1374 return true; 1375 return false; 1376 } 1377 1378 public GraphDefinitionLinkTargetCompartmentComponent addCompartment() { // 3 1379 GraphDefinitionLinkTargetCompartmentComponent t = new GraphDefinitionLinkTargetCompartmentComponent(); 1380 if (this.compartment == null) 1381 this.compartment = new ArrayList<GraphDefinitionLinkTargetCompartmentComponent>(); 1382 this.compartment.add(t); 1383 return t; 1384 } 1385 1386 public GraphDefinitionLinkTargetComponent addCompartment(GraphDefinitionLinkTargetCompartmentComponent t) { // 3 1387 if (t == null) 1388 return this; 1389 if (this.compartment == null) 1390 this.compartment = new ArrayList<GraphDefinitionLinkTargetCompartmentComponent>(); 1391 this.compartment.add(t); 1392 return this; 1393 } 1394 1395 /** 1396 * @return The first repetition of repeating field {@link #compartment}, 1397 * creating it if it does not already exist 1398 */ 1399 public GraphDefinitionLinkTargetCompartmentComponent getCompartmentFirstRep() { 1400 if (getCompartment().isEmpty()) { 1401 addCompartment(); 1402 } 1403 return getCompartment().get(0); 1404 } 1405 1406 /** 1407 * @return {@link #link} (Additional links from target resource.) 1408 */ 1409 public List<GraphDefinitionLinkComponent> getLink() { 1410 if (this.link == null) 1411 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 1412 return this.link; 1413 } 1414 1415 /** 1416 * @return Returns a reference to <code>this</code> for easy method chaining 1417 */ 1418 public GraphDefinitionLinkTargetComponent setLink(List<GraphDefinitionLinkComponent> theLink) { 1419 this.link = theLink; 1420 return this; 1421 } 1422 1423 public boolean hasLink() { 1424 if (this.link == null) 1425 return false; 1426 for (GraphDefinitionLinkComponent item : this.link) 1427 if (!item.isEmpty()) 1428 return true; 1429 return false; 1430 } 1431 1432 public GraphDefinitionLinkComponent addLink() { // 3 1433 GraphDefinitionLinkComponent t = new GraphDefinitionLinkComponent(); 1434 if (this.link == null) 1435 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 1436 this.link.add(t); 1437 return t; 1438 } 1439 1440 public GraphDefinitionLinkTargetComponent addLink(GraphDefinitionLinkComponent t) { // 3 1441 if (t == null) 1442 return this; 1443 if (this.link == null) 1444 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 1445 this.link.add(t); 1446 return this; 1447 } 1448 1449 /** 1450 * @return The first repetition of repeating field {@link #link}, creating it if 1451 * it does not already exist 1452 */ 1453 public GraphDefinitionLinkComponent getLinkFirstRep() { 1454 if (getLink().isEmpty()) { 1455 addLink(); 1456 } 1457 return getLink().get(0); 1458 } 1459 1460 protected void listChildren(List<Property> children) { 1461 super.listChildren(children); 1462 children.add(new Property("type", "code", "Type of resource this link refers to.", 0, 1, type)); 1463 children.add(new Property("params", "string", "A set of parameters to look up.", 0, 1, params)); 1464 children.add( 1465 new Property("profile", "canonical(StructureDefinition)", "Profile for the target resource.", 0, 1, profile)); 1466 children.add(new Property("compartment", "", "Compartment Consistency Rules.", 0, java.lang.Integer.MAX_VALUE, 1467 compartment)); 1468 children.add(new Property("link", "@GraphDefinition.link", "Additional links from target resource.", 0, 1469 java.lang.Integer.MAX_VALUE, link)); 1470 } 1471 1472 @Override 1473 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1474 switch (_hash) { 1475 case 3575610: 1476 /* type */ return new Property("type", "code", "Type of resource this link refers to.", 0, 1, type); 1477 case -995427962: 1478 /* params */ return new Property("params", "string", "A set of parameters to look up.", 0, 1, params); 1479 case -309425751: 1480 /* profile */ return new Property("profile", "canonical(StructureDefinition)", 1481 "Profile for the target resource.", 0, 1, profile); 1482 case -397756334: 1483 /* compartment */ return new Property("compartment", "", "Compartment Consistency Rules.", 0, 1484 java.lang.Integer.MAX_VALUE, compartment); 1485 case 3321850: 1486 /* link */ return new Property("link", "@GraphDefinition.link", "Additional links from target resource.", 0, 1487 java.lang.Integer.MAX_VALUE, link); 1488 default: 1489 return super.getNamedProperty(_hash, _name, _checkValid); 1490 } 1491 1492 } 1493 1494 @Override 1495 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1496 switch (hash) { 1497 case 3575610: 1498 /* type */ return this.type == null ? new Base[0] : new Base[] { this.type }; // CodeType 1499 case -995427962: 1500 /* params */ return this.params == null ? new Base[0] : new Base[] { this.params }; // StringType 1501 case -309425751: 1502 /* profile */ return this.profile == null ? new Base[0] : new Base[] { this.profile }; // CanonicalType 1503 case -397756334: 1504 /* compartment */ return this.compartment == null ? new Base[0] 1505 : this.compartment.toArray(new Base[this.compartment.size()]); // GraphDefinitionLinkTargetCompartmentComponent 1506 case 3321850: 1507 /* link */ return this.link == null ? new Base[0] : this.link.toArray(new Base[this.link.size()]); // GraphDefinitionLinkComponent 1508 default: 1509 return super.getProperty(hash, name, checkValid); 1510 } 1511 1512 } 1513 1514 @Override 1515 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1516 switch (hash) { 1517 case 3575610: // type 1518 this.type = castToCode(value); // CodeType 1519 return value; 1520 case -995427962: // params 1521 this.params = castToString(value); // StringType 1522 return value; 1523 case -309425751: // profile 1524 this.profile = castToCanonical(value); // CanonicalType 1525 return value; 1526 case -397756334: // compartment 1527 this.getCompartment().add((GraphDefinitionLinkTargetCompartmentComponent) value); // GraphDefinitionLinkTargetCompartmentComponent 1528 return value; 1529 case 3321850: // link 1530 this.getLink().add((GraphDefinitionLinkComponent) value); // GraphDefinitionLinkComponent 1531 return value; 1532 default: 1533 return super.setProperty(hash, name, value); 1534 } 1535 1536 } 1537 1538 @Override 1539 public Base setProperty(String name, Base value) throws FHIRException { 1540 if (name.equals("type")) { 1541 this.type = castToCode(value); // CodeType 1542 } else if (name.equals("params")) { 1543 this.params = castToString(value); // StringType 1544 } else if (name.equals("profile")) { 1545 this.profile = castToCanonical(value); // CanonicalType 1546 } else if (name.equals("compartment")) { 1547 this.getCompartment().add((GraphDefinitionLinkTargetCompartmentComponent) value); 1548 } else if (name.equals("link")) { 1549 this.getLink().add((GraphDefinitionLinkComponent) value); 1550 } else 1551 return super.setProperty(name, value); 1552 return value; 1553 } 1554 1555 @Override 1556 public void removeChild(String name, Base value) throws FHIRException { 1557 if (name.equals("type")) { 1558 this.type = null; 1559 } else if (name.equals("params")) { 1560 this.params = null; 1561 } else if (name.equals("profile")) { 1562 this.profile = null; 1563 } else if (name.equals("compartment")) { 1564 this.getCompartment().remove((GraphDefinitionLinkTargetCompartmentComponent) value); 1565 } else if (name.equals("link")) { 1566 this.getLink().remove((GraphDefinitionLinkComponent) value); 1567 } else 1568 super.removeChild(name, value); 1569 1570 } 1571 1572 @Override 1573 public Base makeProperty(int hash, String name) throws FHIRException { 1574 switch (hash) { 1575 case 3575610: 1576 return getTypeElement(); 1577 case -995427962: 1578 return getParamsElement(); 1579 case -309425751: 1580 return getProfileElement(); 1581 case -397756334: 1582 return addCompartment(); 1583 case 3321850: 1584 return addLink(); 1585 default: 1586 return super.makeProperty(hash, name); 1587 } 1588 1589 } 1590 1591 @Override 1592 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1593 switch (hash) { 1594 case 3575610: 1595 /* type */ return new String[] { "code" }; 1596 case -995427962: 1597 /* params */ return new String[] { "string" }; 1598 case -309425751: 1599 /* profile */ return new String[] { "canonical" }; 1600 case -397756334: 1601 /* compartment */ return new String[] {}; 1602 case 3321850: 1603 /* link */ return new String[] { "@GraphDefinition.link" }; 1604 default: 1605 return super.getTypesForProperty(hash, name); 1606 } 1607 1608 } 1609 1610 @Override 1611 public Base addChild(String name) throws FHIRException { 1612 if (name.equals("type")) { 1613 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.type"); 1614 } else if (name.equals("params")) { 1615 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.params"); 1616 } else if (name.equals("profile")) { 1617 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.profile"); 1618 } else if (name.equals("compartment")) { 1619 return addCompartment(); 1620 } else if (name.equals("link")) { 1621 return addLink(); 1622 } else 1623 return super.addChild(name); 1624 } 1625 1626 public GraphDefinitionLinkTargetComponent copy() { 1627 GraphDefinitionLinkTargetComponent dst = new GraphDefinitionLinkTargetComponent(); 1628 copyValues(dst); 1629 return dst; 1630 } 1631 1632 public void copyValues(GraphDefinitionLinkTargetComponent dst) { 1633 super.copyValues(dst); 1634 dst.type = type == null ? null : type.copy(); 1635 dst.params = params == null ? null : params.copy(); 1636 dst.profile = profile == null ? null : profile.copy(); 1637 if (compartment != null) { 1638 dst.compartment = new ArrayList<GraphDefinitionLinkTargetCompartmentComponent>(); 1639 for (GraphDefinitionLinkTargetCompartmentComponent i : compartment) 1640 dst.compartment.add(i.copy()); 1641 } 1642 ; 1643 if (link != null) { 1644 dst.link = new ArrayList<GraphDefinitionLinkComponent>(); 1645 for (GraphDefinitionLinkComponent i : link) 1646 dst.link.add(i.copy()); 1647 } 1648 ; 1649 } 1650 1651 @Override 1652 public boolean equalsDeep(Base other_) { 1653 if (!super.equalsDeep(other_)) 1654 return false; 1655 if (!(other_ instanceof GraphDefinitionLinkTargetComponent)) 1656 return false; 1657 GraphDefinitionLinkTargetComponent o = (GraphDefinitionLinkTargetComponent) other_; 1658 return compareDeep(type, o.type, true) && compareDeep(params, o.params, true) 1659 && compareDeep(profile, o.profile, true) && compareDeep(compartment, o.compartment, true) 1660 && compareDeep(link, o.link, true); 1661 } 1662 1663 @Override 1664 public boolean equalsShallow(Base other_) { 1665 if (!super.equalsShallow(other_)) 1666 return false; 1667 if (!(other_ instanceof GraphDefinitionLinkTargetComponent)) 1668 return false; 1669 GraphDefinitionLinkTargetComponent o = (GraphDefinitionLinkTargetComponent) other_; 1670 return compareValues(type, o.type, true) && compareValues(params, o.params, true); 1671 } 1672 1673 public boolean isEmpty() { 1674 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, params, profile, compartment, link); 1675 } 1676 1677 public String fhirType() { 1678 return "GraphDefinition.link.target"; 1679 1680 } 1681 1682 } 1683 1684 @Block() 1685 public static class GraphDefinitionLinkTargetCompartmentComponent extends BackboneElement 1686 implements IBaseBackboneElement { 1687 /** 1688 * Defines how the compartment rule is used - whether it it is used to test 1689 * whether resources are subject to the rule, or whether it is a rule that must 1690 * be followed. 1691 */ 1692 @Child(name = "use", type = { CodeType.class }, order = 1, min = 1, max = 1, modifier = false, summary = false) 1693 @Description(shortDefinition = "condition | requirement", formalDefinition = "Defines how the compartment rule is used - whether it it is used to test whether resources are subject to the rule, or whether it is a rule that must be followed.") 1694 @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/graph-compartment-use") 1695 protected Enumeration<GraphCompartmentUse> use; 1696 1697 /** 1698 * Identifies the compartment. 1699 */ 1700 @Child(name = "code", type = { CodeType.class }, order = 2, min = 1, max = 1, modifier = false, summary = false) 1701 @Description(shortDefinition = "Patient | Encounter | RelatedPerson | Practitioner | Device", formalDefinition = "Identifies the compartment.") 1702 @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/compartment-type") 1703 protected Enumeration<CompartmentCode> code; 1704 1705 /** 1706 * identical | matching | different | no-rule | custom. 1707 */ 1708 @Child(name = "rule", type = { CodeType.class }, order = 3, min = 1, max = 1, modifier = false, summary = false) 1709 @Description(shortDefinition = "identical | matching | different | custom", formalDefinition = "identical | matching | different | no-rule | custom.") 1710 @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/graph-compartment-rule") 1711 protected Enumeration<GraphCompartmentRule> rule; 1712 1713 /** 1714 * Custom rule, as a FHIRPath expression. 1715 */ 1716 @Child(name = "expression", type = { 1717 StringType.class }, order = 4, min = 0, max = 1, modifier = false, summary = false) 1718 @Description(shortDefinition = "Custom rule, as a FHIRPath expression", formalDefinition = "Custom rule, as a FHIRPath expression.") 1719 protected StringType expression; 1720 1721 /** 1722 * Documentation for FHIRPath expression. 1723 */ 1724 @Child(name = "description", type = { 1725 StringType.class }, order = 5, min = 0, max = 1, modifier = false, summary = false) 1726 @Description(shortDefinition = "Documentation for FHIRPath expression", formalDefinition = "Documentation for FHIRPath expression.") 1727 protected StringType description; 1728 1729 private static final long serialVersionUID = 1023364175L; 1730 1731 /** 1732 * Constructor 1733 */ 1734 public GraphDefinitionLinkTargetCompartmentComponent() { 1735 super(); 1736 } 1737 1738 /** 1739 * Constructor 1740 */ 1741 public GraphDefinitionLinkTargetCompartmentComponent(Enumeration<GraphCompartmentUse> use, 1742 Enumeration<CompartmentCode> code, Enumeration<GraphCompartmentRule> rule) { 1743 super(); 1744 this.use = use; 1745 this.code = code; 1746 this.rule = rule; 1747 } 1748 1749 /** 1750 * @return {@link #use} (Defines how the compartment rule is used - whether it 1751 * it is used to test whether resources are subject to the rule, or 1752 * whether it is a rule that must be followed.). This is the underlying 1753 * object with id, value and extensions. The accessor "getUse" gives 1754 * direct access to the value 1755 */ 1756 public Enumeration<GraphCompartmentUse> getUseElement() { 1757 if (this.use == null) 1758 if (Configuration.errorOnAutoCreate()) 1759 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetCompartmentComponent.use"); 1760 else if (Configuration.doAutoCreate()) 1761 this.use = new Enumeration<GraphCompartmentUse>(new GraphCompartmentUseEnumFactory()); // bb 1762 return this.use; 1763 } 1764 1765 public boolean hasUseElement() { 1766 return this.use != null && !this.use.isEmpty(); 1767 } 1768 1769 public boolean hasUse() { 1770 return this.use != null && !this.use.isEmpty(); 1771 } 1772 1773 /** 1774 * @param value {@link #use} (Defines how the compartment rule is used - whether 1775 * it it is used to test whether resources are subject to the rule, 1776 * or whether it is a rule that must be followed.). This is the 1777 * underlying object with id, value and extensions. The accessor 1778 * "getUse" gives direct access to the value 1779 */ 1780 public GraphDefinitionLinkTargetCompartmentComponent setUseElement(Enumeration<GraphCompartmentUse> value) { 1781 this.use = value; 1782 return this; 1783 } 1784 1785 /** 1786 * @return Defines how the compartment rule is used - whether it it is used to 1787 * test whether resources are subject to the rule, or whether it is a 1788 * rule that must be followed. 1789 */ 1790 public GraphCompartmentUse getUse() { 1791 return this.use == null ? null : this.use.getValue(); 1792 } 1793 1794 /** 1795 * @param value Defines how the compartment rule is used - whether it it is used 1796 * to test whether resources are subject to the rule, or whether it 1797 * is a rule that must be followed. 1798 */ 1799 public GraphDefinitionLinkTargetCompartmentComponent setUse(GraphCompartmentUse value) { 1800 if (this.use == null) 1801 this.use = new Enumeration<GraphCompartmentUse>(new GraphCompartmentUseEnumFactory()); 1802 this.use.setValue(value); 1803 return this; 1804 } 1805 1806 /** 1807 * @return {@link #code} (Identifies the compartment.). This is the underlying 1808 * object with id, value and extensions. The accessor "getCode" gives 1809 * direct access to the value 1810 */ 1811 public Enumeration<CompartmentCode> getCodeElement() { 1812 if (this.code == null) 1813 if (Configuration.errorOnAutoCreate()) 1814 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetCompartmentComponent.code"); 1815 else if (Configuration.doAutoCreate()) 1816 this.code = new Enumeration<CompartmentCode>(new CompartmentCodeEnumFactory()); // bb 1817 return this.code; 1818 } 1819 1820 public boolean hasCodeElement() { 1821 return this.code != null && !this.code.isEmpty(); 1822 } 1823 1824 public boolean hasCode() { 1825 return this.code != null && !this.code.isEmpty(); 1826 } 1827 1828 /** 1829 * @param value {@link #code} (Identifies the compartment.). This is the 1830 * underlying object with id, value and extensions. The accessor 1831 * "getCode" gives direct access to the value 1832 */ 1833 public GraphDefinitionLinkTargetCompartmentComponent setCodeElement(Enumeration<CompartmentCode> value) { 1834 this.code = value; 1835 return this; 1836 } 1837 1838 /** 1839 * @return Identifies the compartment. 1840 */ 1841 public CompartmentCode getCode() { 1842 return this.code == null ? null : this.code.getValue(); 1843 } 1844 1845 /** 1846 * @param value Identifies the compartment. 1847 */ 1848 public GraphDefinitionLinkTargetCompartmentComponent setCode(CompartmentCode value) { 1849 if (this.code == null) 1850 this.code = new Enumeration<CompartmentCode>(new CompartmentCodeEnumFactory()); 1851 this.code.setValue(value); 1852 return this; 1853 } 1854 1855 /** 1856 * @return {@link #rule} (identical | matching | different | no-rule | custom.). 1857 * This is the underlying object with id, value and extensions. The 1858 * accessor "getRule" gives direct access to the value 1859 */ 1860 public Enumeration<GraphCompartmentRule> getRuleElement() { 1861 if (this.rule == null) 1862 if (Configuration.errorOnAutoCreate()) 1863 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetCompartmentComponent.rule"); 1864 else if (Configuration.doAutoCreate()) 1865 this.rule = new Enumeration<GraphCompartmentRule>(new GraphCompartmentRuleEnumFactory()); // bb 1866 return this.rule; 1867 } 1868 1869 public boolean hasRuleElement() { 1870 return this.rule != null && !this.rule.isEmpty(); 1871 } 1872 1873 public boolean hasRule() { 1874 return this.rule != null && !this.rule.isEmpty(); 1875 } 1876 1877 /** 1878 * @param value {@link #rule} (identical | matching | different | no-rule | 1879 * custom.). This is the underlying object with id, value and 1880 * extensions. The accessor "getRule" gives direct access to the 1881 * value 1882 */ 1883 public GraphDefinitionLinkTargetCompartmentComponent setRuleElement(Enumeration<GraphCompartmentRule> value) { 1884 this.rule = value; 1885 return this; 1886 } 1887 1888 /** 1889 * @return identical | matching | different | no-rule | custom. 1890 */ 1891 public GraphCompartmentRule getRule() { 1892 return this.rule == null ? null : this.rule.getValue(); 1893 } 1894 1895 /** 1896 * @param value identical | matching | different | no-rule | custom. 1897 */ 1898 public GraphDefinitionLinkTargetCompartmentComponent setRule(GraphCompartmentRule value) { 1899 if (this.rule == null) 1900 this.rule = new Enumeration<GraphCompartmentRule>(new GraphCompartmentRuleEnumFactory()); 1901 this.rule.setValue(value); 1902 return this; 1903 } 1904 1905 /** 1906 * @return {@link #expression} (Custom rule, as a FHIRPath expression.). This is 1907 * the underlying object with id, value and extensions. The accessor 1908 * "getExpression" gives direct access to the value 1909 */ 1910 public StringType getExpressionElement() { 1911 if (this.expression == null) 1912 if (Configuration.errorOnAutoCreate()) 1913 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetCompartmentComponent.expression"); 1914 else if (Configuration.doAutoCreate()) 1915 this.expression = new StringType(); // bb 1916 return this.expression; 1917 } 1918 1919 public boolean hasExpressionElement() { 1920 return this.expression != null && !this.expression.isEmpty(); 1921 } 1922 1923 public boolean hasExpression() { 1924 return this.expression != null && !this.expression.isEmpty(); 1925 } 1926 1927 /** 1928 * @param value {@link #expression} (Custom rule, as a FHIRPath expression.). 1929 * This is the underlying object with id, value and extensions. The 1930 * accessor "getExpression" gives direct access to the value 1931 */ 1932 public GraphDefinitionLinkTargetCompartmentComponent setExpressionElement(StringType value) { 1933 this.expression = value; 1934 return this; 1935 } 1936 1937 /** 1938 * @return Custom rule, as a FHIRPath expression. 1939 */ 1940 public String getExpression() { 1941 return this.expression == null ? null : this.expression.getValue(); 1942 } 1943 1944 /** 1945 * @param value Custom rule, as a FHIRPath expression. 1946 */ 1947 public GraphDefinitionLinkTargetCompartmentComponent setExpression(String value) { 1948 if (Utilities.noString(value)) 1949 this.expression = null; 1950 else { 1951 if (this.expression == null) 1952 this.expression = new StringType(); 1953 this.expression.setValue(value); 1954 } 1955 return this; 1956 } 1957 1958 /** 1959 * @return {@link #description} (Documentation for FHIRPath expression.). This 1960 * is the underlying object with id, value and extensions. The accessor 1961 * "getDescription" gives direct access to the value 1962 */ 1963 public StringType getDescriptionElement() { 1964 if (this.description == null) 1965 if (Configuration.errorOnAutoCreate()) 1966 throw new Error("Attempt to auto-create GraphDefinitionLinkTargetCompartmentComponent.description"); 1967 else if (Configuration.doAutoCreate()) 1968 this.description = new StringType(); // bb 1969 return this.description; 1970 } 1971 1972 public boolean hasDescriptionElement() { 1973 return this.description != null && !this.description.isEmpty(); 1974 } 1975 1976 public boolean hasDescription() { 1977 return this.description != null && !this.description.isEmpty(); 1978 } 1979 1980 /** 1981 * @param value {@link #description} (Documentation for FHIRPath expression.). 1982 * This is the underlying object with id, value and extensions. The 1983 * accessor "getDescription" gives direct access to the value 1984 */ 1985 public GraphDefinitionLinkTargetCompartmentComponent setDescriptionElement(StringType value) { 1986 this.description = value; 1987 return this; 1988 } 1989 1990 /** 1991 * @return Documentation for FHIRPath expression. 1992 */ 1993 public String getDescription() { 1994 return this.description == null ? null : this.description.getValue(); 1995 } 1996 1997 /** 1998 * @param value Documentation for FHIRPath expression. 1999 */ 2000 public GraphDefinitionLinkTargetCompartmentComponent setDescription(String value) { 2001 if (Utilities.noString(value)) 2002 this.description = null; 2003 else { 2004 if (this.description == null) 2005 this.description = new StringType(); 2006 this.description.setValue(value); 2007 } 2008 return this; 2009 } 2010 2011 protected void listChildren(List<Property> children) { 2012 super.listChildren(children); 2013 children.add(new Property("use", "code", 2014 "Defines how the compartment rule is used - whether it it is used to test whether resources are subject to the rule, or whether it is a rule that must be followed.", 2015 0, 1, use)); 2016 children.add(new Property("code", "code", "Identifies the compartment.", 0, 1, code)); 2017 children.add(new Property("rule", "code", "identical | matching | different | no-rule | custom.", 0, 1, rule)); 2018 children.add(new Property("expression", "string", "Custom rule, as a FHIRPath expression.", 0, 1, expression)); 2019 children.add(new Property("description", "string", "Documentation for FHIRPath expression.", 0, 1, description)); 2020 } 2021 2022 @Override 2023 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2024 switch (_hash) { 2025 case 116103: 2026 /* use */ return new Property("use", "code", 2027 "Defines how the compartment rule is used - whether it it is used to test whether resources are subject to the rule, or whether it is a rule that must be followed.", 2028 0, 1, use); 2029 case 3059181: 2030 /* code */ return new Property("code", "code", "Identifies the compartment.", 0, 1, code); 2031 case 3512060: 2032 /* rule */ return new Property("rule", "code", "identical | matching | different | no-rule | custom.", 0, 1, 2033 rule); 2034 case -1795452264: 2035 /* expression */ return new Property("expression", "string", "Custom rule, as a FHIRPath expression.", 0, 1, 2036 expression); 2037 case -1724546052: 2038 /* description */ return new Property("description", "string", "Documentation for FHIRPath expression.", 0, 1, 2039 description); 2040 default: 2041 return super.getNamedProperty(_hash, _name, _checkValid); 2042 } 2043 2044 } 2045 2046 @Override 2047 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2048 switch (hash) { 2049 case 116103: 2050 /* use */ return this.use == null ? new Base[0] : new Base[] { this.use }; // Enumeration<GraphCompartmentUse> 2051 case 3059181: 2052 /* code */ return this.code == null ? new Base[0] : new Base[] { this.code }; // Enumeration<CompartmentCode> 2053 case 3512060: 2054 /* rule */ return this.rule == null ? new Base[0] : new Base[] { this.rule }; // Enumeration<GraphCompartmentRule> 2055 case -1795452264: 2056 /* expression */ return this.expression == null ? new Base[0] : new Base[] { this.expression }; // StringType 2057 case -1724546052: 2058 /* description */ return this.description == null ? new Base[0] : new Base[] { this.description }; // StringType 2059 default: 2060 return super.getProperty(hash, name, checkValid); 2061 } 2062 2063 } 2064 2065 @Override 2066 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2067 switch (hash) { 2068 case 116103: // use 2069 value = new GraphCompartmentUseEnumFactory().fromType(castToCode(value)); 2070 this.use = (Enumeration) value; // Enumeration<GraphCompartmentUse> 2071 return value; 2072 case 3059181: // code 2073 value = new CompartmentCodeEnumFactory().fromType(castToCode(value)); 2074 this.code = (Enumeration) value; // Enumeration<CompartmentCode> 2075 return value; 2076 case 3512060: // rule 2077 value = new GraphCompartmentRuleEnumFactory().fromType(castToCode(value)); 2078 this.rule = (Enumeration) value; // Enumeration<GraphCompartmentRule> 2079 return value; 2080 case -1795452264: // expression 2081 this.expression = castToString(value); // StringType 2082 return value; 2083 case -1724546052: // description 2084 this.description = castToString(value); // StringType 2085 return value; 2086 default: 2087 return super.setProperty(hash, name, value); 2088 } 2089 2090 } 2091 2092 @Override 2093 public Base setProperty(String name, Base value) throws FHIRException { 2094 if (name.equals("use")) { 2095 value = new GraphCompartmentUseEnumFactory().fromType(castToCode(value)); 2096 this.use = (Enumeration) value; // Enumeration<GraphCompartmentUse> 2097 } else if (name.equals("code")) { 2098 value = new CompartmentCodeEnumFactory().fromType(castToCode(value)); 2099 this.code = (Enumeration) value; // Enumeration<CompartmentCode> 2100 } else if (name.equals("rule")) { 2101 value = new GraphCompartmentRuleEnumFactory().fromType(castToCode(value)); 2102 this.rule = (Enumeration) value; // Enumeration<GraphCompartmentRule> 2103 } else if (name.equals("expression")) { 2104 this.expression = castToString(value); // StringType 2105 } else if (name.equals("description")) { 2106 this.description = castToString(value); // StringType 2107 } else 2108 return super.setProperty(name, value); 2109 return value; 2110 } 2111 2112 @Override 2113 public void removeChild(String name, Base value) throws FHIRException { 2114 if (name.equals("use")) { 2115 this.use = null; 2116 } else if (name.equals("code")) { 2117 this.code = null; 2118 } else if (name.equals("rule")) { 2119 this.rule = null; 2120 } else if (name.equals("expression")) { 2121 this.expression = null; 2122 } else if (name.equals("description")) { 2123 this.description = null; 2124 } else 2125 super.removeChild(name, value); 2126 2127 } 2128 2129 @Override 2130 public Base makeProperty(int hash, String name) throws FHIRException { 2131 switch (hash) { 2132 case 116103: 2133 return getUseElement(); 2134 case 3059181: 2135 return getCodeElement(); 2136 case 3512060: 2137 return getRuleElement(); 2138 case -1795452264: 2139 return getExpressionElement(); 2140 case -1724546052: 2141 return getDescriptionElement(); 2142 default: 2143 return super.makeProperty(hash, name); 2144 } 2145 2146 } 2147 2148 @Override 2149 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2150 switch (hash) { 2151 case 116103: 2152 /* use */ return new String[] { "code" }; 2153 case 3059181: 2154 /* code */ return new String[] { "code" }; 2155 case 3512060: 2156 /* rule */ return new String[] { "code" }; 2157 case -1795452264: 2158 /* expression */ return new String[] { "string" }; 2159 case -1724546052: 2160 /* description */ return new String[] { "string" }; 2161 default: 2162 return super.getTypesForProperty(hash, name); 2163 } 2164 2165 } 2166 2167 @Override 2168 public Base addChild(String name) throws FHIRException { 2169 if (name.equals("use")) { 2170 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.use"); 2171 } else if (name.equals("code")) { 2172 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.code"); 2173 } else if (name.equals("rule")) { 2174 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.rule"); 2175 } else if (name.equals("expression")) { 2176 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.expression"); 2177 } else if (name.equals("description")) { 2178 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.description"); 2179 } else 2180 return super.addChild(name); 2181 } 2182 2183 public GraphDefinitionLinkTargetCompartmentComponent copy() { 2184 GraphDefinitionLinkTargetCompartmentComponent dst = new GraphDefinitionLinkTargetCompartmentComponent(); 2185 copyValues(dst); 2186 return dst; 2187 } 2188 2189 public void copyValues(GraphDefinitionLinkTargetCompartmentComponent dst) { 2190 super.copyValues(dst); 2191 dst.use = use == null ? null : use.copy(); 2192 dst.code = code == null ? null : code.copy(); 2193 dst.rule = rule == null ? null : rule.copy(); 2194 dst.expression = expression == null ? null : expression.copy(); 2195 dst.description = description == null ? null : description.copy(); 2196 } 2197 2198 @Override 2199 public boolean equalsDeep(Base other_) { 2200 if (!super.equalsDeep(other_)) 2201 return false; 2202 if (!(other_ instanceof GraphDefinitionLinkTargetCompartmentComponent)) 2203 return false; 2204 GraphDefinitionLinkTargetCompartmentComponent o = (GraphDefinitionLinkTargetCompartmentComponent) other_; 2205 return compareDeep(use, o.use, true) && compareDeep(code, o.code, true) && compareDeep(rule, o.rule, true) 2206 && compareDeep(expression, o.expression, true) && compareDeep(description, o.description, true); 2207 } 2208 2209 @Override 2210 public boolean equalsShallow(Base other_) { 2211 if (!super.equalsShallow(other_)) 2212 return false; 2213 if (!(other_ instanceof GraphDefinitionLinkTargetCompartmentComponent)) 2214 return false; 2215 GraphDefinitionLinkTargetCompartmentComponent o = (GraphDefinitionLinkTargetCompartmentComponent) other_; 2216 return compareValues(use, o.use, true) && compareValues(code, o.code, true) && compareValues(rule, o.rule, true) 2217 && compareValues(expression, o.expression, true) && compareValues(description, o.description, true); 2218 } 2219 2220 public boolean isEmpty() { 2221 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(use, code, rule, expression, description); 2222 } 2223 2224 public String fhirType() { 2225 return "GraphDefinition.link.target.compartment"; 2226 2227 } 2228 2229 } 2230 2231 /** 2232 * Explanation of why this graph definition is needed and why it has been 2233 * designed as it has. 2234 */ 2235 @Child(name = "purpose", type = { 2236 MarkdownType.class }, order = 0, min = 0, max = 1, modifier = false, summary = false) 2237 @Description(shortDefinition = "Why this graph definition is defined", formalDefinition = "Explanation of why this graph definition is needed and why it has been designed as it has.") 2238 protected MarkdownType purpose; 2239 2240 /** 2241 * The type of FHIR resource at which instances of this graph start. 2242 */ 2243 @Child(name = "start", type = { CodeType.class }, order = 1, min = 1, max = 1, modifier = false, summary = true) 2244 @Description(shortDefinition = "Type of resource at which the graph starts", formalDefinition = "The type of FHIR resource at which instances of this graph start.") 2245 @ca.uhn.fhir.model.api.annotation.Binding(valueSet = "http://hl7.org/fhir/ValueSet/resource-types") 2246 protected CodeType start; 2247 2248 /** 2249 * The profile that describes the use of the base resource. 2250 */ 2251 @Child(name = "profile", type = { 2252 CanonicalType.class }, order = 2, min = 0, max = 1, modifier = false, summary = false) 2253 @Description(shortDefinition = "Profile on base resource", formalDefinition = "The profile that describes the use of the base resource.") 2254 protected CanonicalType profile; 2255 2256 /** 2257 * Links this graph makes rules about. 2258 */ 2259 @Child(name = "link", type = {}, order = 3, min = 0, max = Child.MAX_UNLIMITED, modifier = false, summary = false) 2260 @Description(shortDefinition = "Links this graph makes rules about", formalDefinition = "Links this graph makes rules about.") 2261 protected List<GraphDefinitionLinkComponent> link; 2262 2263 private static final long serialVersionUID = 1529157887L; 2264 2265 /** 2266 * Constructor 2267 */ 2268 public GraphDefinition() { 2269 super(); 2270 } 2271 2272 /** 2273 * Constructor 2274 */ 2275 public GraphDefinition(StringType name, Enumeration<PublicationStatus> status, CodeType start) { 2276 super(); 2277 this.name = name; 2278 this.status = status; 2279 this.start = start; 2280 } 2281 2282 /** 2283 * @return {@link #url} (An absolute URI that is used to identify this graph 2284 * definition when it is referenced in a specification, model, design or 2285 * an instance; also called its canonical identifier. This SHOULD be 2286 * globally unique and SHOULD be a literal address at which at which an 2287 * authoritative instance of this graph definition is (or will be) 2288 * published. This URL can be the target of a canonical reference. It 2289 * SHALL remain the same when the graph definition is stored on 2290 * different servers.). This is the underlying object with id, value and 2291 * extensions. The accessor "getUrl" gives direct access to the value 2292 */ 2293 public UriType getUrlElement() { 2294 if (this.url == null) 2295 if (Configuration.errorOnAutoCreate()) 2296 throw new Error("Attempt to auto-create GraphDefinition.url"); 2297 else if (Configuration.doAutoCreate()) 2298 this.url = new UriType(); // bb 2299 return this.url; 2300 } 2301 2302 public boolean hasUrlElement() { 2303 return this.url != null && !this.url.isEmpty(); 2304 } 2305 2306 public boolean hasUrl() { 2307 return this.url != null && !this.url.isEmpty(); 2308 } 2309 2310 /** 2311 * @param value {@link #url} (An absolute URI that is used to identify this 2312 * graph definition when it is referenced in a specification, 2313 * model, design or an instance; also called its canonical 2314 * identifier. This SHOULD be globally unique and SHOULD be a 2315 * literal address at which at which an authoritative instance of 2316 * this graph definition is (or will be) published. This URL can be 2317 * the target of a canonical reference. It SHALL remain the same 2318 * when the graph definition is stored on different servers.). This 2319 * is the underlying object with id, value and extensions. The 2320 * accessor "getUrl" gives direct access to the value 2321 */ 2322 public GraphDefinition setUrlElement(UriType value) { 2323 this.url = value; 2324 return this; 2325 } 2326 2327 /** 2328 * @return An absolute URI that is used to identify this graph definition when 2329 * it is referenced in a specification, model, design or an instance; 2330 * also called its canonical identifier. This SHOULD be globally unique 2331 * and SHOULD be a literal address at which at which an authoritative 2332 * instance of this graph definition is (or will be) published. This URL 2333 * can be the target of a canonical reference. It SHALL remain the same 2334 * when the graph definition is stored on different servers. 2335 */ 2336 public String getUrl() { 2337 return this.url == null ? null : this.url.getValue(); 2338 } 2339 2340 /** 2341 * @param value An absolute URI that is used to identify this graph definition 2342 * when it is referenced in a specification, model, design or an 2343 * instance; also called its canonical identifier. This SHOULD be 2344 * globally unique and SHOULD be a literal address at which at 2345 * which an authoritative instance of this graph definition is (or 2346 * will be) published. This URL can be the target of a canonical 2347 * reference. It SHALL remain the same when the graph definition is 2348 * stored on different servers. 2349 */ 2350 public GraphDefinition setUrl(String value) { 2351 if (Utilities.noString(value)) 2352 this.url = null; 2353 else { 2354 if (this.url == null) 2355 this.url = new UriType(); 2356 this.url.setValue(value); 2357 } 2358 return this; 2359 } 2360 2361 /** 2362 * @return {@link #version} (The identifier that is used to identify this 2363 * version of the graph definition when it is referenced in a 2364 * specification, model, design or instance. This is an arbitrary value 2365 * managed by the graph definition author and is not expected to be 2366 * globally unique. For example, it might be a timestamp (e.g. yyyymmdd) 2367 * if a managed version is not available. There is also no expectation 2368 * that versions can be placed in a lexicographical sequence.). This is 2369 * the underlying object with id, value and extensions. The accessor 2370 * "getVersion" gives direct access to the value 2371 */ 2372 public StringType getVersionElement() { 2373 if (this.version == null) 2374 if (Configuration.errorOnAutoCreate()) 2375 throw new Error("Attempt to auto-create GraphDefinition.version"); 2376 else if (Configuration.doAutoCreate()) 2377 this.version = new StringType(); // bb 2378 return this.version; 2379 } 2380 2381 public boolean hasVersionElement() { 2382 return this.version != null && !this.version.isEmpty(); 2383 } 2384 2385 public boolean hasVersion() { 2386 return this.version != null && !this.version.isEmpty(); 2387 } 2388 2389 /** 2390 * @param value {@link #version} (The identifier that is used to identify this 2391 * version of the graph definition when it is referenced in a 2392 * specification, model, design or instance. This is an arbitrary 2393 * value managed by the graph definition author and is not expected 2394 * to be globally unique. For example, it might be a timestamp 2395 * (e.g. yyyymmdd) if a managed version is not available. There is 2396 * also no expectation that versions can be placed in a 2397 * lexicographical sequence.). This is the underlying object with 2398 * id, value and extensions. The accessor "getVersion" gives direct 2399 * access to the value 2400 */ 2401 public GraphDefinition setVersionElement(StringType value) { 2402 this.version = value; 2403 return this; 2404 } 2405 2406 /** 2407 * @return The identifier that is used to identify this version of the graph 2408 * definition when it is referenced in a specification, model, design or 2409 * instance. This is an arbitrary value managed by the graph definition 2410 * author and is not expected to be globally unique. For example, it 2411 * might be a timestamp (e.g. yyyymmdd) if a managed version is not 2412 * available. There is also no expectation that versions can be placed 2413 * in a lexicographical sequence. 2414 */ 2415 public String getVersion() { 2416 return this.version == null ? null : this.version.getValue(); 2417 } 2418 2419 /** 2420 * @param value The identifier that is used to identify this version of the 2421 * graph definition when it is referenced in a specification, 2422 * model, design or instance. This is an arbitrary value managed by 2423 * the graph definition author and is not expected to be globally 2424 * unique. For example, it might be a timestamp (e.g. yyyymmdd) if 2425 * a managed version is not available. There is also no expectation 2426 * that versions can be placed in a lexicographical sequence. 2427 */ 2428 public GraphDefinition setVersion(String value) { 2429 if (Utilities.noString(value)) 2430 this.version = null; 2431 else { 2432 if (this.version == null) 2433 this.version = new StringType(); 2434 this.version.setValue(value); 2435 } 2436 return this; 2437 } 2438 2439 /** 2440 * @return {@link #name} (A natural language name identifying the graph 2441 * definition. This name should be usable as an identifier for the 2442 * module by machine processing applications such as code generation.). 2443 * This is the underlying object with id, value and extensions. The 2444 * accessor "getName" gives direct access to the value 2445 */ 2446 public StringType getNameElement() { 2447 if (this.name == null) 2448 if (Configuration.errorOnAutoCreate()) 2449 throw new Error("Attempt to auto-create GraphDefinition.name"); 2450 else if (Configuration.doAutoCreate()) 2451 this.name = new StringType(); // bb 2452 return this.name; 2453 } 2454 2455 public boolean hasNameElement() { 2456 return this.name != null && !this.name.isEmpty(); 2457 } 2458 2459 public boolean hasName() { 2460 return this.name != null && !this.name.isEmpty(); 2461 } 2462 2463 /** 2464 * @param value {@link #name} (A natural language name identifying the graph 2465 * definition. This name should be usable as an identifier for the 2466 * module by machine processing applications such as code 2467 * generation.). This is the underlying object with id, value and 2468 * extensions. The accessor "getName" gives direct access to the 2469 * value 2470 */ 2471 public GraphDefinition setNameElement(StringType value) { 2472 this.name = value; 2473 return this; 2474 } 2475 2476 /** 2477 * @return A natural language name identifying the graph definition. This name 2478 * should be usable as an identifier for the module by machine 2479 * processing applications such as code generation. 2480 */ 2481 public String getName() { 2482 return this.name == null ? null : this.name.getValue(); 2483 } 2484 2485 /** 2486 * @param value A natural language name identifying the graph definition. This 2487 * name should be usable as an identifier for the module by machine 2488 * processing applications such as code generation. 2489 */ 2490 public GraphDefinition setName(String value) { 2491 if (this.name == null) 2492 this.name = new StringType(); 2493 this.name.setValue(value); 2494 return this; 2495 } 2496 2497 /** 2498 * @return {@link #status} (The status of this graph definition. Enables 2499 * tracking the life-cycle of the content.). This is the underlying 2500 * object with id, value and extensions. The accessor "getStatus" gives 2501 * direct access to the value 2502 */ 2503 public Enumeration<PublicationStatus> getStatusElement() { 2504 if (this.status == null) 2505 if (Configuration.errorOnAutoCreate()) 2506 throw new Error("Attempt to auto-create GraphDefinition.status"); 2507 else if (Configuration.doAutoCreate()) 2508 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); // bb 2509 return this.status; 2510 } 2511 2512 public boolean hasStatusElement() { 2513 return this.status != null && !this.status.isEmpty(); 2514 } 2515 2516 public boolean hasStatus() { 2517 return this.status != null && !this.status.isEmpty(); 2518 } 2519 2520 /** 2521 * @param value {@link #status} (The status of this graph definition. Enables 2522 * tracking the life-cycle of the content.). This is the underlying 2523 * object with id, value and extensions. The accessor "getStatus" 2524 * gives direct access to the value 2525 */ 2526 public GraphDefinition setStatusElement(Enumeration<PublicationStatus> value) { 2527 this.status = value; 2528 return this; 2529 } 2530 2531 /** 2532 * @return The status of this graph definition. Enables tracking the life-cycle 2533 * of the content. 2534 */ 2535 public PublicationStatus getStatus() { 2536 return this.status == null ? null : this.status.getValue(); 2537 } 2538 2539 /** 2540 * @param value The status of this graph definition. Enables tracking the 2541 * life-cycle of the content. 2542 */ 2543 public GraphDefinition setStatus(PublicationStatus value) { 2544 if (this.status == null) 2545 this.status = new Enumeration<PublicationStatus>(new PublicationStatusEnumFactory()); 2546 this.status.setValue(value); 2547 return this; 2548 } 2549 2550 /** 2551 * @return {@link #experimental} (A Boolean value to indicate that this graph 2552 * definition is authored for testing purposes (or 2553 * education/evaluation/marketing) and is not intended to be used for 2554 * genuine usage.). This is the underlying object with id, value and 2555 * extensions. The accessor "getExperimental" gives direct access to the 2556 * value 2557 */ 2558 public BooleanType getExperimentalElement() { 2559 if (this.experimental == null) 2560 if (Configuration.errorOnAutoCreate()) 2561 throw new Error("Attempt to auto-create GraphDefinition.experimental"); 2562 else if (Configuration.doAutoCreate()) 2563 this.experimental = new BooleanType(); // bb 2564 return this.experimental; 2565 } 2566 2567 public boolean hasExperimentalElement() { 2568 return this.experimental != null && !this.experimental.isEmpty(); 2569 } 2570 2571 public boolean hasExperimental() { 2572 return this.experimental != null && !this.experimental.isEmpty(); 2573 } 2574 2575 /** 2576 * @param value {@link #experimental} (A Boolean value to indicate that this 2577 * graph definition is authored for testing purposes (or 2578 * education/evaluation/marketing) and is not intended to be used 2579 * for genuine usage.). This is the underlying object with id, 2580 * value and extensions. The accessor "getExperimental" gives 2581 * direct access to the value 2582 */ 2583 public GraphDefinition setExperimentalElement(BooleanType value) { 2584 this.experimental = value; 2585 return this; 2586 } 2587 2588 /** 2589 * @return A Boolean value to indicate that this graph definition is authored 2590 * for testing purposes (or education/evaluation/marketing) and is not 2591 * intended to be used for genuine usage. 2592 */ 2593 public boolean getExperimental() { 2594 return this.experimental == null || this.experimental.isEmpty() ? false : this.experimental.getValue(); 2595 } 2596 2597 /** 2598 * @param value A Boolean value to indicate that this graph definition is 2599 * authored for testing purposes (or 2600 * education/evaluation/marketing) and is not intended to be used 2601 * for genuine usage. 2602 */ 2603 public GraphDefinition setExperimental(boolean value) { 2604 if (this.experimental == null) 2605 this.experimental = new BooleanType(); 2606 this.experimental.setValue(value); 2607 return this; 2608 } 2609 2610 /** 2611 * @return {@link #date} (The date (and optionally time) when the graph 2612 * definition was published. The date must change when the business 2613 * version changes and it must change if the status code changes. In 2614 * addition, it should change when the substantive content of the graph 2615 * definition changes.). This is the underlying object with id, value 2616 * and extensions. The accessor "getDate" gives direct access to the 2617 * value 2618 */ 2619 public DateTimeType getDateElement() { 2620 if (this.date == null) 2621 if (Configuration.errorOnAutoCreate()) 2622 throw new Error("Attempt to auto-create GraphDefinition.date"); 2623 else if (Configuration.doAutoCreate()) 2624 this.date = new DateTimeType(); // bb 2625 return this.date; 2626 } 2627 2628 public boolean hasDateElement() { 2629 return this.date != null && !this.date.isEmpty(); 2630 } 2631 2632 public boolean hasDate() { 2633 return this.date != null && !this.date.isEmpty(); 2634 } 2635 2636 /** 2637 * @param value {@link #date} (The date (and optionally time) when the graph 2638 * definition was published. The date must change when the business 2639 * version changes and it must change if the status code changes. 2640 * In addition, it should change when the substantive content of 2641 * the graph definition changes.). This is the underlying object 2642 * with id, value and extensions. The accessor "getDate" gives 2643 * direct access to the value 2644 */ 2645 public GraphDefinition setDateElement(DateTimeType value) { 2646 this.date = value; 2647 return this; 2648 } 2649 2650 /** 2651 * @return The date (and optionally time) when the graph definition was 2652 * published. The date must change when the business version changes and 2653 * it must change if the status code changes. In addition, it should 2654 * change when the substantive content of the graph definition changes. 2655 */ 2656 public Date getDate() { 2657 return this.date == null ? null : this.date.getValue(); 2658 } 2659 2660 /** 2661 * @param value The date (and optionally time) when the graph definition was 2662 * published. The date must change when the business version 2663 * changes and it must change if the status code changes. In 2664 * addition, it should change when the substantive content of the 2665 * graph definition changes. 2666 */ 2667 public GraphDefinition setDate(Date value) { 2668 if (value == null) 2669 this.date = null; 2670 else { 2671 if (this.date == null) 2672 this.date = new DateTimeType(); 2673 this.date.setValue(value); 2674 } 2675 return this; 2676 } 2677 2678 /** 2679 * @return {@link #publisher} (The name of the organization or individual that 2680 * published the graph definition.). This is the underlying object with 2681 * id, value and extensions. The accessor "getPublisher" gives direct 2682 * access to the value 2683 */ 2684 public StringType getPublisherElement() { 2685 if (this.publisher == null) 2686 if (Configuration.errorOnAutoCreate()) 2687 throw new Error("Attempt to auto-create GraphDefinition.publisher"); 2688 else if (Configuration.doAutoCreate()) 2689 this.publisher = new StringType(); // bb 2690 return this.publisher; 2691 } 2692 2693 public boolean hasPublisherElement() { 2694 return this.publisher != null && !this.publisher.isEmpty(); 2695 } 2696 2697 public boolean hasPublisher() { 2698 return this.publisher != null && !this.publisher.isEmpty(); 2699 } 2700 2701 /** 2702 * @param value {@link #publisher} (The name of the organization or individual 2703 * that published the graph definition.). This is the underlying 2704 * object with id, value and extensions. The accessor 2705 * "getPublisher" gives direct access to the value 2706 */ 2707 public GraphDefinition setPublisherElement(StringType value) { 2708 this.publisher = value; 2709 return this; 2710 } 2711 2712 /** 2713 * @return The name of the organization or individual that published the graph 2714 * definition. 2715 */ 2716 public String getPublisher() { 2717 return this.publisher == null ? null : this.publisher.getValue(); 2718 } 2719 2720 /** 2721 * @param value The name of the organization or individual that published the 2722 * graph definition. 2723 */ 2724 public GraphDefinition setPublisher(String value) { 2725 if (Utilities.noString(value)) 2726 this.publisher = null; 2727 else { 2728 if (this.publisher == null) 2729 this.publisher = new StringType(); 2730 this.publisher.setValue(value); 2731 } 2732 return this; 2733 } 2734 2735 /** 2736 * @return {@link #contact} (Contact details to assist a user in finding and 2737 * communicating with the publisher.) 2738 */ 2739 public List<ContactDetail> getContact() { 2740 if (this.contact == null) 2741 this.contact = new ArrayList<ContactDetail>(); 2742 return this.contact; 2743 } 2744 2745 /** 2746 * @return Returns a reference to <code>this</code> for easy method chaining 2747 */ 2748 public GraphDefinition setContact(List<ContactDetail> theContact) { 2749 this.contact = theContact; 2750 return this; 2751 } 2752 2753 public boolean hasContact() { 2754 if (this.contact == null) 2755 return false; 2756 for (ContactDetail item : this.contact) 2757 if (!item.isEmpty()) 2758 return true; 2759 return false; 2760 } 2761 2762 public ContactDetail addContact() { // 3 2763 ContactDetail t = new ContactDetail(); 2764 if (this.contact == null) 2765 this.contact = new ArrayList<ContactDetail>(); 2766 this.contact.add(t); 2767 return t; 2768 } 2769 2770 public GraphDefinition addContact(ContactDetail t) { // 3 2771 if (t == null) 2772 return this; 2773 if (this.contact == null) 2774 this.contact = new ArrayList<ContactDetail>(); 2775 this.contact.add(t); 2776 return this; 2777 } 2778 2779 /** 2780 * @return The first repetition of repeating field {@link #contact}, creating it 2781 * if it does not already exist 2782 */ 2783 public ContactDetail getContactFirstRep() { 2784 if (getContact().isEmpty()) { 2785 addContact(); 2786 } 2787 return getContact().get(0); 2788 } 2789 2790 /** 2791 * @return {@link #description} (A free text natural language description of the 2792 * graph definition from a consumer's perspective.). This is the 2793 * underlying object with id, value and extensions. The accessor 2794 * "getDescription" gives direct access to the value 2795 */ 2796 public MarkdownType getDescriptionElement() { 2797 if (this.description == null) 2798 if (Configuration.errorOnAutoCreate()) 2799 throw new Error("Attempt to auto-create GraphDefinition.description"); 2800 else if (Configuration.doAutoCreate()) 2801 this.description = new MarkdownType(); // bb 2802 return this.description; 2803 } 2804 2805 public boolean hasDescriptionElement() { 2806 return this.description != null && !this.description.isEmpty(); 2807 } 2808 2809 public boolean hasDescription() { 2810 return this.description != null && !this.description.isEmpty(); 2811 } 2812 2813 /** 2814 * @param value {@link #description} (A free text natural language description 2815 * of the graph definition from a consumer's perspective.). This is 2816 * the underlying object with id, value and extensions. The 2817 * accessor "getDescription" gives direct access to the value 2818 */ 2819 public GraphDefinition setDescriptionElement(MarkdownType value) { 2820 this.description = value; 2821 return this; 2822 } 2823 2824 /** 2825 * @return A free text natural language description of the graph definition from 2826 * a consumer's perspective. 2827 */ 2828 public String getDescription() { 2829 return this.description == null ? null : this.description.getValue(); 2830 } 2831 2832 /** 2833 * @param value A free text natural language description of the graph definition 2834 * from a consumer's perspective. 2835 */ 2836 public GraphDefinition setDescription(String value) { 2837 if (value == null) 2838 this.description = null; 2839 else { 2840 if (this.description == null) 2841 this.description = new MarkdownType(); 2842 this.description.setValue(value); 2843 } 2844 return this; 2845 } 2846 2847 /** 2848 * @return {@link #useContext} (The content was developed with a focus and 2849 * intent of supporting the contexts that are listed. These contexts may 2850 * be general categories (gender, age, ...) or may be references to 2851 * specific programs (insurance plans, studies, ...) and may be used to 2852 * assist with indexing and searching for appropriate graph definition 2853 * instances.) 2854 */ 2855 public List<UsageContext> getUseContext() { 2856 if (this.useContext == null) 2857 this.useContext = new ArrayList<UsageContext>(); 2858 return this.useContext; 2859 } 2860 2861 /** 2862 * @return Returns a reference to <code>this</code> for easy method chaining 2863 */ 2864 public GraphDefinition setUseContext(List<UsageContext> theUseContext) { 2865 this.useContext = theUseContext; 2866 return this; 2867 } 2868 2869 public boolean hasUseContext() { 2870 if (this.useContext == null) 2871 return false; 2872 for (UsageContext item : this.useContext) 2873 if (!item.isEmpty()) 2874 return true; 2875 return false; 2876 } 2877 2878 public UsageContext addUseContext() { // 3 2879 UsageContext t = new UsageContext(); 2880 if (this.useContext == null) 2881 this.useContext = new ArrayList<UsageContext>(); 2882 this.useContext.add(t); 2883 return t; 2884 } 2885 2886 public GraphDefinition addUseContext(UsageContext t) { // 3 2887 if (t == null) 2888 return this; 2889 if (this.useContext == null) 2890 this.useContext = new ArrayList<UsageContext>(); 2891 this.useContext.add(t); 2892 return this; 2893 } 2894 2895 /** 2896 * @return The first repetition of repeating field {@link #useContext}, creating 2897 * it if it does not already exist 2898 */ 2899 public UsageContext getUseContextFirstRep() { 2900 if (getUseContext().isEmpty()) { 2901 addUseContext(); 2902 } 2903 return getUseContext().get(0); 2904 } 2905 2906 /** 2907 * @return {@link #jurisdiction} (A legal or geographic region in which the 2908 * graph definition is intended to be used.) 2909 */ 2910 public List<CodeableConcept> getJurisdiction() { 2911 if (this.jurisdiction == null) 2912 this.jurisdiction = new ArrayList<CodeableConcept>(); 2913 return this.jurisdiction; 2914 } 2915 2916 /** 2917 * @return Returns a reference to <code>this</code> for easy method chaining 2918 */ 2919 public GraphDefinition setJurisdiction(List<CodeableConcept> theJurisdiction) { 2920 this.jurisdiction = theJurisdiction; 2921 return this; 2922 } 2923 2924 public boolean hasJurisdiction() { 2925 if (this.jurisdiction == null) 2926 return false; 2927 for (CodeableConcept item : this.jurisdiction) 2928 if (!item.isEmpty()) 2929 return true; 2930 return false; 2931 } 2932 2933 public CodeableConcept addJurisdiction() { // 3 2934 CodeableConcept t = new CodeableConcept(); 2935 if (this.jurisdiction == null) 2936 this.jurisdiction = new ArrayList<CodeableConcept>(); 2937 this.jurisdiction.add(t); 2938 return t; 2939 } 2940 2941 public GraphDefinition addJurisdiction(CodeableConcept t) { // 3 2942 if (t == null) 2943 return this; 2944 if (this.jurisdiction == null) 2945 this.jurisdiction = new ArrayList<CodeableConcept>(); 2946 this.jurisdiction.add(t); 2947 return this; 2948 } 2949 2950 /** 2951 * @return The first repetition of repeating field {@link #jurisdiction}, 2952 * creating it if it does not already exist 2953 */ 2954 public CodeableConcept getJurisdictionFirstRep() { 2955 if (getJurisdiction().isEmpty()) { 2956 addJurisdiction(); 2957 } 2958 return getJurisdiction().get(0); 2959 } 2960 2961 /** 2962 * @return {@link #purpose} (Explanation of why this graph definition is needed 2963 * and why it has been designed as it has.). This is the underlying 2964 * object with id, value and extensions. The accessor "getPurpose" gives 2965 * direct access to the value 2966 */ 2967 public MarkdownType getPurposeElement() { 2968 if (this.purpose == null) 2969 if (Configuration.errorOnAutoCreate()) 2970 throw new Error("Attempt to auto-create GraphDefinition.purpose"); 2971 else if (Configuration.doAutoCreate()) 2972 this.purpose = new MarkdownType(); // bb 2973 return this.purpose; 2974 } 2975 2976 public boolean hasPurposeElement() { 2977 return this.purpose != null && !this.purpose.isEmpty(); 2978 } 2979 2980 public boolean hasPurpose() { 2981 return this.purpose != null && !this.purpose.isEmpty(); 2982 } 2983 2984 /** 2985 * @param value {@link #purpose} (Explanation of why this graph definition is 2986 * needed and why it has been designed as it has.). This is the 2987 * underlying object with id, value and extensions. The accessor 2988 * "getPurpose" gives direct access to the value 2989 */ 2990 public GraphDefinition setPurposeElement(MarkdownType value) { 2991 this.purpose = value; 2992 return this; 2993 } 2994 2995 /** 2996 * @return Explanation of why this graph definition is needed and why it has 2997 * been designed as it has. 2998 */ 2999 public String getPurpose() { 3000 return this.purpose == null ? null : this.purpose.getValue(); 3001 } 3002 3003 /** 3004 * @param value Explanation of why this graph definition is needed and why it 3005 * has been designed as it has. 3006 */ 3007 public GraphDefinition setPurpose(String value) { 3008 if (value == null) 3009 this.purpose = null; 3010 else { 3011 if (this.purpose == null) 3012 this.purpose = new MarkdownType(); 3013 this.purpose.setValue(value); 3014 } 3015 return this; 3016 } 3017 3018 /** 3019 * @return {@link #start} (The type of FHIR resource at which instances of this 3020 * graph start.). This is the underlying object with id, value and 3021 * extensions. The accessor "getStart" gives direct access to the value 3022 */ 3023 public CodeType getStartElement() { 3024 if (this.start == null) 3025 if (Configuration.errorOnAutoCreate()) 3026 throw new Error("Attempt to auto-create GraphDefinition.start"); 3027 else if (Configuration.doAutoCreate()) 3028 this.start = new CodeType(); // bb 3029 return this.start; 3030 } 3031 3032 public boolean hasStartElement() { 3033 return this.start != null && !this.start.isEmpty(); 3034 } 3035 3036 public boolean hasStart() { 3037 return this.start != null && !this.start.isEmpty(); 3038 } 3039 3040 /** 3041 * @param value {@link #start} (The type of FHIR resource at which instances of 3042 * this graph start.). This is the underlying object with id, value 3043 * and extensions. The accessor "getStart" gives direct access to 3044 * the value 3045 */ 3046 public GraphDefinition setStartElement(CodeType value) { 3047 this.start = value; 3048 return this; 3049 } 3050 3051 /** 3052 * @return The type of FHIR resource at which instances of this graph start. 3053 */ 3054 public String getStart() { 3055 return this.start == null ? null : this.start.getValue(); 3056 } 3057 3058 /** 3059 * @param value The type of FHIR resource at which instances of this graph 3060 * start. 3061 */ 3062 public GraphDefinition setStart(String value) { 3063 if (this.start == null) 3064 this.start = new CodeType(); 3065 this.start.setValue(value); 3066 return this; 3067 } 3068 3069 /** 3070 * @return {@link #profile} (The profile that describes the use of the base 3071 * resource.). This is the underlying object with id, value and 3072 * extensions. The accessor "getProfile" gives direct access to the 3073 * value 3074 */ 3075 public CanonicalType getProfileElement() { 3076 if (this.profile == null) 3077 if (Configuration.errorOnAutoCreate()) 3078 throw new Error("Attempt to auto-create GraphDefinition.profile"); 3079 else if (Configuration.doAutoCreate()) 3080 this.profile = new CanonicalType(); // bb 3081 return this.profile; 3082 } 3083 3084 public boolean hasProfileElement() { 3085 return this.profile != null && !this.profile.isEmpty(); 3086 } 3087 3088 public boolean hasProfile() { 3089 return this.profile != null && !this.profile.isEmpty(); 3090 } 3091 3092 /** 3093 * @param value {@link #profile} (The profile that describes the use of the base 3094 * resource.). This is the underlying object with id, value and 3095 * extensions. The accessor "getProfile" gives direct access to the 3096 * value 3097 */ 3098 public GraphDefinition setProfileElement(CanonicalType value) { 3099 this.profile = value; 3100 return this; 3101 } 3102 3103 /** 3104 * @return The profile that describes the use of the base resource. 3105 */ 3106 public String getProfile() { 3107 return this.profile == null ? null : this.profile.getValue(); 3108 } 3109 3110 /** 3111 * @param value The profile that describes the use of the base resource. 3112 */ 3113 public GraphDefinition setProfile(String value) { 3114 if (Utilities.noString(value)) 3115 this.profile = null; 3116 else { 3117 if (this.profile == null) 3118 this.profile = new CanonicalType(); 3119 this.profile.setValue(value); 3120 } 3121 return this; 3122 } 3123 3124 /** 3125 * @return {@link #link} (Links this graph makes rules about.) 3126 */ 3127 public List<GraphDefinitionLinkComponent> getLink() { 3128 if (this.link == null) 3129 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 3130 return this.link; 3131 } 3132 3133 /** 3134 * @return Returns a reference to <code>this</code> for easy method chaining 3135 */ 3136 public GraphDefinition setLink(List<GraphDefinitionLinkComponent> theLink) { 3137 this.link = theLink; 3138 return this; 3139 } 3140 3141 public boolean hasLink() { 3142 if (this.link == null) 3143 return false; 3144 for (GraphDefinitionLinkComponent item : this.link) 3145 if (!item.isEmpty()) 3146 return true; 3147 return false; 3148 } 3149 3150 public GraphDefinitionLinkComponent addLink() { // 3 3151 GraphDefinitionLinkComponent t = new GraphDefinitionLinkComponent(); 3152 if (this.link == null) 3153 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 3154 this.link.add(t); 3155 return t; 3156 } 3157 3158 public GraphDefinition addLink(GraphDefinitionLinkComponent t) { // 3 3159 if (t == null) 3160 return this; 3161 if (this.link == null) 3162 this.link = new ArrayList<GraphDefinitionLinkComponent>(); 3163 this.link.add(t); 3164 return this; 3165 } 3166 3167 /** 3168 * @return The first repetition of repeating field {@link #link}, creating it if 3169 * it does not already exist 3170 */ 3171 public GraphDefinitionLinkComponent getLinkFirstRep() { 3172 if (getLink().isEmpty()) { 3173 addLink(); 3174 } 3175 return getLink().get(0); 3176 } 3177 3178 protected void listChildren(List<Property> children) { 3179 super.listChildren(children); 3180 children.add(new Property("url", "uri", 3181 "An absolute URI that is used to identify this graph definition when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this graph definition is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the graph definition is stored on different servers.", 3182 0, 1, url)); 3183 children.add(new Property("version", "string", 3184 "The identifier that is used to identify this version of the graph definition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the graph definition author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.", 3185 0, 1, version)); 3186 children.add(new Property("name", "string", 3187 "A natural language name identifying the graph definition. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 3188 0, 1, name)); 3189 children.add(new Property("status", "code", 3190 "The status of this graph definition. Enables tracking the life-cycle of the content.", 0, 1, status)); 3191 children.add(new Property("experimental", "boolean", 3192 "A Boolean value to indicate that this graph definition is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 3193 0, 1, experimental)); 3194 children.add(new Property("date", "dateTime", 3195 "The date (and optionally time) when the graph definition was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the graph definition changes.", 3196 0, 1, date)); 3197 children.add(new Property("publisher", "string", 3198 "The name of the organization or individual that published the graph definition.", 0, 1, publisher)); 3199 children.add(new Property("contact", "ContactDetail", 3200 "Contact details to assist a user in finding and communicating with the publisher.", 0, 3201 java.lang.Integer.MAX_VALUE, contact)); 3202 children.add(new Property("description", "markdown", 3203 "A free text natural language description of the graph definition from a consumer's perspective.", 0, 1, 3204 description)); 3205 children.add(new Property("useContext", "UsageContext", 3206 "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate graph definition instances.", 3207 0, java.lang.Integer.MAX_VALUE, useContext)); 3208 children.add(new Property("jurisdiction", "CodeableConcept", 3209 "A legal or geographic region in which the graph definition is intended to be used.", 0, 3210 java.lang.Integer.MAX_VALUE, jurisdiction)); 3211 children.add(new Property("purpose", "markdown", 3212 "Explanation of why this graph definition is needed and why it has been designed as it has.", 0, 1, purpose)); 3213 children.add(new Property("start", "code", "The type of FHIR resource at which instances of this graph start.", 0, 3214 1, start)); 3215 children.add(new Property("profile", "canonical(StructureDefinition)", 3216 "The profile that describes the use of the base resource.", 0, 1, profile)); 3217 children.add(new Property("link", "", "Links this graph makes rules about.", 0, java.lang.Integer.MAX_VALUE, link)); 3218 } 3219 3220 @Override 3221 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3222 switch (_hash) { 3223 case 116079: 3224 /* url */ return new Property("url", "uri", 3225 "An absolute URI that is used to identify this graph definition when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which at which an authoritative instance of this graph definition is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the graph definition is stored on different servers.", 3226 0, 1, url); 3227 case 351608024: 3228 /* version */ return new Property("version", "string", 3229 "The identifier that is used to identify this version of the graph definition when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the graph definition author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.", 3230 0, 1, version); 3231 case 3373707: 3232 /* name */ return new Property("name", "string", 3233 "A natural language name identifying the graph definition. This name should be usable as an identifier for the module by machine processing applications such as code generation.", 3234 0, 1, name); 3235 case -892481550: 3236 /* status */ return new Property("status", "code", 3237 "The status of this graph definition. Enables tracking the life-cycle of the content.", 0, 1, status); 3238 case -404562712: 3239 /* experimental */ return new Property("experimental", "boolean", 3240 "A Boolean value to indicate that this graph definition is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage.", 3241 0, 1, experimental); 3242 case 3076014: 3243 /* date */ return new Property("date", "dateTime", 3244 "The date (and optionally time) when the graph definition was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the graph definition changes.", 3245 0, 1, date); 3246 case 1447404028: 3247 /* publisher */ return new Property("publisher", "string", 3248 "The name of the organization or individual that published the graph definition.", 0, 1, publisher); 3249 case 951526432: 3250 /* contact */ return new Property("contact", "ContactDetail", 3251 "Contact details to assist a user in finding and communicating with the publisher.", 0, 3252 java.lang.Integer.MAX_VALUE, contact); 3253 case -1724546052: 3254 /* description */ return new Property("description", "markdown", 3255 "A free text natural language description of the graph definition from a consumer's perspective.", 0, 1, 3256 description); 3257 case -669707736: 3258 /* useContext */ return new Property("useContext", "UsageContext", 3259 "The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate graph definition instances.", 3260 0, java.lang.Integer.MAX_VALUE, useContext); 3261 case -507075711: 3262 /* jurisdiction */ return new Property("jurisdiction", "CodeableConcept", 3263 "A legal or geographic region in which the graph definition is intended to be used.", 0, 3264 java.lang.Integer.MAX_VALUE, jurisdiction); 3265 case -220463842: 3266 /* purpose */ return new Property("purpose", "markdown", 3267 "Explanation of why this graph definition is needed and why it has been designed as it has.", 0, 1, purpose); 3268 case 109757538: 3269 /* start */ return new Property("start", "code", 3270 "The type of FHIR resource at which instances of this graph start.", 0, 1, start); 3271 case -309425751: 3272 /* profile */ return new Property("profile", "canonical(StructureDefinition)", 3273 "The profile that describes the use of the base resource.", 0, 1, profile); 3274 case 3321850: 3275 /* link */ return new Property("link", "", "Links this graph makes rules about.", 0, java.lang.Integer.MAX_VALUE, 3276 link); 3277 default: 3278 return super.getNamedProperty(_hash, _name, _checkValid); 3279 } 3280 3281 } 3282 3283 @Override 3284 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3285 switch (hash) { 3286 case 116079: 3287 /* url */ return this.url == null ? new Base[0] : new Base[] { this.url }; // UriType 3288 case 351608024: 3289 /* version */ return this.version == null ? new Base[0] : new Base[] { this.version }; // StringType 3290 case 3373707: 3291 /* name */ return this.name == null ? new Base[0] : new Base[] { this.name }; // StringType 3292 case -892481550: 3293 /* status */ return this.status == null ? new Base[0] : new Base[] { this.status }; // Enumeration<PublicationStatus> 3294 case -404562712: 3295 /* experimental */ return this.experimental == null ? new Base[0] : new Base[] { this.experimental }; // BooleanType 3296 case 3076014: 3297 /* date */ return this.date == null ? new Base[0] : new Base[] { this.date }; // DateTimeType 3298 case 1447404028: 3299 /* publisher */ return this.publisher == null ? new Base[0] : new Base[] { this.publisher }; // StringType 3300 case 951526432: 3301 /* contact */ return this.contact == null ? new Base[0] : this.contact.toArray(new Base[this.contact.size()]); // ContactDetail 3302 case -1724546052: 3303 /* description */ return this.description == null ? new Base[0] : new Base[] { this.description }; // MarkdownType 3304 case -669707736: 3305 /* useContext */ return this.useContext == null ? new Base[0] 3306 : this.useContext.toArray(new Base[this.useContext.size()]); // UsageContext 3307 case -507075711: 3308 /* jurisdiction */ return this.jurisdiction == null ? new Base[0] 3309 : this.jurisdiction.toArray(new Base[this.jurisdiction.size()]); // CodeableConcept 3310 case -220463842: 3311 /* purpose */ return this.purpose == null ? new Base[0] : new Base[] { this.purpose }; // MarkdownType 3312 case 109757538: 3313 /* start */ return this.start == null ? new Base[0] : new Base[] { this.start }; // CodeType 3314 case -309425751: 3315 /* profile */ return this.profile == null ? new Base[0] : new Base[] { this.profile }; // CanonicalType 3316 case 3321850: 3317 /* link */ return this.link == null ? new Base[0] : this.link.toArray(new Base[this.link.size()]); // GraphDefinitionLinkComponent 3318 default: 3319 return super.getProperty(hash, name, checkValid); 3320 } 3321 3322 } 3323 3324 @Override 3325 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3326 switch (hash) { 3327 case 116079: // url 3328 this.url = castToUri(value); // UriType 3329 return value; 3330 case 351608024: // version 3331 this.version = castToString(value); // StringType 3332 return value; 3333 case 3373707: // name 3334 this.name = castToString(value); // StringType 3335 return value; 3336 case -892481550: // status 3337 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 3338 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 3339 return value; 3340 case -404562712: // experimental 3341 this.experimental = castToBoolean(value); // BooleanType 3342 return value; 3343 case 3076014: // date 3344 this.date = castToDateTime(value); // DateTimeType 3345 return value; 3346 case 1447404028: // publisher 3347 this.publisher = castToString(value); // StringType 3348 return value; 3349 case 951526432: // contact 3350 this.getContact().add(castToContactDetail(value)); // ContactDetail 3351 return value; 3352 case -1724546052: // description 3353 this.description = castToMarkdown(value); // MarkdownType 3354 return value; 3355 case -669707736: // useContext 3356 this.getUseContext().add(castToUsageContext(value)); // UsageContext 3357 return value; 3358 case -507075711: // jurisdiction 3359 this.getJurisdiction().add(castToCodeableConcept(value)); // CodeableConcept 3360 return value; 3361 case -220463842: // purpose 3362 this.purpose = castToMarkdown(value); // MarkdownType 3363 return value; 3364 case 109757538: // start 3365 this.start = castToCode(value); // CodeType 3366 return value; 3367 case -309425751: // profile 3368 this.profile = castToCanonical(value); // CanonicalType 3369 return value; 3370 case 3321850: // link 3371 this.getLink().add((GraphDefinitionLinkComponent) value); // GraphDefinitionLinkComponent 3372 return value; 3373 default: 3374 return super.setProperty(hash, name, value); 3375 } 3376 3377 } 3378 3379 @Override 3380 public Base setProperty(String name, Base value) throws FHIRException { 3381 if (name.equals("url")) { 3382 this.url = castToUri(value); // UriType 3383 } else if (name.equals("version")) { 3384 this.version = castToString(value); // StringType 3385 } else if (name.equals("name")) { 3386 this.name = castToString(value); // StringType 3387 } else if (name.equals("status")) { 3388 value = new PublicationStatusEnumFactory().fromType(castToCode(value)); 3389 this.status = (Enumeration) value; // Enumeration<PublicationStatus> 3390 } else if (name.equals("experimental")) { 3391 this.experimental = castToBoolean(value); // BooleanType 3392 } else if (name.equals("date")) { 3393 this.date = castToDateTime(value); // DateTimeType 3394 } else if (name.equals("publisher")) { 3395 this.publisher = castToString(value); // StringType 3396 } else if (name.equals("contact")) { 3397 this.getContact().add(castToContactDetail(value)); 3398 } else if (name.equals("description")) { 3399 this.description = castToMarkdown(value); // MarkdownType 3400 } else if (name.equals("useContext")) { 3401 this.getUseContext().add(castToUsageContext(value)); 3402 } else if (name.equals("jurisdiction")) { 3403 this.getJurisdiction().add(castToCodeableConcept(value)); 3404 } else if (name.equals("purpose")) { 3405 this.purpose = castToMarkdown(value); // MarkdownType 3406 } else if (name.equals("start")) { 3407 this.start = castToCode(value); // CodeType 3408 } else if (name.equals("profile")) { 3409 this.profile = castToCanonical(value); // CanonicalType 3410 } else if (name.equals("link")) { 3411 this.getLink().add((GraphDefinitionLinkComponent) value); 3412 } else 3413 return super.setProperty(name, value); 3414 return value; 3415 } 3416 3417 @Override 3418 public void removeChild(String name, Base value) throws FHIRException { 3419 if (name.equals("url")) { 3420 this.url = null; 3421 } else if (name.equals("version")) { 3422 this.version = null; 3423 } else if (name.equals("name")) { 3424 this.name = null; 3425 } else if (name.equals("status")) { 3426 this.status = null; 3427 } else if (name.equals("experimental")) { 3428 this.experimental = null; 3429 } else if (name.equals("date")) { 3430 this.date = null; 3431 } else if (name.equals("publisher")) { 3432 this.publisher = null; 3433 } else if (name.equals("contact")) { 3434 this.getContact().remove(castToContactDetail(value)); 3435 } else if (name.equals("description")) { 3436 this.description = null; 3437 } else if (name.equals("useContext")) { 3438 this.getUseContext().remove(castToUsageContext(value)); 3439 } else if (name.equals("jurisdiction")) { 3440 this.getJurisdiction().remove(castToCodeableConcept(value)); 3441 } else if (name.equals("purpose")) { 3442 this.purpose = null; 3443 } else if (name.equals("start")) { 3444 this.start = null; 3445 } else if (name.equals("profile")) { 3446 this.profile = null; 3447 } else if (name.equals("link")) { 3448 this.getLink().remove((GraphDefinitionLinkComponent) value); 3449 } else 3450 super.removeChild(name, value); 3451 3452 } 3453 3454 @Override 3455 public Base makeProperty(int hash, String name) throws FHIRException { 3456 switch (hash) { 3457 case 116079: 3458 return getUrlElement(); 3459 case 351608024: 3460 return getVersionElement(); 3461 case 3373707: 3462 return getNameElement(); 3463 case -892481550: 3464 return getStatusElement(); 3465 case -404562712: 3466 return getExperimentalElement(); 3467 case 3076014: 3468 return getDateElement(); 3469 case 1447404028: 3470 return getPublisherElement(); 3471 case 951526432: 3472 return addContact(); 3473 case -1724546052: 3474 return getDescriptionElement(); 3475 case -669707736: 3476 return addUseContext(); 3477 case -507075711: 3478 return addJurisdiction(); 3479 case -220463842: 3480 return getPurposeElement(); 3481 case 109757538: 3482 return getStartElement(); 3483 case -309425751: 3484 return getProfileElement(); 3485 case 3321850: 3486 return addLink(); 3487 default: 3488 return super.makeProperty(hash, name); 3489 } 3490 3491 } 3492 3493 @Override 3494 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3495 switch (hash) { 3496 case 116079: 3497 /* url */ return new String[] { "uri" }; 3498 case 351608024: 3499 /* version */ return new String[] { "string" }; 3500 case 3373707: 3501 /* name */ return new String[] { "string" }; 3502 case -892481550: 3503 /* status */ return new String[] { "code" }; 3504 case -404562712: 3505 /* experimental */ return new String[] { "boolean" }; 3506 case 3076014: 3507 /* date */ return new String[] { "dateTime" }; 3508 case 1447404028: 3509 /* publisher */ return new String[] { "string" }; 3510 case 951526432: 3511 /* contact */ return new String[] { "ContactDetail" }; 3512 case -1724546052: 3513 /* description */ return new String[] { "markdown" }; 3514 case -669707736: 3515 /* useContext */ return new String[] { "UsageContext" }; 3516 case -507075711: 3517 /* jurisdiction */ return new String[] { "CodeableConcept" }; 3518 case -220463842: 3519 /* purpose */ return new String[] { "markdown" }; 3520 case 109757538: 3521 /* start */ return new String[] { "code" }; 3522 case -309425751: 3523 /* profile */ return new String[] { "canonical" }; 3524 case 3321850: 3525 /* link */ return new String[] {}; 3526 default: 3527 return super.getTypesForProperty(hash, name); 3528 } 3529 3530 } 3531 3532 @Override 3533 public Base addChild(String name) throws FHIRException { 3534 if (name.equals("url")) { 3535 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.url"); 3536 } else if (name.equals("version")) { 3537 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.version"); 3538 } else if (name.equals("name")) { 3539 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.name"); 3540 } else if (name.equals("status")) { 3541 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.status"); 3542 } else if (name.equals("experimental")) { 3543 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.experimental"); 3544 } else if (name.equals("date")) { 3545 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.date"); 3546 } else if (name.equals("publisher")) { 3547 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.publisher"); 3548 } else if (name.equals("contact")) { 3549 return addContact(); 3550 } else if (name.equals("description")) { 3551 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.description"); 3552 } else if (name.equals("useContext")) { 3553 return addUseContext(); 3554 } else if (name.equals("jurisdiction")) { 3555 return addJurisdiction(); 3556 } else if (name.equals("purpose")) { 3557 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.purpose"); 3558 } else if (name.equals("start")) { 3559 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.start"); 3560 } else if (name.equals("profile")) { 3561 throw new FHIRException("Cannot call addChild on a singleton property GraphDefinition.profile"); 3562 } else if (name.equals("link")) { 3563 return addLink(); 3564 } else 3565 return super.addChild(name); 3566 } 3567 3568 public String fhirType() { 3569 return "GraphDefinition"; 3570 3571 } 3572 3573 public GraphDefinition copy() { 3574 GraphDefinition dst = new GraphDefinition(); 3575 copyValues(dst); 3576 return dst; 3577 } 3578 3579 public void copyValues(GraphDefinition dst) { 3580 super.copyValues(dst); 3581 dst.url = url == null ? null : url.copy(); 3582 dst.version = version == null ? null : version.copy(); 3583 dst.name = name == null ? null : name.copy(); 3584 dst.status = status == null ? null : status.copy(); 3585 dst.experimental = experimental == null ? null : experimental.copy(); 3586 dst.date = date == null ? null : date.copy(); 3587 dst.publisher = publisher == null ? null : publisher.copy(); 3588 if (contact != null) { 3589 dst.contact = new ArrayList<ContactDetail>(); 3590 for (ContactDetail i : contact) 3591 dst.contact.add(i.copy()); 3592 } 3593 ; 3594 dst.description = description == null ? null : description.copy(); 3595 if (useContext != null) { 3596 dst.useContext = new ArrayList<UsageContext>(); 3597 for (UsageContext i : useContext) 3598 dst.useContext.add(i.copy()); 3599 } 3600 ; 3601 if (jurisdiction != null) { 3602 dst.jurisdiction = new ArrayList<CodeableConcept>(); 3603 for (CodeableConcept i : jurisdiction) 3604 dst.jurisdiction.add(i.copy()); 3605 } 3606 ; 3607 dst.purpose = purpose == null ? null : purpose.copy(); 3608 dst.start = start == null ? null : start.copy(); 3609 dst.profile = profile == null ? null : profile.copy(); 3610 if (link != null) { 3611 dst.link = new ArrayList<GraphDefinitionLinkComponent>(); 3612 for (GraphDefinitionLinkComponent i : link) 3613 dst.link.add(i.copy()); 3614 } 3615 ; 3616 } 3617 3618 protected GraphDefinition typedCopy() { 3619 return copy(); 3620 } 3621 3622 @Override 3623 public boolean equalsDeep(Base other_) { 3624 if (!super.equalsDeep(other_)) 3625 return false; 3626 if (!(other_ instanceof GraphDefinition)) 3627 return false; 3628 GraphDefinition o = (GraphDefinition) other_; 3629 return compareDeep(purpose, o.purpose, true) && compareDeep(start, o.start, true) 3630 && compareDeep(profile, o.profile, true) && compareDeep(link, o.link, true); 3631 } 3632 3633 @Override 3634 public boolean equalsShallow(Base other_) { 3635 if (!super.equalsShallow(other_)) 3636 return false; 3637 if (!(other_ instanceof GraphDefinition)) 3638 return false; 3639 GraphDefinition o = (GraphDefinition) other_; 3640 return compareValues(purpose, o.purpose, true) && compareValues(start, o.start, true); 3641 } 3642 3643 public boolean isEmpty() { 3644 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(purpose, start, profile, link); 3645 } 3646 3647 @Override 3648 public ResourceType getResourceType() { 3649 return ResourceType.GraphDefinition; 3650 } 3651 3652 /** 3653 * Search parameter: <b>date</b> 3654 * <p> 3655 * Description: <b>The graph definition publication date</b><br> 3656 * Type: <b>date</b><br> 3657 * Path: <b>GraphDefinition.date</b><br> 3658 * </p> 3659 */ 3660 @SearchParamDefinition(name = "date", path = "GraphDefinition.date", description = "The graph definition publication date", type = "date") 3661 public static final String SP_DATE = "date"; 3662 /** 3663 * <b>Fluent Client</b> search parameter constant for <b>date</b> 3664 * <p> 3665 * Description: <b>The graph definition publication date</b><br> 3666 * Type: <b>date</b><br> 3667 * Path: <b>GraphDefinition.date</b><br> 3668 * </p> 3669 */ 3670 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam( 3671 SP_DATE); 3672 3673 /** 3674 * Search parameter: <b>context-type-value</b> 3675 * <p> 3676 * Description: <b>A use context type and value assigned to the graph 3677 * definition</b><br> 3678 * Type: <b>composite</b><br> 3679 * Path: <b></b><br> 3680 * </p> 3681 */ 3682 @SearchParamDefinition(name = "context-type-value", path = "GraphDefinition.useContext", description = "A use context type and value assigned to the graph definition", type = "composite", compositeOf = { 3683 "context-type", "context" }) 3684 public static final String SP_CONTEXT_TYPE_VALUE = "context-type-value"; 3685 /** 3686 * <b>Fluent Client</b> search parameter constant for <b>context-type-value</b> 3687 * <p> 3688 * Description: <b>A use context type and value assigned to the graph 3689 * definition</b><br> 3690 * Type: <b>composite</b><br> 3691 * Path: <b></b><br> 3692 * </p> 3693 */ 3694 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam> CONTEXT_TYPE_VALUE = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.TokenClientParam>( 3695 SP_CONTEXT_TYPE_VALUE); 3696 3697 /** 3698 * Search parameter: <b>jurisdiction</b> 3699 * <p> 3700 * Description: <b>Intended jurisdiction for the graph definition</b><br> 3701 * Type: <b>token</b><br> 3702 * Path: <b>GraphDefinition.jurisdiction</b><br> 3703 * </p> 3704 */ 3705 @SearchParamDefinition(name = "jurisdiction", path = "GraphDefinition.jurisdiction", description = "Intended jurisdiction for the graph definition", type = "token") 3706 public static final String SP_JURISDICTION = "jurisdiction"; 3707 /** 3708 * <b>Fluent Client</b> search parameter constant for <b>jurisdiction</b> 3709 * <p> 3710 * Description: <b>Intended jurisdiction for the graph definition</b><br> 3711 * Type: <b>token</b><br> 3712 * Path: <b>GraphDefinition.jurisdiction</b><br> 3713 * </p> 3714 */ 3715 public static final ca.uhn.fhir.rest.gclient.TokenClientParam JURISDICTION = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3716 SP_JURISDICTION); 3717 3718 /** 3719 * Search parameter: <b>start</b> 3720 * <p> 3721 * Description: <b>Type of resource at which the graph starts</b><br> 3722 * Type: <b>token</b><br> 3723 * Path: <b>GraphDefinition.start</b><br> 3724 * </p> 3725 */ 3726 @SearchParamDefinition(name = "start", path = "GraphDefinition.start", description = "Type of resource at which the graph starts", type = "token") 3727 public static final String SP_START = "start"; 3728 /** 3729 * <b>Fluent Client</b> search parameter constant for <b>start</b> 3730 * <p> 3731 * Description: <b>Type of resource at which the graph starts</b><br> 3732 * Type: <b>token</b><br> 3733 * Path: <b>GraphDefinition.start</b><br> 3734 * </p> 3735 */ 3736 public static final ca.uhn.fhir.rest.gclient.TokenClientParam START = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3737 SP_START); 3738 3739 /** 3740 * Search parameter: <b>description</b> 3741 * <p> 3742 * Description: <b>The description of the graph definition</b><br> 3743 * Type: <b>string</b><br> 3744 * Path: <b>GraphDefinition.description</b><br> 3745 * </p> 3746 */ 3747 @SearchParamDefinition(name = "description", path = "GraphDefinition.description", description = "The description of the graph definition", type = "string") 3748 public static final String SP_DESCRIPTION = "description"; 3749 /** 3750 * <b>Fluent Client</b> search parameter constant for <b>description</b> 3751 * <p> 3752 * Description: <b>The description of the graph definition</b><br> 3753 * Type: <b>string</b><br> 3754 * Path: <b>GraphDefinition.description</b><br> 3755 * </p> 3756 */ 3757 public static final ca.uhn.fhir.rest.gclient.StringClientParam DESCRIPTION = new ca.uhn.fhir.rest.gclient.StringClientParam( 3758 SP_DESCRIPTION); 3759 3760 /** 3761 * Search parameter: <b>context-type</b> 3762 * <p> 3763 * Description: <b>A type of use context assigned to the graph 3764 * definition</b><br> 3765 * Type: <b>token</b><br> 3766 * Path: <b>GraphDefinition.useContext.code</b><br> 3767 * </p> 3768 */ 3769 @SearchParamDefinition(name = "context-type", path = "GraphDefinition.useContext.code", description = "A type of use context assigned to the graph definition", type = "token") 3770 public static final String SP_CONTEXT_TYPE = "context-type"; 3771 /** 3772 * <b>Fluent Client</b> search parameter constant for <b>context-type</b> 3773 * <p> 3774 * Description: <b>A type of use context assigned to the graph 3775 * definition</b><br> 3776 * Type: <b>token</b><br> 3777 * Path: <b>GraphDefinition.useContext.code</b><br> 3778 * </p> 3779 */ 3780 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3781 SP_CONTEXT_TYPE); 3782 3783 /** 3784 * Search parameter: <b>version</b> 3785 * <p> 3786 * Description: <b>The business version of the graph definition</b><br> 3787 * Type: <b>token</b><br> 3788 * Path: <b>GraphDefinition.version</b><br> 3789 * </p> 3790 */ 3791 @SearchParamDefinition(name = "version", path = "GraphDefinition.version", description = "The business version of the graph definition", type = "token") 3792 public static final String SP_VERSION = "version"; 3793 /** 3794 * <b>Fluent Client</b> search parameter constant for <b>version</b> 3795 * <p> 3796 * Description: <b>The business version of the graph definition</b><br> 3797 * Type: <b>token</b><br> 3798 * Path: <b>GraphDefinition.version</b><br> 3799 * </p> 3800 */ 3801 public static final ca.uhn.fhir.rest.gclient.TokenClientParam VERSION = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3802 SP_VERSION); 3803 3804 /** 3805 * Search parameter: <b>url</b> 3806 * <p> 3807 * Description: <b>The uri that identifies the graph definition</b><br> 3808 * Type: <b>uri</b><br> 3809 * Path: <b>GraphDefinition.url</b><br> 3810 * </p> 3811 */ 3812 @SearchParamDefinition(name = "url", path = "GraphDefinition.url", description = "The uri that identifies the graph definition", type = "uri") 3813 public static final String SP_URL = "url"; 3814 /** 3815 * <b>Fluent Client</b> search parameter constant for <b>url</b> 3816 * <p> 3817 * Description: <b>The uri that identifies the graph definition</b><br> 3818 * Type: <b>uri</b><br> 3819 * Path: <b>GraphDefinition.url</b><br> 3820 * </p> 3821 */ 3822 public static final ca.uhn.fhir.rest.gclient.UriClientParam URL = new ca.uhn.fhir.rest.gclient.UriClientParam(SP_URL); 3823 3824 /** 3825 * Search parameter: <b>context-quantity</b> 3826 * <p> 3827 * Description: <b>A quantity- or range-valued use context assigned to the graph 3828 * definition</b><br> 3829 * Type: <b>quantity</b><br> 3830 * Path: <b>GraphDefinition.useContext.valueQuantity, 3831 * GraphDefinition.useContext.valueRange</b><br> 3832 * </p> 3833 */ 3834 @SearchParamDefinition(name = "context-quantity", path = "(GraphDefinition.useContext.value as Quantity) | (GraphDefinition.useContext.value as Range)", description = "A quantity- or range-valued use context assigned to the graph definition", type = "quantity") 3835 public static final String SP_CONTEXT_QUANTITY = "context-quantity"; 3836 /** 3837 * <b>Fluent Client</b> search parameter constant for <b>context-quantity</b> 3838 * <p> 3839 * Description: <b>A quantity- or range-valued use context assigned to the graph 3840 * definition</b><br> 3841 * Type: <b>quantity</b><br> 3842 * Path: <b>GraphDefinition.useContext.valueQuantity, 3843 * GraphDefinition.useContext.valueRange</b><br> 3844 * </p> 3845 */ 3846 public static final ca.uhn.fhir.rest.gclient.QuantityClientParam CONTEXT_QUANTITY = new ca.uhn.fhir.rest.gclient.QuantityClientParam( 3847 SP_CONTEXT_QUANTITY); 3848 3849 /** 3850 * Search parameter: <b>name</b> 3851 * <p> 3852 * Description: <b>Computationally friendly name of the graph definition</b><br> 3853 * Type: <b>string</b><br> 3854 * Path: <b>GraphDefinition.name</b><br> 3855 * </p> 3856 */ 3857 @SearchParamDefinition(name = "name", path = "GraphDefinition.name", description = "Computationally friendly name of the graph definition", type = "string") 3858 public static final String SP_NAME = "name"; 3859 /** 3860 * <b>Fluent Client</b> search parameter constant for <b>name</b> 3861 * <p> 3862 * Description: <b>Computationally friendly name of the graph definition</b><br> 3863 * Type: <b>string</b><br> 3864 * Path: <b>GraphDefinition.name</b><br> 3865 * </p> 3866 */ 3867 public static final ca.uhn.fhir.rest.gclient.StringClientParam NAME = new ca.uhn.fhir.rest.gclient.StringClientParam( 3868 SP_NAME); 3869 3870 /** 3871 * Search parameter: <b>context</b> 3872 * <p> 3873 * Description: <b>A use context assigned to the graph definition</b><br> 3874 * Type: <b>token</b><br> 3875 * Path: <b>GraphDefinition.useContext.valueCodeableConcept</b><br> 3876 * </p> 3877 */ 3878 @SearchParamDefinition(name = "context", path = "(GraphDefinition.useContext.value as CodeableConcept)", description = "A use context assigned to the graph definition", type = "token") 3879 public static final String SP_CONTEXT = "context"; 3880 /** 3881 * <b>Fluent Client</b> search parameter constant for <b>context</b> 3882 * <p> 3883 * Description: <b>A use context assigned to the graph definition</b><br> 3884 * Type: <b>token</b><br> 3885 * Path: <b>GraphDefinition.useContext.valueCodeableConcept</b><br> 3886 * </p> 3887 */ 3888 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CONTEXT = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3889 SP_CONTEXT); 3890 3891 /** 3892 * Search parameter: <b>publisher</b> 3893 * <p> 3894 * Description: <b>Name of the publisher of the graph definition</b><br> 3895 * Type: <b>string</b><br> 3896 * Path: <b>GraphDefinition.publisher</b><br> 3897 * </p> 3898 */ 3899 @SearchParamDefinition(name = "publisher", path = "GraphDefinition.publisher", description = "Name of the publisher of the graph definition", type = "string") 3900 public static final String SP_PUBLISHER = "publisher"; 3901 /** 3902 * <b>Fluent Client</b> search parameter constant for <b>publisher</b> 3903 * <p> 3904 * Description: <b>Name of the publisher of the graph definition</b><br> 3905 * Type: <b>string</b><br> 3906 * Path: <b>GraphDefinition.publisher</b><br> 3907 * </p> 3908 */ 3909 public static final ca.uhn.fhir.rest.gclient.StringClientParam PUBLISHER = new ca.uhn.fhir.rest.gclient.StringClientParam( 3910 SP_PUBLISHER); 3911 3912 /** 3913 * Search parameter: <b>context-type-quantity</b> 3914 * <p> 3915 * Description: <b>A use context type and quantity- or range-based value 3916 * assigned to the graph definition</b><br> 3917 * Type: <b>composite</b><br> 3918 * Path: <b></b><br> 3919 * </p> 3920 */ 3921 @SearchParamDefinition(name = "context-type-quantity", path = "GraphDefinition.useContext", description = "A use context type and quantity- or range-based value assigned to the graph definition", type = "composite", compositeOf = { 3922 "context-type", "context-quantity" }) 3923 public static final String SP_CONTEXT_TYPE_QUANTITY = "context-type-quantity"; 3924 /** 3925 * <b>Fluent Client</b> search parameter constant for 3926 * <b>context-type-quantity</b> 3927 * <p> 3928 * Description: <b>A use context type and quantity- or range-based value 3929 * assigned to the graph definition</b><br> 3930 * Type: <b>composite</b><br> 3931 * Path: <b></b><br> 3932 * </p> 3933 */ 3934 public static final ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam> CONTEXT_TYPE_QUANTITY = new ca.uhn.fhir.rest.gclient.CompositeClientParam<ca.uhn.fhir.rest.gclient.TokenClientParam, ca.uhn.fhir.rest.gclient.QuantityClientParam>( 3935 SP_CONTEXT_TYPE_QUANTITY); 3936 3937 /** 3938 * Search parameter: <b>status</b> 3939 * <p> 3940 * Description: <b>The current status of the graph definition</b><br> 3941 * Type: <b>token</b><br> 3942 * Path: <b>GraphDefinition.status</b><br> 3943 * </p> 3944 */ 3945 @SearchParamDefinition(name = "status", path = "GraphDefinition.status", description = "The current status of the graph definition", type = "token") 3946 public static final String SP_STATUS = "status"; 3947 /** 3948 * <b>Fluent Client</b> search parameter constant for <b>status</b> 3949 * <p> 3950 * Description: <b>The current status of the graph definition</b><br> 3951 * Type: <b>token</b><br> 3952 * Path: <b>GraphDefinition.status</b><br> 3953 * </p> 3954 */ 3955 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam( 3956 SP_STATUS); 3957 3958}