001package org.hl7.fhir.r4b.model; 002 003 004/* 005 Copyright (c) 2011+, HL7, Inc. 006 All rights reserved. 007 008 Redistribution and use in source and binary forms, with or without modification, \ 009 are permitted provided that the following conditions are met: 010 011 * Redistributions of source code must retain the above copyright notice, this \ 012 list of conditions and the following disclaimer. 013 * Redistributions in binary form must reproduce the above copyright notice, \ 014 this list of conditions and the following disclaimer in the documentation \ 015 and/or other materials provided with the distribution. 016 * Neither the name of HL7 nor the names of its contributors may be used to 017 endorse or promote products derived from this software without specific 018 prior written permission. 019 020 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 021 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 022 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 023 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 025 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 026 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 027 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 028 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 029 POSSIBILITY OF SUCH DAMAGE. 030 */ 031 032// Generated on Fri, Dec 31, 2021 05:58+1100 for FHIR v4.3.0-snapshot1 033 034import java.util.ArrayList; 035import java.util.Date; 036import java.util.List; 037import org.hl7.fhir.utilities.Utilities; 038import org.hl7.fhir.r4b.model.Enumerations.*; 039import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 040import org.hl7.fhir.exceptions.FHIRException; 041import org.hl7.fhir.instance.model.api.ICompositeType; 042import ca.uhn.fhir.model.api.annotation.ResourceDef; 043import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 044import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 045import ca.uhn.fhir.model.api.annotation.Child; 046import ca.uhn.fhir.model.api.annotation.ChildOrder; 047import ca.uhn.fhir.model.api.annotation.Description; 048import ca.uhn.fhir.model.api.annotation.Block; 049 050/** 051 * A booking of a healthcare event among patient(s), practitioner(s), related person(s) and/or device(s) for a specific date/time. This may result in one or more Encounter(s). 052 */ 053@ResourceDef(name="Appointment", profile="http://hl7.org/fhir/StructureDefinition/Appointment") 054public class Appointment extends DomainResource { 055 056 public enum AppointmentStatus { 057 /** 058 * None of the participant(s) have finalized their acceptance of the appointment request, and the start/end time might not be set yet. 059 */ 060 PROPOSED, 061 /** 062 * Some or all of the participant(s) have not finalized their acceptance of the appointment request. 063 */ 064 PENDING, 065 /** 066 * All participant(s) have been considered and the appointment is confirmed to go ahead at the date/times specified. 067 */ 068 BOOKED, 069 /** 070 * The patient/patients has/have arrived and is/are waiting to be seen. 071 */ 072 ARRIVED, 073 /** 074 * The planning stages of the appointment are now complete, the encounter resource will exist and will track further status changes. Note that an encounter may exist before the appointment status is fulfilled for many reasons. 075 */ 076 FULFILLED, 077 /** 078 * The appointment has been cancelled. 079 */ 080 CANCELLED, 081 /** 082 * Some or all of the participant(s) have not/did not appear for the appointment (usually the patient). 083 */ 084 NOSHOW, 085 /** 086 * This instance should not have been part of this patient's medical record. 087 */ 088 ENTEREDINERROR, 089 /** 090 * When checked in, all pre-encounter administrative work is complete, and the encounter may begin. (where multiple patients are involved, they are all present). 091 */ 092 CHECKEDIN, 093 /** 094 * The appointment has been placed on a waitlist, to be scheduled/confirmed in the future when a slot/service is available.\nA specific time might or might not be pre-allocated. 095 */ 096 WAITLIST, 097 /** 098 * added to help the parsers with the generic types 099 */ 100 NULL; 101 public static AppointmentStatus fromCode(String codeString) throws FHIRException { 102 if (codeString == null || "".equals(codeString)) 103 return null; 104 if ("proposed".equals(codeString)) 105 return PROPOSED; 106 if ("pending".equals(codeString)) 107 return PENDING; 108 if ("booked".equals(codeString)) 109 return BOOKED; 110 if ("arrived".equals(codeString)) 111 return ARRIVED; 112 if ("fulfilled".equals(codeString)) 113 return FULFILLED; 114 if ("cancelled".equals(codeString)) 115 return CANCELLED; 116 if ("noshow".equals(codeString)) 117 return NOSHOW; 118 if ("entered-in-error".equals(codeString)) 119 return ENTEREDINERROR; 120 if ("checked-in".equals(codeString)) 121 return CHECKEDIN; 122 if ("waitlist".equals(codeString)) 123 return WAITLIST; 124 if (Configuration.isAcceptInvalidEnums()) 125 return null; 126 else 127 throw new FHIRException("Unknown AppointmentStatus code '"+codeString+"'"); 128 } 129 public String toCode() { 130 switch (this) { 131 case PROPOSED: return "proposed"; 132 case PENDING: return "pending"; 133 case BOOKED: return "booked"; 134 case ARRIVED: return "arrived"; 135 case FULFILLED: return "fulfilled"; 136 case CANCELLED: return "cancelled"; 137 case NOSHOW: return "noshow"; 138 case ENTEREDINERROR: return "entered-in-error"; 139 case CHECKEDIN: return "checked-in"; 140 case WAITLIST: return "waitlist"; 141 case NULL: return null; 142 default: return "?"; 143 } 144 } 145 public String getSystem() { 146 switch (this) { 147 case PROPOSED: return "http://hl7.org/fhir/appointmentstatus"; 148 case PENDING: return "http://hl7.org/fhir/appointmentstatus"; 149 case BOOKED: return "http://hl7.org/fhir/appointmentstatus"; 150 case ARRIVED: return "http://hl7.org/fhir/appointmentstatus"; 151 case FULFILLED: return "http://hl7.org/fhir/appointmentstatus"; 152 case CANCELLED: return "http://hl7.org/fhir/appointmentstatus"; 153 case NOSHOW: return "http://hl7.org/fhir/appointmentstatus"; 154 case ENTEREDINERROR: return "http://hl7.org/fhir/appointmentstatus"; 155 case CHECKEDIN: return "http://hl7.org/fhir/appointmentstatus"; 156 case WAITLIST: return "http://hl7.org/fhir/appointmentstatus"; 157 case NULL: return null; 158 default: return "?"; 159 } 160 } 161 public String getDefinition() { 162 switch (this) { 163 case PROPOSED: return "None of the participant(s) have finalized their acceptance of the appointment request, and the start/end time might not be set yet."; 164 case PENDING: return "Some or all of the participant(s) have not finalized their acceptance of the appointment request."; 165 case BOOKED: return "All participant(s) have been considered and the appointment is confirmed to go ahead at the date/times specified."; 166 case ARRIVED: return "The patient/patients has/have arrived and is/are waiting to be seen."; 167 case FULFILLED: return "The planning stages of the appointment are now complete, the encounter resource will exist and will track further status changes. Note that an encounter may exist before the appointment status is fulfilled for many reasons."; 168 case CANCELLED: return "The appointment has been cancelled."; 169 case NOSHOW: return "Some or all of the participant(s) have not/did not appear for the appointment (usually the patient)."; 170 case ENTEREDINERROR: return "This instance should not have been part of this patient's medical record."; 171 case CHECKEDIN: return "When checked in, all pre-encounter administrative work is complete, and the encounter may begin. (where multiple patients are involved, they are all present)."; 172 case WAITLIST: return "The appointment has been placed on a waitlist, to be scheduled/confirmed in the future when a slot/service is available.\nA specific time might or might not be pre-allocated."; 173 case NULL: return null; 174 default: return "?"; 175 } 176 } 177 public String getDisplay() { 178 switch (this) { 179 case PROPOSED: return "Proposed"; 180 case PENDING: return "Pending"; 181 case BOOKED: return "Booked"; 182 case ARRIVED: return "Arrived"; 183 case FULFILLED: return "Fulfilled"; 184 case CANCELLED: return "Cancelled"; 185 case NOSHOW: return "No Show"; 186 case ENTEREDINERROR: return "Entered in error"; 187 case CHECKEDIN: return "Checked In"; 188 case WAITLIST: return "Waitlisted"; 189 case NULL: return null; 190 default: return "?"; 191 } 192 } 193 } 194 195 public static class AppointmentStatusEnumFactory implements EnumFactory<AppointmentStatus> { 196 public AppointmentStatus fromCode(String codeString) throws IllegalArgumentException { 197 if (codeString == null || "".equals(codeString)) 198 if (codeString == null || "".equals(codeString)) 199 return null; 200 if ("proposed".equals(codeString)) 201 return AppointmentStatus.PROPOSED; 202 if ("pending".equals(codeString)) 203 return AppointmentStatus.PENDING; 204 if ("booked".equals(codeString)) 205 return AppointmentStatus.BOOKED; 206 if ("arrived".equals(codeString)) 207 return AppointmentStatus.ARRIVED; 208 if ("fulfilled".equals(codeString)) 209 return AppointmentStatus.FULFILLED; 210 if ("cancelled".equals(codeString)) 211 return AppointmentStatus.CANCELLED; 212 if ("noshow".equals(codeString)) 213 return AppointmentStatus.NOSHOW; 214 if ("entered-in-error".equals(codeString)) 215 return AppointmentStatus.ENTEREDINERROR; 216 if ("checked-in".equals(codeString)) 217 return AppointmentStatus.CHECKEDIN; 218 if ("waitlist".equals(codeString)) 219 return AppointmentStatus.WAITLIST; 220 throw new IllegalArgumentException("Unknown AppointmentStatus code '"+codeString+"'"); 221 } 222 public Enumeration<AppointmentStatus> fromType(Base code) throws FHIRException { 223 if (code == null) 224 return null; 225 if (code.isEmpty()) 226 return new Enumeration<AppointmentStatus>(this); 227 String codeString = ((PrimitiveType) code).asStringValue(); 228 if (codeString == null || "".equals(codeString)) 229 return null; 230 if ("proposed".equals(codeString)) 231 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.PROPOSED); 232 if ("pending".equals(codeString)) 233 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.PENDING); 234 if ("booked".equals(codeString)) 235 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.BOOKED); 236 if ("arrived".equals(codeString)) 237 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.ARRIVED); 238 if ("fulfilled".equals(codeString)) 239 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.FULFILLED); 240 if ("cancelled".equals(codeString)) 241 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.CANCELLED); 242 if ("noshow".equals(codeString)) 243 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.NOSHOW); 244 if ("entered-in-error".equals(codeString)) 245 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.ENTEREDINERROR); 246 if ("checked-in".equals(codeString)) 247 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.CHECKEDIN); 248 if ("waitlist".equals(codeString)) 249 return new Enumeration<AppointmentStatus>(this, AppointmentStatus.WAITLIST); 250 throw new FHIRException("Unknown AppointmentStatus code '"+codeString+"'"); 251 } 252 public String toCode(AppointmentStatus code) { 253 if (code == AppointmentStatus.PROPOSED) 254 return "proposed"; 255 if (code == AppointmentStatus.PENDING) 256 return "pending"; 257 if (code == AppointmentStatus.BOOKED) 258 return "booked"; 259 if (code == AppointmentStatus.ARRIVED) 260 return "arrived"; 261 if (code == AppointmentStatus.FULFILLED) 262 return "fulfilled"; 263 if (code == AppointmentStatus.CANCELLED) 264 return "cancelled"; 265 if (code == AppointmentStatus.NOSHOW) 266 return "noshow"; 267 if (code == AppointmentStatus.ENTEREDINERROR) 268 return "entered-in-error"; 269 if (code == AppointmentStatus.CHECKEDIN) 270 return "checked-in"; 271 if (code == AppointmentStatus.WAITLIST) 272 return "waitlist"; 273 return "?"; 274 } 275 public String toSystem(AppointmentStatus code) { 276 return code.getSystem(); 277 } 278 } 279 280 public enum ParticipantRequired { 281 /** 282 * The participant is required to attend the appointment. 283 */ 284 REQUIRED, 285 /** 286 * The participant may optionally attend the appointment. 287 */ 288 OPTIONAL, 289 /** 290 * The participant is excluded from the appointment, and might not be informed of the appointment taking place. (Appointment is about them, not for them - such as 2 doctors discussing results about a patient's test). 291 */ 292 INFORMATIONONLY, 293 /** 294 * added to help the parsers with the generic types 295 */ 296 NULL; 297 public static ParticipantRequired fromCode(String codeString) throws FHIRException { 298 if (codeString == null || "".equals(codeString)) 299 return null; 300 if ("required".equals(codeString)) 301 return REQUIRED; 302 if ("optional".equals(codeString)) 303 return OPTIONAL; 304 if ("information-only".equals(codeString)) 305 return INFORMATIONONLY; 306 if (Configuration.isAcceptInvalidEnums()) 307 return null; 308 else 309 throw new FHIRException("Unknown ParticipantRequired code '"+codeString+"'"); 310 } 311 public String toCode() { 312 switch (this) { 313 case REQUIRED: return "required"; 314 case OPTIONAL: return "optional"; 315 case INFORMATIONONLY: return "information-only"; 316 case NULL: return null; 317 default: return "?"; 318 } 319 } 320 public String getSystem() { 321 switch (this) { 322 case REQUIRED: return "http://hl7.org/fhir/participantrequired"; 323 case OPTIONAL: return "http://hl7.org/fhir/participantrequired"; 324 case INFORMATIONONLY: return "http://hl7.org/fhir/participantrequired"; 325 case NULL: return null; 326 default: return "?"; 327 } 328 } 329 public String getDefinition() { 330 switch (this) { 331 case REQUIRED: return "The participant is required to attend the appointment."; 332 case OPTIONAL: return "The participant may optionally attend the appointment."; 333 case INFORMATIONONLY: return "The participant is excluded from the appointment, and might not be informed of the appointment taking place. (Appointment is about them, not for them - such as 2 doctors discussing results about a patient's test)."; 334 case NULL: return null; 335 default: return "?"; 336 } 337 } 338 public String getDisplay() { 339 switch (this) { 340 case REQUIRED: return "Required"; 341 case OPTIONAL: return "Optional"; 342 case INFORMATIONONLY: return "Information Only"; 343 case NULL: return null; 344 default: return "?"; 345 } 346 } 347 } 348 349 public static class ParticipantRequiredEnumFactory implements EnumFactory<ParticipantRequired> { 350 public ParticipantRequired fromCode(String codeString) throws IllegalArgumentException { 351 if (codeString == null || "".equals(codeString)) 352 if (codeString == null || "".equals(codeString)) 353 return null; 354 if ("required".equals(codeString)) 355 return ParticipantRequired.REQUIRED; 356 if ("optional".equals(codeString)) 357 return ParticipantRequired.OPTIONAL; 358 if ("information-only".equals(codeString)) 359 return ParticipantRequired.INFORMATIONONLY; 360 throw new IllegalArgumentException("Unknown ParticipantRequired code '"+codeString+"'"); 361 } 362 public Enumeration<ParticipantRequired> fromType(Base code) throws FHIRException { 363 if (code == null) 364 return null; 365 if (code.isEmpty()) 366 return new Enumeration<ParticipantRequired>(this); 367 String codeString = ((PrimitiveType) code).asStringValue(); 368 if (codeString == null || "".equals(codeString)) 369 return null; 370 if ("required".equals(codeString)) 371 return new Enumeration<ParticipantRequired>(this, ParticipantRequired.REQUIRED); 372 if ("optional".equals(codeString)) 373 return new Enumeration<ParticipantRequired>(this, ParticipantRequired.OPTIONAL); 374 if ("information-only".equals(codeString)) 375 return new Enumeration<ParticipantRequired>(this, ParticipantRequired.INFORMATIONONLY); 376 throw new FHIRException("Unknown ParticipantRequired code '"+codeString+"'"); 377 } 378 public String toCode(ParticipantRequired code) { 379 if (code == ParticipantRequired.REQUIRED) 380 return "required"; 381 if (code == ParticipantRequired.OPTIONAL) 382 return "optional"; 383 if (code == ParticipantRequired.INFORMATIONONLY) 384 return "information-only"; 385 return "?"; 386 } 387 public String toSystem(ParticipantRequired code) { 388 return code.getSystem(); 389 } 390 } 391 392 @Block() 393 public static class AppointmentParticipantComponent extends BackboneElement implements IBaseBackboneElement { 394 /** 395 * Role of participant in the appointment. 396 */ 397 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 398 @Description(shortDefinition="Role of participant in the appointment", formalDefinition="Role of participant in the appointment." ) 399 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/encounter-participant-type") 400 protected List<CodeableConcept> type; 401 402 /** 403 * A Person, Location/HealthcareService or Device that is participating in the appointment. 404 */ 405 @Child(name = "actor", type = {Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class, Device.class, HealthcareService.class, Location.class}, order=2, min=0, max=1, modifier=false, summary=true) 406 @Description(shortDefinition="Person, Location/HealthcareService or Device", formalDefinition="A Person, Location/HealthcareService or Device that is participating in the appointment." ) 407 protected Reference actor; 408 409 /** 410 * Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present. 411 */ 412 @Child(name = "required", type = {CodeType.class}, order=3, min=0, max=1, modifier=false, summary=true) 413 @Description(shortDefinition="required | optional | information-only", formalDefinition="Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present." ) 414 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/participantrequired") 415 protected Enumeration<ParticipantRequired> required; 416 417 /** 418 * Participation status of the actor. 419 */ 420 @Child(name = "status", type = {CodeType.class}, order=4, min=1, max=1, modifier=false, summary=true) 421 @Description(shortDefinition="accepted | declined | tentative | needs-action", formalDefinition="Participation status of the actor." ) 422 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/participationstatus") 423 protected Enumeration<ParticipationStatus> status; 424 425 /** 426 * Participation period of the actor. 427 */ 428 @Child(name = "period", type = {Period.class}, order=5, min=0, max=1, modifier=false, summary=false) 429 @Description(shortDefinition="Participation period of the actor", formalDefinition="Participation period of the actor." ) 430 protected Period period; 431 432 private static final long serialVersionUID = -1993862145L; 433 434 /** 435 * Constructor 436 */ 437 public AppointmentParticipantComponent() { 438 super(); 439 } 440 441 /** 442 * Constructor 443 */ 444 public AppointmentParticipantComponent(ParticipationStatus status) { 445 super(); 446 this.setStatus(status); 447 } 448 449 /** 450 * @return {@link #type} (Role of participant in the appointment.) 451 */ 452 public List<CodeableConcept> getType() { 453 if (this.type == null) 454 this.type = new ArrayList<CodeableConcept>(); 455 return this.type; 456 } 457 458 /** 459 * @return Returns a reference to <code>this</code> for easy method chaining 460 */ 461 public AppointmentParticipantComponent setType(List<CodeableConcept> theType) { 462 this.type = theType; 463 return this; 464 } 465 466 public boolean hasType() { 467 if (this.type == null) 468 return false; 469 for (CodeableConcept item : this.type) 470 if (!item.isEmpty()) 471 return true; 472 return false; 473 } 474 475 public CodeableConcept addType() { //3 476 CodeableConcept t = new CodeableConcept(); 477 if (this.type == null) 478 this.type = new ArrayList<CodeableConcept>(); 479 this.type.add(t); 480 return t; 481 } 482 483 public AppointmentParticipantComponent addType(CodeableConcept t) { //3 484 if (t == null) 485 return this; 486 if (this.type == null) 487 this.type = new ArrayList<CodeableConcept>(); 488 this.type.add(t); 489 return this; 490 } 491 492 /** 493 * @return The first repetition of repeating field {@link #type}, creating it if it does not already exist {3} 494 */ 495 public CodeableConcept getTypeFirstRep() { 496 if (getType().isEmpty()) { 497 addType(); 498 } 499 return getType().get(0); 500 } 501 502 /** 503 * @return {@link #actor} (A Person, Location/HealthcareService or Device that is participating in the appointment.) 504 */ 505 public Reference getActor() { 506 if (this.actor == null) 507 if (Configuration.errorOnAutoCreate()) 508 throw new Error("Attempt to auto-create AppointmentParticipantComponent.actor"); 509 else if (Configuration.doAutoCreate()) 510 this.actor = new Reference(); // cc 511 return this.actor; 512 } 513 514 public boolean hasActor() { 515 return this.actor != null && !this.actor.isEmpty(); 516 } 517 518 /** 519 * @param value {@link #actor} (A Person, Location/HealthcareService or Device that is participating in the appointment.) 520 */ 521 public AppointmentParticipantComponent setActor(Reference value) { 522 this.actor = value; 523 return this; 524 } 525 526 /** 527 * @return {@link #required} (Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present.). This is the underlying object with id, value and extensions. The accessor "getRequired" gives direct access to the value 528 */ 529 public Enumeration<ParticipantRequired> getRequiredElement() { 530 if (this.required == null) 531 if (Configuration.errorOnAutoCreate()) 532 throw new Error("Attempt to auto-create AppointmentParticipantComponent.required"); 533 else if (Configuration.doAutoCreate()) 534 this.required = new Enumeration<ParticipantRequired>(new ParticipantRequiredEnumFactory()); // bb 535 return this.required; 536 } 537 538 public boolean hasRequiredElement() { 539 return this.required != null && !this.required.isEmpty(); 540 } 541 542 public boolean hasRequired() { 543 return this.required != null && !this.required.isEmpty(); 544 } 545 546 /** 547 * @param value {@link #required} (Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present.). This is the underlying object with id, value and extensions. The accessor "getRequired" gives direct access to the value 548 */ 549 public AppointmentParticipantComponent setRequiredElement(Enumeration<ParticipantRequired> value) { 550 this.required = value; 551 return this; 552 } 553 554 /** 555 * @return Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present. 556 */ 557 public ParticipantRequired getRequired() { 558 return this.required == null ? null : this.required.getValue(); 559 } 560 561 /** 562 * @param value Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present. 563 */ 564 public AppointmentParticipantComponent setRequired(ParticipantRequired value) { 565 if (value == null) 566 this.required = null; 567 else { 568 if (this.required == null) 569 this.required = new Enumeration<ParticipantRequired>(new ParticipantRequiredEnumFactory()); 570 this.required.setValue(value); 571 } 572 return this; 573 } 574 575 /** 576 * @return {@link #status} (Participation status of the actor.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 577 */ 578 public Enumeration<ParticipationStatus> getStatusElement() { 579 if (this.status == null) 580 if (Configuration.errorOnAutoCreate()) 581 throw new Error("Attempt to auto-create AppointmentParticipantComponent.status"); 582 else if (Configuration.doAutoCreate()) 583 this.status = new Enumeration<ParticipationStatus>(new ParticipationStatusEnumFactory()); // bb 584 return this.status; 585 } 586 587 public boolean hasStatusElement() { 588 return this.status != null && !this.status.isEmpty(); 589 } 590 591 public boolean hasStatus() { 592 return this.status != null && !this.status.isEmpty(); 593 } 594 595 /** 596 * @param value {@link #status} (Participation status of the actor.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 597 */ 598 public AppointmentParticipantComponent setStatusElement(Enumeration<ParticipationStatus> value) { 599 this.status = value; 600 return this; 601 } 602 603 /** 604 * @return Participation status of the actor. 605 */ 606 public ParticipationStatus getStatus() { 607 return this.status == null ? null : this.status.getValue(); 608 } 609 610 /** 611 * @param value Participation status of the actor. 612 */ 613 public AppointmentParticipantComponent setStatus(ParticipationStatus value) { 614 if (this.status == null) 615 this.status = new Enumeration<ParticipationStatus>(new ParticipationStatusEnumFactory()); 616 this.status.setValue(value); 617 return this; 618 } 619 620 /** 621 * @return {@link #period} (Participation period of the actor.) 622 */ 623 public Period getPeriod() { 624 if (this.period == null) 625 if (Configuration.errorOnAutoCreate()) 626 throw new Error("Attempt to auto-create AppointmentParticipantComponent.period"); 627 else if (Configuration.doAutoCreate()) 628 this.period = new Period(); // cc 629 return this.period; 630 } 631 632 public boolean hasPeriod() { 633 return this.period != null && !this.period.isEmpty(); 634 } 635 636 /** 637 * @param value {@link #period} (Participation period of the actor.) 638 */ 639 public AppointmentParticipantComponent setPeriod(Period value) { 640 this.period = value; 641 return this; 642 } 643 644 protected void listChildren(List<Property> children) { 645 super.listChildren(children); 646 children.add(new Property("type", "CodeableConcept", "Role of participant in the appointment.", 0, java.lang.Integer.MAX_VALUE, type)); 647 children.add(new Property("actor", "Reference(Patient|Practitioner|PractitionerRole|RelatedPerson|Device|HealthcareService|Location)", "A Person, Location/HealthcareService or Device that is participating in the appointment.", 0, 1, actor)); 648 children.add(new Property("required", "code", "Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present.", 0, 1, required)); 649 children.add(new Property("status", "code", "Participation status of the actor.", 0, 1, status)); 650 children.add(new Property("period", "Period", "Participation period of the actor.", 0, 1, period)); 651 } 652 653 @Override 654 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 655 switch (_hash) { 656 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Role of participant in the appointment.", 0, java.lang.Integer.MAX_VALUE, type); 657 case 92645877: /*actor*/ return new Property("actor", "Reference(Patient|Practitioner|PractitionerRole|RelatedPerson|Device|HealthcareService|Location)", "A Person, Location/HealthcareService or Device that is participating in the appointment.", 0, 1, actor); 658 case -393139297: /*required*/ return new Property("required", "code", "Whether this participant is required to be present at the meeting. This covers a use-case where two doctors need to meet to discuss the results for a specific patient, and the patient is not required to be present.", 0, 1, required); 659 case -892481550: /*status*/ return new Property("status", "code", "Participation status of the actor.", 0, 1, status); 660 case -991726143: /*period*/ return new Property("period", "Period", "Participation period of the actor.", 0, 1, period); 661 default: return super.getNamedProperty(_hash, _name, _checkValid); 662 } 663 664 } 665 666 @Override 667 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 668 switch (hash) { 669 case 3575610: /*type*/ return this.type == null ? new Base[0] : this.type.toArray(new Base[this.type.size()]); // CodeableConcept 670 case 92645877: /*actor*/ return this.actor == null ? new Base[0] : new Base[] {this.actor}; // Reference 671 case -393139297: /*required*/ return this.required == null ? new Base[0] : new Base[] {this.required}; // Enumeration<ParticipantRequired> 672 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<ParticipationStatus> 673 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 674 default: return super.getProperty(hash, name, checkValid); 675 } 676 677 } 678 679 @Override 680 public Base setProperty(int hash, String name, Base value) throws FHIRException { 681 switch (hash) { 682 case 3575610: // type 683 this.getType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 684 return value; 685 case 92645877: // actor 686 this.actor = TypeConvertor.castToReference(value); // Reference 687 return value; 688 case -393139297: // required 689 value = new ParticipantRequiredEnumFactory().fromType(TypeConvertor.castToCode(value)); 690 this.required = (Enumeration) value; // Enumeration<ParticipantRequired> 691 return value; 692 case -892481550: // status 693 value = new ParticipationStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 694 this.status = (Enumeration) value; // Enumeration<ParticipationStatus> 695 return value; 696 case -991726143: // period 697 this.period = TypeConvertor.castToPeriod(value); // Period 698 return value; 699 default: return super.setProperty(hash, name, value); 700 } 701 702 } 703 704 @Override 705 public Base setProperty(String name, Base value) throws FHIRException { 706 if (name.equals("type")) { 707 this.getType().add(TypeConvertor.castToCodeableConcept(value)); 708 } else if (name.equals("actor")) { 709 this.actor = TypeConvertor.castToReference(value); // Reference 710 } else if (name.equals("required")) { 711 value = new ParticipantRequiredEnumFactory().fromType(TypeConvertor.castToCode(value)); 712 this.required = (Enumeration) value; // Enumeration<ParticipantRequired> 713 } else if (name.equals("status")) { 714 value = new ParticipationStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 715 this.status = (Enumeration) value; // Enumeration<ParticipationStatus> 716 } else if (name.equals("period")) { 717 this.period = TypeConvertor.castToPeriod(value); // Period 718 } else 719 return super.setProperty(name, value); 720 return value; 721 } 722 723 @Override 724 public Base makeProperty(int hash, String name) throws FHIRException { 725 switch (hash) { 726 case 3575610: return addType(); 727 case 92645877: return getActor(); 728 case -393139297: return getRequiredElement(); 729 case -892481550: return getStatusElement(); 730 case -991726143: return getPeriod(); 731 default: return super.makeProperty(hash, name); 732 } 733 734 } 735 736 @Override 737 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 738 switch (hash) { 739 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 740 case 92645877: /*actor*/ return new String[] {"Reference"}; 741 case -393139297: /*required*/ return new String[] {"code"}; 742 case -892481550: /*status*/ return new String[] {"code"}; 743 case -991726143: /*period*/ return new String[] {"Period"}; 744 default: return super.getTypesForProperty(hash, name); 745 } 746 747 } 748 749 @Override 750 public Base addChild(String name) throws FHIRException { 751 if (name.equals("type")) { 752 return addType(); 753 } 754 else if (name.equals("actor")) { 755 this.actor = new Reference(); 756 return this.actor; 757 } 758 else if (name.equals("required")) { 759 throw new FHIRException("Cannot call addChild on a primitive type Appointment.participant.required"); 760 } 761 else if (name.equals("status")) { 762 throw new FHIRException("Cannot call addChild on a primitive type Appointment.participant.status"); 763 } 764 else if (name.equals("period")) { 765 this.period = new Period(); 766 return this.period; 767 } 768 else 769 return super.addChild(name); 770 } 771 772 public AppointmentParticipantComponent copy() { 773 AppointmentParticipantComponent dst = new AppointmentParticipantComponent(); 774 copyValues(dst); 775 return dst; 776 } 777 778 public void copyValues(AppointmentParticipantComponent dst) { 779 super.copyValues(dst); 780 if (type != null) { 781 dst.type = new ArrayList<CodeableConcept>(); 782 for (CodeableConcept i : type) 783 dst.type.add(i.copy()); 784 }; 785 dst.actor = actor == null ? null : actor.copy(); 786 dst.required = required == null ? null : required.copy(); 787 dst.status = status == null ? null : status.copy(); 788 dst.period = period == null ? null : period.copy(); 789 } 790 791 @Override 792 public boolean equalsDeep(Base other_) { 793 if (!super.equalsDeep(other_)) 794 return false; 795 if (!(other_ instanceof AppointmentParticipantComponent)) 796 return false; 797 AppointmentParticipantComponent o = (AppointmentParticipantComponent) other_; 798 return compareDeep(type, o.type, true) && compareDeep(actor, o.actor, true) && compareDeep(required, o.required, true) 799 && compareDeep(status, o.status, true) && compareDeep(period, o.period, true); 800 } 801 802 @Override 803 public boolean equalsShallow(Base other_) { 804 if (!super.equalsShallow(other_)) 805 return false; 806 if (!(other_ instanceof AppointmentParticipantComponent)) 807 return false; 808 AppointmentParticipantComponent o = (AppointmentParticipantComponent) other_; 809 return compareValues(required, o.required, true) && compareValues(status, o.status, true); 810 } 811 812 public boolean isEmpty() { 813 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, actor, required, status 814 , period); 815 } 816 817 public String fhirType() { 818 return "Appointment.participant"; 819 820 } 821 822 } 823 824 /** 825 * This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation). 826 */ 827 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 828 @Description(shortDefinition="External Ids for this item", formalDefinition="This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation)." ) 829 protected List<Identifier> identifier; 830 831 /** 832 * The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status. 833 */ 834 @Child(name = "status", type = {CodeType.class}, order=1, min=1, max=1, modifier=true, summary=true) 835 @Description(shortDefinition="proposed | pending | booked | arrived | fulfilled | cancelled | noshow | entered-in-error | checked-in | waitlist", formalDefinition="The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status." ) 836 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/appointmentstatus") 837 protected Enumeration<AppointmentStatus> status; 838 839 /** 840 * The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply. 841 */ 842 @Child(name = "cancelationReason", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=true) 843 @Description(shortDefinition="The coded reason for the appointment being cancelled", formalDefinition="The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply." ) 844 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/appointment-cancellation-reason") 845 protected CodeableConcept cancelationReason; 846 847 /** 848 * A broad categorization of the service that is to be performed during this appointment. 849 */ 850 @Child(name = "serviceCategory", type = {CodeableConcept.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 851 @Description(shortDefinition="A broad categorization of the service that is to be performed during this appointment", formalDefinition="A broad categorization of the service that is to be performed during this appointment." ) 852 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/service-category") 853 protected List<CodeableConcept> serviceCategory; 854 855 /** 856 * The specific service that is to be performed during this appointment. 857 */ 858 @Child(name = "serviceType", type = {CodeableConcept.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 859 @Description(shortDefinition="The specific service that is to be performed during this appointment", formalDefinition="The specific service that is to be performed during this appointment." ) 860 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/service-type") 861 protected List<CodeableConcept> serviceType; 862 863 /** 864 * The specialty of a practitioner that would be required to perform the service requested in this appointment. 865 */ 866 @Child(name = "specialty", type = {CodeableConcept.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 867 @Description(shortDefinition="The specialty of a practitioner that would be required to perform the service requested in this appointment", formalDefinition="The specialty of a practitioner that would be required to perform the service requested in this appointment." ) 868 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/c80-practice-codes") 869 protected List<CodeableConcept> specialty; 870 871 /** 872 * The style of appointment or patient that has been booked in the slot (not service type). 873 */ 874 @Child(name = "appointmentType", type = {CodeableConcept.class}, order=6, min=0, max=1, modifier=false, summary=true) 875 @Description(shortDefinition="The style of appointment or patient that has been booked in the slot (not service type)", formalDefinition="The style of appointment or patient that has been booked in the slot (not service type)." ) 876 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://terminology.hl7.org/ValueSet/v2-0276") 877 protected CodeableConcept appointmentType; 878 879 /** 880 * The coded reason that this appointment is being scheduled. This is more clinical than administrative. 881 */ 882 @Child(name = "reasonCode", type = {CodeableConcept.class}, order=7, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 883 @Description(shortDefinition="Coded reason this appointment is scheduled", formalDefinition="The coded reason that this appointment is being scheduled. This is more clinical than administrative." ) 884 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/encounter-reason") 885 protected List<CodeableConcept> reasonCode; 886 887 /** 888 * Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure. 889 */ 890 @Child(name = "reasonReference", type = {Condition.class, Procedure.class, Observation.class, ImmunizationRecommendation.class}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 891 @Description(shortDefinition="Reason the appointment is to take place (resource)", formalDefinition="Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure." ) 892 protected List<Reference> reasonReference; 893 894 /** 895 * The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority). 896 */ 897 @Child(name = "priority", type = {UnsignedIntType.class}, order=9, min=0, max=1, modifier=false, summary=false) 898 @Description(shortDefinition="Used to make informed decisions if needing to re-prioritize", formalDefinition="The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority)." ) 899 protected UnsignedIntType priority; 900 901 /** 902 * The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field. 903 */ 904 @Child(name = "description", type = {StringType.class}, order=10, min=0, max=1, modifier=false, summary=false) 905 @Description(shortDefinition="Shown on a subject line in a meeting request, or appointment list", formalDefinition="The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field." ) 906 protected StringType description; 907 908 /** 909 * Additional information to support the appointment provided when making the appointment. 910 */ 911 @Child(name = "supportingInformation", type = {Reference.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 912 @Description(shortDefinition="Additional information to support the appointment", formalDefinition="Additional information to support the appointment provided when making the appointment." ) 913 protected List<Reference> supportingInformation; 914 915 /** 916 * Date/Time that the appointment is to take place. 917 */ 918 @Child(name = "start", type = {InstantType.class}, order=12, min=0, max=1, modifier=false, summary=true) 919 @Description(shortDefinition="When appointment is to take place", formalDefinition="Date/Time that the appointment is to take place." ) 920 protected InstantType start; 921 922 /** 923 * Date/Time that the appointment is to conclude. 924 */ 925 @Child(name = "end", type = {InstantType.class}, order=13, min=0, max=1, modifier=false, summary=true) 926 @Description(shortDefinition="When appointment is to conclude", formalDefinition="Date/Time that the appointment is to conclude." ) 927 protected InstantType end; 928 929 /** 930 * Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end. 931 */ 932 @Child(name = "minutesDuration", type = {PositiveIntType.class}, order=14, min=0, max=1, modifier=false, summary=false) 933 @Description(shortDefinition="Can be less than start/end (e.g. estimate)", formalDefinition="Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end." ) 934 protected PositiveIntType minutesDuration; 935 936 /** 937 * The slots from the participants' schedules that will be filled by the appointment. 938 */ 939 @Child(name = "slot", type = {Slot.class}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 940 @Description(shortDefinition="The slots that this appointment is filling", formalDefinition="The slots from the participants' schedules that will be filled by the appointment." ) 941 protected List<Reference> slot; 942 943 /** 944 * The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment. 945 */ 946 @Child(name = "created", type = {DateTimeType.class}, order=16, min=0, max=1, modifier=false, summary=false) 947 @Description(shortDefinition="The date that this appointment was initially created", formalDefinition="The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment." ) 948 protected DateTimeType created; 949 950 /** 951 * Additional comments about the appointment. 952 */ 953 @Child(name = "comment", type = {StringType.class}, order=17, min=0, max=1, modifier=false, summary=false) 954 @Description(shortDefinition="Additional comments", formalDefinition="Additional comments about the appointment." ) 955 protected StringType comment; 956 957 /** 958 * While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before). 959 */ 960 @Child(name = "patientInstruction", type = {StringType.class}, order=18, min=0, max=1, modifier=false, summary=false) 961 @Description(shortDefinition="Detailed information and instructions for the patient", formalDefinition="While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before)." ) 962 protected StringType patientInstruction; 963 964 /** 965 * The service request this appointment is allocated to assess (e.g. incoming referral or procedure request). 966 */ 967 @Child(name = "basedOn", type = {ServiceRequest.class}, order=19, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 968 @Description(shortDefinition="The service request this appointment is allocated to assess", formalDefinition="The service request this appointment is allocated to assess (e.g. incoming referral or procedure request)." ) 969 protected List<Reference> basedOn; 970 971 /** 972 * List of participants involved in the appointment. 973 */ 974 @Child(name = "participant", type = {}, order=20, min=1, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 975 @Description(shortDefinition="Participants involved in appointment", formalDefinition="List of participants involved in the appointment." ) 976 protected List<AppointmentParticipantComponent> participant; 977 978 /** 979 * A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within. 980 981The duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system. 982 */ 983 @Child(name = "requestedPeriod", type = {Period.class}, order=21, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 984 @Description(shortDefinition="Potential date/time interval(s) requested to allocate the appointment within", formalDefinition="A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system." ) 985 protected List<Period> requestedPeriod; 986 987 private static final long serialVersionUID = 267666863L; 988 989 /** 990 * Constructor 991 */ 992 public Appointment() { 993 super(); 994 } 995 996 /** 997 * Constructor 998 */ 999 public Appointment(AppointmentStatus status, AppointmentParticipantComponent participant) { 1000 super(); 1001 this.setStatus(status); 1002 this.addParticipant(participant); 1003 } 1004 1005 /** 1006 * @return {@link #identifier} (This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).) 1007 */ 1008 public List<Identifier> getIdentifier() { 1009 if (this.identifier == null) 1010 this.identifier = new ArrayList<Identifier>(); 1011 return this.identifier; 1012 } 1013 1014 /** 1015 * @return Returns a reference to <code>this</code> for easy method chaining 1016 */ 1017 public Appointment setIdentifier(List<Identifier> theIdentifier) { 1018 this.identifier = theIdentifier; 1019 return this; 1020 } 1021 1022 public boolean hasIdentifier() { 1023 if (this.identifier == null) 1024 return false; 1025 for (Identifier item : this.identifier) 1026 if (!item.isEmpty()) 1027 return true; 1028 return false; 1029 } 1030 1031 public Identifier addIdentifier() { //3 1032 Identifier t = new Identifier(); 1033 if (this.identifier == null) 1034 this.identifier = new ArrayList<Identifier>(); 1035 this.identifier.add(t); 1036 return t; 1037 } 1038 1039 public Appointment addIdentifier(Identifier t) { //3 1040 if (t == null) 1041 return this; 1042 if (this.identifier == null) 1043 this.identifier = new ArrayList<Identifier>(); 1044 this.identifier.add(t); 1045 return this; 1046 } 1047 1048 /** 1049 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1050 */ 1051 public Identifier getIdentifierFirstRep() { 1052 if (getIdentifier().isEmpty()) { 1053 addIdentifier(); 1054 } 1055 return getIdentifier().get(0); 1056 } 1057 1058 /** 1059 * @return {@link #status} (The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1060 */ 1061 public Enumeration<AppointmentStatus> getStatusElement() { 1062 if (this.status == null) 1063 if (Configuration.errorOnAutoCreate()) 1064 throw new Error("Attempt to auto-create Appointment.status"); 1065 else if (Configuration.doAutoCreate()) 1066 this.status = new Enumeration<AppointmentStatus>(new AppointmentStatusEnumFactory()); // bb 1067 return this.status; 1068 } 1069 1070 public boolean hasStatusElement() { 1071 return this.status != null && !this.status.isEmpty(); 1072 } 1073 1074 public boolean hasStatus() { 1075 return this.status != null && !this.status.isEmpty(); 1076 } 1077 1078 /** 1079 * @param value {@link #status} (The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 1080 */ 1081 public Appointment setStatusElement(Enumeration<AppointmentStatus> value) { 1082 this.status = value; 1083 return this; 1084 } 1085 1086 /** 1087 * @return The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status. 1088 */ 1089 public AppointmentStatus getStatus() { 1090 return this.status == null ? null : this.status.getValue(); 1091 } 1092 1093 /** 1094 * @param value The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status. 1095 */ 1096 public Appointment setStatus(AppointmentStatus value) { 1097 if (this.status == null) 1098 this.status = new Enumeration<AppointmentStatus>(new AppointmentStatusEnumFactory()); 1099 this.status.setValue(value); 1100 return this; 1101 } 1102 1103 /** 1104 * @return {@link #cancelationReason} (The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.) 1105 */ 1106 public CodeableConcept getCancelationReason() { 1107 if (this.cancelationReason == null) 1108 if (Configuration.errorOnAutoCreate()) 1109 throw new Error("Attempt to auto-create Appointment.cancelationReason"); 1110 else if (Configuration.doAutoCreate()) 1111 this.cancelationReason = new CodeableConcept(); // cc 1112 return this.cancelationReason; 1113 } 1114 1115 public boolean hasCancelationReason() { 1116 return this.cancelationReason != null && !this.cancelationReason.isEmpty(); 1117 } 1118 1119 /** 1120 * @param value {@link #cancelationReason} (The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.) 1121 */ 1122 public Appointment setCancelationReason(CodeableConcept value) { 1123 this.cancelationReason = value; 1124 return this; 1125 } 1126 1127 /** 1128 * @return {@link #serviceCategory} (A broad categorization of the service that is to be performed during this appointment.) 1129 */ 1130 public List<CodeableConcept> getServiceCategory() { 1131 if (this.serviceCategory == null) 1132 this.serviceCategory = new ArrayList<CodeableConcept>(); 1133 return this.serviceCategory; 1134 } 1135 1136 /** 1137 * @return Returns a reference to <code>this</code> for easy method chaining 1138 */ 1139 public Appointment setServiceCategory(List<CodeableConcept> theServiceCategory) { 1140 this.serviceCategory = theServiceCategory; 1141 return this; 1142 } 1143 1144 public boolean hasServiceCategory() { 1145 if (this.serviceCategory == null) 1146 return false; 1147 for (CodeableConcept item : this.serviceCategory) 1148 if (!item.isEmpty()) 1149 return true; 1150 return false; 1151 } 1152 1153 public CodeableConcept addServiceCategory() { //3 1154 CodeableConcept t = new CodeableConcept(); 1155 if (this.serviceCategory == null) 1156 this.serviceCategory = new ArrayList<CodeableConcept>(); 1157 this.serviceCategory.add(t); 1158 return t; 1159 } 1160 1161 public Appointment addServiceCategory(CodeableConcept t) { //3 1162 if (t == null) 1163 return this; 1164 if (this.serviceCategory == null) 1165 this.serviceCategory = new ArrayList<CodeableConcept>(); 1166 this.serviceCategory.add(t); 1167 return this; 1168 } 1169 1170 /** 1171 * @return The first repetition of repeating field {@link #serviceCategory}, creating it if it does not already exist {3} 1172 */ 1173 public CodeableConcept getServiceCategoryFirstRep() { 1174 if (getServiceCategory().isEmpty()) { 1175 addServiceCategory(); 1176 } 1177 return getServiceCategory().get(0); 1178 } 1179 1180 /** 1181 * @return {@link #serviceType} (The specific service that is to be performed during this appointment.) 1182 */ 1183 public List<CodeableConcept> getServiceType() { 1184 if (this.serviceType == null) 1185 this.serviceType = new ArrayList<CodeableConcept>(); 1186 return this.serviceType; 1187 } 1188 1189 /** 1190 * @return Returns a reference to <code>this</code> for easy method chaining 1191 */ 1192 public Appointment setServiceType(List<CodeableConcept> theServiceType) { 1193 this.serviceType = theServiceType; 1194 return this; 1195 } 1196 1197 public boolean hasServiceType() { 1198 if (this.serviceType == null) 1199 return false; 1200 for (CodeableConcept item : this.serviceType) 1201 if (!item.isEmpty()) 1202 return true; 1203 return false; 1204 } 1205 1206 public CodeableConcept addServiceType() { //3 1207 CodeableConcept t = new CodeableConcept(); 1208 if (this.serviceType == null) 1209 this.serviceType = new ArrayList<CodeableConcept>(); 1210 this.serviceType.add(t); 1211 return t; 1212 } 1213 1214 public Appointment addServiceType(CodeableConcept t) { //3 1215 if (t == null) 1216 return this; 1217 if (this.serviceType == null) 1218 this.serviceType = new ArrayList<CodeableConcept>(); 1219 this.serviceType.add(t); 1220 return this; 1221 } 1222 1223 /** 1224 * @return The first repetition of repeating field {@link #serviceType}, creating it if it does not already exist {3} 1225 */ 1226 public CodeableConcept getServiceTypeFirstRep() { 1227 if (getServiceType().isEmpty()) { 1228 addServiceType(); 1229 } 1230 return getServiceType().get(0); 1231 } 1232 1233 /** 1234 * @return {@link #specialty} (The specialty of a practitioner that would be required to perform the service requested in this appointment.) 1235 */ 1236 public List<CodeableConcept> getSpecialty() { 1237 if (this.specialty == null) 1238 this.specialty = new ArrayList<CodeableConcept>(); 1239 return this.specialty; 1240 } 1241 1242 /** 1243 * @return Returns a reference to <code>this</code> for easy method chaining 1244 */ 1245 public Appointment setSpecialty(List<CodeableConcept> theSpecialty) { 1246 this.specialty = theSpecialty; 1247 return this; 1248 } 1249 1250 public boolean hasSpecialty() { 1251 if (this.specialty == null) 1252 return false; 1253 for (CodeableConcept item : this.specialty) 1254 if (!item.isEmpty()) 1255 return true; 1256 return false; 1257 } 1258 1259 public CodeableConcept addSpecialty() { //3 1260 CodeableConcept t = new CodeableConcept(); 1261 if (this.specialty == null) 1262 this.specialty = new ArrayList<CodeableConcept>(); 1263 this.specialty.add(t); 1264 return t; 1265 } 1266 1267 public Appointment addSpecialty(CodeableConcept t) { //3 1268 if (t == null) 1269 return this; 1270 if (this.specialty == null) 1271 this.specialty = new ArrayList<CodeableConcept>(); 1272 this.specialty.add(t); 1273 return this; 1274 } 1275 1276 /** 1277 * @return The first repetition of repeating field {@link #specialty}, creating it if it does not already exist {3} 1278 */ 1279 public CodeableConcept getSpecialtyFirstRep() { 1280 if (getSpecialty().isEmpty()) { 1281 addSpecialty(); 1282 } 1283 return getSpecialty().get(0); 1284 } 1285 1286 /** 1287 * @return {@link #appointmentType} (The style of appointment or patient that has been booked in the slot (not service type).) 1288 */ 1289 public CodeableConcept getAppointmentType() { 1290 if (this.appointmentType == null) 1291 if (Configuration.errorOnAutoCreate()) 1292 throw new Error("Attempt to auto-create Appointment.appointmentType"); 1293 else if (Configuration.doAutoCreate()) 1294 this.appointmentType = new CodeableConcept(); // cc 1295 return this.appointmentType; 1296 } 1297 1298 public boolean hasAppointmentType() { 1299 return this.appointmentType != null && !this.appointmentType.isEmpty(); 1300 } 1301 1302 /** 1303 * @param value {@link #appointmentType} (The style of appointment or patient that has been booked in the slot (not service type).) 1304 */ 1305 public Appointment setAppointmentType(CodeableConcept value) { 1306 this.appointmentType = value; 1307 return this; 1308 } 1309 1310 /** 1311 * @return {@link #reasonCode} (The coded reason that this appointment is being scheduled. This is more clinical than administrative.) 1312 */ 1313 public List<CodeableConcept> getReasonCode() { 1314 if (this.reasonCode == null) 1315 this.reasonCode = new ArrayList<CodeableConcept>(); 1316 return this.reasonCode; 1317 } 1318 1319 /** 1320 * @return Returns a reference to <code>this</code> for easy method chaining 1321 */ 1322 public Appointment setReasonCode(List<CodeableConcept> theReasonCode) { 1323 this.reasonCode = theReasonCode; 1324 return this; 1325 } 1326 1327 public boolean hasReasonCode() { 1328 if (this.reasonCode == null) 1329 return false; 1330 for (CodeableConcept item : this.reasonCode) 1331 if (!item.isEmpty()) 1332 return true; 1333 return false; 1334 } 1335 1336 public CodeableConcept addReasonCode() { //3 1337 CodeableConcept t = new CodeableConcept(); 1338 if (this.reasonCode == null) 1339 this.reasonCode = new ArrayList<CodeableConcept>(); 1340 this.reasonCode.add(t); 1341 return t; 1342 } 1343 1344 public Appointment addReasonCode(CodeableConcept t) { //3 1345 if (t == null) 1346 return this; 1347 if (this.reasonCode == null) 1348 this.reasonCode = new ArrayList<CodeableConcept>(); 1349 this.reasonCode.add(t); 1350 return this; 1351 } 1352 1353 /** 1354 * @return The first repetition of repeating field {@link #reasonCode}, creating it if it does not already exist {3} 1355 */ 1356 public CodeableConcept getReasonCodeFirstRep() { 1357 if (getReasonCode().isEmpty()) { 1358 addReasonCode(); 1359 } 1360 return getReasonCode().get(0); 1361 } 1362 1363 /** 1364 * @return {@link #reasonReference} (Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.) 1365 */ 1366 public List<Reference> getReasonReference() { 1367 if (this.reasonReference == null) 1368 this.reasonReference = new ArrayList<Reference>(); 1369 return this.reasonReference; 1370 } 1371 1372 /** 1373 * @return Returns a reference to <code>this</code> for easy method chaining 1374 */ 1375 public Appointment setReasonReference(List<Reference> theReasonReference) { 1376 this.reasonReference = theReasonReference; 1377 return this; 1378 } 1379 1380 public boolean hasReasonReference() { 1381 if (this.reasonReference == null) 1382 return false; 1383 for (Reference item : this.reasonReference) 1384 if (!item.isEmpty()) 1385 return true; 1386 return false; 1387 } 1388 1389 public Reference addReasonReference() { //3 1390 Reference t = new Reference(); 1391 if (this.reasonReference == null) 1392 this.reasonReference = new ArrayList<Reference>(); 1393 this.reasonReference.add(t); 1394 return t; 1395 } 1396 1397 public Appointment addReasonReference(Reference t) { //3 1398 if (t == null) 1399 return this; 1400 if (this.reasonReference == null) 1401 this.reasonReference = new ArrayList<Reference>(); 1402 this.reasonReference.add(t); 1403 return this; 1404 } 1405 1406 /** 1407 * @return The first repetition of repeating field {@link #reasonReference}, creating it if it does not already exist {3} 1408 */ 1409 public Reference getReasonReferenceFirstRep() { 1410 if (getReasonReference().isEmpty()) { 1411 addReasonReference(); 1412 } 1413 return getReasonReference().get(0); 1414 } 1415 1416 /** 1417 * @return {@link #priority} (The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority).). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value 1418 */ 1419 public UnsignedIntType getPriorityElement() { 1420 if (this.priority == null) 1421 if (Configuration.errorOnAutoCreate()) 1422 throw new Error("Attempt to auto-create Appointment.priority"); 1423 else if (Configuration.doAutoCreate()) 1424 this.priority = new UnsignedIntType(); // bb 1425 return this.priority; 1426 } 1427 1428 public boolean hasPriorityElement() { 1429 return this.priority != null && !this.priority.isEmpty(); 1430 } 1431 1432 public boolean hasPriority() { 1433 return this.priority != null && !this.priority.isEmpty(); 1434 } 1435 1436 /** 1437 * @param value {@link #priority} (The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority).). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value 1438 */ 1439 public Appointment setPriorityElement(UnsignedIntType value) { 1440 this.priority = value; 1441 return this; 1442 } 1443 1444 /** 1445 * @return The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority). 1446 */ 1447 public int getPriority() { 1448 return this.priority == null || this.priority.isEmpty() ? 0 : this.priority.getValue(); 1449 } 1450 1451 /** 1452 * @param value The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority). 1453 */ 1454 public Appointment setPriority(int value) { 1455 if (this.priority == null) 1456 this.priority = new UnsignedIntType(); 1457 this.priority.setValue(value); 1458 return this; 1459 } 1460 1461 /** 1462 * @return {@link #description} (The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1463 */ 1464 public StringType getDescriptionElement() { 1465 if (this.description == null) 1466 if (Configuration.errorOnAutoCreate()) 1467 throw new Error("Attempt to auto-create Appointment.description"); 1468 else if (Configuration.doAutoCreate()) 1469 this.description = new StringType(); // bb 1470 return this.description; 1471 } 1472 1473 public boolean hasDescriptionElement() { 1474 return this.description != null && !this.description.isEmpty(); 1475 } 1476 1477 public boolean hasDescription() { 1478 return this.description != null && !this.description.isEmpty(); 1479 } 1480 1481 /** 1482 * @param value {@link #description} (The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 1483 */ 1484 public Appointment setDescriptionElement(StringType value) { 1485 this.description = value; 1486 return this; 1487 } 1488 1489 /** 1490 * @return The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field. 1491 */ 1492 public String getDescription() { 1493 return this.description == null ? null : this.description.getValue(); 1494 } 1495 1496 /** 1497 * @param value The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field. 1498 */ 1499 public Appointment setDescription(String value) { 1500 if (Utilities.noString(value)) 1501 this.description = null; 1502 else { 1503 if (this.description == null) 1504 this.description = new StringType(); 1505 this.description.setValue(value); 1506 } 1507 return this; 1508 } 1509 1510 /** 1511 * @return {@link #supportingInformation} (Additional information to support the appointment provided when making the appointment.) 1512 */ 1513 public List<Reference> getSupportingInformation() { 1514 if (this.supportingInformation == null) 1515 this.supportingInformation = new ArrayList<Reference>(); 1516 return this.supportingInformation; 1517 } 1518 1519 /** 1520 * @return Returns a reference to <code>this</code> for easy method chaining 1521 */ 1522 public Appointment setSupportingInformation(List<Reference> theSupportingInformation) { 1523 this.supportingInformation = theSupportingInformation; 1524 return this; 1525 } 1526 1527 public boolean hasSupportingInformation() { 1528 if (this.supportingInformation == null) 1529 return false; 1530 for (Reference item : this.supportingInformation) 1531 if (!item.isEmpty()) 1532 return true; 1533 return false; 1534 } 1535 1536 public Reference addSupportingInformation() { //3 1537 Reference t = new Reference(); 1538 if (this.supportingInformation == null) 1539 this.supportingInformation = new ArrayList<Reference>(); 1540 this.supportingInformation.add(t); 1541 return t; 1542 } 1543 1544 public Appointment addSupportingInformation(Reference t) { //3 1545 if (t == null) 1546 return this; 1547 if (this.supportingInformation == null) 1548 this.supportingInformation = new ArrayList<Reference>(); 1549 this.supportingInformation.add(t); 1550 return this; 1551 } 1552 1553 /** 1554 * @return The first repetition of repeating field {@link #supportingInformation}, creating it if it does not already exist {3} 1555 */ 1556 public Reference getSupportingInformationFirstRep() { 1557 if (getSupportingInformation().isEmpty()) { 1558 addSupportingInformation(); 1559 } 1560 return getSupportingInformation().get(0); 1561 } 1562 1563 /** 1564 * @return {@link #start} (Date/Time that the appointment is to take place.). This is the underlying object with id, value and extensions. The accessor "getStart" gives direct access to the value 1565 */ 1566 public InstantType getStartElement() { 1567 if (this.start == null) 1568 if (Configuration.errorOnAutoCreate()) 1569 throw new Error("Attempt to auto-create Appointment.start"); 1570 else if (Configuration.doAutoCreate()) 1571 this.start = new InstantType(); // bb 1572 return this.start; 1573 } 1574 1575 public boolean hasStartElement() { 1576 return this.start != null && !this.start.isEmpty(); 1577 } 1578 1579 public boolean hasStart() { 1580 return this.start != null && !this.start.isEmpty(); 1581 } 1582 1583 /** 1584 * @param value {@link #start} (Date/Time that the appointment is to take place.). This is the underlying object with id, value and extensions. The accessor "getStart" gives direct access to the value 1585 */ 1586 public Appointment setStartElement(InstantType value) { 1587 this.start = value; 1588 return this; 1589 } 1590 1591 /** 1592 * @return Date/Time that the appointment is to take place. 1593 */ 1594 public Date getStart() { 1595 return this.start == null ? null : this.start.getValue(); 1596 } 1597 1598 /** 1599 * @param value Date/Time that the appointment is to take place. 1600 */ 1601 public Appointment setStart(Date value) { 1602 if (value == null) 1603 this.start = null; 1604 else { 1605 if (this.start == null) 1606 this.start = new InstantType(); 1607 this.start.setValue(value); 1608 } 1609 return this; 1610 } 1611 1612 /** 1613 * @return {@link #end} (Date/Time that the appointment is to conclude.). This is the underlying object with id, value and extensions. The accessor "getEnd" gives direct access to the value 1614 */ 1615 public InstantType getEndElement() { 1616 if (this.end == null) 1617 if (Configuration.errorOnAutoCreate()) 1618 throw new Error("Attempt to auto-create Appointment.end"); 1619 else if (Configuration.doAutoCreate()) 1620 this.end = new InstantType(); // bb 1621 return this.end; 1622 } 1623 1624 public boolean hasEndElement() { 1625 return this.end != null && !this.end.isEmpty(); 1626 } 1627 1628 public boolean hasEnd() { 1629 return this.end != null && !this.end.isEmpty(); 1630 } 1631 1632 /** 1633 * @param value {@link #end} (Date/Time that the appointment is to conclude.). This is the underlying object with id, value and extensions. The accessor "getEnd" gives direct access to the value 1634 */ 1635 public Appointment setEndElement(InstantType value) { 1636 this.end = value; 1637 return this; 1638 } 1639 1640 /** 1641 * @return Date/Time that the appointment is to conclude. 1642 */ 1643 public Date getEnd() { 1644 return this.end == null ? null : this.end.getValue(); 1645 } 1646 1647 /** 1648 * @param value Date/Time that the appointment is to conclude. 1649 */ 1650 public Appointment setEnd(Date value) { 1651 if (value == null) 1652 this.end = null; 1653 else { 1654 if (this.end == null) 1655 this.end = new InstantType(); 1656 this.end.setValue(value); 1657 } 1658 return this; 1659 } 1660 1661 /** 1662 * @return {@link #minutesDuration} (Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end.). This is the underlying object with id, value and extensions. The accessor "getMinutesDuration" gives direct access to the value 1663 */ 1664 public PositiveIntType getMinutesDurationElement() { 1665 if (this.minutesDuration == null) 1666 if (Configuration.errorOnAutoCreate()) 1667 throw new Error("Attempt to auto-create Appointment.minutesDuration"); 1668 else if (Configuration.doAutoCreate()) 1669 this.minutesDuration = new PositiveIntType(); // bb 1670 return this.minutesDuration; 1671 } 1672 1673 public boolean hasMinutesDurationElement() { 1674 return this.minutesDuration != null && !this.minutesDuration.isEmpty(); 1675 } 1676 1677 public boolean hasMinutesDuration() { 1678 return this.minutesDuration != null && !this.minutesDuration.isEmpty(); 1679 } 1680 1681 /** 1682 * @param value {@link #minutesDuration} (Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end.). This is the underlying object with id, value and extensions. The accessor "getMinutesDuration" gives direct access to the value 1683 */ 1684 public Appointment setMinutesDurationElement(PositiveIntType value) { 1685 this.minutesDuration = value; 1686 return this; 1687 } 1688 1689 /** 1690 * @return Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end. 1691 */ 1692 public int getMinutesDuration() { 1693 return this.minutesDuration == null || this.minutesDuration.isEmpty() ? 0 : this.minutesDuration.getValue(); 1694 } 1695 1696 /** 1697 * @param value Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end. 1698 */ 1699 public Appointment setMinutesDuration(int value) { 1700 if (this.minutesDuration == null) 1701 this.minutesDuration = new PositiveIntType(); 1702 this.minutesDuration.setValue(value); 1703 return this; 1704 } 1705 1706 /** 1707 * @return {@link #slot} (The slots from the participants' schedules that will be filled by the appointment.) 1708 */ 1709 public List<Reference> getSlot() { 1710 if (this.slot == null) 1711 this.slot = new ArrayList<Reference>(); 1712 return this.slot; 1713 } 1714 1715 /** 1716 * @return Returns a reference to <code>this</code> for easy method chaining 1717 */ 1718 public Appointment setSlot(List<Reference> theSlot) { 1719 this.slot = theSlot; 1720 return this; 1721 } 1722 1723 public boolean hasSlot() { 1724 if (this.slot == null) 1725 return false; 1726 for (Reference item : this.slot) 1727 if (!item.isEmpty()) 1728 return true; 1729 return false; 1730 } 1731 1732 public Reference addSlot() { //3 1733 Reference t = new Reference(); 1734 if (this.slot == null) 1735 this.slot = new ArrayList<Reference>(); 1736 this.slot.add(t); 1737 return t; 1738 } 1739 1740 public Appointment addSlot(Reference t) { //3 1741 if (t == null) 1742 return this; 1743 if (this.slot == null) 1744 this.slot = new ArrayList<Reference>(); 1745 this.slot.add(t); 1746 return this; 1747 } 1748 1749 /** 1750 * @return The first repetition of repeating field {@link #slot}, creating it if it does not already exist {3} 1751 */ 1752 public Reference getSlotFirstRep() { 1753 if (getSlot().isEmpty()) { 1754 addSlot(); 1755 } 1756 return getSlot().get(0); 1757 } 1758 1759 /** 1760 * @return {@link #created} (The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 1761 */ 1762 public DateTimeType getCreatedElement() { 1763 if (this.created == null) 1764 if (Configuration.errorOnAutoCreate()) 1765 throw new Error("Attempt to auto-create Appointment.created"); 1766 else if (Configuration.doAutoCreate()) 1767 this.created = new DateTimeType(); // bb 1768 return this.created; 1769 } 1770 1771 public boolean hasCreatedElement() { 1772 return this.created != null && !this.created.isEmpty(); 1773 } 1774 1775 public boolean hasCreated() { 1776 return this.created != null && !this.created.isEmpty(); 1777 } 1778 1779 /** 1780 * @param value {@link #created} (The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 1781 */ 1782 public Appointment setCreatedElement(DateTimeType value) { 1783 this.created = value; 1784 return this; 1785 } 1786 1787 /** 1788 * @return The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment. 1789 */ 1790 public Date getCreated() { 1791 return this.created == null ? null : this.created.getValue(); 1792 } 1793 1794 /** 1795 * @param value The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment. 1796 */ 1797 public Appointment setCreated(Date value) { 1798 if (value == null) 1799 this.created = null; 1800 else { 1801 if (this.created == null) 1802 this.created = new DateTimeType(); 1803 this.created.setValue(value); 1804 } 1805 return this; 1806 } 1807 1808 /** 1809 * @return {@link #comment} (Additional comments about the appointment.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 1810 */ 1811 public StringType getCommentElement() { 1812 if (this.comment == null) 1813 if (Configuration.errorOnAutoCreate()) 1814 throw new Error("Attempt to auto-create Appointment.comment"); 1815 else if (Configuration.doAutoCreate()) 1816 this.comment = new StringType(); // bb 1817 return this.comment; 1818 } 1819 1820 public boolean hasCommentElement() { 1821 return this.comment != null && !this.comment.isEmpty(); 1822 } 1823 1824 public boolean hasComment() { 1825 return this.comment != null && !this.comment.isEmpty(); 1826 } 1827 1828 /** 1829 * @param value {@link #comment} (Additional comments about the appointment.). This is the underlying object with id, value and extensions. The accessor "getComment" gives direct access to the value 1830 */ 1831 public Appointment setCommentElement(StringType value) { 1832 this.comment = value; 1833 return this; 1834 } 1835 1836 /** 1837 * @return Additional comments about the appointment. 1838 */ 1839 public String getComment() { 1840 return this.comment == null ? null : this.comment.getValue(); 1841 } 1842 1843 /** 1844 * @param value Additional comments about the appointment. 1845 */ 1846 public Appointment setComment(String value) { 1847 if (Utilities.noString(value)) 1848 this.comment = null; 1849 else { 1850 if (this.comment == null) 1851 this.comment = new StringType(); 1852 this.comment.setValue(value); 1853 } 1854 return this; 1855 } 1856 1857 /** 1858 * @return {@link #patientInstruction} (While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before).). This is the underlying object with id, value and extensions. The accessor "getPatientInstruction" gives direct access to the value 1859 */ 1860 public StringType getPatientInstructionElement() { 1861 if (this.patientInstruction == null) 1862 if (Configuration.errorOnAutoCreate()) 1863 throw new Error("Attempt to auto-create Appointment.patientInstruction"); 1864 else if (Configuration.doAutoCreate()) 1865 this.patientInstruction = new StringType(); // bb 1866 return this.patientInstruction; 1867 } 1868 1869 public boolean hasPatientInstructionElement() { 1870 return this.patientInstruction != null && !this.patientInstruction.isEmpty(); 1871 } 1872 1873 public boolean hasPatientInstruction() { 1874 return this.patientInstruction != null && !this.patientInstruction.isEmpty(); 1875 } 1876 1877 /** 1878 * @param value {@link #patientInstruction} (While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before).). This is the underlying object with id, value and extensions. The accessor "getPatientInstruction" gives direct access to the value 1879 */ 1880 public Appointment setPatientInstructionElement(StringType value) { 1881 this.patientInstruction = value; 1882 return this; 1883 } 1884 1885 /** 1886 * @return While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before). 1887 */ 1888 public String getPatientInstruction() { 1889 return this.patientInstruction == null ? null : this.patientInstruction.getValue(); 1890 } 1891 1892 /** 1893 * @param value While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before). 1894 */ 1895 public Appointment setPatientInstruction(String value) { 1896 if (Utilities.noString(value)) 1897 this.patientInstruction = null; 1898 else { 1899 if (this.patientInstruction == null) 1900 this.patientInstruction = new StringType(); 1901 this.patientInstruction.setValue(value); 1902 } 1903 return this; 1904 } 1905 1906 /** 1907 * @return {@link #basedOn} (The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).) 1908 */ 1909 public List<Reference> getBasedOn() { 1910 if (this.basedOn == null) 1911 this.basedOn = new ArrayList<Reference>(); 1912 return this.basedOn; 1913 } 1914 1915 /** 1916 * @return Returns a reference to <code>this</code> for easy method chaining 1917 */ 1918 public Appointment setBasedOn(List<Reference> theBasedOn) { 1919 this.basedOn = theBasedOn; 1920 return this; 1921 } 1922 1923 public boolean hasBasedOn() { 1924 if (this.basedOn == null) 1925 return false; 1926 for (Reference item : this.basedOn) 1927 if (!item.isEmpty()) 1928 return true; 1929 return false; 1930 } 1931 1932 public Reference addBasedOn() { //3 1933 Reference t = new Reference(); 1934 if (this.basedOn == null) 1935 this.basedOn = new ArrayList<Reference>(); 1936 this.basedOn.add(t); 1937 return t; 1938 } 1939 1940 public Appointment addBasedOn(Reference t) { //3 1941 if (t == null) 1942 return this; 1943 if (this.basedOn == null) 1944 this.basedOn = new ArrayList<Reference>(); 1945 this.basedOn.add(t); 1946 return this; 1947 } 1948 1949 /** 1950 * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist {3} 1951 */ 1952 public Reference getBasedOnFirstRep() { 1953 if (getBasedOn().isEmpty()) { 1954 addBasedOn(); 1955 } 1956 return getBasedOn().get(0); 1957 } 1958 1959 /** 1960 * @return {@link #participant} (List of participants involved in the appointment.) 1961 */ 1962 public List<AppointmentParticipantComponent> getParticipant() { 1963 if (this.participant == null) 1964 this.participant = new ArrayList<AppointmentParticipantComponent>(); 1965 return this.participant; 1966 } 1967 1968 /** 1969 * @return Returns a reference to <code>this</code> for easy method chaining 1970 */ 1971 public Appointment setParticipant(List<AppointmentParticipantComponent> theParticipant) { 1972 this.participant = theParticipant; 1973 return this; 1974 } 1975 1976 public boolean hasParticipant() { 1977 if (this.participant == null) 1978 return false; 1979 for (AppointmentParticipantComponent item : this.participant) 1980 if (!item.isEmpty()) 1981 return true; 1982 return false; 1983 } 1984 1985 public AppointmentParticipantComponent addParticipant() { //3 1986 AppointmentParticipantComponent t = new AppointmentParticipantComponent(); 1987 if (this.participant == null) 1988 this.participant = new ArrayList<AppointmentParticipantComponent>(); 1989 this.participant.add(t); 1990 return t; 1991 } 1992 1993 public Appointment addParticipant(AppointmentParticipantComponent t) { //3 1994 if (t == null) 1995 return this; 1996 if (this.participant == null) 1997 this.participant = new ArrayList<AppointmentParticipantComponent>(); 1998 this.participant.add(t); 1999 return this; 2000 } 2001 2002 /** 2003 * @return The first repetition of repeating field {@link #participant}, creating it if it does not already exist {3} 2004 */ 2005 public AppointmentParticipantComponent getParticipantFirstRep() { 2006 if (getParticipant().isEmpty()) { 2007 addParticipant(); 2008 } 2009 return getParticipant().get(0); 2010 } 2011 2012 /** 2013 * @return {@link #requestedPeriod} (A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within. 2014 2015The duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.) 2016 */ 2017 public List<Period> getRequestedPeriod() { 2018 if (this.requestedPeriod == null) 2019 this.requestedPeriod = new ArrayList<Period>(); 2020 return this.requestedPeriod; 2021 } 2022 2023 /** 2024 * @return Returns a reference to <code>this</code> for easy method chaining 2025 */ 2026 public Appointment setRequestedPeriod(List<Period> theRequestedPeriod) { 2027 this.requestedPeriod = theRequestedPeriod; 2028 return this; 2029 } 2030 2031 public boolean hasRequestedPeriod() { 2032 if (this.requestedPeriod == null) 2033 return false; 2034 for (Period item : this.requestedPeriod) 2035 if (!item.isEmpty()) 2036 return true; 2037 return false; 2038 } 2039 2040 public Period addRequestedPeriod() { //3 2041 Period t = new Period(); 2042 if (this.requestedPeriod == null) 2043 this.requestedPeriod = new ArrayList<Period>(); 2044 this.requestedPeriod.add(t); 2045 return t; 2046 } 2047 2048 public Appointment addRequestedPeriod(Period t) { //3 2049 if (t == null) 2050 return this; 2051 if (this.requestedPeriod == null) 2052 this.requestedPeriod = new ArrayList<Period>(); 2053 this.requestedPeriod.add(t); 2054 return this; 2055 } 2056 2057 /** 2058 * @return The first repetition of repeating field {@link #requestedPeriod}, creating it if it does not already exist {3} 2059 */ 2060 public Period getRequestedPeriodFirstRep() { 2061 if (getRequestedPeriod().isEmpty()) { 2062 addRequestedPeriod(); 2063 } 2064 return getRequestedPeriod().get(0); 2065 } 2066 2067 protected void listChildren(List<Property> children) { 2068 super.listChildren(children); 2069 children.add(new Property("identifier", "Identifier", "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).", 0, java.lang.Integer.MAX_VALUE, identifier)); 2070 children.add(new Property("status", "code", "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status.", 0, 1, status)); 2071 children.add(new Property("cancelationReason", "CodeableConcept", "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.", 0, 1, cancelationReason)); 2072 children.add(new Property("serviceCategory", "CodeableConcept", "A broad categorization of the service that is to be performed during this appointment.", 0, java.lang.Integer.MAX_VALUE, serviceCategory)); 2073 children.add(new Property("serviceType", "CodeableConcept", "The specific service that is to be performed during this appointment.", 0, java.lang.Integer.MAX_VALUE, serviceType)); 2074 children.add(new Property("specialty", "CodeableConcept", "The specialty of a practitioner that would be required to perform the service requested in this appointment.", 0, java.lang.Integer.MAX_VALUE, specialty)); 2075 children.add(new Property("appointmentType", "CodeableConcept", "The style of appointment or patient that has been booked in the slot (not service type).", 0, 1, appointmentType)); 2076 children.add(new Property("reasonCode", "CodeableConcept", "The coded reason that this appointment is being scheduled. This is more clinical than administrative.", 0, java.lang.Integer.MAX_VALUE, reasonCode)); 2077 children.add(new Property("reasonReference", "Reference(Condition|Procedure|Observation|ImmunizationRecommendation)", "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.", 0, java.lang.Integer.MAX_VALUE, reasonReference)); 2078 children.add(new Property("priority", "unsignedInt", "The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority).", 0, 1, priority)); 2079 children.add(new Property("description", "string", "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field.", 0, 1, description)); 2080 children.add(new Property("supportingInformation", "Reference(Any)", "Additional information to support the appointment provided when making the appointment.", 0, java.lang.Integer.MAX_VALUE, supportingInformation)); 2081 children.add(new Property("start", "instant", "Date/Time that the appointment is to take place.", 0, 1, start)); 2082 children.add(new Property("end", "instant", "Date/Time that the appointment is to conclude.", 0, 1, end)); 2083 children.add(new Property("minutesDuration", "positiveInt", "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end.", 0, 1, minutesDuration)); 2084 children.add(new Property("slot", "Reference(Slot)", "The slots from the participants' schedules that will be filled by the appointment.", 0, java.lang.Integer.MAX_VALUE, slot)); 2085 children.add(new Property("created", "dateTime", "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment.", 0, 1, created)); 2086 children.add(new Property("comment", "string", "Additional comments about the appointment.", 0, 1, comment)); 2087 children.add(new Property("patientInstruction", "string", "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before).", 0, 1, patientInstruction)); 2088 children.add(new Property("basedOn", "Reference(ServiceRequest)", "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).", 0, java.lang.Integer.MAX_VALUE, basedOn)); 2089 children.add(new Property("participant", "", "List of participants involved in the appointment.", 0, java.lang.Integer.MAX_VALUE, participant)); 2090 children.add(new Property("requestedPeriod", "Period", "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.", 0, java.lang.Integer.MAX_VALUE, requestedPeriod)); 2091 } 2092 2093 @Override 2094 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2095 switch (_hash) { 2096 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "This records identifiers associated with this appointment concern that are defined by business processes and/or used to refer to it when a direct URL reference to the resource itself is not appropriate (e.g. in CDA documents, or in written / printed documentation).", 0, java.lang.Integer.MAX_VALUE, identifier); 2097 case -892481550: /*status*/ return new Property("status", "code", "The overall status of the Appointment. Each of the participants has their own participation status which indicates their involvement in the process, however this status indicates the shared status.", 0, 1, status); 2098 case 987811551: /*cancelationReason*/ return new Property("cancelationReason", "CodeableConcept", "The coded reason for the appointment being cancelled. This is often used in reporting/billing/futher processing to determine if further actions are required, or specific fees apply.", 0, 1, cancelationReason); 2099 case 1281188563: /*serviceCategory*/ return new Property("serviceCategory", "CodeableConcept", "A broad categorization of the service that is to be performed during this appointment.", 0, java.lang.Integer.MAX_VALUE, serviceCategory); 2100 case -1928370289: /*serviceType*/ return new Property("serviceType", "CodeableConcept", "The specific service that is to be performed during this appointment.", 0, java.lang.Integer.MAX_VALUE, serviceType); 2101 case -1694759682: /*specialty*/ return new Property("specialty", "CodeableConcept", "The specialty of a practitioner that would be required to perform the service requested in this appointment.", 0, java.lang.Integer.MAX_VALUE, specialty); 2102 case -1596426375: /*appointmentType*/ return new Property("appointmentType", "CodeableConcept", "The style of appointment or patient that has been booked in the slot (not service type).", 0, 1, appointmentType); 2103 case 722137681: /*reasonCode*/ return new Property("reasonCode", "CodeableConcept", "The coded reason that this appointment is being scheduled. This is more clinical than administrative.", 0, java.lang.Integer.MAX_VALUE, reasonCode); 2104 case -1146218137: /*reasonReference*/ return new Property("reasonReference", "Reference(Condition|Procedure|Observation|ImmunizationRecommendation)", "Reason the appointment has been scheduled to take place, as specified using information from another resource. When the patient arrives and the encounter begins it may be used as the admission diagnosis. The indication will typically be a Condition (with other resources referenced in the evidence.detail), or a Procedure.", 0, java.lang.Integer.MAX_VALUE, reasonReference); 2105 case -1165461084: /*priority*/ return new Property("priority", "unsignedInt", "The priority of the appointment. Can be used to make informed decisions if needing to re-prioritize appointments. (The iCal Standard specifies 0 as undefined, 1 as highest, 9 as lowest priority).", 0, 1, priority); 2106 case -1724546052: /*description*/ return new Property("description", "string", "The brief description of the appointment as would be shown on a subject line in a meeting request, or appointment list. Detailed or expanded information should be put in the comment field.", 0, 1, description); 2107 case -1248768647: /*supportingInformation*/ return new Property("supportingInformation", "Reference(Any)", "Additional information to support the appointment provided when making the appointment.", 0, java.lang.Integer.MAX_VALUE, supportingInformation); 2108 case 109757538: /*start*/ return new Property("start", "instant", "Date/Time that the appointment is to take place.", 0, 1, start); 2109 case 100571: /*end*/ return new Property("end", "instant", "Date/Time that the appointment is to conclude.", 0, 1, end); 2110 case -413630573: /*minutesDuration*/ return new Property("minutesDuration", "positiveInt", "Number of minutes that the appointment is to take. This can be less than the duration between the start and end times. For example, where the actual time of appointment is only an estimate or if a 30 minute appointment is being requested, but any time would work. Also, if there is, for example, a planned 15 minute break in the middle of a long appointment, the duration may be 15 minutes less than the difference between the start and end.", 0, 1, minutesDuration); 2111 case 3533310: /*slot*/ return new Property("slot", "Reference(Slot)", "The slots from the participants' schedules that will be filled by the appointment.", 0, java.lang.Integer.MAX_VALUE, slot); 2112 case 1028554472: /*created*/ return new Property("created", "dateTime", "The date that this appointment was initially created. This could be different to the meta.lastModified value on the initial entry, as this could have been before the resource was created on the FHIR server, and should remain unchanged over the lifespan of the appointment.", 0, 1, created); 2113 case 950398559: /*comment*/ return new Property("comment", "string", "Additional comments about the appointment.", 0, 1, comment); 2114 case 737543241: /*patientInstruction*/ return new Property("patientInstruction", "string", "While Appointment.comment contains information for internal use, Appointment.patientInstructions is used to capture patient facing information about the Appointment (e.g. please bring your referral or fast from 8pm night before).", 0, 1, patientInstruction); 2115 case -332612366: /*basedOn*/ return new Property("basedOn", "Reference(ServiceRequest)", "The service request this appointment is allocated to assess (e.g. incoming referral or procedure request).", 0, java.lang.Integer.MAX_VALUE, basedOn); 2116 case 767422259: /*participant*/ return new Property("participant", "", "List of participants involved in the appointment.", 0, java.lang.Integer.MAX_VALUE, participant); 2117 case -897241393: /*requestedPeriod*/ return new Property("requestedPeriod", "Period", "A set of date ranges (potentially including times) that the appointment is preferred to be scheduled within.\n\nThe duration (usually in minutes) could also be provided to indicate the length of the appointment to fill and populate the start/end times for the actual allocated time. However, in other situations the duration may be calculated by the scheduling system.", 0, java.lang.Integer.MAX_VALUE, requestedPeriod); 2118 default: return super.getNamedProperty(_hash, _name, _checkValid); 2119 } 2120 2121 } 2122 2123 @Override 2124 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2125 switch (hash) { 2126 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 2127 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<AppointmentStatus> 2128 case 987811551: /*cancelationReason*/ return this.cancelationReason == null ? new Base[0] : new Base[] {this.cancelationReason}; // CodeableConcept 2129 case 1281188563: /*serviceCategory*/ return this.serviceCategory == null ? new Base[0] : this.serviceCategory.toArray(new Base[this.serviceCategory.size()]); // CodeableConcept 2130 case -1928370289: /*serviceType*/ return this.serviceType == null ? new Base[0] : this.serviceType.toArray(new Base[this.serviceType.size()]); // CodeableConcept 2131 case -1694759682: /*specialty*/ return this.specialty == null ? new Base[0] : this.specialty.toArray(new Base[this.specialty.size()]); // CodeableConcept 2132 case -1596426375: /*appointmentType*/ return this.appointmentType == null ? new Base[0] : new Base[] {this.appointmentType}; // CodeableConcept 2133 case 722137681: /*reasonCode*/ return this.reasonCode == null ? new Base[0] : this.reasonCode.toArray(new Base[this.reasonCode.size()]); // CodeableConcept 2134 case -1146218137: /*reasonReference*/ return this.reasonReference == null ? new Base[0] : this.reasonReference.toArray(new Base[this.reasonReference.size()]); // Reference 2135 case -1165461084: /*priority*/ return this.priority == null ? new Base[0] : new Base[] {this.priority}; // UnsignedIntType 2136 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 2137 case -1248768647: /*supportingInformation*/ return this.supportingInformation == null ? new Base[0] : this.supportingInformation.toArray(new Base[this.supportingInformation.size()]); // Reference 2138 case 109757538: /*start*/ return this.start == null ? new Base[0] : new Base[] {this.start}; // InstantType 2139 case 100571: /*end*/ return this.end == null ? new Base[0] : new Base[] {this.end}; // InstantType 2140 case -413630573: /*minutesDuration*/ return this.minutesDuration == null ? new Base[0] : new Base[] {this.minutesDuration}; // PositiveIntType 2141 case 3533310: /*slot*/ return this.slot == null ? new Base[0] : this.slot.toArray(new Base[this.slot.size()]); // Reference 2142 case 1028554472: /*created*/ return this.created == null ? new Base[0] : new Base[] {this.created}; // DateTimeType 2143 case 950398559: /*comment*/ return this.comment == null ? new Base[0] : new Base[] {this.comment}; // StringType 2144 case 737543241: /*patientInstruction*/ return this.patientInstruction == null ? new Base[0] : new Base[] {this.patientInstruction}; // StringType 2145 case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference 2146 case 767422259: /*participant*/ return this.participant == null ? new Base[0] : this.participant.toArray(new Base[this.participant.size()]); // AppointmentParticipantComponent 2147 case -897241393: /*requestedPeriod*/ return this.requestedPeriod == null ? new Base[0] : this.requestedPeriod.toArray(new Base[this.requestedPeriod.size()]); // Period 2148 default: return super.getProperty(hash, name, checkValid); 2149 } 2150 2151 } 2152 2153 @Override 2154 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2155 switch (hash) { 2156 case -1618432855: // identifier 2157 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 2158 return value; 2159 case -892481550: // status 2160 value = new AppointmentStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 2161 this.status = (Enumeration) value; // Enumeration<AppointmentStatus> 2162 return value; 2163 case 987811551: // cancelationReason 2164 this.cancelationReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2165 return value; 2166 case 1281188563: // serviceCategory 2167 this.getServiceCategory().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 2168 return value; 2169 case -1928370289: // serviceType 2170 this.getServiceType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 2171 return value; 2172 case -1694759682: // specialty 2173 this.getSpecialty().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 2174 return value; 2175 case -1596426375: // appointmentType 2176 this.appointmentType = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2177 return value; 2178 case 722137681: // reasonCode 2179 this.getReasonCode().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 2180 return value; 2181 case -1146218137: // reasonReference 2182 this.getReasonReference().add(TypeConvertor.castToReference(value)); // Reference 2183 return value; 2184 case -1165461084: // priority 2185 this.priority = TypeConvertor.castToUnsignedInt(value); // UnsignedIntType 2186 return value; 2187 case -1724546052: // description 2188 this.description = TypeConvertor.castToString(value); // StringType 2189 return value; 2190 case -1248768647: // supportingInformation 2191 this.getSupportingInformation().add(TypeConvertor.castToReference(value)); // Reference 2192 return value; 2193 case 109757538: // start 2194 this.start = TypeConvertor.castToInstant(value); // InstantType 2195 return value; 2196 case 100571: // end 2197 this.end = TypeConvertor.castToInstant(value); // InstantType 2198 return value; 2199 case -413630573: // minutesDuration 2200 this.minutesDuration = TypeConvertor.castToPositiveInt(value); // PositiveIntType 2201 return value; 2202 case 3533310: // slot 2203 this.getSlot().add(TypeConvertor.castToReference(value)); // Reference 2204 return value; 2205 case 1028554472: // created 2206 this.created = TypeConvertor.castToDateTime(value); // DateTimeType 2207 return value; 2208 case 950398559: // comment 2209 this.comment = TypeConvertor.castToString(value); // StringType 2210 return value; 2211 case 737543241: // patientInstruction 2212 this.patientInstruction = TypeConvertor.castToString(value); // StringType 2213 return value; 2214 case -332612366: // basedOn 2215 this.getBasedOn().add(TypeConvertor.castToReference(value)); // Reference 2216 return value; 2217 case 767422259: // participant 2218 this.getParticipant().add((AppointmentParticipantComponent) value); // AppointmentParticipantComponent 2219 return value; 2220 case -897241393: // requestedPeriod 2221 this.getRequestedPeriod().add(TypeConvertor.castToPeriod(value)); // Period 2222 return value; 2223 default: return super.setProperty(hash, name, value); 2224 } 2225 2226 } 2227 2228 @Override 2229 public Base setProperty(String name, Base value) throws FHIRException { 2230 if (name.equals("identifier")) { 2231 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 2232 } else if (name.equals("status")) { 2233 value = new AppointmentStatusEnumFactory().fromType(TypeConvertor.castToCode(value)); 2234 this.status = (Enumeration) value; // Enumeration<AppointmentStatus> 2235 } else if (name.equals("cancelationReason")) { 2236 this.cancelationReason = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2237 } else if (name.equals("serviceCategory")) { 2238 this.getServiceCategory().add(TypeConvertor.castToCodeableConcept(value)); 2239 } else if (name.equals("serviceType")) { 2240 this.getServiceType().add(TypeConvertor.castToCodeableConcept(value)); 2241 } else if (name.equals("specialty")) { 2242 this.getSpecialty().add(TypeConvertor.castToCodeableConcept(value)); 2243 } else if (name.equals("appointmentType")) { 2244 this.appointmentType = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 2245 } else if (name.equals("reasonCode")) { 2246 this.getReasonCode().add(TypeConvertor.castToCodeableConcept(value)); 2247 } else if (name.equals("reasonReference")) { 2248 this.getReasonReference().add(TypeConvertor.castToReference(value)); 2249 } else if (name.equals("priority")) { 2250 this.priority = TypeConvertor.castToUnsignedInt(value); // UnsignedIntType 2251 } else if (name.equals("description")) { 2252 this.description = TypeConvertor.castToString(value); // StringType 2253 } else if (name.equals("supportingInformation")) { 2254 this.getSupportingInformation().add(TypeConvertor.castToReference(value)); 2255 } else if (name.equals("start")) { 2256 this.start = TypeConvertor.castToInstant(value); // InstantType 2257 } else if (name.equals("end")) { 2258 this.end = TypeConvertor.castToInstant(value); // InstantType 2259 } else if (name.equals("minutesDuration")) { 2260 this.minutesDuration = TypeConvertor.castToPositiveInt(value); // PositiveIntType 2261 } else if (name.equals("slot")) { 2262 this.getSlot().add(TypeConvertor.castToReference(value)); 2263 } else if (name.equals("created")) { 2264 this.created = TypeConvertor.castToDateTime(value); // DateTimeType 2265 } else if (name.equals("comment")) { 2266 this.comment = TypeConvertor.castToString(value); // StringType 2267 } else if (name.equals("patientInstruction")) { 2268 this.patientInstruction = TypeConvertor.castToString(value); // StringType 2269 } else if (name.equals("basedOn")) { 2270 this.getBasedOn().add(TypeConvertor.castToReference(value)); 2271 } else if (name.equals("participant")) { 2272 this.getParticipant().add((AppointmentParticipantComponent) value); 2273 } else if (name.equals("requestedPeriod")) { 2274 this.getRequestedPeriod().add(TypeConvertor.castToPeriod(value)); 2275 } else 2276 return super.setProperty(name, value); 2277 return value; 2278 } 2279 2280 @Override 2281 public Base makeProperty(int hash, String name) throws FHIRException { 2282 switch (hash) { 2283 case -1618432855: return addIdentifier(); 2284 case -892481550: return getStatusElement(); 2285 case 987811551: return getCancelationReason(); 2286 case 1281188563: return addServiceCategory(); 2287 case -1928370289: return addServiceType(); 2288 case -1694759682: return addSpecialty(); 2289 case -1596426375: return getAppointmentType(); 2290 case 722137681: return addReasonCode(); 2291 case -1146218137: return addReasonReference(); 2292 case -1165461084: return getPriorityElement(); 2293 case -1724546052: return getDescriptionElement(); 2294 case -1248768647: return addSupportingInformation(); 2295 case 109757538: return getStartElement(); 2296 case 100571: return getEndElement(); 2297 case -413630573: return getMinutesDurationElement(); 2298 case 3533310: return addSlot(); 2299 case 1028554472: return getCreatedElement(); 2300 case 950398559: return getCommentElement(); 2301 case 737543241: return getPatientInstructionElement(); 2302 case -332612366: return addBasedOn(); 2303 case 767422259: return addParticipant(); 2304 case -897241393: return addRequestedPeriod(); 2305 default: return super.makeProperty(hash, name); 2306 } 2307 2308 } 2309 2310 @Override 2311 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2312 switch (hash) { 2313 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 2314 case -892481550: /*status*/ return new String[] {"code"}; 2315 case 987811551: /*cancelationReason*/ return new String[] {"CodeableConcept"}; 2316 case 1281188563: /*serviceCategory*/ return new String[] {"CodeableConcept"}; 2317 case -1928370289: /*serviceType*/ return new String[] {"CodeableConcept"}; 2318 case -1694759682: /*specialty*/ return new String[] {"CodeableConcept"}; 2319 case -1596426375: /*appointmentType*/ return new String[] {"CodeableConcept"}; 2320 case 722137681: /*reasonCode*/ return new String[] {"CodeableConcept"}; 2321 case -1146218137: /*reasonReference*/ return new String[] {"Reference"}; 2322 case -1165461084: /*priority*/ return new String[] {"unsignedInt"}; 2323 case -1724546052: /*description*/ return new String[] {"string"}; 2324 case -1248768647: /*supportingInformation*/ return new String[] {"Reference"}; 2325 case 109757538: /*start*/ return new String[] {"instant"}; 2326 case 100571: /*end*/ return new String[] {"instant"}; 2327 case -413630573: /*minutesDuration*/ return new String[] {"positiveInt"}; 2328 case 3533310: /*slot*/ return new String[] {"Reference"}; 2329 case 1028554472: /*created*/ return new String[] {"dateTime"}; 2330 case 950398559: /*comment*/ return new String[] {"string"}; 2331 case 737543241: /*patientInstruction*/ return new String[] {"string"}; 2332 case -332612366: /*basedOn*/ return new String[] {"Reference"}; 2333 case 767422259: /*participant*/ return new String[] {}; 2334 case -897241393: /*requestedPeriod*/ return new String[] {"Period"}; 2335 default: return super.getTypesForProperty(hash, name); 2336 } 2337 2338 } 2339 2340 @Override 2341 public Base addChild(String name) throws FHIRException { 2342 if (name.equals("identifier")) { 2343 return addIdentifier(); 2344 } 2345 else if (name.equals("status")) { 2346 throw new FHIRException("Cannot call addChild on a primitive type Appointment.status"); 2347 } 2348 else if (name.equals("cancelationReason")) { 2349 this.cancelationReason = new CodeableConcept(); 2350 return this.cancelationReason; 2351 } 2352 else if (name.equals("serviceCategory")) { 2353 return addServiceCategory(); 2354 } 2355 else if (name.equals("serviceType")) { 2356 return addServiceType(); 2357 } 2358 else if (name.equals("specialty")) { 2359 return addSpecialty(); 2360 } 2361 else if (name.equals("appointmentType")) { 2362 this.appointmentType = new CodeableConcept(); 2363 return this.appointmentType; 2364 } 2365 else if (name.equals("reasonCode")) { 2366 return addReasonCode(); 2367 } 2368 else if (name.equals("reasonReference")) { 2369 return addReasonReference(); 2370 } 2371 else if (name.equals("priority")) { 2372 throw new FHIRException("Cannot call addChild on a primitive type Appointment.priority"); 2373 } 2374 else if (name.equals("description")) { 2375 throw new FHIRException("Cannot call addChild on a primitive type Appointment.description"); 2376 } 2377 else if (name.equals("supportingInformation")) { 2378 return addSupportingInformation(); 2379 } 2380 else if (name.equals("start")) { 2381 throw new FHIRException("Cannot call addChild on a primitive type Appointment.start"); 2382 } 2383 else if (name.equals("end")) { 2384 throw new FHIRException("Cannot call addChild on a primitive type Appointment.end"); 2385 } 2386 else if (name.equals("minutesDuration")) { 2387 throw new FHIRException("Cannot call addChild on a primitive type Appointment.minutesDuration"); 2388 } 2389 else if (name.equals("slot")) { 2390 return addSlot(); 2391 } 2392 else if (name.equals("created")) { 2393 throw new FHIRException("Cannot call addChild on a primitive type Appointment.created"); 2394 } 2395 else if (name.equals("comment")) { 2396 throw new FHIRException("Cannot call addChild on a primitive type Appointment.comment"); 2397 } 2398 else if (name.equals("patientInstruction")) { 2399 throw new FHIRException("Cannot call addChild on a primitive type Appointment.patientInstruction"); 2400 } 2401 else if (name.equals("basedOn")) { 2402 return addBasedOn(); 2403 } 2404 else if (name.equals("participant")) { 2405 return addParticipant(); 2406 } 2407 else if (name.equals("requestedPeriod")) { 2408 return addRequestedPeriod(); 2409 } 2410 else 2411 return super.addChild(name); 2412 } 2413 2414 public String fhirType() { 2415 return "Appointment"; 2416 2417 } 2418 2419 public Appointment copy() { 2420 Appointment dst = new Appointment(); 2421 copyValues(dst); 2422 return dst; 2423 } 2424 2425 public void copyValues(Appointment dst) { 2426 super.copyValues(dst); 2427 if (identifier != null) { 2428 dst.identifier = new ArrayList<Identifier>(); 2429 for (Identifier i : identifier) 2430 dst.identifier.add(i.copy()); 2431 }; 2432 dst.status = status == null ? null : status.copy(); 2433 dst.cancelationReason = cancelationReason == null ? null : cancelationReason.copy(); 2434 if (serviceCategory != null) { 2435 dst.serviceCategory = new ArrayList<CodeableConcept>(); 2436 for (CodeableConcept i : serviceCategory) 2437 dst.serviceCategory.add(i.copy()); 2438 }; 2439 if (serviceType != null) { 2440 dst.serviceType = new ArrayList<CodeableConcept>(); 2441 for (CodeableConcept i : serviceType) 2442 dst.serviceType.add(i.copy()); 2443 }; 2444 if (specialty != null) { 2445 dst.specialty = new ArrayList<CodeableConcept>(); 2446 for (CodeableConcept i : specialty) 2447 dst.specialty.add(i.copy()); 2448 }; 2449 dst.appointmentType = appointmentType == null ? null : appointmentType.copy(); 2450 if (reasonCode != null) { 2451 dst.reasonCode = new ArrayList<CodeableConcept>(); 2452 for (CodeableConcept i : reasonCode) 2453 dst.reasonCode.add(i.copy()); 2454 }; 2455 if (reasonReference != null) { 2456 dst.reasonReference = new ArrayList<Reference>(); 2457 for (Reference i : reasonReference) 2458 dst.reasonReference.add(i.copy()); 2459 }; 2460 dst.priority = priority == null ? null : priority.copy(); 2461 dst.description = description == null ? null : description.copy(); 2462 if (supportingInformation != null) { 2463 dst.supportingInformation = new ArrayList<Reference>(); 2464 for (Reference i : supportingInformation) 2465 dst.supportingInformation.add(i.copy()); 2466 }; 2467 dst.start = start == null ? null : start.copy(); 2468 dst.end = end == null ? null : end.copy(); 2469 dst.minutesDuration = minutesDuration == null ? null : minutesDuration.copy(); 2470 if (slot != null) { 2471 dst.slot = new ArrayList<Reference>(); 2472 for (Reference i : slot) 2473 dst.slot.add(i.copy()); 2474 }; 2475 dst.created = created == null ? null : created.copy(); 2476 dst.comment = comment == null ? null : comment.copy(); 2477 dst.patientInstruction = patientInstruction == null ? null : patientInstruction.copy(); 2478 if (basedOn != null) { 2479 dst.basedOn = new ArrayList<Reference>(); 2480 for (Reference i : basedOn) 2481 dst.basedOn.add(i.copy()); 2482 }; 2483 if (participant != null) { 2484 dst.participant = new ArrayList<AppointmentParticipantComponent>(); 2485 for (AppointmentParticipantComponent i : participant) 2486 dst.participant.add(i.copy()); 2487 }; 2488 if (requestedPeriod != null) { 2489 dst.requestedPeriod = new ArrayList<Period>(); 2490 for (Period i : requestedPeriod) 2491 dst.requestedPeriod.add(i.copy()); 2492 }; 2493 } 2494 2495 protected Appointment typedCopy() { 2496 return copy(); 2497 } 2498 2499 @Override 2500 public boolean equalsDeep(Base other_) { 2501 if (!super.equalsDeep(other_)) 2502 return false; 2503 if (!(other_ instanceof Appointment)) 2504 return false; 2505 Appointment o = (Appointment) other_; 2506 return compareDeep(identifier, o.identifier, true) && compareDeep(status, o.status, true) && compareDeep(cancelationReason, o.cancelationReason, true) 2507 && compareDeep(serviceCategory, o.serviceCategory, true) && compareDeep(serviceType, o.serviceType, true) 2508 && compareDeep(specialty, o.specialty, true) && compareDeep(appointmentType, o.appointmentType, true) 2509 && compareDeep(reasonCode, o.reasonCode, true) && compareDeep(reasonReference, o.reasonReference, true) 2510 && compareDeep(priority, o.priority, true) && compareDeep(description, o.description, true) && compareDeep(supportingInformation, o.supportingInformation, true) 2511 && compareDeep(start, o.start, true) && compareDeep(end, o.end, true) && compareDeep(minutesDuration, o.minutesDuration, true) 2512 && compareDeep(slot, o.slot, true) && compareDeep(created, o.created, true) && compareDeep(comment, o.comment, true) 2513 && compareDeep(patientInstruction, o.patientInstruction, true) && compareDeep(basedOn, o.basedOn, true) 2514 && compareDeep(participant, o.participant, true) && compareDeep(requestedPeriod, o.requestedPeriod, true) 2515 ; 2516 } 2517 2518 @Override 2519 public boolean equalsShallow(Base other_) { 2520 if (!super.equalsShallow(other_)) 2521 return false; 2522 if (!(other_ instanceof Appointment)) 2523 return false; 2524 Appointment o = (Appointment) other_; 2525 return compareValues(status, o.status, true) && compareValues(priority, o.priority, true) && compareValues(description, o.description, true) 2526 && compareValues(start, o.start, true) && compareValues(end, o.end, true) && compareValues(minutesDuration, o.minutesDuration, true) 2527 && compareValues(created, o.created, true) && compareValues(comment, o.comment, true) && compareValues(patientInstruction, o.patientInstruction, true) 2528 ; 2529 } 2530 2531 public boolean isEmpty() { 2532 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, status, cancelationReason 2533 , serviceCategory, serviceType, specialty, appointmentType, reasonCode, reasonReference 2534 , priority, description, supportingInformation, start, end, minutesDuration, slot 2535 , created, comment, patientInstruction, basedOn, participant, requestedPeriod); 2536 } 2537 2538 @Override 2539 public ResourceType getResourceType() { 2540 return ResourceType.Appointment; 2541 } 2542 2543 /** 2544 * Search parameter: <b>actor</b> 2545 * <p> 2546 * Description: <b>Any one of the individuals participating in the appointment</b><br> 2547 * Type: <b>reference</b><br> 2548 * Path: <b>Appointment.participant.actor</b><br> 2549 * </p> 2550 */ 2551 @SearchParamDefinition(name="actor", path="Appointment.participant.actor", description="Any one of the individuals participating in the appointment", type="reference", providesMembershipIn={ @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Device"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Patient"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for Practitioner"), @ca.uhn.fhir.model.api.annotation.Compartment(name="Base FHIR compartment definition for RelatedPerson") }, target={Device.class, HealthcareService.class, Location.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2552 public static final String SP_ACTOR = "actor"; 2553 /** 2554 * <b>Fluent Client</b> search parameter constant for <b>actor</b> 2555 * <p> 2556 * Description: <b>Any one of the individuals participating in the appointment</b><br> 2557 * Type: <b>reference</b><br> 2558 * Path: <b>Appointment.participant.actor</b><br> 2559 * </p> 2560 */ 2561 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ACTOR = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ACTOR); 2562 2563/** 2564 * Constant for fluent queries to be used to add include statements. Specifies 2565 * the path value of "<b>Appointment:actor</b>". 2566 */ 2567 public static final ca.uhn.fhir.model.api.Include INCLUDE_ACTOR = new ca.uhn.fhir.model.api.Include("Appointment:actor").toLocked(); 2568 2569 /** 2570 * Search parameter: <b>appointment-type</b> 2571 * <p> 2572 * Description: <b>The style of appointment or patient that has been booked in the slot (not service type)</b><br> 2573 * Type: <b>token</b><br> 2574 * Path: <b>Appointment.appointmentType</b><br> 2575 * </p> 2576 */ 2577 @SearchParamDefinition(name="appointment-type", path="Appointment.appointmentType", description="The style of appointment or patient that has been booked in the slot (not service type)", type="token" ) 2578 public static final String SP_APPOINTMENT_TYPE = "appointment-type"; 2579 /** 2580 * <b>Fluent Client</b> search parameter constant for <b>appointment-type</b> 2581 * <p> 2582 * Description: <b>The style of appointment or patient that has been booked in the slot (not service type)</b><br> 2583 * Type: <b>token</b><br> 2584 * Path: <b>Appointment.appointmentType</b><br> 2585 * </p> 2586 */ 2587 public static final ca.uhn.fhir.rest.gclient.TokenClientParam APPOINTMENT_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_APPOINTMENT_TYPE); 2588 2589 /** 2590 * Search parameter: <b>based-on</b> 2591 * <p> 2592 * Description: <b>The service request this appointment is allocated to assess</b><br> 2593 * Type: <b>reference</b><br> 2594 * Path: <b>Appointment.basedOn</b><br> 2595 * </p> 2596 */ 2597 @SearchParamDefinition(name="based-on", path="Appointment.basedOn", description="The service request this appointment is allocated to assess", type="reference", target={ServiceRequest.class } ) 2598 public static final String SP_BASED_ON = "based-on"; 2599 /** 2600 * <b>Fluent Client</b> search parameter constant for <b>based-on</b> 2601 * <p> 2602 * Description: <b>The service request this appointment is allocated to assess</b><br> 2603 * Type: <b>reference</b><br> 2604 * Path: <b>Appointment.basedOn</b><br> 2605 * </p> 2606 */ 2607 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BASED_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BASED_ON); 2608 2609/** 2610 * Constant for fluent queries to be used to add include statements. Specifies 2611 * the path value of "<b>Appointment:based-on</b>". 2612 */ 2613 public static final ca.uhn.fhir.model.api.Include INCLUDE_BASED_ON = new ca.uhn.fhir.model.api.Include("Appointment:based-on").toLocked(); 2614 2615 /** 2616 * Search parameter: <b>date</b> 2617 * <p> 2618 * Description: <b>Appointment date/time.</b><br> 2619 * Type: <b>date</b><br> 2620 * Path: <b>Appointment.start</b><br> 2621 * </p> 2622 */ 2623 @SearchParamDefinition(name="date", path="Appointment.start", description="Appointment date/time.", type="date" ) 2624 public static final String SP_DATE = "date"; 2625 /** 2626 * <b>Fluent Client</b> search parameter constant for <b>date</b> 2627 * <p> 2628 * Description: <b>Appointment date/time.</b><br> 2629 * Type: <b>date</b><br> 2630 * Path: <b>Appointment.start</b><br> 2631 * </p> 2632 */ 2633 public static final ca.uhn.fhir.rest.gclient.DateClientParam DATE = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_DATE); 2634 2635 /** 2636 * Search parameter: <b>identifier</b> 2637 * <p> 2638 * Description: <b>An Identifier of the Appointment</b><br> 2639 * Type: <b>token</b><br> 2640 * Path: <b>Appointment.identifier</b><br> 2641 * </p> 2642 */ 2643 @SearchParamDefinition(name="identifier", path="Appointment.identifier", description="An Identifier of the Appointment", type="token" ) 2644 public static final String SP_IDENTIFIER = "identifier"; 2645 /** 2646 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 2647 * <p> 2648 * Description: <b>An Identifier of the Appointment</b><br> 2649 * Type: <b>token</b><br> 2650 * Path: <b>Appointment.identifier</b><br> 2651 * </p> 2652 */ 2653 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 2654 2655 /** 2656 * Search parameter: <b>location</b> 2657 * <p> 2658 * Description: <b>This location is listed in the participants of the appointment</b><br> 2659 * Type: <b>reference</b><br> 2660 * Path: <b>Appointment.participant.actor.where(resolve() is Location)</b><br> 2661 * </p> 2662 */ 2663 @SearchParamDefinition(name="location", path="Appointment.participant.actor.where(resolve() is Location)", description="This location is listed in the participants of the appointment", type="reference", target={Device.class, HealthcareService.class, Location.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2664 public static final String SP_LOCATION = "location"; 2665 /** 2666 * <b>Fluent Client</b> search parameter constant for <b>location</b> 2667 * <p> 2668 * Description: <b>This location is listed in the participants of the appointment</b><br> 2669 * Type: <b>reference</b><br> 2670 * Path: <b>Appointment.participant.actor.where(resolve() is Location)</b><br> 2671 * </p> 2672 */ 2673 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam LOCATION = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_LOCATION); 2674 2675/** 2676 * Constant for fluent queries to be used to add include statements. Specifies 2677 * the path value of "<b>Appointment:location</b>". 2678 */ 2679 public static final ca.uhn.fhir.model.api.Include INCLUDE_LOCATION = new ca.uhn.fhir.model.api.Include("Appointment:location").toLocked(); 2680 2681 /** 2682 * Search parameter: <b>part-status</b> 2683 * <p> 2684 * Description: <b>The Participation status of the subject, or other participant on the appointment. Can be used to locate participants that have not responded to meeting requests.</b><br> 2685 * Type: <b>token</b><br> 2686 * Path: <b>Appointment.participant.status</b><br> 2687 * </p> 2688 */ 2689 @SearchParamDefinition(name="part-status", path="Appointment.participant.status", description="The Participation status of the subject, or other participant on the appointment. Can be used to locate participants that have not responded to meeting requests.", type="token" ) 2690 public static final String SP_PART_STATUS = "part-status"; 2691 /** 2692 * <b>Fluent Client</b> search parameter constant for <b>part-status</b> 2693 * <p> 2694 * Description: <b>The Participation status of the subject, or other participant on the appointment. Can be used to locate participants that have not responded to meeting requests.</b><br> 2695 * Type: <b>token</b><br> 2696 * Path: <b>Appointment.participant.status</b><br> 2697 * </p> 2698 */ 2699 public static final ca.uhn.fhir.rest.gclient.TokenClientParam PART_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PART_STATUS); 2700 2701 /** 2702 * Search parameter: <b>patient</b> 2703 * <p> 2704 * Description: <b>One of the individuals of the appointment is this patient</b><br> 2705 * Type: <b>reference</b><br> 2706 * Path: <b>Appointment.participant.actor.where(resolve() is Patient)</b><br> 2707 * </p> 2708 */ 2709 @SearchParamDefinition(name="patient", path="Appointment.participant.actor.where(resolve() is Patient)", description="One of the individuals of the appointment is this patient", type="reference", target={Device.class, HealthcareService.class, Location.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2710 public static final String SP_PATIENT = "patient"; 2711 /** 2712 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 2713 * <p> 2714 * Description: <b>One of the individuals of the appointment is this patient</b><br> 2715 * Type: <b>reference</b><br> 2716 * Path: <b>Appointment.participant.actor.where(resolve() is Patient)</b><br> 2717 * </p> 2718 */ 2719 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 2720 2721/** 2722 * Constant for fluent queries to be used to add include statements. Specifies 2723 * the path value of "<b>Appointment:patient</b>". 2724 */ 2725 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("Appointment:patient").toLocked(); 2726 2727 /** 2728 * Search parameter: <b>practitioner</b> 2729 * <p> 2730 * Description: <b>One of the individuals of the appointment is this practitioner</b><br> 2731 * Type: <b>reference</b><br> 2732 * Path: <b>Appointment.participant.actor.where(resolve() is Practitioner)</b><br> 2733 * </p> 2734 */ 2735 @SearchParamDefinition(name="practitioner", path="Appointment.participant.actor.where(resolve() is Practitioner)", description="One of the individuals of the appointment is this practitioner", type="reference", target={Device.class, HealthcareService.class, Location.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 2736 public static final String SP_PRACTITIONER = "practitioner"; 2737 /** 2738 * <b>Fluent Client</b> search parameter constant for <b>practitioner</b> 2739 * <p> 2740 * Description: <b>One of the individuals of the appointment is this practitioner</b><br> 2741 * Type: <b>reference</b><br> 2742 * Path: <b>Appointment.participant.actor.where(resolve() is Practitioner)</b><br> 2743 * </p> 2744 */ 2745 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PRACTITIONER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PRACTITIONER); 2746 2747/** 2748 * Constant for fluent queries to be used to add include statements. Specifies 2749 * the path value of "<b>Appointment:practitioner</b>". 2750 */ 2751 public static final ca.uhn.fhir.model.api.Include INCLUDE_PRACTITIONER = new ca.uhn.fhir.model.api.Include("Appointment:practitioner").toLocked(); 2752 2753 /** 2754 * Search parameter: <b>reason-code</b> 2755 * <p> 2756 * Description: <b>Coded reason this appointment is scheduled</b><br> 2757 * Type: <b>token</b><br> 2758 * Path: <b>Appointment.reasonCode</b><br> 2759 * </p> 2760 */ 2761 @SearchParamDefinition(name="reason-code", path="Appointment.reasonCode", description="Coded reason this appointment is scheduled", type="token" ) 2762 public static final String SP_REASON_CODE = "reason-code"; 2763 /** 2764 * <b>Fluent Client</b> search parameter constant for <b>reason-code</b> 2765 * <p> 2766 * Description: <b>Coded reason this appointment is scheduled</b><br> 2767 * Type: <b>token</b><br> 2768 * Path: <b>Appointment.reasonCode</b><br> 2769 * </p> 2770 */ 2771 public static final ca.uhn.fhir.rest.gclient.TokenClientParam REASON_CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_REASON_CODE); 2772 2773 /** 2774 * Search parameter: <b>reason-reference</b> 2775 * <p> 2776 * Description: <b>Reason the appointment is to take place (resource)</b><br> 2777 * Type: <b>reference</b><br> 2778 * Path: <b>Appointment.reasonReference</b><br> 2779 * </p> 2780 */ 2781 @SearchParamDefinition(name="reason-reference", path="Appointment.reasonReference", description="Reason the appointment is to take place (resource)", type="reference", target={Condition.class, ImmunizationRecommendation.class, Observation.class, Procedure.class } ) 2782 public static final String SP_REASON_REFERENCE = "reason-reference"; 2783 /** 2784 * <b>Fluent Client</b> search parameter constant for <b>reason-reference</b> 2785 * <p> 2786 * Description: <b>Reason the appointment is to take place (resource)</b><br> 2787 * Type: <b>reference</b><br> 2788 * Path: <b>Appointment.reasonReference</b><br> 2789 * </p> 2790 */ 2791 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REASON_REFERENCE = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REASON_REFERENCE); 2792 2793/** 2794 * Constant for fluent queries to be used to add include statements. Specifies 2795 * the path value of "<b>Appointment:reason-reference</b>". 2796 */ 2797 public static final ca.uhn.fhir.model.api.Include INCLUDE_REASON_REFERENCE = new ca.uhn.fhir.model.api.Include("Appointment:reason-reference").toLocked(); 2798 2799 /** 2800 * Search parameter: <b>service-category</b> 2801 * <p> 2802 * Description: <b>A broad categorization of the service that is to be performed during this appointment</b><br> 2803 * Type: <b>token</b><br> 2804 * Path: <b>Appointment.serviceCategory</b><br> 2805 * </p> 2806 */ 2807 @SearchParamDefinition(name="service-category", path="Appointment.serviceCategory", description="A broad categorization of the service that is to be performed during this appointment", type="token" ) 2808 public static final String SP_SERVICE_CATEGORY = "service-category"; 2809 /** 2810 * <b>Fluent Client</b> search parameter constant for <b>service-category</b> 2811 * <p> 2812 * Description: <b>A broad categorization of the service that is to be performed during this appointment</b><br> 2813 * Type: <b>token</b><br> 2814 * Path: <b>Appointment.serviceCategory</b><br> 2815 * </p> 2816 */ 2817 public static final ca.uhn.fhir.rest.gclient.TokenClientParam SERVICE_CATEGORY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_SERVICE_CATEGORY); 2818 2819 /** 2820 * Search parameter: <b>service-type</b> 2821 * <p> 2822 * Description: <b>The specific service that is to be performed during this appointment</b><br> 2823 * Type: <b>token</b><br> 2824 * Path: <b>Appointment.serviceType</b><br> 2825 * </p> 2826 */ 2827 @SearchParamDefinition(name="service-type", path="Appointment.serviceType", description="The specific service that is to be performed during this appointment", type="token" ) 2828 public static final String SP_SERVICE_TYPE = "service-type"; 2829 /** 2830 * <b>Fluent Client</b> search parameter constant for <b>service-type</b> 2831 * <p> 2832 * Description: <b>The specific service that is to be performed during this appointment</b><br> 2833 * Type: <b>token</b><br> 2834 * Path: <b>Appointment.serviceType</b><br> 2835 * </p> 2836 */ 2837 public static final ca.uhn.fhir.rest.gclient.TokenClientParam SERVICE_TYPE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_SERVICE_TYPE); 2838 2839 /** 2840 * Search parameter: <b>slot</b> 2841 * <p> 2842 * Description: <b>The slots that this appointment is filling</b><br> 2843 * Type: <b>reference</b><br> 2844 * Path: <b>Appointment.slot</b><br> 2845 * </p> 2846 */ 2847 @SearchParamDefinition(name="slot", path="Appointment.slot", description="The slots that this appointment is filling", type="reference", target={Slot.class } ) 2848 public static final String SP_SLOT = "slot"; 2849 /** 2850 * <b>Fluent Client</b> search parameter constant for <b>slot</b> 2851 * <p> 2852 * Description: <b>The slots that this appointment is filling</b><br> 2853 * Type: <b>reference</b><br> 2854 * Path: <b>Appointment.slot</b><br> 2855 * </p> 2856 */ 2857 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SLOT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SLOT); 2858 2859/** 2860 * Constant for fluent queries to be used to add include statements. Specifies 2861 * the path value of "<b>Appointment:slot</b>". 2862 */ 2863 public static final ca.uhn.fhir.model.api.Include INCLUDE_SLOT = new ca.uhn.fhir.model.api.Include("Appointment:slot").toLocked(); 2864 2865 /** 2866 * Search parameter: <b>specialty</b> 2867 * <p> 2868 * Description: <b>The specialty of a practitioner that would be required to perform the service requested in this appointment</b><br> 2869 * Type: <b>token</b><br> 2870 * Path: <b>Appointment.specialty</b><br> 2871 * </p> 2872 */ 2873 @SearchParamDefinition(name="specialty", path="Appointment.specialty", description="The specialty of a practitioner that would be required to perform the service requested in this appointment", type="token" ) 2874 public static final String SP_SPECIALTY = "specialty"; 2875 /** 2876 * <b>Fluent Client</b> search parameter constant for <b>specialty</b> 2877 * <p> 2878 * Description: <b>The specialty of a practitioner that would be required to perform the service requested in this appointment</b><br> 2879 * Type: <b>token</b><br> 2880 * Path: <b>Appointment.specialty</b><br> 2881 * </p> 2882 */ 2883 public static final ca.uhn.fhir.rest.gclient.TokenClientParam SPECIALTY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_SPECIALTY); 2884 2885 /** 2886 * Search parameter: <b>status</b> 2887 * <p> 2888 * Description: <b>The overall status of the appointment</b><br> 2889 * Type: <b>token</b><br> 2890 * Path: <b>Appointment.status</b><br> 2891 * </p> 2892 */ 2893 @SearchParamDefinition(name="status", path="Appointment.status", description="The overall status of the appointment", type="token" ) 2894 public static final String SP_STATUS = "status"; 2895 /** 2896 * <b>Fluent Client</b> search parameter constant for <b>status</b> 2897 * <p> 2898 * Description: <b>The overall status of the appointment</b><br> 2899 * Type: <b>token</b><br> 2900 * Path: <b>Appointment.status</b><br> 2901 * </p> 2902 */ 2903 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 2904 2905 /** 2906 * Search parameter: <b>supporting-info</b> 2907 * <p> 2908 * Description: <b>Additional information to support the appointment</b><br> 2909 * Type: <b>reference</b><br> 2910 * Path: <b>Appointment.supportingInformation</b><br> 2911 * </p> 2912 */ 2913 @SearchParamDefinition(name="supporting-info", path="Appointment.supportingInformation", description="Additional information to support the appointment", type="reference", target={Account.class, ActivityDefinition.class, AdministrableProductDefinition.class, AdverseEvent.class, AllergyIntolerance.class, Appointment.class, AppointmentResponse.class, AuditEvent.class, Basic.class, Binary.class, BiologicallyDerivedProduct.class, BodyStructure.class, Bundle.class, CapabilityStatement.class, CarePlan.class, CareTeam.class, CatalogEntry.class, ChargeItem.class, ChargeItemDefinition.class, Citation.class, Claim.class, ClaimResponse.class, ClinicalImpression.class, ClinicalUseDefinition.class, CodeSystem.class, Communication.class, CommunicationRequest.class, CompartmentDefinition.class, Composition.class, ConceptMap.class, Condition.class, Consent.class, Contract.class, Coverage.class, CoverageEligibilityRequest.class, CoverageEligibilityResponse.class, DetectedIssue.class, Device.class, DeviceDefinition.class, DeviceMetric.class, DeviceRequest.class, DeviceUseStatement.class, DiagnosticReport.class, DocumentManifest.class, DocumentReference.class, Encounter.class, Endpoint.class, EnrollmentRequest.class, EnrollmentResponse.class, EpisodeOfCare.class, EventDefinition.class, Evidence.class, EvidenceReport.class, EvidenceVariable.class, ExampleScenario.class, ExplanationOfBenefit.class, FamilyMemberHistory.class, Flag.class, Goal.class, GraphDefinition.class, Group.class, GuidanceResponse.class, HealthcareService.class, ImagingStudy.class, Immunization.class, ImmunizationEvaluation.class, ImmunizationRecommendation.class, ImplementationGuide.class, Ingredient.class, InsurancePlan.class, Invoice.class, Library.class, Linkage.class, ListResource.class, Location.class, ManufacturedItemDefinition.class, Measure.class, MeasureReport.class, Media.class, Medication.class, MedicationAdministration.class, MedicationDispense.class, MedicationKnowledge.class, MedicationRequest.class, MedicationStatement.class, MedicinalProductDefinition.class, MessageDefinition.class, MessageHeader.class, MolecularSequence.class, NamingSystem.class, NutritionOrder.class, NutritionProduct.class, Observation.class, ObservationDefinition.class, OperationDefinition.class, OperationOutcome.class, Organization.class, OrganizationAffiliation.class, PackagedProductDefinition.class, Patient.class, PaymentNotice.class, PaymentReconciliation.class, Person.class, PlanDefinition.class, Practitioner.class, PractitionerRole.class, Procedure.class, Provenance.class, Questionnaire.class, QuestionnaireResponse.class, RegulatedAuthorization.class, RelatedPerson.class, RequestGroup.class, ResearchDefinition.class, ResearchElementDefinition.class, ResearchStudy.class, ResearchSubject.class, RiskAssessment.class, Schedule.class, SearchParameter.class, ServiceRequest.class, Slot.class, Specimen.class, SpecimenDefinition.class, StructureDefinition.class, StructureMap.class, Subscription.class, SubscriptionStatus.class, SubscriptionTopic.class, Substance.class, SubstanceDefinition.class, SupplyDelivery.class, SupplyRequest.class, Task.class, TerminologyCapabilities.class, TestReport.class, TestScript.class, ValueSet.class, VerificationResult.class, VisionPrescription.class } ) 2914 public static final String SP_SUPPORTING_INFO = "supporting-info"; 2915 /** 2916 * <b>Fluent Client</b> search parameter constant for <b>supporting-info</b> 2917 * <p> 2918 * Description: <b>Additional information to support the appointment</b><br> 2919 * Type: <b>reference</b><br> 2920 * Path: <b>Appointment.supportingInformation</b><br> 2921 * </p> 2922 */ 2923 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUPPORTING_INFO = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUPPORTING_INFO); 2924 2925/** 2926 * Constant for fluent queries to be used to add include statements. Specifies 2927 * the path value of "<b>Appointment:supporting-info</b>". 2928 */ 2929 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUPPORTING_INFO = new ca.uhn.fhir.model.api.Include("Appointment:supporting-info").toLocked(); 2930 2931 2932} 2933