001package org.hl7.fhir.r5.model; 002 003 004/* 005 * #%L 006 * org.hl7.fhir.r5 007 * %% 008 * Copyright (C) 2014 - 2019 Health Level 7 009 * %% 010 * Licensed under the Apache License, Version 2.0 (the \"License\"); 011 * you may not use this file except in compliance with the License. 012 * You may obtain a copy of the License at 013 * 014 * http://www.apache.org/licenses/LICENSE-2.0 015 * 016 * Unless required by applicable law or agreed to in writing, software 017 * distributed under the License is distributed on an \"AS IS\" BASIS, 018 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 019 * See the License for the specific language governing permissions and 020 * limitations under the License. 021 * #L% 022 */ 023 024/* 025 Copyright (c) 2011+, HL7, Inc. 026 All rights reserved. 027 028 Redistribution and use in source and binary forms, with or without modification, \ 029 are permitted provided that the following conditions are met: 030 031 * Redistributions of source code must retain the above copyright notice, this \ 032 list of conditions and the following disclaimer. 033 * Redistributions in binary form must reproduce the above copyright notice, \ 034 this list of conditions and the following disclaimer in the documentation \ 035 and/or other materials provided with the distribution. 036 * Neither the name of HL7 nor the names of its contributors may be used to 037 endorse or promote products derived from this software without specific 038 prior written permission. 039 040 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 041 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 042 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 043 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 044 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 045 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 046 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 047 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 048 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 049 POSSIBILITY OF SUCH DAMAGE. 050 */ 051 052// Generated on Tue, Dec 31, 2019 12:12+1100 for FHIR vcurrent 053 054import java.util.ArrayList; 055import java.util.Date; 056import java.util.List; 057import java.math.*; 058import org.hl7.fhir.utilities.Utilities; 059import org.hl7.fhir.r5.model.Enumerations.*; 060import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 061import org.hl7.fhir.exceptions.FHIRException; 062import org.hl7.fhir.instance.model.api.ICompositeType; 063import ca.uhn.fhir.model.api.annotation.ResourceDef; 064import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 065import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 066import ca.uhn.fhir.model.api.annotation.Child; 067import ca.uhn.fhir.model.api.annotation.ChildOrder; 068import ca.uhn.fhir.model.api.annotation.Description; 069import ca.uhn.fhir.model.api.annotation.Block; 070 071/** 072 * An authorization for the provision of glasses and/or contact lenses to a patient. 073 */ 074@ResourceDef(name="VisionPrescription", profile="http://hl7.org/fhir/StructureDefinition/VisionPrescription") 075public class VisionPrescription extends DomainResource { 076 077 public enum VisionBase { 078 /** 079 * top. 080 */ 081 UP, 082 /** 083 * bottom. 084 */ 085 DOWN, 086 /** 087 * inner edge. 088 */ 089 IN, 090 /** 091 * outer edge. 092 */ 093 OUT, 094 /** 095 * added to help the parsers with the generic types 096 */ 097 NULL; 098 public static VisionBase fromCode(String codeString) throws FHIRException { 099 if (codeString == null || "".equals(codeString)) 100 return null; 101 if ("up".equals(codeString)) 102 return UP; 103 if ("down".equals(codeString)) 104 return DOWN; 105 if ("in".equals(codeString)) 106 return IN; 107 if ("out".equals(codeString)) 108 return OUT; 109 if (Configuration.isAcceptInvalidEnums()) 110 return null; 111 else 112 throw new FHIRException("Unknown VisionBase code '"+codeString+"'"); 113 } 114 public String toCode() { 115 switch (this) { 116 case UP: return "up"; 117 case DOWN: return "down"; 118 case IN: return "in"; 119 case OUT: return "out"; 120 default: return "?"; 121 } 122 } 123 public String getSystem() { 124 switch (this) { 125 case UP: return "http://hl7.org/fhir/vision-base-codes"; 126 case DOWN: return "http://hl7.org/fhir/vision-base-codes"; 127 case IN: return "http://hl7.org/fhir/vision-base-codes"; 128 case OUT: return "http://hl7.org/fhir/vision-base-codes"; 129 default: return "?"; 130 } 131 } 132 public String getDefinition() { 133 switch (this) { 134 case UP: return "top."; 135 case DOWN: return "bottom."; 136 case IN: return "inner edge."; 137 case OUT: return "outer edge."; 138 default: return "?"; 139 } 140 } 141 public String getDisplay() { 142 switch (this) { 143 case UP: return "Up"; 144 case DOWN: return "Down"; 145 case IN: return "In"; 146 case OUT: return "Out"; 147 default: return "?"; 148 } 149 } 150 } 151 152 public static class VisionBaseEnumFactory implements EnumFactory<VisionBase> { 153 public VisionBase fromCode(String codeString) throws IllegalArgumentException { 154 if (codeString == null || "".equals(codeString)) 155 if (codeString == null || "".equals(codeString)) 156 return null; 157 if ("up".equals(codeString)) 158 return VisionBase.UP; 159 if ("down".equals(codeString)) 160 return VisionBase.DOWN; 161 if ("in".equals(codeString)) 162 return VisionBase.IN; 163 if ("out".equals(codeString)) 164 return VisionBase.OUT; 165 throw new IllegalArgumentException("Unknown VisionBase code '"+codeString+"'"); 166 } 167 public Enumeration<VisionBase> fromType(Base code) throws FHIRException { 168 if (code == null) 169 return null; 170 if (code.isEmpty()) 171 return new Enumeration<VisionBase>(this); 172 String codeString = ((PrimitiveType) code).asStringValue(); 173 if (codeString == null || "".equals(codeString)) 174 return null; 175 if ("up".equals(codeString)) 176 return new Enumeration<VisionBase>(this, VisionBase.UP); 177 if ("down".equals(codeString)) 178 return new Enumeration<VisionBase>(this, VisionBase.DOWN); 179 if ("in".equals(codeString)) 180 return new Enumeration<VisionBase>(this, VisionBase.IN); 181 if ("out".equals(codeString)) 182 return new Enumeration<VisionBase>(this, VisionBase.OUT); 183 throw new FHIRException("Unknown VisionBase code '"+codeString+"'"); 184 } 185 public String toCode(VisionBase code) { 186 if (code == VisionBase.UP) 187 return "up"; 188 if (code == VisionBase.DOWN) 189 return "down"; 190 if (code == VisionBase.IN) 191 return "in"; 192 if (code == VisionBase.OUT) 193 return "out"; 194 return "?"; 195 } 196 public String toSystem(VisionBase code) { 197 return code.getSystem(); 198 } 199 } 200 201 public enum VisionEyes { 202 /** 203 * Right Eye. 204 */ 205 RIGHT, 206 /** 207 * Left Eye. 208 */ 209 LEFT, 210 /** 211 * added to help the parsers with the generic types 212 */ 213 NULL; 214 public static VisionEyes fromCode(String codeString) throws FHIRException { 215 if (codeString == null || "".equals(codeString)) 216 return null; 217 if ("right".equals(codeString)) 218 return RIGHT; 219 if ("left".equals(codeString)) 220 return LEFT; 221 if (Configuration.isAcceptInvalidEnums()) 222 return null; 223 else 224 throw new FHIRException("Unknown VisionEyes code '"+codeString+"'"); 225 } 226 public String toCode() { 227 switch (this) { 228 case RIGHT: return "right"; 229 case LEFT: return "left"; 230 default: return "?"; 231 } 232 } 233 public String getSystem() { 234 switch (this) { 235 case RIGHT: return "http://hl7.org/fhir/vision-eye-codes"; 236 case LEFT: return "http://hl7.org/fhir/vision-eye-codes"; 237 default: return "?"; 238 } 239 } 240 public String getDefinition() { 241 switch (this) { 242 case RIGHT: return "Right Eye."; 243 case LEFT: return "Left Eye."; 244 default: return "?"; 245 } 246 } 247 public String getDisplay() { 248 switch (this) { 249 case RIGHT: return "Right Eye"; 250 case LEFT: return "Left Eye"; 251 default: return "?"; 252 } 253 } 254 } 255 256 public static class VisionEyesEnumFactory implements EnumFactory<VisionEyes> { 257 public VisionEyes fromCode(String codeString) throws IllegalArgumentException { 258 if (codeString == null || "".equals(codeString)) 259 if (codeString == null || "".equals(codeString)) 260 return null; 261 if ("right".equals(codeString)) 262 return VisionEyes.RIGHT; 263 if ("left".equals(codeString)) 264 return VisionEyes.LEFT; 265 throw new IllegalArgumentException("Unknown VisionEyes code '"+codeString+"'"); 266 } 267 public Enumeration<VisionEyes> fromType(Base code) throws FHIRException { 268 if (code == null) 269 return null; 270 if (code.isEmpty()) 271 return new Enumeration<VisionEyes>(this); 272 String codeString = ((PrimitiveType) code).asStringValue(); 273 if (codeString == null || "".equals(codeString)) 274 return null; 275 if ("right".equals(codeString)) 276 return new Enumeration<VisionEyes>(this, VisionEyes.RIGHT); 277 if ("left".equals(codeString)) 278 return new Enumeration<VisionEyes>(this, VisionEyes.LEFT); 279 throw new FHIRException("Unknown VisionEyes code '"+codeString+"'"); 280 } 281 public String toCode(VisionEyes code) { 282 if (code == VisionEyes.RIGHT) 283 return "right"; 284 if (code == VisionEyes.LEFT) 285 return "left"; 286 return "?"; 287 } 288 public String toSystem(VisionEyes code) { 289 return code.getSystem(); 290 } 291 } 292 293 @Block() 294 public static class VisionPrescriptionLensSpecificationComponent extends BackboneElement implements IBaseBackboneElement { 295 /** 296 * Identifies the type of vision correction product which is required for the patient. 297 */ 298 @Child(name = "product", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=true) 299 @Description(shortDefinition="Product to be supplied", formalDefinition="Identifies the type of vision correction product which is required for the patient." ) 300 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/vision-product") 301 protected CodeableConcept product; 302 303 /** 304 * The eye for which the lens specification applies. 305 */ 306 @Child(name = "eye", type = {CodeType.class}, order=2, min=1, max=1, modifier=false, summary=true) 307 @Description(shortDefinition="right | left", formalDefinition="The eye for which the lens specification applies." ) 308 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/vision-eye-codes") 309 protected Enumeration<VisionEyes> eye; 310 311 /** 312 * Lens power measured in dioptres (0.25 units). 313 */ 314 @Child(name = "sphere", type = {DecimalType.class}, order=3, min=0, max=1, modifier=false, summary=false) 315 @Description(shortDefinition="Power of the lens", formalDefinition="Lens power measured in dioptres (0.25 units)." ) 316 protected DecimalType sphere; 317 318 /** 319 * Power adjustment for astigmatism measured in dioptres (0.25 units). 320 */ 321 @Child(name = "cylinder", type = {DecimalType.class}, order=4, min=0, max=1, modifier=false, summary=false) 322 @Description(shortDefinition="Lens power for astigmatism", formalDefinition="Power adjustment for astigmatism measured in dioptres (0.25 units)." ) 323 protected DecimalType cylinder; 324 325 /** 326 * Adjustment for astigmatism measured in integer degrees. 327 */ 328 @Child(name = "axis", type = {IntegerType.class}, order=5, min=0, max=1, modifier=false, summary=false) 329 @Description(shortDefinition="Lens meridian which contain no power for astigmatism", formalDefinition="Adjustment for astigmatism measured in integer degrees." ) 330 protected IntegerType axis; 331 332 /** 333 * Allows for adjustment on two axis. 334 */ 335 @Child(name = "prism", type = {}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 336 @Description(shortDefinition="Eye alignment compensation", formalDefinition="Allows for adjustment on two axis." ) 337 protected List<PrismComponent> prism; 338 339 /** 340 * Power adjustment for multifocal lenses measured in dioptres (0.25 units). 341 */ 342 @Child(name = "add", type = {DecimalType.class}, order=7, min=0, max=1, modifier=false, summary=false) 343 @Description(shortDefinition="Added power for multifocal levels", formalDefinition="Power adjustment for multifocal lenses measured in dioptres (0.25 units)." ) 344 protected DecimalType add; 345 346 /** 347 * Contact lens power measured in dioptres (0.25 units). 348 */ 349 @Child(name = "power", type = {DecimalType.class}, order=8, min=0, max=1, modifier=false, summary=false) 350 @Description(shortDefinition="Contact lens power", formalDefinition="Contact lens power measured in dioptres (0.25 units)." ) 351 protected DecimalType power; 352 353 /** 354 * Back curvature measured in millimetres. 355 */ 356 @Child(name = "backCurve", type = {DecimalType.class}, order=9, min=0, max=1, modifier=false, summary=false) 357 @Description(shortDefinition="Contact lens back curvature", formalDefinition="Back curvature measured in millimetres." ) 358 protected DecimalType backCurve; 359 360 /** 361 * Contact lens diameter measured in millimetres. 362 */ 363 @Child(name = "diameter", type = {DecimalType.class}, order=10, min=0, max=1, modifier=false, summary=false) 364 @Description(shortDefinition="Contact lens diameter", formalDefinition="Contact lens diameter measured in millimetres." ) 365 protected DecimalType diameter; 366 367 /** 368 * The recommended maximum wear period for the lens. 369 */ 370 @Child(name = "duration", type = {Quantity.class}, order=11, min=0, max=1, modifier=false, summary=false) 371 @Description(shortDefinition="Lens wear duration", formalDefinition="The recommended maximum wear period for the lens." ) 372 protected Quantity duration; 373 374 /** 375 * Special color or pattern. 376 */ 377 @Child(name = "color", type = {StringType.class}, order=12, min=0, max=1, modifier=false, summary=false) 378 @Description(shortDefinition="Color required", formalDefinition="Special color or pattern." ) 379 protected StringType color; 380 381 /** 382 * Brand recommendations or restrictions. 383 */ 384 @Child(name = "brand", type = {StringType.class}, order=13, min=0, max=1, modifier=false, summary=false) 385 @Description(shortDefinition="Brand required", formalDefinition="Brand recommendations or restrictions." ) 386 protected StringType brand; 387 388 /** 389 * Notes for special requirements such as coatings and lens materials. 390 */ 391 @Child(name = "note", type = {Annotation.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 392 @Description(shortDefinition="Notes for coatings", formalDefinition="Notes for special requirements such as coatings and lens materials." ) 393 protected List<Annotation> note; 394 395 private static final long serialVersionUID = 688924460L; 396 397 /** 398 * Constructor 399 */ 400 public VisionPrescriptionLensSpecificationComponent() { 401 super(); 402 } 403 404 /** 405 * Constructor 406 */ 407 public VisionPrescriptionLensSpecificationComponent(CodeableConcept product, VisionEyes eye) { 408 super(); 409 this.setProduct(product); 410 this.setEye(eye); 411 } 412 413 /** 414 * @return {@link #product} (Identifies the type of vision correction product which is required for the patient.) 415 */ 416 public CodeableConcept getProduct() { 417 if (this.product == null) 418 if (Configuration.errorOnAutoCreate()) 419 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.product"); 420 else if (Configuration.doAutoCreate()) 421 this.product = new CodeableConcept(); // cc 422 return this.product; 423 } 424 425 public boolean hasProduct() { 426 return this.product != null && !this.product.isEmpty(); 427 } 428 429 /** 430 * @param value {@link #product} (Identifies the type of vision correction product which is required for the patient.) 431 */ 432 public VisionPrescriptionLensSpecificationComponent setProduct(CodeableConcept value) { 433 this.product = value; 434 return this; 435 } 436 437 /** 438 * @return {@link #eye} (The eye for which the lens specification applies.). This is the underlying object with id, value and extensions. The accessor "getEye" gives direct access to the value 439 */ 440 public Enumeration<VisionEyes> getEyeElement() { 441 if (this.eye == null) 442 if (Configuration.errorOnAutoCreate()) 443 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.eye"); 444 else if (Configuration.doAutoCreate()) 445 this.eye = new Enumeration<VisionEyes>(new VisionEyesEnumFactory()); // bb 446 return this.eye; 447 } 448 449 public boolean hasEyeElement() { 450 return this.eye != null && !this.eye.isEmpty(); 451 } 452 453 public boolean hasEye() { 454 return this.eye != null && !this.eye.isEmpty(); 455 } 456 457 /** 458 * @param value {@link #eye} (The eye for which the lens specification applies.). This is the underlying object with id, value and extensions. The accessor "getEye" gives direct access to the value 459 */ 460 public VisionPrescriptionLensSpecificationComponent setEyeElement(Enumeration<VisionEyes> value) { 461 this.eye = value; 462 return this; 463 } 464 465 /** 466 * @return The eye for which the lens specification applies. 467 */ 468 public VisionEyes getEye() { 469 return this.eye == null ? null : this.eye.getValue(); 470 } 471 472 /** 473 * @param value The eye for which the lens specification applies. 474 */ 475 public VisionPrescriptionLensSpecificationComponent setEye(VisionEyes value) { 476 if (this.eye == null) 477 this.eye = new Enumeration<VisionEyes>(new VisionEyesEnumFactory()); 478 this.eye.setValue(value); 479 return this; 480 } 481 482 /** 483 * @return {@link #sphere} (Lens power measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getSphere" gives direct access to the value 484 */ 485 public DecimalType getSphereElement() { 486 if (this.sphere == null) 487 if (Configuration.errorOnAutoCreate()) 488 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.sphere"); 489 else if (Configuration.doAutoCreate()) 490 this.sphere = new DecimalType(); // bb 491 return this.sphere; 492 } 493 494 public boolean hasSphereElement() { 495 return this.sphere != null && !this.sphere.isEmpty(); 496 } 497 498 public boolean hasSphere() { 499 return this.sphere != null && !this.sphere.isEmpty(); 500 } 501 502 /** 503 * @param value {@link #sphere} (Lens power measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getSphere" gives direct access to the value 504 */ 505 public VisionPrescriptionLensSpecificationComponent setSphereElement(DecimalType value) { 506 this.sphere = value; 507 return this; 508 } 509 510 /** 511 * @return Lens power measured in dioptres (0.25 units). 512 */ 513 public BigDecimal getSphere() { 514 return this.sphere == null ? null : this.sphere.getValue(); 515 } 516 517 /** 518 * @param value Lens power measured in dioptres (0.25 units). 519 */ 520 public VisionPrescriptionLensSpecificationComponent setSphere(BigDecimal value) { 521 if (value == null) 522 this.sphere = null; 523 else { 524 if (this.sphere == null) 525 this.sphere = new DecimalType(); 526 this.sphere.setValue(value); 527 } 528 return this; 529 } 530 531 /** 532 * @param value Lens power measured in dioptres (0.25 units). 533 */ 534 public VisionPrescriptionLensSpecificationComponent setSphere(long value) { 535 this.sphere = new DecimalType(); 536 this.sphere.setValue(value); 537 return this; 538 } 539 540 /** 541 * @param value Lens power measured in dioptres (0.25 units). 542 */ 543 public VisionPrescriptionLensSpecificationComponent setSphere(double value) { 544 this.sphere = new DecimalType(); 545 this.sphere.setValue(value); 546 return this; 547 } 548 549 /** 550 * @return {@link #cylinder} (Power adjustment for astigmatism measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getCylinder" gives direct access to the value 551 */ 552 public DecimalType getCylinderElement() { 553 if (this.cylinder == null) 554 if (Configuration.errorOnAutoCreate()) 555 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.cylinder"); 556 else if (Configuration.doAutoCreate()) 557 this.cylinder = new DecimalType(); // bb 558 return this.cylinder; 559 } 560 561 public boolean hasCylinderElement() { 562 return this.cylinder != null && !this.cylinder.isEmpty(); 563 } 564 565 public boolean hasCylinder() { 566 return this.cylinder != null && !this.cylinder.isEmpty(); 567 } 568 569 /** 570 * @param value {@link #cylinder} (Power adjustment for astigmatism measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getCylinder" gives direct access to the value 571 */ 572 public VisionPrescriptionLensSpecificationComponent setCylinderElement(DecimalType value) { 573 this.cylinder = value; 574 return this; 575 } 576 577 /** 578 * @return Power adjustment for astigmatism measured in dioptres (0.25 units). 579 */ 580 public BigDecimal getCylinder() { 581 return this.cylinder == null ? null : this.cylinder.getValue(); 582 } 583 584 /** 585 * @param value Power adjustment for astigmatism measured in dioptres (0.25 units). 586 */ 587 public VisionPrescriptionLensSpecificationComponent setCylinder(BigDecimal value) { 588 if (value == null) 589 this.cylinder = null; 590 else { 591 if (this.cylinder == null) 592 this.cylinder = new DecimalType(); 593 this.cylinder.setValue(value); 594 } 595 return this; 596 } 597 598 /** 599 * @param value Power adjustment for astigmatism measured in dioptres (0.25 units). 600 */ 601 public VisionPrescriptionLensSpecificationComponent setCylinder(long value) { 602 this.cylinder = new DecimalType(); 603 this.cylinder.setValue(value); 604 return this; 605 } 606 607 /** 608 * @param value Power adjustment for astigmatism measured in dioptres (0.25 units). 609 */ 610 public VisionPrescriptionLensSpecificationComponent setCylinder(double value) { 611 this.cylinder = new DecimalType(); 612 this.cylinder.setValue(value); 613 return this; 614 } 615 616 /** 617 * @return {@link #axis} (Adjustment for astigmatism measured in integer degrees.). This is the underlying object with id, value and extensions. The accessor "getAxis" gives direct access to the value 618 */ 619 public IntegerType getAxisElement() { 620 if (this.axis == null) 621 if (Configuration.errorOnAutoCreate()) 622 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.axis"); 623 else if (Configuration.doAutoCreate()) 624 this.axis = new IntegerType(); // bb 625 return this.axis; 626 } 627 628 public boolean hasAxisElement() { 629 return this.axis != null && !this.axis.isEmpty(); 630 } 631 632 public boolean hasAxis() { 633 return this.axis != null && !this.axis.isEmpty(); 634 } 635 636 /** 637 * @param value {@link #axis} (Adjustment for astigmatism measured in integer degrees.). This is the underlying object with id, value and extensions. The accessor "getAxis" gives direct access to the value 638 */ 639 public VisionPrescriptionLensSpecificationComponent setAxisElement(IntegerType value) { 640 this.axis = value; 641 return this; 642 } 643 644 /** 645 * @return Adjustment for astigmatism measured in integer degrees. 646 */ 647 public int getAxis() { 648 return this.axis == null || this.axis.isEmpty() ? 0 : this.axis.getValue(); 649 } 650 651 /** 652 * @param value Adjustment for astigmatism measured in integer degrees. 653 */ 654 public VisionPrescriptionLensSpecificationComponent setAxis(int value) { 655 if (this.axis == null) 656 this.axis = new IntegerType(); 657 this.axis.setValue(value); 658 return this; 659 } 660 661 /** 662 * @return {@link #prism} (Allows for adjustment on two axis.) 663 */ 664 public List<PrismComponent> getPrism() { 665 if (this.prism == null) 666 this.prism = new ArrayList<PrismComponent>(); 667 return this.prism; 668 } 669 670 /** 671 * @return Returns a reference to <code>this</code> for easy method chaining 672 */ 673 public VisionPrescriptionLensSpecificationComponent setPrism(List<PrismComponent> thePrism) { 674 this.prism = thePrism; 675 return this; 676 } 677 678 public boolean hasPrism() { 679 if (this.prism == null) 680 return false; 681 for (PrismComponent item : this.prism) 682 if (!item.isEmpty()) 683 return true; 684 return false; 685 } 686 687 public PrismComponent addPrism() { //3 688 PrismComponent t = new PrismComponent(); 689 if (this.prism == null) 690 this.prism = new ArrayList<PrismComponent>(); 691 this.prism.add(t); 692 return t; 693 } 694 695 public VisionPrescriptionLensSpecificationComponent addPrism(PrismComponent t) { //3 696 if (t == null) 697 return this; 698 if (this.prism == null) 699 this.prism = new ArrayList<PrismComponent>(); 700 this.prism.add(t); 701 return this; 702 } 703 704 /** 705 * @return The first repetition of repeating field {@link #prism}, creating it if it does not already exist {3} 706 */ 707 public PrismComponent getPrismFirstRep() { 708 if (getPrism().isEmpty()) { 709 addPrism(); 710 } 711 return getPrism().get(0); 712 } 713 714 /** 715 * @return {@link #add} (Power adjustment for multifocal lenses measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getAdd" gives direct access to the value 716 */ 717 public DecimalType getAddElement() { 718 if (this.add == null) 719 if (Configuration.errorOnAutoCreate()) 720 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.add"); 721 else if (Configuration.doAutoCreate()) 722 this.add = new DecimalType(); // bb 723 return this.add; 724 } 725 726 public boolean hasAddElement() { 727 return this.add != null && !this.add.isEmpty(); 728 } 729 730 public boolean hasAdd() { 731 return this.add != null && !this.add.isEmpty(); 732 } 733 734 /** 735 * @param value {@link #add} (Power adjustment for multifocal lenses measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getAdd" gives direct access to the value 736 */ 737 public VisionPrescriptionLensSpecificationComponent setAddElement(DecimalType value) { 738 this.add = value; 739 return this; 740 } 741 742 /** 743 * @return Power adjustment for multifocal lenses measured in dioptres (0.25 units). 744 */ 745 public BigDecimal getAdd() { 746 return this.add == null ? null : this.add.getValue(); 747 } 748 749 /** 750 * @param value Power adjustment for multifocal lenses measured in dioptres (0.25 units). 751 */ 752 public VisionPrescriptionLensSpecificationComponent setAdd(BigDecimal value) { 753 if (value == null) 754 this.add = null; 755 else { 756 if (this.add == null) 757 this.add = new DecimalType(); 758 this.add.setValue(value); 759 } 760 return this; 761 } 762 763 /** 764 * @param value Power adjustment for multifocal lenses measured in dioptres (0.25 units). 765 */ 766 public VisionPrescriptionLensSpecificationComponent setAdd(long value) { 767 this.add = new DecimalType(); 768 this.add.setValue(value); 769 return this; 770 } 771 772 /** 773 * @param value Power adjustment for multifocal lenses measured in dioptres (0.25 units). 774 */ 775 public VisionPrescriptionLensSpecificationComponent setAdd(double value) { 776 this.add = new DecimalType(); 777 this.add.setValue(value); 778 return this; 779 } 780 781 /** 782 * @return {@link #power} (Contact lens power measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getPower" gives direct access to the value 783 */ 784 public DecimalType getPowerElement() { 785 if (this.power == null) 786 if (Configuration.errorOnAutoCreate()) 787 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.power"); 788 else if (Configuration.doAutoCreate()) 789 this.power = new DecimalType(); // bb 790 return this.power; 791 } 792 793 public boolean hasPowerElement() { 794 return this.power != null && !this.power.isEmpty(); 795 } 796 797 public boolean hasPower() { 798 return this.power != null && !this.power.isEmpty(); 799 } 800 801 /** 802 * @param value {@link #power} (Contact lens power measured in dioptres (0.25 units).). This is the underlying object with id, value and extensions. The accessor "getPower" gives direct access to the value 803 */ 804 public VisionPrescriptionLensSpecificationComponent setPowerElement(DecimalType value) { 805 this.power = value; 806 return this; 807 } 808 809 /** 810 * @return Contact lens power measured in dioptres (0.25 units). 811 */ 812 public BigDecimal getPower() { 813 return this.power == null ? null : this.power.getValue(); 814 } 815 816 /** 817 * @param value Contact lens power measured in dioptres (0.25 units). 818 */ 819 public VisionPrescriptionLensSpecificationComponent setPower(BigDecimal value) { 820 if (value == null) 821 this.power = null; 822 else { 823 if (this.power == null) 824 this.power = new DecimalType(); 825 this.power.setValue(value); 826 } 827 return this; 828 } 829 830 /** 831 * @param value Contact lens power measured in dioptres (0.25 units). 832 */ 833 public VisionPrescriptionLensSpecificationComponent setPower(long value) { 834 this.power = new DecimalType(); 835 this.power.setValue(value); 836 return this; 837 } 838 839 /** 840 * @param value Contact lens power measured in dioptres (0.25 units). 841 */ 842 public VisionPrescriptionLensSpecificationComponent setPower(double value) { 843 this.power = new DecimalType(); 844 this.power.setValue(value); 845 return this; 846 } 847 848 /** 849 * @return {@link #backCurve} (Back curvature measured in millimetres.). This is the underlying object with id, value and extensions. The accessor "getBackCurve" gives direct access to the value 850 */ 851 public DecimalType getBackCurveElement() { 852 if (this.backCurve == null) 853 if (Configuration.errorOnAutoCreate()) 854 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.backCurve"); 855 else if (Configuration.doAutoCreate()) 856 this.backCurve = new DecimalType(); // bb 857 return this.backCurve; 858 } 859 860 public boolean hasBackCurveElement() { 861 return this.backCurve != null && !this.backCurve.isEmpty(); 862 } 863 864 public boolean hasBackCurve() { 865 return this.backCurve != null && !this.backCurve.isEmpty(); 866 } 867 868 /** 869 * @param value {@link #backCurve} (Back curvature measured in millimetres.). This is the underlying object with id, value and extensions. The accessor "getBackCurve" gives direct access to the value 870 */ 871 public VisionPrescriptionLensSpecificationComponent setBackCurveElement(DecimalType value) { 872 this.backCurve = value; 873 return this; 874 } 875 876 /** 877 * @return Back curvature measured in millimetres. 878 */ 879 public BigDecimal getBackCurve() { 880 return this.backCurve == null ? null : this.backCurve.getValue(); 881 } 882 883 /** 884 * @param value Back curvature measured in millimetres. 885 */ 886 public VisionPrescriptionLensSpecificationComponent setBackCurve(BigDecimal value) { 887 if (value == null) 888 this.backCurve = null; 889 else { 890 if (this.backCurve == null) 891 this.backCurve = new DecimalType(); 892 this.backCurve.setValue(value); 893 } 894 return this; 895 } 896 897 /** 898 * @param value Back curvature measured in millimetres. 899 */ 900 public VisionPrescriptionLensSpecificationComponent setBackCurve(long value) { 901 this.backCurve = new DecimalType(); 902 this.backCurve.setValue(value); 903 return this; 904 } 905 906 /** 907 * @param value Back curvature measured in millimetres. 908 */ 909 public VisionPrescriptionLensSpecificationComponent setBackCurve(double value) { 910 this.backCurve = new DecimalType(); 911 this.backCurve.setValue(value); 912 return this; 913 } 914 915 /** 916 * @return {@link #diameter} (Contact lens diameter measured in millimetres.). This is the underlying object with id, value and extensions. The accessor "getDiameter" gives direct access to the value 917 */ 918 public DecimalType getDiameterElement() { 919 if (this.diameter == null) 920 if (Configuration.errorOnAutoCreate()) 921 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.diameter"); 922 else if (Configuration.doAutoCreate()) 923 this.diameter = new DecimalType(); // bb 924 return this.diameter; 925 } 926 927 public boolean hasDiameterElement() { 928 return this.diameter != null && !this.diameter.isEmpty(); 929 } 930 931 public boolean hasDiameter() { 932 return this.diameter != null && !this.diameter.isEmpty(); 933 } 934 935 /** 936 * @param value {@link #diameter} (Contact lens diameter measured in millimetres.). This is the underlying object with id, value and extensions. The accessor "getDiameter" gives direct access to the value 937 */ 938 public VisionPrescriptionLensSpecificationComponent setDiameterElement(DecimalType value) { 939 this.diameter = value; 940 return this; 941 } 942 943 /** 944 * @return Contact lens diameter measured in millimetres. 945 */ 946 public BigDecimal getDiameter() { 947 return this.diameter == null ? null : this.diameter.getValue(); 948 } 949 950 /** 951 * @param value Contact lens diameter measured in millimetres. 952 */ 953 public VisionPrescriptionLensSpecificationComponent setDiameter(BigDecimal value) { 954 if (value == null) 955 this.diameter = null; 956 else { 957 if (this.diameter == null) 958 this.diameter = new DecimalType(); 959 this.diameter.setValue(value); 960 } 961 return this; 962 } 963 964 /** 965 * @param value Contact lens diameter measured in millimetres. 966 */ 967 public VisionPrescriptionLensSpecificationComponent setDiameter(long value) { 968 this.diameter = new DecimalType(); 969 this.diameter.setValue(value); 970 return this; 971 } 972 973 /** 974 * @param value Contact lens diameter measured in millimetres. 975 */ 976 public VisionPrescriptionLensSpecificationComponent setDiameter(double value) { 977 this.diameter = new DecimalType(); 978 this.diameter.setValue(value); 979 return this; 980 } 981 982 /** 983 * @return {@link #duration} (The recommended maximum wear period for the lens.) 984 */ 985 public Quantity getDuration() { 986 if (this.duration == null) 987 if (Configuration.errorOnAutoCreate()) 988 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.duration"); 989 else if (Configuration.doAutoCreate()) 990 this.duration = new Quantity(); // cc 991 return this.duration; 992 } 993 994 public boolean hasDuration() { 995 return this.duration != null && !this.duration.isEmpty(); 996 } 997 998 /** 999 * @param value {@link #duration} (The recommended maximum wear period for the lens.) 1000 */ 1001 public VisionPrescriptionLensSpecificationComponent setDuration(Quantity value) { 1002 this.duration = value; 1003 return this; 1004 } 1005 1006 /** 1007 * @return {@link #color} (Special color or pattern.). This is the underlying object with id, value and extensions. The accessor "getColor" gives direct access to the value 1008 */ 1009 public StringType getColorElement() { 1010 if (this.color == null) 1011 if (Configuration.errorOnAutoCreate()) 1012 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.color"); 1013 else if (Configuration.doAutoCreate()) 1014 this.color = new StringType(); // bb 1015 return this.color; 1016 } 1017 1018 public boolean hasColorElement() { 1019 return this.color != null && !this.color.isEmpty(); 1020 } 1021 1022 public boolean hasColor() { 1023 return this.color != null && !this.color.isEmpty(); 1024 } 1025 1026 /** 1027 * @param value {@link #color} (Special color or pattern.). This is the underlying object with id, value and extensions. The accessor "getColor" gives direct access to the value 1028 */ 1029 public VisionPrescriptionLensSpecificationComponent setColorElement(StringType value) { 1030 this.color = value; 1031 return this; 1032 } 1033 1034 /** 1035 * @return Special color or pattern. 1036 */ 1037 public String getColor() { 1038 return this.color == null ? null : this.color.getValue(); 1039 } 1040 1041 /** 1042 * @param value Special color or pattern. 1043 */ 1044 public VisionPrescriptionLensSpecificationComponent setColor(String value) { 1045 if (Utilities.noString(value)) 1046 this.color = null; 1047 else { 1048 if (this.color == null) 1049 this.color = new StringType(); 1050 this.color.setValue(value); 1051 } 1052 return this; 1053 } 1054 1055 /** 1056 * @return {@link #brand} (Brand recommendations or restrictions.). This is the underlying object with id, value and extensions. The accessor "getBrand" gives direct access to the value 1057 */ 1058 public StringType getBrandElement() { 1059 if (this.brand == null) 1060 if (Configuration.errorOnAutoCreate()) 1061 throw new Error("Attempt to auto-create VisionPrescriptionLensSpecificationComponent.brand"); 1062 else if (Configuration.doAutoCreate()) 1063 this.brand = new StringType(); // bb 1064 return this.brand; 1065 } 1066 1067 public boolean hasBrandElement() { 1068 return this.brand != null && !this.brand.isEmpty(); 1069 } 1070 1071 public boolean hasBrand() { 1072 return this.brand != null && !this.brand.isEmpty(); 1073 } 1074 1075 /** 1076 * @param value {@link #brand} (Brand recommendations or restrictions.). This is the underlying object with id, value and extensions. The accessor "getBrand" gives direct access to the value 1077 */ 1078 public VisionPrescriptionLensSpecificationComponent setBrandElement(StringType value) { 1079 this.brand = value; 1080 return this; 1081 } 1082 1083 /** 1084 * @return Brand recommendations or restrictions. 1085 */ 1086 public String getBrand() { 1087 return this.brand == null ? null : this.brand.getValue(); 1088 } 1089 1090 /** 1091 * @param value Brand recommendations or restrictions. 1092 */ 1093 public VisionPrescriptionLensSpecificationComponent setBrand(String value) { 1094 if (Utilities.noString(value)) 1095 this.brand = null; 1096 else { 1097 if (this.brand == null) 1098 this.brand = new StringType(); 1099 this.brand.setValue(value); 1100 } 1101 return this; 1102 } 1103 1104 /** 1105 * @return {@link #note} (Notes for special requirements such as coatings and lens materials.) 1106 */ 1107 public List<Annotation> getNote() { 1108 if (this.note == null) 1109 this.note = new ArrayList<Annotation>(); 1110 return this.note; 1111 } 1112 1113 /** 1114 * @return Returns a reference to <code>this</code> for easy method chaining 1115 */ 1116 public VisionPrescriptionLensSpecificationComponent setNote(List<Annotation> theNote) { 1117 this.note = theNote; 1118 return this; 1119 } 1120 1121 public boolean hasNote() { 1122 if (this.note == null) 1123 return false; 1124 for (Annotation item : this.note) 1125 if (!item.isEmpty()) 1126 return true; 1127 return false; 1128 } 1129 1130 public Annotation addNote() { //3 1131 Annotation t = new Annotation(); 1132 if (this.note == null) 1133 this.note = new ArrayList<Annotation>(); 1134 this.note.add(t); 1135 return t; 1136 } 1137 1138 public VisionPrescriptionLensSpecificationComponent addNote(Annotation t) { //3 1139 if (t == null) 1140 return this; 1141 if (this.note == null) 1142 this.note = new ArrayList<Annotation>(); 1143 this.note.add(t); 1144 return this; 1145 } 1146 1147 /** 1148 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 1149 */ 1150 public Annotation getNoteFirstRep() { 1151 if (getNote().isEmpty()) { 1152 addNote(); 1153 } 1154 return getNote().get(0); 1155 } 1156 1157 protected void listChildren(List<Property> children) { 1158 super.listChildren(children); 1159 children.add(new Property("product", "CodeableConcept", "Identifies the type of vision correction product which is required for the patient.", 0, 1, product)); 1160 children.add(new Property("eye", "code", "The eye for which the lens specification applies.", 0, 1, eye)); 1161 children.add(new Property("sphere", "decimal", "Lens power measured in dioptres (0.25 units).", 0, 1, sphere)); 1162 children.add(new Property("cylinder", "decimal", "Power adjustment for astigmatism measured in dioptres (0.25 units).", 0, 1, cylinder)); 1163 children.add(new Property("axis", "integer", "Adjustment for astigmatism measured in integer degrees.", 0, 1, axis)); 1164 children.add(new Property("prism", "", "Allows for adjustment on two axis.", 0, java.lang.Integer.MAX_VALUE, prism)); 1165 children.add(new Property("add", "decimal", "Power adjustment for multifocal lenses measured in dioptres (0.25 units).", 0, 1, add)); 1166 children.add(new Property("power", "decimal", "Contact lens power measured in dioptres (0.25 units).", 0, 1, power)); 1167 children.add(new Property("backCurve", "decimal", "Back curvature measured in millimetres.", 0, 1, backCurve)); 1168 children.add(new Property("diameter", "decimal", "Contact lens diameter measured in millimetres.", 0, 1, diameter)); 1169 children.add(new Property("duration", "Quantity", "The recommended maximum wear period for the lens.", 0, 1, duration)); 1170 children.add(new Property("color", "string", "Special color or pattern.", 0, 1, color)); 1171 children.add(new Property("brand", "string", "Brand recommendations or restrictions.", 0, 1, brand)); 1172 children.add(new Property("note", "Annotation", "Notes for special requirements such as coatings and lens materials.", 0, java.lang.Integer.MAX_VALUE, note)); 1173 } 1174 1175 @Override 1176 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1177 switch (_hash) { 1178 case -309474065: /*product*/ return new Property("product", "CodeableConcept", "Identifies the type of vision correction product which is required for the patient.", 0, 1, product); 1179 case 100913: /*eye*/ return new Property("eye", "code", "The eye for which the lens specification applies.", 0, 1, eye); 1180 case -895981619: /*sphere*/ return new Property("sphere", "decimal", "Lens power measured in dioptres (0.25 units).", 0, 1, sphere); 1181 case -349378602: /*cylinder*/ return new Property("cylinder", "decimal", "Power adjustment for astigmatism measured in dioptres (0.25 units).", 0, 1, cylinder); 1182 case 3008417: /*axis*/ return new Property("axis", "integer", "Adjustment for astigmatism measured in integer degrees.", 0, 1, axis); 1183 case 106935105: /*prism*/ return new Property("prism", "", "Allows for adjustment on two axis.", 0, java.lang.Integer.MAX_VALUE, prism); 1184 case 96417: /*add*/ return new Property("add", "decimal", "Power adjustment for multifocal lenses measured in dioptres (0.25 units).", 0, 1, add); 1185 case 106858757: /*power*/ return new Property("power", "decimal", "Contact lens power measured in dioptres (0.25 units).", 0, 1, power); 1186 case 1309344840: /*backCurve*/ return new Property("backCurve", "decimal", "Back curvature measured in millimetres.", 0, 1, backCurve); 1187 case -233204595: /*diameter*/ return new Property("diameter", "decimal", "Contact lens diameter measured in millimetres.", 0, 1, diameter); 1188 case -1992012396: /*duration*/ return new Property("duration", "Quantity", "The recommended maximum wear period for the lens.", 0, 1, duration); 1189 case 94842723: /*color*/ return new Property("color", "string", "Special color or pattern.", 0, 1, color); 1190 case 93997959: /*brand*/ return new Property("brand", "string", "Brand recommendations or restrictions.", 0, 1, brand); 1191 case 3387378: /*note*/ return new Property("note", "Annotation", "Notes for special requirements such as coatings and lens materials.", 0, java.lang.Integer.MAX_VALUE, note); 1192 default: return super.getNamedProperty(_hash, _name, _checkValid); 1193 } 1194 1195 } 1196 1197 @Override 1198 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1199 switch (hash) { 1200 case -309474065: /*product*/ return this.product == null ? new Base[0] : new Base[] {this.product}; // CodeableConcept 1201 case 100913: /*eye*/ return this.eye == null ? new Base[0] : new Base[] {this.eye}; // Enumeration<VisionEyes> 1202 case -895981619: /*sphere*/ return this.sphere == null ? new Base[0] : new Base[] {this.sphere}; // DecimalType 1203 case -349378602: /*cylinder*/ return this.cylinder == null ? new Base[0] : new Base[] {this.cylinder}; // DecimalType 1204 case 3008417: /*axis*/ return this.axis == null ? new Base[0] : new Base[] {this.axis}; // IntegerType 1205 case 106935105: /*prism*/ return this.prism == null ? new Base[0] : this.prism.toArray(new Base[this.prism.size()]); // PrismComponent 1206 case 96417: /*add*/ return this.add == null ? new Base[0] : new Base[] {this.add}; // DecimalType 1207 case 106858757: /*power*/ return this.power == null ? new Base[0] : new Base[] {this.power}; // DecimalType 1208 case 1309344840: /*backCurve*/ return this.backCurve == null ? new Base[0] : new Base[] {this.backCurve}; // DecimalType 1209 case -233204595: /*diameter*/ return this.diameter == null ? new Base[0] : new Base[] {this.diameter}; // DecimalType 1210 case -1992012396: /*duration*/ return this.duration == null ? new Base[0] : new Base[] {this.duration}; // Quantity 1211 case 94842723: /*color*/ return this.color == null ? new Base[0] : new Base[] {this.color}; // StringType 1212 case 93997959: /*brand*/ return this.brand == null ? new Base[0] : new Base[] {this.brand}; // StringType 1213 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 1214 default: return super.getProperty(hash, name, checkValid); 1215 } 1216 1217 } 1218 1219 @Override 1220 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1221 switch (hash) { 1222 case -309474065: // product 1223 this.product = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1224 return value; 1225 case 100913: // eye 1226 value = new VisionEyesEnumFactory().fromType(TypeConvertor.castToCode(value)); 1227 this.eye = (Enumeration) value; // Enumeration<VisionEyes> 1228 return value; 1229 case -895981619: // sphere 1230 this.sphere = TypeConvertor.castToDecimal(value); // DecimalType 1231 return value; 1232 case -349378602: // cylinder 1233 this.cylinder = TypeConvertor.castToDecimal(value); // DecimalType 1234 return value; 1235 case 3008417: // axis 1236 this.axis = TypeConvertor.castToInteger(value); // IntegerType 1237 return value; 1238 case 106935105: // prism 1239 this.getPrism().add((PrismComponent) value); // PrismComponent 1240 return value; 1241 case 96417: // add 1242 this.add = TypeConvertor.castToDecimal(value); // DecimalType 1243 return value; 1244 case 106858757: // power 1245 this.power = TypeConvertor.castToDecimal(value); // DecimalType 1246 return value; 1247 case 1309344840: // backCurve 1248 this.backCurve = TypeConvertor.castToDecimal(value); // DecimalType 1249 return value; 1250 case -233204595: // diameter 1251 this.diameter = TypeConvertor.castToDecimal(value); // DecimalType 1252 return value; 1253 case -1992012396: // duration 1254 this.duration = TypeConvertor.castToQuantity(value); // Quantity 1255 return value; 1256 case 94842723: // color 1257 this.color = TypeConvertor.castToString(value); // StringType 1258 return value; 1259 case 93997959: // brand 1260 this.brand = TypeConvertor.castToString(value); // StringType 1261 return value; 1262 case 3387378: // note 1263 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 1264 return value; 1265 default: return super.setProperty(hash, name, value); 1266 } 1267 1268 } 1269 1270 @Override 1271 public Base setProperty(String name, Base value) throws FHIRException { 1272 if (name.equals("product")) { 1273 this.product = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1274 } else if (name.equals("eye")) { 1275 value = new VisionEyesEnumFactory().fromType(TypeConvertor.castToCode(value)); 1276 this.eye = (Enumeration) value; // Enumeration<VisionEyes> 1277 } else if (name.equals("sphere")) { 1278 this.sphere = TypeConvertor.castToDecimal(value); // DecimalType 1279 } else if (name.equals("cylinder")) { 1280 this.cylinder = TypeConvertor.castToDecimal(value); // DecimalType 1281 } else if (name.equals("axis")) { 1282 this.axis = TypeConvertor.castToInteger(value); // IntegerType 1283 } else if (name.equals("prism")) { 1284 this.getPrism().add((PrismComponent) value); 1285 } else if (name.equals("add")) { 1286 this.add = TypeConvertor.castToDecimal(value); // DecimalType 1287 } else if (name.equals("power")) { 1288 this.power = TypeConvertor.castToDecimal(value); // DecimalType 1289 } else if (name.equals("backCurve")) { 1290 this.backCurve = TypeConvertor.castToDecimal(value); // DecimalType 1291 } else if (name.equals("diameter")) { 1292 this.diameter = TypeConvertor.castToDecimal(value); // DecimalType 1293 } else if (name.equals("duration")) { 1294 this.duration = TypeConvertor.castToQuantity(value); // Quantity 1295 } else if (name.equals("color")) { 1296 this.color = TypeConvertor.castToString(value); // StringType 1297 } else if (name.equals("brand")) { 1298 this.brand = TypeConvertor.castToString(value); // StringType 1299 } else if (name.equals("note")) { 1300 this.getNote().add(TypeConvertor.castToAnnotation(value)); 1301 } else 1302 return super.setProperty(name, value); 1303 return value; 1304 } 1305 1306 @Override 1307 public Base makeProperty(int hash, String name) throws FHIRException { 1308 switch (hash) { 1309 case -309474065: return getProduct(); 1310 case 100913: return getEyeElement(); 1311 case -895981619: return getSphereElement(); 1312 case -349378602: return getCylinderElement(); 1313 case 3008417: return getAxisElement(); 1314 case 106935105: return addPrism(); 1315 case 96417: return getAddElement(); 1316 case 106858757: return getPowerElement(); 1317 case 1309344840: return getBackCurveElement(); 1318 case -233204595: return getDiameterElement(); 1319 case -1992012396: return getDuration(); 1320 case 94842723: return getColorElement(); 1321 case 93997959: return getBrandElement(); 1322 case 3387378: return addNote(); 1323 default: return super.makeProperty(hash, name); 1324 } 1325 1326 } 1327 1328 @Override 1329 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1330 switch (hash) { 1331 case -309474065: /*product*/ return new String[] {"CodeableConcept"}; 1332 case 100913: /*eye*/ return new String[] {"code"}; 1333 case -895981619: /*sphere*/ return new String[] {"decimal"}; 1334 case -349378602: /*cylinder*/ return new String[] {"decimal"}; 1335 case 3008417: /*axis*/ return new String[] {"integer"}; 1336 case 106935105: /*prism*/ return new String[] {}; 1337 case 96417: /*add*/ return new String[] {"decimal"}; 1338 case 106858757: /*power*/ return new String[] {"decimal"}; 1339 case 1309344840: /*backCurve*/ return new String[] {"decimal"}; 1340 case -233204595: /*diameter*/ return new String[] {"decimal"}; 1341 case -1992012396: /*duration*/ return new String[] {"Quantity"}; 1342 case 94842723: /*color*/ return new String[] {"string"}; 1343 case 93997959: /*brand*/ return new String[] {"string"}; 1344 case 3387378: /*note*/ return new String[] {"Annotation"}; 1345 default: return super.getTypesForProperty(hash, name); 1346 } 1347 1348 } 1349 1350 @Override 1351 public Base addChild(String name) throws FHIRException { 1352 if (name.equals("product")) { 1353 this.product = new CodeableConcept(); 1354 return this.product; 1355 } 1356 else if (name.equals("eye")) { 1357 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.eye"); 1358 } 1359 else if (name.equals("sphere")) { 1360 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.sphere"); 1361 } 1362 else if (name.equals("cylinder")) { 1363 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.cylinder"); 1364 } 1365 else if (name.equals("axis")) { 1366 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.axis"); 1367 } 1368 else if (name.equals("prism")) { 1369 return addPrism(); 1370 } 1371 else if (name.equals("add")) { 1372 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.add"); 1373 } 1374 else if (name.equals("power")) { 1375 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.power"); 1376 } 1377 else if (name.equals("backCurve")) { 1378 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.backCurve"); 1379 } 1380 else if (name.equals("diameter")) { 1381 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.diameter"); 1382 } 1383 else if (name.equals("duration")) { 1384 this.duration = new Quantity(); 1385 return this.duration; 1386 } 1387 else if (name.equals("color")) { 1388 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.color"); 1389 } 1390 else if (name.equals("brand")) { 1391 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.brand"); 1392 } 1393 else if (name.equals("note")) { 1394 return addNote(); 1395 } 1396 else 1397 return super.addChild(name); 1398 } 1399 1400 public VisionPrescriptionLensSpecificationComponent copy() { 1401 VisionPrescriptionLensSpecificationComponent dst = new VisionPrescriptionLensSpecificationComponent(); 1402 copyValues(dst); 1403 return dst; 1404 } 1405 1406 public void copyValues(VisionPrescriptionLensSpecificationComponent dst) { 1407 super.copyValues(dst); 1408 dst.product = product == null ? null : product.copy(); 1409 dst.eye = eye == null ? null : eye.copy(); 1410 dst.sphere = sphere == null ? null : sphere.copy(); 1411 dst.cylinder = cylinder == null ? null : cylinder.copy(); 1412 dst.axis = axis == null ? null : axis.copy(); 1413 if (prism != null) { 1414 dst.prism = new ArrayList<PrismComponent>(); 1415 for (PrismComponent i : prism) 1416 dst.prism.add(i.copy()); 1417 }; 1418 dst.add = add == null ? null : add.copy(); 1419 dst.power = power == null ? null : power.copy(); 1420 dst.backCurve = backCurve == null ? null : backCurve.copy(); 1421 dst.diameter = diameter == null ? null : diameter.copy(); 1422 dst.duration = duration == null ? null : duration.copy(); 1423 dst.color = color == null ? null : color.copy(); 1424 dst.brand = brand == null ? null : brand.copy(); 1425 if (note != null) { 1426 dst.note = new ArrayList<Annotation>(); 1427 for (Annotation i : note) 1428 dst.note.add(i.copy()); 1429 }; 1430 } 1431 1432 @Override 1433 public boolean equalsDeep(Base other_) { 1434 if (!super.equalsDeep(other_)) 1435 return false; 1436 if (!(other_ instanceof VisionPrescriptionLensSpecificationComponent)) 1437 return false; 1438 VisionPrescriptionLensSpecificationComponent o = (VisionPrescriptionLensSpecificationComponent) other_; 1439 return compareDeep(product, o.product, true) && compareDeep(eye, o.eye, true) && compareDeep(sphere, o.sphere, true) 1440 && compareDeep(cylinder, o.cylinder, true) && compareDeep(axis, o.axis, true) && compareDeep(prism, o.prism, true) 1441 && compareDeep(add, o.add, true) && compareDeep(power, o.power, true) && compareDeep(backCurve, o.backCurve, true) 1442 && compareDeep(diameter, o.diameter, true) && compareDeep(duration, o.duration, true) && compareDeep(color, o.color, true) 1443 && compareDeep(brand, o.brand, true) && compareDeep(note, o.note, true); 1444 } 1445 1446 @Override 1447 public boolean equalsShallow(Base other_) { 1448 if (!super.equalsShallow(other_)) 1449 return false; 1450 if (!(other_ instanceof VisionPrescriptionLensSpecificationComponent)) 1451 return false; 1452 VisionPrescriptionLensSpecificationComponent o = (VisionPrescriptionLensSpecificationComponent) other_; 1453 return compareValues(eye, o.eye, true) && compareValues(sphere, o.sphere, true) && compareValues(cylinder, o.cylinder, true) 1454 && compareValues(axis, o.axis, true) && compareValues(add, o.add, true) && compareValues(power, o.power, true) 1455 && compareValues(backCurve, o.backCurve, true) && compareValues(diameter, o.diameter, true) && compareValues(color, o.color, true) 1456 && compareValues(brand, o.brand, true); 1457 } 1458 1459 public boolean isEmpty() { 1460 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(product, eye, sphere, cylinder 1461 , axis, prism, add, power, backCurve, diameter, duration, color, brand, note 1462 ); 1463 } 1464 1465 public String fhirType() { 1466 return "VisionPrescription.lensSpecification"; 1467 1468 } 1469 1470 } 1471 1472 @Block() 1473 public static class PrismComponent extends BackboneElement implements IBaseBackboneElement { 1474 /** 1475 * Amount of prism to compensate for eye alignment in fractional units. 1476 */ 1477 @Child(name = "amount", type = {DecimalType.class}, order=1, min=1, max=1, modifier=false, summary=false) 1478 @Description(shortDefinition="Amount of adjustment", formalDefinition="Amount of prism to compensate for eye alignment in fractional units." ) 1479 protected DecimalType amount; 1480 1481 /** 1482 * The relative base, or reference lens edge, for the prism. 1483 */ 1484 @Child(name = "base", type = {CodeType.class}, order=2, min=1, max=1, modifier=false, summary=false) 1485 @Description(shortDefinition="up | down | in | out", formalDefinition="The relative base, or reference lens edge, for the prism." ) 1486 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/vision-base-codes") 1487 protected Enumeration<VisionBase> base; 1488 1489 private static final long serialVersionUID = 1677247628L; 1490 1491 /** 1492 * Constructor 1493 */ 1494 public PrismComponent() { 1495 super(); 1496 } 1497 1498 /** 1499 * Constructor 1500 */ 1501 public PrismComponent(BigDecimal amount, VisionBase base) { 1502 super(); 1503 this.setAmount(amount); 1504 this.setBase(base); 1505 } 1506 1507 /** 1508 * @return {@link #amount} (Amount of prism to compensate for eye alignment in fractional units.). This is the underlying object with id, value and extensions. The accessor "getAmount" gives direct access to the value 1509 */ 1510 public DecimalType getAmountElement() { 1511 if (this.amount == null) 1512 if (Configuration.errorOnAutoCreate()) 1513 throw new Error("Attempt to auto-create PrismComponent.amount"); 1514 else if (Configuration.doAutoCreate()) 1515 this.amount = new DecimalType(); // bb 1516 return this.amount; 1517 } 1518 1519 public boolean hasAmountElement() { 1520 return this.amount != null && !this.amount.isEmpty(); 1521 } 1522 1523 public boolean hasAmount() { 1524 return this.amount != null && !this.amount.isEmpty(); 1525 } 1526 1527 /** 1528 * @param value {@link #amount} (Amount of prism to compensate for eye alignment in fractional units.). This is the underlying object with id, value and extensions. The accessor "getAmount" gives direct access to the value 1529 */ 1530 public PrismComponent setAmountElement(DecimalType value) { 1531 this.amount = value; 1532 return this; 1533 } 1534 1535 /** 1536 * @return Amount of prism to compensate for eye alignment in fractional units. 1537 */ 1538 public BigDecimal getAmount() { 1539 return this.amount == null ? null : this.amount.getValue(); 1540 } 1541 1542 /** 1543 * @param value Amount of prism to compensate for eye alignment in fractional units. 1544 */ 1545 public PrismComponent setAmount(BigDecimal value) { 1546 if (this.amount == null) 1547 this.amount = new DecimalType(); 1548 this.amount.setValue(value); 1549 return this; 1550 } 1551 1552 /** 1553 * @param value Amount of prism to compensate for eye alignment in fractional units. 1554 */ 1555 public PrismComponent setAmount(long value) { 1556 this.amount = new DecimalType(); 1557 this.amount.setValue(value); 1558 return this; 1559 } 1560 1561 /** 1562 * @param value Amount of prism to compensate for eye alignment in fractional units. 1563 */ 1564 public PrismComponent setAmount(double value) { 1565 this.amount = new DecimalType(); 1566 this.amount.setValue(value); 1567 return this; 1568 } 1569 1570 /** 1571 * @return {@link #base} (The relative base, or reference lens edge, for the prism.). This is the underlying object with id, value and extensions. The accessor "getBase" gives direct access to the value 1572 */ 1573 public Enumeration<VisionBase> getBaseElement() { 1574 if (this.base == null) 1575 if (Configuration.errorOnAutoCreate()) 1576 throw new Error("Attempt to auto-create PrismComponent.base"); 1577 else if (Configuration.doAutoCreate()) 1578 this.base = new Enumeration<VisionBase>(new VisionBaseEnumFactory()); // bb 1579 return this.base; 1580 } 1581 1582 public boolean hasBaseElement() { 1583 return this.base != null && !this.base.isEmpty(); 1584 } 1585 1586 public boolean hasBase() { 1587 return this.base != null && !this.base.isEmpty(); 1588 } 1589 1590 /** 1591 * @param value {@link #base} (The relative base, or reference lens edge, for the prism.). This is the underlying object with id, value and extensions. The accessor "getBase" gives direct access to the value 1592 */ 1593 public PrismComponent setBaseElement(Enumeration<VisionBase> value) { 1594 this.base = value; 1595 return this; 1596 } 1597 1598 /** 1599 * @return The relative base, or reference lens edge, for the prism. 1600 */ 1601 public VisionBase getBase() { 1602 return this.base == null ? null : this.base.getValue(); 1603 } 1604 1605 /** 1606 * @param value The relative base, or reference lens edge, for the prism. 1607 */ 1608 public PrismComponent setBase(VisionBase value) { 1609 if (this.base == null) 1610 this.base = new Enumeration<VisionBase>(new VisionBaseEnumFactory()); 1611 this.base.setValue(value); 1612 return this; 1613 } 1614 1615 protected void listChildren(List<Property> children) { 1616 super.listChildren(children); 1617 children.add(new Property("amount", "decimal", "Amount of prism to compensate for eye alignment in fractional units.", 0, 1, amount)); 1618 children.add(new Property("base", "code", "The relative base, or reference lens edge, for the prism.", 0, 1, base)); 1619 } 1620 1621 @Override 1622 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1623 switch (_hash) { 1624 case -1413853096: /*amount*/ return new Property("amount", "decimal", "Amount of prism to compensate for eye alignment in fractional units.", 0, 1, amount); 1625 case 3016401: /*base*/ return new Property("base", "code", "The relative base, or reference lens edge, for the prism.", 0, 1, base); 1626 default: return super.getNamedProperty(_hash, _name, _checkValid); 1627 } 1628 1629 } 1630 1631 @Override 1632 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1633 switch (hash) { 1634 case -1413853096: /*amount*/ return this.amount == null ? new Base[0] : new Base[] {this.amount}; // DecimalType 1635 case 3016401: /*base*/ return this.base == null ? new Base[0] : new Base[] {this.base}; // Enumeration<VisionBase> 1636 default: return super.getProperty(hash, name, checkValid); 1637 } 1638 1639 } 1640 1641 @Override 1642 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1643 switch (hash) { 1644 case -1413853096: // amount 1645 this.amount = TypeConvertor.castToDecimal(value); // DecimalType 1646 return value; 1647 case 3016401: // base 1648 value = new VisionBaseEnumFactory().fromType(TypeConvertor.castToCode(value)); 1649 this.base = (Enumeration) value; // Enumeration<VisionBase> 1650 return value; 1651 default: return super.setProperty(hash, name, value); 1652 } 1653 1654 } 1655 1656 @Override 1657 public Base setProperty(String name, Base value) throws FHIRException { 1658 if (name.equals("amount")) { 1659 this.amount = TypeConvertor.castToDecimal(value); // DecimalType 1660 } else if (name.equals("base")) { 1661 value = new VisionBaseEnumFactory().fromType(TypeConvertor.castToCode(value)); 1662 this.base = (Enumeration) value; // Enumeration<VisionBase> 1663 } else 1664 return super.setProperty(name, value); 1665 return value; 1666 } 1667 1668 @Override 1669 public Base makeProperty(int hash, String name) throws FHIRException { 1670 switch (hash) { 1671 case -1413853096: return getAmountElement(); 1672 case 3016401: return getBaseElement(); 1673 default: return super.makeProperty(hash, name); 1674 } 1675 1676 } 1677 1678 @Override 1679 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1680 switch (hash) { 1681 case -1413853096: /*amount*/ return new String[] {"decimal"}; 1682 case 3016401: /*base*/ return new String[] {"code"}; 1683 default: return super.getTypesForProperty(hash, name); 1684 } 1685 1686 } 1687 1688 @Override 1689 public Base addChild(String name) throws FHIRException { 1690 if (name.equals("amount")) { 1691 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.prism.amount"); 1692 } 1693 else if (name.equals("base")) { 1694 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.lensSpecification.prism.base"); 1695 } 1696 else 1697 return super.addChild(name); 1698 } 1699 1700 public PrismComponent copy() { 1701 PrismComponent dst = new PrismComponent(); 1702 copyValues(dst); 1703 return dst; 1704 } 1705 1706 public void copyValues(PrismComponent dst) { 1707 super.copyValues(dst); 1708 dst.amount = amount == null ? null : amount.copy(); 1709 dst.base = base == null ? null : base.copy(); 1710 } 1711 1712 @Override 1713 public boolean equalsDeep(Base other_) { 1714 if (!super.equalsDeep(other_)) 1715 return false; 1716 if (!(other_ instanceof PrismComponent)) 1717 return false; 1718 PrismComponent o = (PrismComponent) other_; 1719 return compareDeep(amount, o.amount, true) && compareDeep(base, o.base, true); 1720 } 1721 1722 @Override 1723 public boolean equalsShallow(Base other_) { 1724 if (!super.equalsShallow(other_)) 1725 return false; 1726 if (!(other_ instanceof PrismComponent)) 1727 return false; 1728 PrismComponent o = (PrismComponent) other_; 1729 return compareValues(amount, o.amount, true) && compareValues(base, o.base, true); 1730 } 1731 1732 public boolean isEmpty() { 1733 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(amount, base); 1734 } 1735 1736 public String fhirType() { 1737 return "VisionPrescription.lensSpecification.prism"; 1738 1739 } 1740 1741 } 1742 1743 /** 1744 * A unique identifier assigned to this vision prescription. 1745 */ 1746 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1747 @Description(shortDefinition="Business Identifier for vision prescription", formalDefinition="A unique identifier assigned to this vision prescription." ) 1748 protected List<Identifier> identifier; 1749 1750 /** 1751 * The status of the resource instance. 1752 */ 1753 @Child(name = "status", type = {CodeType.class}, order=1, min=1, max=1, modifier=true, summary=true) 1754 @Description(shortDefinition="active | cancelled | draft | entered-in-error", formalDefinition="The status of the resource instance." ) 1755 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/fm-status") 1756 protected Enumeration<FinancialResourceStatusCodes> status; 1757 1758 /** 1759 * The date this resource was created. 1760 */ 1761 @Child(name = "created", type = {DateTimeType.class}, order=2, min=1, max=1, modifier=false, summary=true) 1762 @Description(shortDefinition="Response creation date", formalDefinition="The date this resource was created." ) 1763 protected DateTimeType created; 1764 1765 /** 1766 * A resource reference to the person to whom the vision prescription applies. 1767 */ 1768 @Child(name = "patient", type = {Patient.class}, order=3, min=1, max=1, modifier=false, summary=true) 1769 @Description(shortDefinition="Who prescription is for", formalDefinition="A resource reference to the person to whom the vision prescription applies." ) 1770 protected Reference patient; 1771 1772 /** 1773 * A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued. 1774 */ 1775 @Child(name = "encounter", type = {Encounter.class}, order=4, min=0, max=1, modifier=false, summary=false) 1776 @Description(shortDefinition="Created during encounter / admission / stay", formalDefinition="A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued." ) 1777 protected Reference encounter; 1778 1779 /** 1780 * The date (and perhaps time) when the prescription was written. 1781 */ 1782 @Child(name = "dateWritten", type = {DateTimeType.class}, order=5, min=1, max=1, modifier=false, summary=true) 1783 @Description(shortDefinition="When prescription was authorized", formalDefinition="The date (and perhaps time) when the prescription was written." ) 1784 protected DateTimeType dateWritten; 1785 1786 /** 1787 * The healthcare professional responsible for authorizing the prescription. 1788 */ 1789 @Child(name = "prescriber", type = {Practitioner.class, PractitionerRole.class}, order=6, min=1, max=1, modifier=false, summary=true) 1790 @Description(shortDefinition="Who authorized the vision prescription", formalDefinition="The healthcare professional responsible for authorizing the prescription." ) 1791 protected Reference prescriber; 1792 1793 /** 1794 * Contain the details of the individual lens specifications and serves as the authorization for the fullfillment by certified professionals. 1795 */ 1796 @Child(name = "lensSpecification", type = {}, order=7, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1797 @Description(shortDefinition="Vision lens authorization", formalDefinition="Contain the details of the individual lens specifications and serves as the authorization for the fullfillment by certified professionals." ) 1798 protected List<VisionPrescriptionLensSpecificationComponent> lensSpecification; 1799 1800 private static final long serialVersionUID = -194296688L; 1801 1802 /** 1803 * Constructor 1804 */ 1805 public VisionPrescription() { 1806 super(); 1807 } 1808 1809 /** 1810 * Constructor 1811 */ 1812 public VisionPrescription(FinancialResourceStatusCodes status, Date created, Reference patient, Date dateWritten, Reference prescriber, VisionPrescriptionLensSpecificationComponent lensSpecification) { 1813 super(); 1814 this.setStatus(status); 1815 this.setCreated(created); 1816 this.setPatient(patient); 1817 this.setDateWritten(dateWritten); 1818 this.setPrescriber(prescriber); 1819 this.addLensSpecification(lensSpecification); 1820 } 1821 1822 /** 1823 * @return {@link #identifier} (A unique identifier assigned to this vision prescription.) 1824 */ 1825 public List<Identifier> getIdentifier() { 1826 if (this.identifier == null) 1827 this.identifier = new ArrayList<Identifier>(); 1828 return this.identifier; 1829 } 1830 1831 /** 1832 * @return Returns a reference to <code>this</code> for easy method chaining 1833 */ 1834 public VisionPrescription setIdentifier(List<Identifier> theIdentifier) { 1835 this.identifier = theIdentifier; 1836 return this; 1837 } 1838 1839 public boolean hasIdentifier() { 1840 if (this.identifier == null) 1841 return false; 1842 for (Identifier item : this.identifier) 1843 if (!item.isEmpty()) 1844 return true; 1845 return false; 1846 } 1847 1848 public Identifier addIdentifier() { //3 1849 Identifier t = new Identifier(); 1850 if (this.identifier == null) 1851 this.identifier = new ArrayList<Identifier>(); 1852 this.identifier.add(t); 1853 return t; 1854 } 1855 1856 public VisionPrescription addIdentifier(Identifier t) { //3 1857 if (t == null) 1858 return this; 1859 if (this.identifier == null) 1860 this.identifier = new ArrayList<Identifier>(); 1861 this.identifier.add(t); 1862 return this; 1863 } 1864 1865 /** 1866 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1867 */ 1868 public Identifier getIdentifierFirstRep() { 1869 if (getIdentifier().isEmpty()) { 1870 addIdentifier(); 1871 } 1872 return getIdentifier().get(0); 1873 } 1874 1875 /** 1876 * @return {@link #status} (The status of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1877 */ 1878 public Enumeration<FinancialResourceStatusCodes> getStatusElement() { 1879 if (this.status == null) 1880 if (Configuration.errorOnAutoCreate()) 1881 throw new Error("Attempt to auto-create VisionPrescription.status"); 1882 else if (Configuration.doAutoCreate()) 1883 this.status = new Enumeration<FinancialResourceStatusCodes>(new FinancialResourceStatusCodesEnumFactory()); // bb 1884 return this.status; 1885 } 1886 1887 public boolean hasStatusElement() { 1888 return this.status != null && !this.status.isEmpty(); 1889 } 1890 1891 public boolean hasStatus() { 1892 return this.status != null && !this.status.isEmpty(); 1893 } 1894 1895 /** 1896 * @param value {@link #status} (The status of the resource instance.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1897 */ 1898 public VisionPrescription setStatusElement(Enumeration<FinancialResourceStatusCodes> value) { 1899 this.status = value; 1900 return this; 1901 } 1902 1903 /** 1904 * @return The status of the resource instance. 1905 */ 1906 public FinancialResourceStatusCodes getStatus() { 1907 return this.status == null ? null : this.status.getValue(); 1908 } 1909 1910 /** 1911 * @param value The status of the resource instance. 1912 */ 1913 public VisionPrescription setStatus(FinancialResourceStatusCodes value) { 1914 if (this.status == null) 1915 this.status = new Enumeration<FinancialResourceStatusCodes>(new FinancialResourceStatusCodesEnumFactory()); 1916 this.status.setValue(value); 1917 return this; 1918 } 1919 1920 /** 1921 * @return {@link #created} (The date this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 1922 */ 1923 public DateTimeType getCreatedElement() { 1924 if (this.created == null) 1925 if (Configuration.errorOnAutoCreate()) 1926 throw new Error("Attempt to auto-create VisionPrescription.created"); 1927 else if (Configuration.doAutoCreate()) 1928 this.created = new DateTimeType(); // bb 1929 return this.created; 1930 } 1931 1932 public boolean hasCreatedElement() { 1933 return this.created != null && !this.created.isEmpty(); 1934 } 1935 1936 public boolean hasCreated() { 1937 return this.created != null && !this.created.isEmpty(); 1938 } 1939 1940 /** 1941 * @param value {@link #created} (The date this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 1942 */ 1943 public VisionPrescription setCreatedElement(DateTimeType value) { 1944 this.created = value; 1945 return this; 1946 } 1947 1948 /** 1949 * @return The date this resource was created. 1950 */ 1951 public Date getCreated() { 1952 return this.created == null ? null : this.created.getValue(); 1953 } 1954 1955 /** 1956 * @param value The date this resource was created. 1957 */ 1958 public VisionPrescription setCreated(Date value) { 1959 if (this.created == null) 1960 this.created = new DateTimeType(); 1961 this.created.setValue(value); 1962 return this; 1963 } 1964 1965 /** 1966 * @return {@link #patient} (A resource reference to the person to whom the vision prescription applies.) 1967 */ 1968 public Reference getPatient() { 1969 if (this.patient == null) 1970 if (Configuration.errorOnAutoCreate()) 1971 throw new Error("Attempt to auto-create VisionPrescription.patient"); 1972 else if (Configuration.doAutoCreate()) 1973 this.patient = new Reference(); // cc 1974 return this.patient; 1975 } 1976 1977 public boolean hasPatient() { 1978 return this.patient != null && !this.patient.isEmpty(); 1979 } 1980 1981 /** 1982 * @param value {@link #patient} (A resource reference to the person to whom the vision prescription applies.) 1983 */ 1984 public VisionPrescription setPatient(Reference value) { 1985 this.patient = value; 1986 return this; 1987 } 1988 1989 /** 1990 * @return {@link #encounter} (A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued.) 1991 */ 1992 public Reference getEncounter() { 1993 if (this.encounter == null) 1994 if (Configuration.errorOnAutoCreate()) 1995 throw new Error("Attempt to auto-create VisionPrescription.encounter"); 1996 else if (Configuration.doAutoCreate()) 1997 this.encounter = new Reference(); // cc 1998 return this.encounter; 1999 } 2000 2001 public boolean hasEncounter() { 2002 return this.encounter != null && !this.encounter.isEmpty(); 2003 } 2004 2005 /** 2006 * @param value {@link #encounter} (A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued.) 2007 */ 2008 public VisionPrescription setEncounter(Reference value) { 2009 this.encounter = value; 2010 return this; 2011 } 2012 2013 /** 2014 * @return {@link #dateWritten} (The date (and perhaps time) when the prescription was written.). This is the underlying object with id, value and extensions. The accessor "getDateWritten" gives direct access to the value 2015 */ 2016 public DateTimeType getDateWrittenElement() { 2017 if (this.dateWritten == null) 2018 if (Configuration.errorOnAutoCreate()) 2019 throw new Error("Attempt to auto-create VisionPrescription.dateWritten"); 2020 else if (Configuration.doAutoCreate()) 2021 this.dateWritten = new DateTimeType(); // bb 2022 return this.dateWritten; 2023 } 2024 2025 public boolean hasDateWrittenElement() { 2026 return this.dateWritten != null && !this.dateWritten.isEmpty(); 2027 } 2028 2029 public boolean hasDateWritten() { 2030 return this.dateWritten != null && !this.dateWritten.isEmpty(); 2031 } 2032 2033 /** 2034 * @param value {@link #dateWritten} (The date (and perhaps time) when the prescription was written.). This is the underlying object with id, value and extensions. The accessor "getDateWritten" gives direct access to the value 2035 */ 2036 public VisionPrescription setDateWrittenElement(DateTimeType value) { 2037 this.dateWritten = value; 2038 return this; 2039 } 2040 2041 /** 2042 * @return The date (and perhaps time) when the prescription was written. 2043 */ 2044 public Date getDateWritten() { 2045 return this.dateWritten == null ? null : this.dateWritten.getValue(); 2046 } 2047 2048 /** 2049 * @param value The date (and perhaps time) when the prescription was written. 2050 */ 2051 public VisionPrescription setDateWritten(Date value) { 2052 if (this.dateWritten == null) 2053 this.dateWritten = new DateTimeType(); 2054 this.dateWritten.setValue(value); 2055 return this; 2056 } 2057 2058 /** 2059 * @return {@link #prescriber} (The healthcare professional responsible for authorizing the prescription.) 2060 */ 2061 public Reference getPrescriber() { 2062 if (this.prescriber == null) 2063 if (Configuration.errorOnAutoCreate()) 2064 throw new Error("Attempt to auto-create VisionPrescription.prescriber"); 2065 else if (Configuration.doAutoCreate()) 2066 this.prescriber = new Reference(); // cc 2067 return this.prescriber; 2068 } 2069 2070 public boolean hasPrescriber() { 2071 return this.prescriber != null && !this.prescriber.isEmpty(); 2072 } 2073 2074 /** 2075 * @param value {@link #prescriber} (The healthcare professional responsible for authorizing the prescription.) 2076 */ 2077 public VisionPrescription setPrescriber(Reference value) { 2078 this.prescriber = value; 2079 return this; 2080 } 2081 2082 /** 2083 * @return {@link #lensSpecification} (Contain the details of the individual lens specifications and serves as the authorization for the fullfillment by certified professionals.) 2084 */ 2085 public List<VisionPrescriptionLensSpecificationComponent> getLensSpecification() { 2086 if (this.lensSpecification == null) 2087 this.lensSpecification = new ArrayList<VisionPrescriptionLensSpecificationComponent>(); 2088 return this.lensSpecification; 2089 } 2090 2091 /** 2092 * @return Returns a reference to <code>this</code> for easy method chaining 2093 */ 2094 public VisionPrescription setLensSpecification(List<VisionPrescriptionLensSpecificationComponent> theLensSpecification) { 2095 this.lensSpecification = theLensSpecification; 2096 return this; 2097 } 2098 2099 public boolean hasLensSpecification() { 2100 if (this.lensSpecification == null) 2101 return false; 2102 for (VisionPrescriptionLensSpecificationComponent item : this.lensSpecification) 2103 if (!item.isEmpty()) 2104 return true; 2105 return false; 2106 } 2107 2108 public VisionPrescriptionLensSpecificationComponent addLensSpecification() { //3 2109 VisionPrescriptionLensSpecificationComponent t = new VisionPrescriptionLensSpecificationComponent(); 2110 if (this.lensSpecification == null) 2111 this.lensSpecification = new ArrayList<VisionPrescriptionLensSpecificationComponent>(); 2112 this.lensSpecification.add(t); 2113 return t; 2114 } 2115 2116 public VisionPrescription addLensSpecification(VisionPrescriptionLensSpecificationComponent t) { //3 2117 if (t == null) 2118 return this; 2119 if (this.lensSpecification == null) 2120 this.lensSpecification = new ArrayList<VisionPrescriptionLensSpecificationComponent>(); 2121 this.lensSpecification.add(t); 2122 return this; 2123 } 2124 2125 /** 2126 * @return The first repetition of repeating field {@link #lensSpecification}, creating it if it does not already exist {3} 2127 */ 2128 public VisionPrescriptionLensSpecificationComponent getLensSpecificationFirstRep() { 2129 if (getLensSpecification().isEmpty()) { 2130 addLensSpecification(); 2131 } 2132 return getLensSpecification().get(0); 2133 } 2134 2135 protected void listChildren(List<Property> children) { 2136 super.listChildren(children); 2137 children.add(new Property("identifier", "Identifier", "A unique identifier assigned to this vision prescription.", 0, java.lang.Integer.MAX_VALUE, identifier)); 2138 children.add(new Property("status", "code", "The status of the resource instance.", 0, 1, status)); 2139 children.add(new Property("created", "dateTime", "The date this resource was created.", 0, 1, created)); 2140 children.add(new Property("patient", "Reference(Patient)", "A resource reference to the person to whom the vision prescription applies.", 0, 1, patient)); 2141 children.add(new Property("encounter", "Reference(Encounter)", "A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued.", 0, 1, encounter)); 2142 children.add(new Property("dateWritten", "dateTime", "The date (and perhaps time) when the prescription was written.", 0, 1, dateWritten)); 2143 children.add(new Property("prescriber", "Reference(Practitioner|PractitionerRole)", "The healthcare professional responsible for authorizing the prescription.", 0, 1, prescriber)); 2144 children.add(new Property("lensSpecification", "", "Contain the details of the individual lens specifications and serves as the authorization for the fullfillment by certified professionals.", 0, java.lang.Integer.MAX_VALUE, lensSpecification)); 2145 } 2146 2147 @Override 2148 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2149 switch (_hash) { 2150 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A unique identifier assigned to this vision prescription.", 0, java.lang.Integer.MAX_VALUE, identifier); 2151 case -892481550: /*status*/ return new Property("status", "code", "The status of the resource instance.", 0, 1, status); 2152 case 1028554472: /*created*/ return new Property("created", "dateTime", "The date this resource was created.", 0, 1, created); 2153 case -791418107: /*patient*/ return new Property("patient", "Reference(Patient)", "A resource reference to the person to whom the vision prescription applies.", 0, 1, patient); 2154 case 1524132147: /*encounter*/ return new Property("encounter", "Reference(Encounter)", "A reference to a resource that identifies the particular occurrence of contact between patient and health care provider during which the prescription was issued.", 0, 1, encounter); 2155 case -1496880759: /*dateWritten*/ return new Property("dateWritten", "dateTime", "The date (and perhaps time) when the prescription was written.", 0, 1, dateWritten); 2156 case 1430631077: /*prescriber*/ return new Property("prescriber", "Reference(Practitioner|PractitionerRole)", "The healthcare professional responsible for authorizing the prescription.", 0, 1, prescriber); 2157 case -1767318363: /*lensSpecification*/ return new Property("lensSpecification", "", "Contain the details of the individual lens specifications and serves as the authorization for the fullfillment by certified professionals.", 0, java.lang.Integer.MAX_VALUE, lensSpecification); 2158 default: return super.getNamedProperty(_hash, _name, _checkValid); 2159 } 2160 2161 } 2162 2163 @Override 2164 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2165 switch (hash) { 2166 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 2167 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<FinancialResourceStatusCodes> 2168 case 1028554472: /*created*/ return this.created == null ? new Base[0] : new Base[] {this.created}; // DateTimeType 2169 case -791418107: /*patient*/ return this.patient == null ? new Base[0] : new Base[] {this.patient}; // Reference 2170 case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference 2171 case -1496880759: /*dateWritten*/ return this.dateWritten == null ? new Base[0] : new Base[] {this.dateWritten}; // DateTimeType 2172 case 1430631077: /*prescriber*/ return this.prescriber == null ? new Base[0] : new Base[] {this.prescriber}; // Reference 2173 case -1767318363: /*lensSpecification*/ return this.lensSpecification == null ? new Base[0] : this.lensSpecification.toArray(new Base[this.lensSpecification.size()]); // VisionPrescriptionLensSpecificationComponent 2174 default: return super.getProperty(hash, name, checkValid); 2175 } 2176 2177 } 2178 2179 @Override 2180 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2181 switch (hash) { 2182 case -1618432855: // identifier 2183 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 2184 return value; 2185 case -892481550: // status 2186 value = new FinancialResourceStatusCodesEnumFactory().fromType(TypeConvertor.castToCode(value)); 2187 this.status = (Enumeration) value; // Enumeration<FinancialResourceStatusCodes> 2188 return value; 2189 case 1028554472: // created 2190 this.created = TypeConvertor.castToDateTime(value); // DateTimeType 2191 return value; 2192 case -791418107: // patient 2193 this.patient = TypeConvertor.castToReference(value); // Reference 2194 return value; 2195 case 1524132147: // encounter 2196 this.encounter = TypeConvertor.castToReference(value); // Reference 2197 return value; 2198 case -1496880759: // dateWritten 2199 this.dateWritten = TypeConvertor.castToDateTime(value); // DateTimeType 2200 return value; 2201 case 1430631077: // prescriber 2202 this.prescriber = TypeConvertor.castToReference(value); // Reference 2203 return value; 2204 case -1767318363: // lensSpecification 2205 this.getLensSpecification().add((VisionPrescriptionLensSpecificationComponent) value); // VisionPrescriptionLensSpecificationComponent 2206 return value; 2207 default: return super.setProperty(hash, name, value); 2208 } 2209 2210 } 2211 2212 @Override 2213 public Base setProperty(String name, Base value) throws FHIRException { 2214 if (name.equals("identifier")) { 2215 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 2216 } else if (name.equals("status")) { 2217 value = new FinancialResourceStatusCodesEnumFactory().fromType(TypeConvertor.castToCode(value)); 2218 this.status = (Enumeration) value; // Enumeration<FinancialResourceStatusCodes> 2219 } else if (name.equals("created")) { 2220 this.created = TypeConvertor.castToDateTime(value); // DateTimeType 2221 } else if (name.equals("patient")) { 2222 this.patient = TypeConvertor.castToReference(value); // Reference 2223 } else if (name.equals("encounter")) { 2224 this.encounter = TypeConvertor.castToReference(value); // Reference 2225 } else if (name.equals("dateWritten")) { 2226 this.dateWritten = TypeConvertor.castToDateTime(value); // DateTimeType 2227 } else if (name.equals("prescriber")) { 2228 this.prescriber = TypeConvertor.castToReference(value); // Reference 2229 } else if (name.equals("lensSpecification")) { 2230 this.getLensSpecification().add((VisionPrescriptionLensSpecificationComponent) value); 2231 } else 2232 return super.setProperty(name, value); 2233 return value; 2234 } 2235 2236 @Override 2237 public Base makeProperty(int hash, String name) throws FHIRException { 2238 switch (hash) { 2239 case -1618432855: return addIdentifier(); 2240 case -892481550: return getStatusElement(); 2241 case 1028554472: return getCreatedElement(); 2242 case -791418107: return getPatient(); 2243 case 1524132147: return getEncounter(); 2244 case -1496880759: return getDateWrittenElement(); 2245 case 1430631077: return getPrescriber(); 2246 case -1767318363: return addLensSpecification(); 2247 default: return super.makeProperty(hash, name); 2248 } 2249 2250 } 2251 2252 @Override 2253 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2254 switch (hash) { 2255 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 2256 case -892481550: /*status*/ return new String[] {"code"}; 2257 case 1028554472: /*created*/ return new String[] {"dateTime"}; 2258 case -791418107: /*patient*/ return new String[] {"Reference"}; 2259 case 1524132147: /*encounter*/ return new String[] {"Reference"}; 2260 case -1496880759: /*dateWritten*/ return new String[] {"dateTime"}; 2261 case 1430631077: /*prescriber*/ return new String[] {"Reference"}; 2262 case -1767318363: /*lensSpecification*/ return new String[] {}; 2263 default: return super.getTypesForProperty(hash, name); 2264 } 2265 2266 } 2267 2268 @Override 2269 public Base addChild(String name) throws FHIRException { 2270 if (name.equals("identifier")) { 2271 return addIdentifier(); 2272 } 2273 else if (name.equals("status")) { 2274 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.status"); 2275 } 2276 else if (name.equals("created")) { 2277 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.created"); 2278 } 2279 else if (name.equals("patient")) { 2280 this.patient = new Reference(); 2281 return this.patient; 2282 } 2283 else if (name.equals("encounter")) { 2284 this.encounter = new Reference(); 2285 return this.encounter; 2286 } 2287 else if (name.equals("dateWritten")) { 2288 throw new FHIRException("Cannot call addChild on a primitive type VisionPrescription.dateWritten"); 2289 } 2290 else if (name.equals("prescriber")) { 2291 this.prescriber = new Reference(); 2292 return this.prescriber; 2293 } 2294 else if (name.equals("lensSpecification")) { 2295 return addLensSpecification(); 2296 } 2297 else 2298 return super.addChild(name); 2299 } 2300 2301 public String fhirType() { 2302 return "VisionPrescription"; 2303 2304 } 2305 2306 public VisionPrescription copy() { 2307 VisionPrescription dst = new VisionPrescription(); 2308 copyValues(dst); 2309 return dst; 2310 } 2311 2312 public void copyValues(VisionPrescription dst) { 2313 super.copyValues(dst); 2314 if (identifier != null) { 2315 dst.identifier = new ArrayList<Identifier>(); 2316 for (Identifier i : identifier) 2317 dst.identifier.add(i.copy()); 2318 }; 2319 dst.status = status == null ? null : status.copy(); 2320 dst.created = created == null ? null : created.copy(); 2321 dst.patient = patient == null ? null : patient.copy(); 2322 dst.encounter = encounter == null ? null : encounter.copy(); 2323 dst.dateWritten = dateWritten == null ? null : dateWritten.copy(); 2324 dst.prescriber = prescriber == null ? null : prescriber.copy(); 2325 if (lensSpecification != null) { 2326 dst.lensSpecification = new ArrayList<VisionPrescriptionLensSpecificationComponent>(); 2327 for (VisionPrescriptionLensSpecificationComponent i : lensSpecification) 2328 dst.lensSpecification.add(i.copy()); 2329 }; 2330 } 2331 2332 protected VisionPrescription typedCopy() { 2333 return copy(); 2334 } 2335 2336 @Override 2337 public boolean equalsDeep(Base other_) { 2338 if (!super.equalsDeep(other_)) 2339 return false; 2340 if (!(other_ instanceof VisionPrescription)) 2341 return false; 2342 VisionPrescription o = (VisionPrescription) other_; 2343 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(created, o.created, true) 2344 && compareDeep(patient, o.patient, true) && compareDeep(encounter, o.encounter, true) && compareDeep(dateWritten, o.dateWritten, true) 2345 && compareDeep(prescriber, o.prescriber, true) && compareDeep(lensSpecification, o.lensSpecification, true) 2346 ; 2347 } 2348 2349 @Override 2350 public boolean equalsShallow(Base other_) { 2351 if (!super.equalsShallow(other_)) 2352 return false; 2353 if (!(other_ instanceof VisionPrescription)) 2354 return false; 2355 VisionPrescription o = (VisionPrescription) other_; 2356 return compareValues(status, o.status, true) && compareValues(created, o.created, true) && compareValues(dateWritten, o.dateWritten, true) 2357 ; 2358 } 2359 2360 public boolean isEmpty() { 2361 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, created 2362 , patient, encounter, dateWritten, prescriber, lensSpecification); 2363 } 2364 2365 @Override 2366 public ResourceType getResourceType() { 2367 return ResourceType.VisionPrescription; 2368 } 2369 2370 /** 2371 * Search parameter: <b>datewritten</b> 2372 * <p> 2373 * Description: <b>Return prescriptions written on this date</b><br> 2374 * Type: <b>date</b><br> 2375 * Path: <b>VisionPrescription.dateWritten</b><br> 2376 * </p> 2377 */ 2378 @SearchParamDefinition(name="datewritten", path="VisionPrescription.dateWritten", description="Return prescriptions written on this date", type="date" ) 2379 public static final String SP_DATEWRITTEN = "datewritten"; 2380 /** 2381 * <b>Fluent Client</b> search parameter constant for <b>datewritten</b> 2382 * <p> 2383 * Description: <b>Return prescriptions written on this date</b><br> 2384 * Type: <b>date</b><br> 2385 * Path: <b>VisionPrescription.dateWritten</b><br> 2386 * </p> 2387 */ 2388 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATEWRITTEN = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATEWRITTEN); 2389 2390 /** 2391 * Search parameter: <b>prescriber</b> 2392 * <p> 2393 * Description: <b>Who authorized the vision prescription</b><br> 2394 * Type: <b>reference</b><br> 2395 * Path: <b>VisionPrescription.prescriber</b><br> 2396 * </p> 2397 */ 2398 @SearchParamDefinition(name="prescriber", path="VisionPrescription.prescriber", description="Who authorized the vision prescription", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Practitioner") }, target={Practitioner.class, PractitionerRole.class } ) 2399 public static final String SP_PRESCRIBER = "prescriber"; 2400 /** 2401 * <b>Fluent Client</b> search parameter constant for <b>prescriber</b> 2402 * <p> 2403 * Description: <b>Who authorized the vision prescription</b><br> 2404 * Type: <b>reference</b><br> 2405 * Path: <b>VisionPrescription.prescriber</b><br> 2406 * </p> 2407 */ 2408 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PRESCRIBER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PRESCRIBER); 2409 2410/** 2411 * Constant for fluent queries to be used to add include statements. Specifies 2412 * the path value of "<b>VisionPrescription:prescriber</b>". 2413 */ 2414 public static final ca.uhn.fhir.model.api.Include INCLUDE_PRESCRIBER = new ca.uhn.fhir.model.api.Include("VisionPrescription:prescriber").toLocked(); 2415 2416 /** 2417 * Search parameter: <b>status</b> 2418 * <p> 2419 * Description: <b>The status of the vision prescription</b><br> 2420 * Type: <b>token</b><br> 2421 * Path: <b>VisionPrescription.status</b><br> 2422 * </p> 2423 */ 2424 @SearchParamDefinition(name="status", path="VisionPrescription.status", description="The status of the vision prescription", type="token" ) 2425 public static final String SP_STATUS = "status"; 2426 /** 2427 * <b>Fluent Client</b> search parameter constant for <b>status</b> 2428 * <p> 2429 * Description: <b>The status of the vision prescription</b><br> 2430 * Type: <b>token</b><br> 2431 * Path: <b>VisionPrescription.status</b><br> 2432 * </p> 2433 */ 2434 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 2435 2436 /** 2437 * Search parameter: <b>encounter</b> 2438 * <p> 2439 * Description: <b>Multiple Resources: 2440 2441* [Composition](composition.html): Context of the Composition 2442* [DeviceRequest](devicerequest.html): Encounter during which request was created 2443* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made 2444* [DocumentReference](documentreference.html): Context of the document content 2445* [Flag](flag.html): Alert relevant during encounter 2446* [List](list.html): Context in which list created 2447* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier 2448* [Observation](observation.html): Encounter related to the observation 2449* [Procedure](procedure.html): The Encounter during which this Procedure was created 2450* [RiskAssessment](riskassessment.html): Where was assessment performed? 2451* [ServiceRequest](servicerequest.html): An encounter in which this request is made 2452* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier 2453</b><br> 2454 * Type: <b>reference</b><br> 2455 * Path: <b>Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | DocumentReference.context.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter</b><br> 2456 * </p> 2457 */ 2458 @SearchParamDefinition(name="encounter", path="Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | DocumentReference.context.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter", description="Multiple Resources: \r\n\r\n* [Composition](composition.html): Context of the Composition\r\n* [DeviceRequest](devicerequest.html): Encounter during which request was created\r\n* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made\r\n* [DocumentReference](documentreference.html): Context of the document content\r\n* [Flag](flag.html): Alert relevant during encounter\r\n* [List](list.html): Context in which list created\r\n* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier\r\n* [Observation](observation.html): Encounter related to the observation\r\n* [Procedure](procedure.html): The Encounter during which this Procedure was created\r\n* [RiskAssessment](riskassessment.html): Where was assessment performed?\r\n* [ServiceRequest](servicerequest.html): An encounter in which this request is made\r\n* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier\r\n", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Encounter") }, target={Encounter.class } ) 2459 public static final String SP_ENCOUNTER = "encounter"; 2460 /** 2461 * <b>Fluent Client</b> search parameter constant for <b>encounter</b> 2462 * <p> 2463 * Description: <b>Multiple Resources: 2464 2465* [Composition](composition.html): Context of the Composition 2466* [DeviceRequest](devicerequest.html): Encounter during which request was created 2467* [DiagnosticReport](diagnosticreport.html): The Encounter when the order was made 2468* [DocumentReference](documentreference.html): Context of the document content 2469* [Flag](flag.html): Alert relevant during encounter 2470* [List](list.html): Context in which list created 2471* [NutritionOrder](nutritionorder.html): Return nutrition orders with this encounter identifier 2472* [Observation](observation.html): Encounter related to the observation 2473* [Procedure](procedure.html): The Encounter during which this Procedure was created 2474* [RiskAssessment](riskassessment.html): Where was assessment performed? 2475* [ServiceRequest](servicerequest.html): An encounter in which this request is made 2476* [VisionPrescription](visionprescription.html): Return prescriptions with this encounter identifier 2477</b><br> 2478 * Type: <b>reference</b><br> 2479 * Path: <b>Composition.encounter | DeviceRequest.encounter | DiagnosticReport.encounter | DocumentReference.context.encounter | Flag.encounter | List.encounter | NutritionOrder.encounter | Observation.encounter | Procedure.encounter | RiskAssessment.encounter | ServiceRequest.encounter | VisionPrescription.encounter</b><br> 2480 * </p> 2481 */ 2482 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER); 2483 2484/** 2485 * Constant for fluent queries to be used to add include statements. Specifies 2486 * the path value of "<b>VisionPrescription:encounter</b>". 2487 */ 2488 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("VisionPrescription:encounter").toLocked(); 2489 2490 /** 2491 * Search parameter: <b>identifier</b> 2492 * <p> 2493 * Description: <b>Multiple Resources: 2494 2495* [AllergyIntolerance](allergyintolerance.html): External ids for this item 2496* [CarePlan](careplan.html): External Ids for this plan 2497* [CareTeam](careteam.html): External Ids for this team 2498* [Composition](composition.html): Version-independent identifier for the Composition 2499* [Condition](condition.html): A unique identifier of the condition record 2500* [Consent](consent.html): Identifier for this record (external references) 2501* [DetectedIssue](detectedissue.html): Unique id for the detected issue 2502* [DeviceRequest](devicerequest.html): Business identifier for request/order 2503* [DiagnosticReport](diagnosticreport.html): An identifier for the report 2504* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 2505* [DocumentReference](documentreference.html): Master Version Specific Identifier 2506* [Encounter](encounter.html): Identifier(s) by which this encounter is known 2507* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 2508* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 2509* [Goal](goal.html): External Ids for this goal 2510* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID and Accession number 2511* [Immunization](immunization.html): Business identifier 2512* [List](list.html): Business identifier 2513* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 2514* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 2515* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 2516* [MedicationUsage](medicationusage.html): Return statements with this external identifier 2517* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 2518* [Observation](observation.html): The unique id for a particular observation 2519* [Procedure](procedure.html): A unique identifier for a procedure 2520* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 2521* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 2522* [SupplyDelivery](supplydelivery.html): External identifier 2523* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 2524* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 2525</b><br> 2526 * Type: <b>token</b><br> 2527 * Path: <b>AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.masterIdentifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier</b><br> 2528 * </p> 2529 */ 2530 @SearchParamDefinition(name="identifier", path="AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.masterIdentifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): External ids for this item\r\n* [CarePlan](careplan.html): External Ids for this plan\r\n* [CareTeam](careteam.html): External Ids for this team\r\n* [Composition](composition.html): Version-independent identifier for the Composition\r\n* [Condition](condition.html): A unique identifier of the condition record\r\n* [Consent](consent.html): Identifier for this record (external references)\r\n* [DetectedIssue](detectedissue.html): Unique id for the detected issue\r\n* [DeviceRequest](devicerequest.html): Business identifier for request/order\r\n* [DiagnosticReport](diagnosticreport.html): An identifier for the report\r\n* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents\r\n* [DocumentReference](documentreference.html): Master Version Specific Identifier\r\n* [Encounter](encounter.html): Identifier(s) by which this encounter is known\r\n* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare\r\n* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier\r\n* [Goal](goal.html): External Ids for this goal\r\n* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID and Accession number\r\n* [Immunization](immunization.html): Business identifier\r\n* [List](list.html): Business identifier\r\n* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier\r\n* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier\r\n* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier\r\n* [MedicationUsage](medicationusage.html): Return statements with this external identifier\r\n* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier\r\n* [Observation](observation.html): The unique id for a particular observation\r\n* [Procedure](procedure.html): A unique identifier for a procedure\r\n* [RiskAssessment](riskassessment.html): Unique identifier for the assessment\r\n* [ServiceRequest](servicerequest.html): Identifiers assigned to this order\r\n* [SupplyDelivery](supplydelivery.html): External identifier\r\n* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest\r\n* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier\r\n", type="token" ) 2531 public static final String SP_IDENTIFIER = "identifier"; 2532 /** 2533 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2534 * <p> 2535 * Description: <b>Multiple Resources: 2536 2537* [AllergyIntolerance](allergyintolerance.html): External ids for this item 2538* [CarePlan](careplan.html): External Ids for this plan 2539* [CareTeam](careteam.html): External Ids for this team 2540* [Composition](composition.html): Version-independent identifier for the Composition 2541* [Condition](condition.html): A unique identifier of the condition record 2542* [Consent](consent.html): Identifier for this record (external references) 2543* [DetectedIssue](detectedissue.html): Unique id for the detected issue 2544* [DeviceRequest](devicerequest.html): Business identifier for request/order 2545* [DiagnosticReport](diagnosticreport.html): An identifier for the report 2546* [DocumentManifest](documentmanifest.html): Unique Identifier for the set of documents 2547* [DocumentReference](documentreference.html): Master Version Specific Identifier 2548* [Encounter](encounter.html): Identifier(s) by which this encounter is known 2549* [EpisodeOfCare](episodeofcare.html): Business Identifier(s) relevant for this EpisodeOfCare 2550* [FamilyMemberHistory](familymemberhistory.html): A search by a record identifier 2551* [Goal](goal.html): External Ids for this goal 2552* [ImagingStudy](imagingstudy.html): Identifiers for the Study, such as DICOM Study Instance UID and Accession number 2553* [Immunization](immunization.html): Business identifier 2554* [List](list.html): Business identifier 2555* [MedicationAdministration](medicationadministration.html): Return administrations with this external identifier 2556* [MedicationDispense](medicationdispense.html): Returns dispenses with this external identifier 2557* [MedicationRequest](medicationrequest.html): Return prescriptions with this external identifier 2558* [MedicationUsage](medicationusage.html): Return statements with this external identifier 2559* [NutritionOrder](nutritionorder.html): Return nutrition orders with this external identifier 2560* [Observation](observation.html): The unique id for a particular observation 2561* [Procedure](procedure.html): A unique identifier for a procedure 2562* [RiskAssessment](riskassessment.html): Unique identifier for the assessment 2563* [ServiceRequest](servicerequest.html): Identifiers assigned to this order 2564* [SupplyDelivery](supplydelivery.html): External identifier 2565* [SupplyRequest](supplyrequest.html): Business Identifier for SupplyRequest 2566* [VisionPrescription](visionprescription.html): Return prescriptions with this external identifier 2567</b><br> 2568 * Type: <b>token</b><br> 2569 * Path: <b>AllergyIntolerance.identifier | CarePlan.identifier | CareTeam.identifier | Composition.identifier | Condition.identifier | Consent.identifier | DetectedIssue.identifier | DeviceRequest.identifier | DiagnosticReport.identifier | DocumentManifest.masterIdentifier | DocumentManifest.identifier | DocumentReference.masterIdentifier | DocumentReference.identifier | Encounter.identifier | EpisodeOfCare.identifier | FamilyMemberHistory.identifier | Goal.identifier | ImagingStudy.identifier | Immunization.identifier | List.identifier | MedicationAdministration.identifier | MedicationDispense.identifier | MedicationRequest.identifier | MedicationUsage.identifier | NutritionOrder.identifier | Observation.identifier | Procedure.identifier | RiskAssessment.identifier | ServiceRequest.identifier | SupplyDelivery.identifier | SupplyRequest.identifier | VisionPrescription.identifier</b><br> 2570 * </p> 2571 */ 2572 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2573 2574 /** 2575 * Search parameter: <b>patient</b> 2576 * <p> 2577 * Description: <b>Multiple Resources: 2578 2579* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 2580* [CarePlan](careplan.html): Who the care plan is for 2581* [CareTeam](careteam.html): Who care team is for 2582* [ClinicalImpression](clinicalimpression.html): Patient or group assessed 2583* [Composition](composition.html): Who and/or what the composition is about 2584* [Condition](condition.html): Who has the condition? 2585* [Consent](consent.html): Who the consent applies to 2586* [DetectedIssue](detectedissue.html): Associated patient 2587* [DeviceRequest](devicerequest.html): Individual the service is ordered for 2588* [DeviceUseStatement](deviceusestatement.html): Search by subject - a patient 2589* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 2590* [DocumentManifest](documentmanifest.html): The subject of the set of documents 2591* [DocumentReference](documentreference.html): Who/what is the subject of the document 2592* [Encounter](encounter.html): The patient or group present at the encounter 2593* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 2594* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 2595* [Flag](flag.html): The identity of a subject to list flags for 2596* [Goal](goal.html): Who this goal is intended for 2597* [ImagingStudy](imagingstudy.html): Who the study is about 2598* [Immunization](immunization.html): The patient for the vaccination record 2599* [List](list.html): If all resources have the same subject 2600* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 2601* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 2602* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 2603* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 2604* [NutritionOrder](nutritionorder.html): The identity of the person who requires the diet, formula or nutritional supplement 2605* [Observation](observation.html): The subject that the observation is about (if patient) 2606* [Procedure](procedure.html): Search by subject - a patient 2607* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 2608* [ServiceRequest](servicerequest.html): Search by subject - a patient 2609* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 2610* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 2611</b><br> 2612 * Type: <b>reference</b><br> 2613 * Path: <b>AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.patient | DetectedIssue.patient | DeviceRequest.subject.where(resolve() is Patient) | DeviceUseStatement.subject | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.patient | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient</b><br> 2614 * </p> 2615 */ 2616 @SearchParamDefinition(name="patient", path="AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.patient | DetectedIssue.patient | DeviceRequest.subject.where(resolve() is Patient) | DeviceUseStatement.subject | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.patient | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient", description="Multiple Resources: \r\n\r\n* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for\r\n* [CarePlan](careplan.html): Who the care plan is for\r\n* [CareTeam](careteam.html): Who care team is for\r\n* [ClinicalImpression](clinicalimpression.html): Patient or group assessed\r\n* [Composition](composition.html): Who and/or what the composition is about\r\n* [Condition](condition.html): Who has the condition?\r\n* [Consent](consent.html): Who the consent applies to\r\n* [DetectedIssue](detectedissue.html): Associated patient\r\n* [DeviceRequest](devicerequest.html): Individual the service is ordered for\r\n* [DeviceUseStatement](deviceusestatement.html): Search by subject - a patient\r\n* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient\r\n* [DocumentManifest](documentmanifest.html): The subject of the set of documents\r\n* [DocumentReference](documentreference.html): Who/what is the subject of the document\r\n* [Encounter](encounter.html): The patient or group present at the encounter\r\n* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care\r\n* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for\r\n* [Flag](flag.html): The identity of a subject to list flags for\r\n* [Goal](goal.html): Who this goal is intended for\r\n* [ImagingStudy](imagingstudy.html): Who the study is about\r\n* [Immunization](immunization.html): The patient for the vaccination record\r\n* [List](list.html): If all resources have the same subject\r\n* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for\r\n* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for\r\n* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient\r\n* [MedicationUsage](medicationusage.html): Returns statements for a specific patient.\r\n* [NutritionOrder](nutritionorder.html): The identity of the person who requires the diet, formula or nutritional supplement\r\n* [Observation](observation.html): The subject that the observation is about (if patient)\r\n* [Procedure](procedure.html): Search by subject - a patient\r\n* [RiskAssessment](riskassessment.html): Who/what does assessment apply to?\r\n* [ServiceRequest](servicerequest.html): Search by subject - a patient\r\n* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied\r\n* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for\r\n", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient") }, target={Group.class, Patient.class } ) 2617 public static final String SP_PATIENT = "patient"; 2618 /** 2619 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2620 * <p> 2621 * Description: <b>Multiple Resources: 2622 2623* [AllergyIntolerance](allergyintolerance.html): Who the sensitivity is for 2624* [CarePlan](careplan.html): Who the care plan is for 2625* [CareTeam](careteam.html): Who care team is for 2626* [ClinicalImpression](clinicalimpression.html): Patient or group assessed 2627* [Composition](composition.html): Who and/or what the composition is about 2628* [Condition](condition.html): Who has the condition? 2629* [Consent](consent.html): Who the consent applies to 2630* [DetectedIssue](detectedissue.html): Associated patient 2631* [DeviceRequest](devicerequest.html): Individual the service is ordered for 2632* [DeviceUseStatement](deviceusestatement.html): Search by subject - a patient 2633* [DiagnosticReport](diagnosticreport.html): The subject of the report if a patient 2634* [DocumentManifest](documentmanifest.html): The subject of the set of documents 2635* [DocumentReference](documentreference.html): Who/what is the subject of the document 2636* [Encounter](encounter.html): The patient or group present at the encounter 2637* [EpisodeOfCare](episodeofcare.html): The patient who is the focus of this episode of care 2638* [FamilyMemberHistory](familymemberhistory.html): The identity of a subject to list family member history items for 2639* [Flag](flag.html): The identity of a subject to list flags for 2640* [Goal](goal.html): Who this goal is intended for 2641* [ImagingStudy](imagingstudy.html): Who the study is about 2642* [Immunization](immunization.html): The patient for the vaccination record 2643* [List](list.html): If all resources have the same subject 2644* [MedicationAdministration](medicationadministration.html): The identity of a patient to list administrations for 2645* [MedicationDispense](medicationdispense.html): The identity of a patient to list dispenses for 2646* [MedicationRequest](medicationrequest.html): Returns prescriptions for a specific patient 2647* [MedicationUsage](medicationusage.html): Returns statements for a specific patient. 2648* [NutritionOrder](nutritionorder.html): The identity of the person who requires the diet, formula or nutritional supplement 2649* [Observation](observation.html): The subject that the observation is about (if patient) 2650* [Procedure](procedure.html): Search by subject - a patient 2651* [RiskAssessment](riskassessment.html): Who/what does assessment apply to? 2652* [ServiceRequest](servicerequest.html): Search by subject - a patient 2653* [SupplyDelivery](supplydelivery.html): Patient for whom the item is supplied 2654* [VisionPrescription](visionprescription.html): The identity of a patient to list dispenses for 2655</b><br> 2656 * Type: <b>reference</b><br> 2657 * Path: <b>AllergyIntolerance.patient | CarePlan.subject.where(resolve() is Patient) | CareTeam.subject.where(resolve() is Patient) | ClinicalImpression.subject.where(resolve() is Patient) | Composition.subject.where(resolve() is Patient) | Condition.subject.where(resolve() is Patient) | Consent.patient | DetectedIssue.patient | DeviceRequest.subject.where(resolve() is Patient) | DeviceUseStatement.subject | DiagnosticReport.subject.where(resolve() is Patient) | DocumentManifest.subject.where(resolve() is Patient) | DocumentReference.subject.where(resolve() is Patient) | Encounter.subject.where(resolve() is Patient) | EpisodeOfCare.patient | FamilyMemberHistory.patient | Flag.subject.where(resolve() is Patient) | Goal.subject.where(resolve() is Patient) | ImagingStudy.subject.where(resolve() is Patient) | Immunization.patient | List.subject.where(resolve() is Patient) | MedicationAdministration.subject.where(resolve() is Patient) | MedicationDispense.subject.where(resolve() is Patient) | MedicationRequest.subject.where(resolve() is Patient) | MedicationUsage.subject.where(resolve() is Patient) | NutritionOrder.patient | Observation.subject.where(resolve() is Patient) | Procedure.subject.where(resolve() is Patient) | RiskAssessment.subject.where(resolve() is Patient) | ServiceRequest.subject.where(resolve() is Patient) | SupplyDelivery.patient | VisionPrescription.patient</b><br> 2658 * </p> 2659 */ 2660 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2661 2662/** 2663 * Constant for fluent queries to be used to add include statements. Specifies 2664 * the path value of "<b>VisionPrescription:patient</b>". 2665 */ 2666 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("VisionPrescription:patient").toLocked(); 2667 2668 2669} 2670