001package org.hl7.fhir.r4.model; 002 003 004 005/* 006 Copyright (c) 2011+, HL7, Inc. 007 All rights reserved. 008 009 Redistribution and use in source and binary forms, with or without modification, 010 are permitted provided that the following conditions are met: 011 012 * Redistributions of source code must retain the above copyright notice, this 013 list of conditions and the following disclaimer. 014 * Redistributions in binary form must reproduce the above copyright notice, 015 this list of conditions and the following disclaimer in the documentation 016 and/or other materials provided with the distribution. 017 * Neither the name of HL7 nor the names of its contributors may be used to 018 endorse or promote products derived from this software without specific 019 prior written permission. 020 021 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 022 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 023 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 024 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 025 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 026 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 027 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 028 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 029 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 030 POSSIBILITY OF SUCH DAMAGE. 031 032*/ 033 034 035// Generated on Tue, May 12, 2020 07:26+1000 for FHIR v4.0.1 036 037import java.util.*; 038 039import org.hl7.fhir.utilities.Utilities; 040import ca.uhn.fhir.model.api.annotation.ResourceDef; 041import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 042import ca.uhn.fhir.model.api.annotation.Child; 043import ca.uhn.fhir.model.api.annotation.ChildOrder; 044import ca.uhn.fhir.model.api.annotation.Description; 045import ca.uhn.fhir.model.api.annotation.Block; 046import org.hl7.fhir.instance.model.api.*; 047import org.hl7.fhir.exceptions.FHIRException; 048/** 049 * A task to be performed. 050 */ 051@ResourceDef(name="Task", profile="http://hl7.org/fhir/StructureDefinition/Task") 052public class Task extends DomainResource { 053 054 public enum TaskStatus { 055 /** 056 * The task is not yet ready to be acted upon. 057 */ 058 DRAFT, 059 /** 060 * The task is ready to be acted upon and action is sought. 061 */ 062 REQUESTED, 063 /** 064 * A potential performer has claimed ownership of the task and is evaluating whether to perform it. 065 */ 066 RECEIVED, 067 /** 068 * The potential performer has agreed to execute the task but has not yet started work. 069 */ 070 ACCEPTED, 071 /** 072 * The potential performer who claimed ownership of the task has decided not to execute it prior to performing any action. 073 */ 074 REJECTED, 075 /** 076 * The task is ready to be performed, but no action has yet been taken. Used in place of requested/received/accepted/rejected when request assignment and acceptance is a given. 077 */ 078 READY, 079 /** 080 * The task was not completed. 081 */ 082 CANCELLED, 083 /** 084 * The task has been started but is not yet complete. 085 */ 086 INPROGRESS, 087 /** 088 * The task has been started but work has been paused. 089 */ 090 ONHOLD, 091 /** 092 * The task was attempted but could not be completed due to some error. 093 */ 094 FAILED, 095 /** 096 * The task has been completed. 097 */ 098 COMPLETED, 099 /** 100 * The task should never have existed and is retained only because of the possibility it may have used. 101 */ 102 ENTEREDINERROR, 103 /** 104 * added to help the parsers with the generic types 105 */ 106 NULL; 107 public static TaskStatus fromCode(String codeString) throws FHIRException { 108 if (codeString == null || "".equals(codeString)) 109 return null; 110 if ("draft".equals(codeString)) 111 return DRAFT; 112 if ("requested".equals(codeString)) 113 return REQUESTED; 114 if ("received".equals(codeString)) 115 return RECEIVED; 116 if ("accepted".equals(codeString)) 117 return ACCEPTED; 118 if ("rejected".equals(codeString)) 119 return REJECTED; 120 if ("ready".equals(codeString)) 121 return READY; 122 if ("cancelled".equals(codeString)) 123 return CANCELLED; 124 if ("in-progress".equals(codeString)) 125 return INPROGRESS; 126 if ("on-hold".equals(codeString)) 127 return ONHOLD; 128 if ("failed".equals(codeString)) 129 return FAILED; 130 if ("completed".equals(codeString)) 131 return COMPLETED; 132 if ("entered-in-error".equals(codeString)) 133 return ENTEREDINERROR; 134 if (Configuration.isAcceptInvalidEnums()) 135 return null; 136 else 137 throw new FHIRException("Unknown TaskStatus code '"+codeString+"'"); 138 } 139 public String toCode() { 140 switch (this) { 141 case DRAFT: return "draft"; 142 case REQUESTED: return "requested"; 143 case RECEIVED: return "received"; 144 case ACCEPTED: return "accepted"; 145 case REJECTED: return "rejected"; 146 case READY: return "ready"; 147 case CANCELLED: return "cancelled"; 148 case INPROGRESS: return "in-progress"; 149 case ONHOLD: return "on-hold"; 150 case FAILED: return "failed"; 151 case COMPLETED: return "completed"; 152 case ENTEREDINERROR: return "entered-in-error"; 153 default: return "?"; 154 } 155 } 156 public String getSystem() { 157 switch (this) { 158 case DRAFT: return "http://hl7.org/fhir/task-status"; 159 case REQUESTED: return "http://hl7.org/fhir/task-status"; 160 case RECEIVED: return "http://hl7.org/fhir/task-status"; 161 case ACCEPTED: return "http://hl7.org/fhir/task-status"; 162 case REJECTED: return "http://hl7.org/fhir/task-status"; 163 case READY: return "http://hl7.org/fhir/task-status"; 164 case CANCELLED: return "http://hl7.org/fhir/task-status"; 165 case INPROGRESS: return "http://hl7.org/fhir/task-status"; 166 case ONHOLD: return "http://hl7.org/fhir/task-status"; 167 case FAILED: return "http://hl7.org/fhir/task-status"; 168 case COMPLETED: return "http://hl7.org/fhir/task-status"; 169 case ENTEREDINERROR: return "http://hl7.org/fhir/task-status"; 170 default: return "?"; 171 } 172 } 173 public String getDefinition() { 174 switch (this) { 175 case DRAFT: return "The task is not yet ready to be acted upon."; 176 case REQUESTED: return "The task is ready to be acted upon and action is sought."; 177 case RECEIVED: return "A potential performer has claimed ownership of the task and is evaluating whether to perform it."; 178 case ACCEPTED: return "The potential performer has agreed to execute the task but has not yet started work."; 179 case REJECTED: return "The potential performer who claimed ownership of the task has decided not to execute it prior to performing any action."; 180 case READY: return "The task is ready to be performed, but no action has yet been taken. Used in place of requested/received/accepted/rejected when request assignment and acceptance is a given."; 181 case CANCELLED: return "The task was not completed."; 182 case INPROGRESS: return "The task has been started but is not yet complete."; 183 case ONHOLD: return "The task has been started but work has been paused."; 184 case FAILED: return "The task was attempted but could not be completed due to some error."; 185 case COMPLETED: return "The task has been completed."; 186 case ENTEREDINERROR: return "The task should never have existed and is retained only because of the possibility it may have used."; 187 default: return "?"; 188 } 189 } 190 public String getDisplay() { 191 switch (this) { 192 case DRAFT: return "Draft"; 193 case REQUESTED: return "Requested"; 194 case RECEIVED: return "Received"; 195 case ACCEPTED: return "Accepted"; 196 case REJECTED: return "Rejected"; 197 case READY: return "Ready"; 198 case CANCELLED: return "Cancelled"; 199 case INPROGRESS: return "In Progress"; 200 case ONHOLD: return "On Hold"; 201 case FAILED: return "Failed"; 202 case COMPLETED: return "Completed"; 203 case ENTEREDINERROR: return "Entered in Error"; 204 default: return "?"; 205 } 206 } 207 } 208 209 public static class TaskStatusEnumFactory implements EnumFactory<TaskStatus> { 210 public TaskStatus fromCode(String codeString) throws IllegalArgumentException { 211 if (codeString == null || "".equals(codeString)) 212 if (codeString == null || "".equals(codeString)) 213 return null; 214 if ("draft".equals(codeString)) 215 return TaskStatus.DRAFT; 216 if ("requested".equals(codeString)) 217 return TaskStatus.REQUESTED; 218 if ("received".equals(codeString)) 219 return TaskStatus.RECEIVED; 220 if ("accepted".equals(codeString)) 221 return TaskStatus.ACCEPTED; 222 if ("rejected".equals(codeString)) 223 return TaskStatus.REJECTED; 224 if ("ready".equals(codeString)) 225 return TaskStatus.READY; 226 if ("cancelled".equals(codeString)) 227 return TaskStatus.CANCELLED; 228 if ("in-progress".equals(codeString)) 229 return TaskStatus.INPROGRESS; 230 if ("on-hold".equals(codeString)) 231 return TaskStatus.ONHOLD; 232 if ("failed".equals(codeString)) 233 return TaskStatus.FAILED; 234 if ("completed".equals(codeString)) 235 return TaskStatus.COMPLETED; 236 if ("entered-in-error".equals(codeString)) 237 return TaskStatus.ENTEREDINERROR; 238 throw new IllegalArgumentException("Unknown TaskStatus code '"+codeString+"'"); 239 } 240 public Enumeration<TaskStatus> fromType(Base code) throws FHIRException { 241 if (code == null) 242 return null; 243 if (code.isEmpty()) 244 return new Enumeration<TaskStatus>(this); 245 String codeString = ((PrimitiveType) code).asStringValue(); 246 if (codeString == null || "".equals(codeString)) 247 return null; 248 if ("draft".equals(codeString)) 249 return new Enumeration<TaskStatus>(this, TaskStatus.DRAFT); 250 if ("requested".equals(codeString)) 251 return new Enumeration<TaskStatus>(this, TaskStatus.REQUESTED); 252 if ("received".equals(codeString)) 253 return new Enumeration<TaskStatus>(this, TaskStatus.RECEIVED); 254 if ("accepted".equals(codeString)) 255 return new Enumeration<TaskStatus>(this, TaskStatus.ACCEPTED); 256 if ("rejected".equals(codeString)) 257 return new Enumeration<TaskStatus>(this, TaskStatus.REJECTED); 258 if ("ready".equals(codeString)) 259 return new Enumeration<TaskStatus>(this, TaskStatus.READY); 260 if ("cancelled".equals(codeString)) 261 return new Enumeration<TaskStatus>(this, TaskStatus.CANCELLED); 262 if ("in-progress".equals(codeString)) 263 return new Enumeration<TaskStatus>(this, TaskStatus.INPROGRESS); 264 if ("on-hold".equals(codeString)) 265 return new Enumeration<TaskStatus>(this, TaskStatus.ONHOLD); 266 if ("failed".equals(codeString)) 267 return new Enumeration<TaskStatus>(this, TaskStatus.FAILED); 268 if ("completed".equals(codeString)) 269 return new Enumeration<TaskStatus>(this, TaskStatus.COMPLETED); 270 if ("entered-in-error".equals(codeString)) 271 return new Enumeration<TaskStatus>(this, TaskStatus.ENTEREDINERROR); 272 throw new FHIRException("Unknown TaskStatus code '"+codeString+"'"); 273 } 274 public String toCode(TaskStatus code) { 275 if (code == TaskStatus.DRAFT) 276 return "draft"; 277 if (code == TaskStatus.REQUESTED) 278 return "requested"; 279 if (code == TaskStatus.RECEIVED) 280 return "received"; 281 if (code == TaskStatus.ACCEPTED) 282 return "accepted"; 283 if (code == TaskStatus.REJECTED) 284 return "rejected"; 285 if (code == TaskStatus.READY) 286 return "ready"; 287 if (code == TaskStatus.CANCELLED) 288 return "cancelled"; 289 if (code == TaskStatus.INPROGRESS) 290 return "in-progress"; 291 if (code == TaskStatus.ONHOLD) 292 return "on-hold"; 293 if (code == TaskStatus.FAILED) 294 return "failed"; 295 if (code == TaskStatus.COMPLETED) 296 return "completed"; 297 if (code == TaskStatus.ENTEREDINERROR) 298 return "entered-in-error"; 299 return "?"; 300 } 301 public String toSystem(TaskStatus code) { 302 return code.getSystem(); 303 } 304 } 305 306 public enum TaskIntent { 307 /** 308 * The intent is not known. When dealing with Task, it's not always known (or relevant) how the task was initiated - i.e. whether it was proposed, planned, ordered or just done spontaneously. 309 */ 310 UNKNOWN, 311 /** 312 * null 313 */ 314 PROPOSAL, 315 /** 316 * null 317 */ 318 PLAN, 319 /** 320 * null 321 */ 322 ORDER, 323 /** 324 * null 325 */ 326 ORIGINALORDER, 327 /** 328 * null 329 */ 330 REFLEXORDER, 331 /** 332 * null 333 */ 334 FILLERORDER, 335 /** 336 * null 337 */ 338 INSTANCEORDER, 339 /** 340 * null 341 */ 342 OPTION, 343 /** 344 * added to help the parsers with the generic types 345 */ 346 NULL; 347 public static TaskIntent fromCode(String codeString) throws FHIRException { 348 if (codeString == null || "".equals(codeString)) 349 return null; 350 if ("unknown".equals(codeString)) 351 return UNKNOWN; 352 if ("proposal".equals(codeString)) 353 return PROPOSAL; 354 if ("plan".equals(codeString)) 355 return PLAN; 356 if ("order".equals(codeString)) 357 return ORDER; 358 if ("original-order".equals(codeString)) 359 return ORIGINALORDER; 360 if ("reflex-order".equals(codeString)) 361 return REFLEXORDER; 362 if ("filler-order".equals(codeString)) 363 return FILLERORDER; 364 if ("instance-order".equals(codeString)) 365 return INSTANCEORDER; 366 if ("option".equals(codeString)) 367 return OPTION; 368 if (Configuration.isAcceptInvalidEnums()) 369 return null; 370 else 371 throw new FHIRException("Unknown TaskIntent code '"+codeString+"'"); 372 } 373 public String toCode() { 374 switch (this) { 375 case UNKNOWN: return "unknown"; 376 case PROPOSAL: return "proposal"; 377 case PLAN: return "plan"; 378 case ORDER: return "order"; 379 case ORIGINALORDER: return "original-order"; 380 case REFLEXORDER: return "reflex-order"; 381 case FILLERORDER: return "filler-order"; 382 case INSTANCEORDER: return "instance-order"; 383 case OPTION: return "option"; 384 default: return "?"; 385 } 386 } 387 public String getSystem() { 388 switch (this) { 389 case UNKNOWN: return "http://hl7.org/fhir/task-intent"; 390 case PROPOSAL: return "http://hl7.org/fhir/request-intent"; 391 case PLAN: return "http://hl7.org/fhir/request-intent"; 392 case ORDER: return "http://hl7.org/fhir/request-intent"; 393 case ORIGINALORDER: return "http://hl7.org/fhir/request-intent"; 394 case REFLEXORDER: return "http://hl7.org/fhir/request-intent"; 395 case FILLERORDER: return "http://hl7.org/fhir/request-intent"; 396 case INSTANCEORDER: return "http://hl7.org/fhir/request-intent"; 397 case OPTION: return "http://hl7.org/fhir/request-intent"; 398 default: return "?"; 399 } 400 } 401 public String getDefinition() { 402 switch (this) { 403 case UNKNOWN: return "The intent is not known. When dealing with Task, it's not always known (or relevant) how the task was initiated - i.e. whether it was proposed, planned, ordered or just done spontaneously."; 404 case PROPOSAL: return ""; 405 case PLAN: return ""; 406 case ORDER: return ""; 407 case ORIGINALORDER: return ""; 408 case REFLEXORDER: return ""; 409 case FILLERORDER: return ""; 410 case INSTANCEORDER: return ""; 411 case OPTION: return ""; 412 default: return "?"; 413 } 414 } 415 public String getDisplay() { 416 switch (this) { 417 case UNKNOWN: return "Unknown"; 418 case PROPOSAL: return "proposal"; 419 case PLAN: return "plan"; 420 case ORDER: return "order"; 421 case ORIGINALORDER: return "original-order"; 422 case REFLEXORDER: return "reflex-order"; 423 case FILLERORDER: return "filler-order"; 424 case INSTANCEORDER: return "instance-order"; 425 case OPTION: return "option"; 426 default: return "?"; 427 } 428 } 429 } 430 431 public static class TaskIntentEnumFactory implements EnumFactory<TaskIntent> { 432 public TaskIntent fromCode(String codeString) throws IllegalArgumentException { 433 if (codeString == null || "".equals(codeString)) 434 if (codeString == null || "".equals(codeString)) 435 return null; 436 if ("unknown".equals(codeString)) 437 return TaskIntent.UNKNOWN; 438 if ("proposal".equals(codeString)) 439 return TaskIntent.PROPOSAL; 440 if ("plan".equals(codeString)) 441 return TaskIntent.PLAN; 442 if ("order".equals(codeString)) 443 return TaskIntent.ORDER; 444 if ("original-order".equals(codeString)) 445 return TaskIntent.ORIGINALORDER; 446 if ("reflex-order".equals(codeString)) 447 return TaskIntent.REFLEXORDER; 448 if ("filler-order".equals(codeString)) 449 return TaskIntent.FILLERORDER; 450 if ("instance-order".equals(codeString)) 451 return TaskIntent.INSTANCEORDER; 452 if ("option".equals(codeString)) 453 return TaskIntent.OPTION; 454 throw new IllegalArgumentException("Unknown TaskIntent code '"+codeString+"'"); 455 } 456 public Enumeration<TaskIntent> fromType(Base code) throws FHIRException { 457 if (code == null) 458 return null; 459 if (code.isEmpty()) 460 return new Enumeration<TaskIntent>(this); 461 String codeString = ((PrimitiveType) code).asStringValue(); 462 if (codeString == null || "".equals(codeString)) 463 return null; 464 if ("unknown".equals(codeString)) 465 return new Enumeration<TaskIntent>(this, TaskIntent.UNKNOWN); 466 if ("proposal".equals(codeString)) 467 return new Enumeration<TaskIntent>(this, TaskIntent.PROPOSAL); 468 if ("plan".equals(codeString)) 469 return new Enumeration<TaskIntent>(this, TaskIntent.PLAN); 470 if ("order".equals(codeString)) 471 return new Enumeration<TaskIntent>(this, TaskIntent.ORDER); 472 if ("original-order".equals(codeString)) 473 return new Enumeration<TaskIntent>(this, TaskIntent.ORIGINALORDER); 474 if ("reflex-order".equals(codeString)) 475 return new Enumeration<TaskIntent>(this, TaskIntent.REFLEXORDER); 476 if ("filler-order".equals(codeString)) 477 return new Enumeration<TaskIntent>(this, TaskIntent.FILLERORDER); 478 if ("instance-order".equals(codeString)) 479 return new Enumeration<TaskIntent>(this, TaskIntent.INSTANCEORDER); 480 if ("option".equals(codeString)) 481 return new Enumeration<TaskIntent>(this, TaskIntent.OPTION); 482 throw new FHIRException("Unknown TaskIntent code '"+codeString+"'"); 483 } 484 public String toCode(TaskIntent code) { 485 if (code == TaskIntent.UNKNOWN) 486 return "unknown"; 487 if (code == TaskIntent.PROPOSAL) 488 return "proposal"; 489 if (code == TaskIntent.PLAN) 490 return "plan"; 491 if (code == TaskIntent.ORDER) 492 return "order"; 493 if (code == TaskIntent.ORIGINALORDER) 494 return "original-order"; 495 if (code == TaskIntent.REFLEXORDER) 496 return "reflex-order"; 497 if (code == TaskIntent.FILLERORDER) 498 return "filler-order"; 499 if (code == TaskIntent.INSTANCEORDER) 500 return "instance-order"; 501 if (code == TaskIntent.OPTION) 502 return "option"; 503 return "?"; 504 } 505 public String toSystem(TaskIntent code) { 506 return code.getSystem(); 507 } 508 } 509 510 public enum TaskPriority { 511 /** 512 * The request has normal priority. 513 */ 514 ROUTINE, 515 /** 516 * The request should be actioned promptly - higher priority than routine. 517 */ 518 URGENT, 519 /** 520 * The request should be actioned as soon as possible - higher priority than urgent. 521 */ 522 ASAP, 523 /** 524 * The request should be actioned immediately - highest possible priority. E.g. an emergency. 525 */ 526 STAT, 527 /** 528 * added to help the parsers with the generic types 529 */ 530 NULL; 531 public static TaskPriority fromCode(String codeString) throws FHIRException { 532 if (codeString == null || "".equals(codeString)) 533 return null; 534 if ("routine".equals(codeString)) 535 return ROUTINE; 536 if ("urgent".equals(codeString)) 537 return URGENT; 538 if ("asap".equals(codeString)) 539 return ASAP; 540 if ("stat".equals(codeString)) 541 return STAT; 542 if (Configuration.isAcceptInvalidEnums()) 543 return null; 544 else 545 throw new FHIRException("Unknown TaskPriority code '"+codeString+"'"); 546 } 547 public String toCode() { 548 switch (this) { 549 case ROUTINE: return "routine"; 550 case URGENT: return "urgent"; 551 case ASAP: return "asap"; 552 case STAT: return "stat"; 553 default: return "?"; 554 } 555 } 556 public String getSystem() { 557 switch (this) { 558 case ROUTINE: return "http://hl7.org/fhir/request-priority"; 559 case URGENT: return "http://hl7.org/fhir/request-priority"; 560 case ASAP: return "http://hl7.org/fhir/request-priority"; 561 case STAT: return "http://hl7.org/fhir/request-priority"; 562 default: return "?"; 563 } 564 } 565 public String getDefinition() { 566 switch (this) { 567 case ROUTINE: return "The request has normal priority."; 568 case URGENT: return "The request should be actioned promptly - higher priority than routine."; 569 case ASAP: return "The request should be actioned as soon as possible - higher priority than urgent."; 570 case STAT: return "The request should be actioned immediately - highest possible priority. E.g. an emergency."; 571 default: return "?"; 572 } 573 } 574 public String getDisplay() { 575 switch (this) { 576 case ROUTINE: return "Routine"; 577 case URGENT: return "Urgent"; 578 case ASAP: return "ASAP"; 579 case STAT: return "STAT"; 580 default: return "?"; 581 } 582 } 583 } 584 585 public static class TaskPriorityEnumFactory implements EnumFactory<TaskPriority> { 586 public TaskPriority fromCode(String codeString) throws IllegalArgumentException { 587 if (codeString == null || "".equals(codeString)) 588 if (codeString == null || "".equals(codeString)) 589 return null; 590 if ("routine".equals(codeString)) 591 return TaskPriority.ROUTINE; 592 if ("urgent".equals(codeString)) 593 return TaskPriority.URGENT; 594 if ("asap".equals(codeString)) 595 return TaskPriority.ASAP; 596 if ("stat".equals(codeString)) 597 return TaskPriority.STAT; 598 throw new IllegalArgumentException("Unknown TaskPriority code '"+codeString+"'"); 599 } 600 public Enumeration<TaskPriority> fromType(Base code) throws FHIRException { 601 if (code == null) 602 return null; 603 if (code.isEmpty()) 604 return new Enumeration<TaskPriority>(this); 605 String codeString = ((PrimitiveType) code).asStringValue(); 606 if (codeString == null || "".equals(codeString)) 607 return null; 608 if ("routine".equals(codeString)) 609 return new Enumeration<TaskPriority>(this, TaskPriority.ROUTINE); 610 if ("urgent".equals(codeString)) 611 return new Enumeration<TaskPriority>(this, TaskPriority.URGENT); 612 if ("asap".equals(codeString)) 613 return new Enumeration<TaskPriority>(this, TaskPriority.ASAP); 614 if ("stat".equals(codeString)) 615 return new Enumeration<TaskPriority>(this, TaskPriority.STAT); 616 throw new FHIRException("Unknown TaskPriority code '"+codeString+"'"); 617 } 618 public String toCode(TaskPriority code) { 619 if (code == TaskPriority.ROUTINE) 620 return "routine"; 621 if (code == TaskPriority.URGENT) 622 return "urgent"; 623 if (code == TaskPriority.ASAP) 624 return "asap"; 625 if (code == TaskPriority.STAT) 626 return "stat"; 627 return "?"; 628 } 629 public String toSystem(TaskPriority code) { 630 return code.getSystem(); 631 } 632 } 633 634 @Block() 635 public static class TaskRestrictionComponent extends BackboneElement implements IBaseBackboneElement { 636 /** 637 * Indicates the number of times the requested action should occur. 638 */ 639 @Child(name = "repetitions", type = {PositiveIntType.class}, order=1, min=0, max=1, modifier=false, summary=false) 640 @Description(shortDefinition="How many times to repeat", formalDefinition="Indicates the number of times the requested action should occur." ) 641 protected PositiveIntType repetitions; 642 643 /** 644 * Over what time-period is fulfillment sought. 645 */ 646 @Child(name = "period", type = {Period.class}, order=2, min=0, max=1, modifier=false, summary=false) 647 @Description(shortDefinition="When fulfillment sought", formalDefinition="Over what time-period is fulfillment sought." ) 648 protected Period period; 649 650 /** 651 * For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought? 652 */ 653 @Child(name = "recipient", type = {Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class, Group.class, Organization.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 654 @Description(shortDefinition="For whom is fulfillment sought?", formalDefinition="For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought?" ) 655 protected List<Reference> recipient; 656 /** 657 * The actual objects that are the target of the reference (For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought?) 658 */ 659 protected List<Resource> recipientTarget; 660 661 662 private static final long serialVersionUID = 1503908360L; 663 664 /** 665 * Constructor 666 */ 667 public TaskRestrictionComponent() { 668 super(); 669 } 670 671 /** 672 * @return {@link #repetitions} (Indicates the number of times the requested action should occur.). This is the underlying object with id, value and extensions. The accessor "getRepetitions" gives direct access to the value 673 */ 674 public PositiveIntType getRepetitionsElement() { 675 if (this.repetitions == null) 676 if (Configuration.errorOnAutoCreate()) 677 throw new Error("Attempt to auto-create TaskRestrictionComponent.repetitions"); 678 else if (Configuration.doAutoCreate()) 679 this.repetitions = new PositiveIntType(); // bb 680 return this.repetitions; 681 } 682 683 public boolean hasRepetitionsElement() { 684 return this.repetitions != null && !this.repetitions.isEmpty(); 685 } 686 687 public boolean hasRepetitions() { 688 return this.repetitions != null && !this.repetitions.isEmpty(); 689 } 690 691 /** 692 * @param value {@link #repetitions} (Indicates the number of times the requested action should occur.). This is the underlying object with id, value and extensions. The accessor "getRepetitions" gives direct access to the value 693 */ 694 public TaskRestrictionComponent setRepetitionsElement(PositiveIntType value) { 695 this.repetitions = value; 696 return this; 697 } 698 699 /** 700 * @return Indicates the number of times the requested action should occur. 701 */ 702 public int getRepetitions() { 703 return this.repetitions == null || this.repetitions.isEmpty() ? 0 : this.repetitions.getValue(); 704 } 705 706 /** 707 * @param value Indicates the number of times the requested action should occur. 708 */ 709 public TaskRestrictionComponent setRepetitions(int value) { 710 if (this.repetitions == null) 711 this.repetitions = new PositiveIntType(); 712 this.repetitions.setValue(value); 713 return this; 714 } 715 716 /** 717 * @return {@link #period} (Over what time-period is fulfillment sought.) 718 */ 719 public Period getPeriod() { 720 if (this.period == null) 721 if (Configuration.errorOnAutoCreate()) 722 throw new Error("Attempt to auto-create TaskRestrictionComponent.period"); 723 else if (Configuration.doAutoCreate()) 724 this.period = new Period(); // cc 725 return this.period; 726 } 727 728 public boolean hasPeriod() { 729 return this.period != null && !this.period.isEmpty(); 730 } 731 732 /** 733 * @param value {@link #period} (Over what time-period is fulfillment sought.) 734 */ 735 public TaskRestrictionComponent setPeriod(Period value) { 736 this.period = value; 737 return this; 738 } 739 740 /** 741 * @return {@link #recipient} (For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought?) 742 */ 743 public List<Reference> getRecipient() { 744 if (this.recipient == null) 745 this.recipient = new ArrayList<Reference>(); 746 return this.recipient; 747 } 748 749 /** 750 * @return Returns a reference to <code>this</code> for easy method chaining 751 */ 752 public TaskRestrictionComponent setRecipient(List<Reference> theRecipient) { 753 this.recipient = theRecipient; 754 return this; 755 } 756 757 public boolean hasRecipient() { 758 if (this.recipient == null) 759 return false; 760 for (Reference item : this.recipient) 761 if (!item.isEmpty()) 762 return true; 763 return false; 764 } 765 766 public Reference addRecipient() { //3 767 Reference t = new Reference(); 768 if (this.recipient == null) 769 this.recipient = new ArrayList<Reference>(); 770 this.recipient.add(t); 771 return t; 772 } 773 774 public TaskRestrictionComponent addRecipient(Reference t) { //3 775 if (t == null) 776 return this; 777 if (this.recipient == null) 778 this.recipient = new ArrayList<Reference>(); 779 this.recipient.add(t); 780 return this; 781 } 782 783 /** 784 * @return The first repetition of repeating field {@link #recipient}, creating it if it does not already exist 785 */ 786 public Reference getRecipientFirstRep() { 787 if (getRecipient().isEmpty()) { 788 addRecipient(); 789 } 790 return getRecipient().get(0); 791 } 792 793 /** 794 * @deprecated Use Reference#setResource(IBaseResource) instead 795 */ 796 @Deprecated 797 public List<Resource> getRecipientTarget() { 798 if (this.recipientTarget == null) 799 this.recipientTarget = new ArrayList<Resource>(); 800 return this.recipientTarget; 801 } 802 803 protected void listChildren(List<Property> children) { 804 super.listChildren(children); 805 children.add(new Property("repetitions", "positiveInt", "Indicates the number of times the requested action should occur.", 0, 1, repetitions)); 806 children.add(new Property("period", "Period", "Over what time-period is fulfillment sought.", 0, 1, period)); 807 children.add(new Property("recipient", "Reference(Patient|Practitioner|PractitionerRole|RelatedPerson|Group|Organization)", "For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought?", 0, java.lang.Integer.MAX_VALUE, recipient)); 808 } 809 810 @Override 811 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 812 switch (_hash) { 813 case 984367650: /*repetitions*/ return new Property("repetitions", "positiveInt", "Indicates the number of times the requested action should occur.", 0, 1, repetitions); 814 case -991726143: /*period*/ return new Property("period", "Period", "Over what time-period is fulfillment sought.", 0, 1, period); 815 case 820081177: /*recipient*/ return new Property("recipient", "Reference(Patient|Practitioner|PractitionerRole|RelatedPerson|Group|Organization)", "For requests that are targeted to more than on potential recipient/target, for whom is fulfillment sought?", 0, java.lang.Integer.MAX_VALUE, recipient); 816 default: return super.getNamedProperty(_hash, _name, _checkValid); 817 } 818 819 } 820 821 @Override 822 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 823 switch (hash) { 824 case 984367650: /*repetitions*/ return this.repetitions == null ? new Base[0] : new Base[] {this.repetitions}; // PositiveIntType 825 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 826 case 820081177: /*recipient*/ return this.recipient == null ? new Base[0] : this.recipient.toArray(new Base[this.recipient.size()]); // Reference 827 default: return super.getProperty(hash, name, checkValid); 828 } 829 830 } 831 832 @Override 833 public Base setProperty(int hash, String name, Base value) throws FHIRException { 834 switch (hash) { 835 case 984367650: // repetitions 836 this.repetitions = castToPositiveInt(value); // PositiveIntType 837 return value; 838 case -991726143: // period 839 this.period = castToPeriod(value); // Period 840 return value; 841 case 820081177: // recipient 842 this.getRecipient().add(castToReference(value)); // Reference 843 return value; 844 default: return super.setProperty(hash, name, value); 845 } 846 847 } 848 849 @Override 850 public Base setProperty(String name, Base value) throws FHIRException { 851 if (name.equals("repetitions")) { 852 this.repetitions = castToPositiveInt(value); // PositiveIntType 853 } else if (name.equals("period")) { 854 this.period = castToPeriod(value); // Period 855 } else if (name.equals("recipient")) { 856 this.getRecipient().add(castToReference(value)); 857 } else 858 return super.setProperty(name, value); 859 return value; 860 } 861 862 @Override 863 public Base makeProperty(int hash, String name) throws FHIRException { 864 switch (hash) { 865 case 984367650: return getRepetitionsElement(); 866 case -991726143: return getPeriod(); 867 case 820081177: return addRecipient(); 868 default: return super.makeProperty(hash, name); 869 } 870 871 } 872 873 @Override 874 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 875 switch (hash) { 876 case 984367650: /*repetitions*/ return new String[] {"positiveInt"}; 877 case -991726143: /*period*/ return new String[] {"Period"}; 878 case 820081177: /*recipient*/ return new String[] {"Reference"}; 879 default: return super.getTypesForProperty(hash, name); 880 } 881 882 } 883 884 @Override 885 public Base addChild(String name) throws FHIRException { 886 if (name.equals("repetitions")) { 887 throw new FHIRException("Cannot call addChild on a primitive type Task.repetitions"); 888 } 889 else if (name.equals("period")) { 890 this.period = new Period(); 891 return this.period; 892 } 893 else if (name.equals("recipient")) { 894 return addRecipient(); 895 } 896 else 897 return super.addChild(name); 898 } 899 900 public TaskRestrictionComponent copy() { 901 TaskRestrictionComponent dst = new TaskRestrictionComponent(); 902 copyValues(dst); 903 return dst; 904 } 905 906 public void copyValues(TaskRestrictionComponent dst) { 907 super.copyValues(dst); 908 dst.repetitions = repetitions == null ? null : repetitions.copy(); 909 dst.period = period == null ? null : period.copy(); 910 if (recipient != null) { 911 dst.recipient = new ArrayList<Reference>(); 912 for (Reference i : recipient) 913 dst.recipient.add(i.copy()); 914 }; 915 } 916 917 @Override 918 public boolean equalsDeep(Base other_) { 919 if (!super.equalsDeep(other_)) 920 return false; 921 if (!(other_ instanceof TaskRestrictionComponent)) 922 return false; 923 TaskRestrictionComponent o = (TaskRestrictionComponent) other_; 924 return compareDeep(repetitions, o.repetitions, true) && compareDeep(period, o.period, true) && compareDeep(recipient, o.recipient, true) 925 ; 926 } 927 928 @Override 929 public boolean equalsShallow(Base other_) { 930 if (!super.equalsShallow(other_)) 931 return false; 932 if (!(other_ instanceof TaskRestrictionComponent)) 933 return false; 934 TaskRestrictionComponent o = (TaskRestrictionComponent) other_; 935 return compareValues(repetitions, o.repetitions, true); 936 } 937 938 public boolean isEmpty() { 939 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(repetitions, period, recipient 940 ); 941 } 942 943 public String fhirType() { 944 return "Task.restriction"; 945 946 } 947 948 } 949 950 @Block() 951 public static class ParameterComponent extends BackboneElement implements IBaseBackboneElement { 952 /** 953 * A code or description indicating how the input is intended to be used as part of the task execution. 954 */ 955 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 956 @Description(shortDefinition="Label for the input", formalDefinition="A code or description indicating how the input is intended to be used as part of the task execution." ) 957 protected CodeableConcept type; 958 959 /** 960 * The value of the input parameter as a basic type. 961 */ 962 @Child(name = "value", type = {}, order=2, min=1, max=1, modifier=false, summary=false) 963 @Description(shortDefinition="Content to use in performing the task", formalDefinition="The value of the input parameter as a basic type." ) 964 protected org.hl7.fhir.r4.model.Type value; 965 966 private static final long serialVersionUID = -850267045L; 967 968 /** 969 * Constructor 970 */ 971 public ParameterComponent() { 972 super(); 973 } 974 975 /** 976 * Constructor 977 */ 978 public ParameterComponent(CodeableConcept type, org.hl7.fhir.r4.model.Type value) { 979 super(); 980 this.type = type; 981 this.value = value; 982 } 983 984 /** 985 * @return {@link #type} (A code or description indicating how the input is intended to be used as part of the task execution.) 986 */ 987 public CodeableConcept getType() { 988 if (this.type == null) 989 if (Configuration.errorOnAutoCreate()) 990 throw new Error("Attempt to auto-create ParameterComponent.type"); 991 else if (Configuration.doAutoCreate()) 992 this.type = new CodeableConcept(); // cc 993 return this.type; 994 } 995 996 public boolean hasType() { 997 return this.type != null && !this.type.isEmpty(); 998 } 999 1000 /** 1001 * @param value {@link #type} (A code or description indicating how the input is intended to be used as part of the task execution.) 1002 */ 1003 public ParameterComponent setType(CodeableConcept value) { 1004 this.type = value; 1005 return this; 1006 } 1007 1008 /** 1009 * @return {@link #value} (The value of the input parameter as a basic type.) 1010 */ 1011 public org.hl7.fhir.r4.model.Type getValue() { 1012 return this.value; 1013 } 1014 1015 public boolean hasValue() { 1016 return this.value != null && !this.value.isEmpty(); 1017 } 1018 1019 /** 1020 * @param value {@link #value} (The value of the input parameter as a basic type.) 1021 */ 1022 public ParameterComponent setValue(org.hl7.fhir.r4.model.Type value) { 1023 this.value = value; 1024 return this; 1025 } 1026 1027 protected void listChildren(List<Property> children) { 1028 super.listChildren(children); 1029 children.add(new Property("type", "CodeableConcept", "A code or description indicating how the input is intended to be used as part of the task execution.", 0, 1, type)); 1030 children.add(new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value)); 1031 } 1032 1033 @Override 1034 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1035 switch (_hash) { 1036 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "A code or description indicating how the input is intended to be used as part of the task execution.", 0, 1, type); 1037 case -1410166417: /*value[x]*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1038 case 111972721: /*value*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1039 case -1535024575: /*valueBase64Binary*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1040 case 733421943: /*valueBoolean*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1041 case -786218365: /*valueCanonical*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1042 case -766209282: /*valueCode*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1043 case -766192449: /*valueDate*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1044 case 1047929900: /*valueDateTime*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1045 case -2083993440: /*valueDecimal*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1046 case 231604844: /*valueId*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1047 case -1668687056: /*valueInstant*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1048 case -1668204915: /*valueInteger*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1049 case -497880704: /*valueMarkdown*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1050 case -1410178407: /*valueOid*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1051 case -1249932027: /*valuePositiveInt*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1052 case -1424603934: /*valueString*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1053 case -765708322: /*valueTime*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1054 case 26529417: /*valueUnsignedInt*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1055 case -1410172357: /*valueUri*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1056 case -1410172354: /*valueUrl*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1057 case -765667124: /*valueUuid*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1058 case -478981821: /*valueAddress*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1059 case -67108992: /*valueAnnotation*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1060 case -475566732: /*valueAttachment*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1061 case 924902896: /*valueCodeableConcept*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1062 case -1887705029: /*valueCoding*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1063 case 944904545: /*valueContactPoint*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1064 case -2026205465: /*valueHumanName*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1065 case -130498310: /*valueIdentifier*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1066 case -1524344174: /*valuePeriod*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1067 case -2029823716: /*valueQuantity*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1068 case 2030761548: /*valueRange*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1069 case 2030767386: /*valueRatio*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1070 case 1755241690: /*valueReference*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1071 case -962229101: /*valueSampledData*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1072 case -540985785: /*valueSignature*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1073 case -1406282469: /*valueTiming*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1074 case -1858636920: /*valueDosage*/ return new Property("value[x]", "*", "The value of the input parameter as a basic type.", 0, 1, value); 1075 default: return super.getNamedProperty(_hash, _name, _checkValid); 1076 } 1077 1078 } 1079 1080 @Override 1081 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1082 switch (hash) { 1083 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1084 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // org.hl7.fhir.r4.model.Type 1085 default: return super.getProperty(hash, name, checkValid); 1086 } 1087 1088 } 1089 1090 @Override 1091 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1092 switch (hash) { 1093 case 3575610: // type 1094 this.type = castToCodeableConcept(value); // CodeableConcept 1095 return value; 1096 case 111972721: // value 1097 this.value = castToType(value); // org.hl7.fhir.r4.model.Type 1098 return value; 1099 default: return super.setProperty(hash, name, value); 1100 } 1101 1102 } 1103 1104 @Override 1105 public Base setProperty(String name, Base value) throws FHIRException { 1106 if (name.equals("type")) { 1107 this.type = castToCodeableConcept(value); // CodeableConcept 1108 } else if (name.equals("value[x]")) { 1109 this.value = castToType(value); // org.hl7.fhir.r4.model.Type 1110 } else 1111 return super.setProperty(name, value); 1112 return value; 1113 } 1114 1115 @Override 1116 public Base makeProperty(int hash, String name) throws FHIRException { 1117 switch (hash) { 1118 case 3575610: return getType(); 1119 case -1410166417: return getValue(); 1120 case 111972721: return getValue(); 1121 default: return super.makeProperty(hash, name); 1122 } 1123 1124 } 1125 1126 @Override 1127 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1128 switch (hash) { 1129 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1130 case 111972721: /*value*/ return new String[] {"*"}; 1131 default: return super.getTypesForProperty(hash, name); 1132 } 1133 1134 } 1135 1136 @Override 1137 public Base addChild(String name) throws FHIRException { 1138 if (name.equals("type")) { 1139 this.type = new CodeableConcept(); 1140 return this.type; 1141 } 1142 else if (name.equals("valueBase64Binary")) { 1143 this.value = new Base64BinaryType(); 1144 return this.value; 1145 } 1146 else if (name.equals("valueBoolean")) { 1147 this.value = new BooleanType(); 1148 return this.value; 1149 } 1150 else if (name.equals("valueCanonical")) { 1151 this.value = new CanonicalType(); 1152 return this.value; 1153 } 1154 else if (name.equals("valueCode")) { 1155 this.value = new CodeType(); 1156 return this.value; 1157 } 1158 else if (name.equals("valueDate")) { 1159 this.value = new DateType(); 1160 return this.value; 1161 } 1162 else if (name.equals("valueDateTime")) { 1163 this.value = new DateTimeType(); 1164 return this.value; 1165 } 1166 else if (name.equals("valueDecimal")) { 1167 this.value = new DecimalType(); 1168 return this.value; 1169 } 1170 else if (name.equals("valueId")) { 1171 this.value = new IdType(); 1172 return this.value; 1173 } 1174 else if (name.equals("valueInstant")) { 1175 this.value = new InstantType(); 1176 return this.value; 1177 } 1178 else if (name.equals("valueInteger")) { 1179 this.value = new IntegerType(); 1180 return this.value; 1181 } 1182 else if (name.equals("valueMarkdown")) { 1183 this.value = new MarkdownType(); 1184 return this.value; 1185 } 1186 else if (name.equals("valueOid")) { 1187 this.value = new OidType(); 1188 return this.value; 1189 } 1190 else if (name.equals("valuePositiveInt")) { 1191 this.value = new PositiveIntType(); 1192 return this.value; 1193 } 1194 else if (name.equals("valueString")) { 1195 this.value = new StringType(); 1196 return this.value; 1197 } 1198 else if (name.equals("valueTime")) { 1199 this.value = new TimeType(); 1200 return this.value; 1201 } 1202 else if (name.equals("valueUnsignedInt")) { 1203 this.value = new UnsignedIntType(); 1204 return this.value; 1205 } 1206 else if (name.equals("valueUri")) { 1207 this.value = new UriType(); 1208 return this.value; 1209 } 1210 else if (name.equals("valueUrl")) { 1211 this.value = new UrlType(); 1212 return this.value; 1213 } 1214 else if (name.equals("valueUuid")) { 1215 this.value = new UuidType(); 1216 return this.value; 1217 } 1218 else if (name.equals("valueAddress")) { 1219 this.value = new Address(); 1220 return this.value; 1221 } 1222 else if (name.equals("valueAge")) { 1223 this.value = new Age(); 1224 return this.value; 1225 } 1226 else if (name.equals("valueAnnotation")) { 1227 this.value = new Annotation(); 1228 return this.value; 1229 } 1230 else if (name.equals("valueAttachment")) { 1231 this.value = new Attachment(); 1232 return this.value; 1233 } 1234 else if (name.equals("valueCodeableConcept")) { 1235 this.value = new CodeableConcept(); 1236 return this.value; 1237 } 1238 else if (name.equals("valueCoding")) { 1239 this.value = new Coding(); 1240 return this.value; 1241 } 1242 else if (name.equals("valueContactPoint")) { 1243 this.value = new ContactPoint(); 1244 return this.value; 1245 } 1246 else if (name.equals("valueCount")) { 1247 this.value = new Count(); 1248 return this.value; 1249 } 1250 else if (name.equals("valueDistance")) { 1251 this.value = new Distance(); 1252 return this.value; 1253 } 1254 else if (name.equals("valueDuration")) { 1255 this.value = new Duration(); 1256 return this.value; 1257 } 1258 else if (name.equals("valueHumanName")) { 1259 this.value = new HumanName(); 1260 return this.value; 1261 } 1262 else if (name.equals("valueIdentifier")) { 1263 this.value = new Identifier(); 1264 return this.value; 1265 } 1266 else if (name.equals("valueMoney")) { 1267 this.value = new Money(); 1268 return this.value; 1269 } 1270 else if (name.equals("valuePeriod")) { 1271 this.value = new Period(); 1272 return this.value; 1273 } 1274 else if (name.equals("valueQuantity")) { 1275 this.value = new Quantity(); 1276 return this.value; 1277 } 1278 else if (name.equals("valueRange")) { 1279 this.value = new Range(); 1280 return this.value; 1281 } 1282 else if (name.equals("valueRatio")) { 1283 this.value = new Ratio(); 1284 return this.value; 1285 } 1286 else if (name.equals("valueReference")) { 1287 this.value = new Reference(); 1288 return this.value; 1289 } 1290 else if (name.equals("valueSampledData")) { 1291 this.value = new SampledData(); 1292 return this.value; 1293 } 1294 else if (name.equals("valueSignature")) { 1295 this.value = new Signature(); 1296 return this.value; 1297 } 1298 else if (name.equals("valueTiming")) { 1299 this.value = new Timing(); 1300 return this.value; 1301 } 1302 else if (name.equals("valueContactDetail")) { 1303 this.value = new ContactDetail(); 1304 return this.value; 1305 } 1306 else if (name.equals("valueContributor")) { 1307 this.value = new Contributor(); 1308 return this.value; 1309 } 1310 else if (name.equals("valueDataRequirement")) { 1311 this.value = new DataRequirement(); 1312 return this.value; 1313 } 1314 else if (name.equals("valueExpression")) { 1315 this.value = new Expression(); 1316 return this.value; 1317 } 1318 else if (name.equals("valueParameterDefinition")) { 1319 this.value = new ParameterDefinition(); 1320 return this.value; 1321 } 1322 else if (name.equals("valueRelatedArtifact")) { 1323 this.value = new RelatedArtifact(); 1324 return this.value; 1325 } 1326 else if (name.equals("valueTriggerDefinition")) { 1327 this.value = new TriggerDefinition(); 1328 return this.value; 1329 } 1330 else if (name.equals("valueUsageContext")) { 1331 this.value = new UsageContext(); 1332 return this.value; 1333 } 1334 else if (name.equals("valueDosage")) { 1335 this.value = new Dosage(); 1336 return this.value; 1337 } 1338 else if (name.equals("valueMeta")) { 1339 this.value = new Meta(); 1340 return this.value; 1341 } 1342 else 1343 return super.addChild(name); 1344 } 1345 1346 public ParameterComponent copy() { 1347 ParameterComponent dst = new ParameterComponent(); 1348 copyValues(dst); 1349 return dst; 1350 } 1351 1352 public void copyValues(ParameterComponent dst) { 1353 super.copyValues(dst); 1354 dst.type = type == null ? null : type.copy(); 1355 dst.value = value == null ? null : value.copy(); 1356 } 1357 1358 @Override 1359 public boolean equalsDeep(Base other_) { 1360 if (!super.equalsDeep(other_)) 1361 return false; 1362 if (!(other_ instanceof ParameterComponent)) 1363 return false; 1364 ParameterComponent o = (ParameterComponent) other_; 1365 return compareDeep(type, o.type, true) && compareDeep(value, o.value, true); 1366 } 1367 1368 @Override 1369 public boolean equalsShallow(Base other_) { 1370 if (!super.equalsShallow(other_)) 1371 return false; 1372 if (!(other_ instanceof ParameterComponent)) 1373 return false; 1374 ParameterComponent o = (ParameterComponent) other_; 1375 return true; 1376 } 1377 1378 public boolean isEmpty() { 1379 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, value); 1380 } 1381 1382 public String fhirType() { 1383 return "Task.input"; 1384 1385 } 1386 1387 } 1388 1389 @Block() 1390 public static class TaskOutputComponent extends BackboneElement implements IBaseBackboneElement { 1391 /** 1392 * The name of the Output parameter. 1393 */ 1394 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 1395 @Description(shortDefinition="Label for output", formalDefinition="The name of the Output parameter." ) 1396 protected CodeableConcept type; 1397 1398 /** 1399 * The value of the Output parameter as a basic type. 1400 */ 1401 @Child(name = "value", type = {}, order=2, min=1, max=1, modifier=false, summary=false) 1402 @Description(shortDefinition="Result of output", formalDefinition="The value of the Output parameter as a basic type." ) 1403 protected org.hl7.fhir.r4.model.Type value; 1404 1405 private static final long serialVersionUID = -850267045L; 1406 1407 /** 1408 * Constructor 1409 */ 1410 public TaskOutputComponent() { 1411 super(); 1412 } 1413 1414 /** 1415 * Constructor 1416 */ 1417 public TaskOutputComponent(CodeableConcept type, org.hl7.fhir.r4.model.Type value) { 1418 super(); 1419 this.type = type; 1420 this.value = value; 1421 } 1422 1423 /** 1424 * @return {@link #type} (The name of the Output parameter.) 1425 */ 1426 public CodeableConcept getType() { 1427 if (this.type == null) 1428 if (Configuration.errorOnAutoCreate()) 1429 throw new Error("Attempt to auto-create TaskOutputComponent.type"); 1430 else if (Configuration.doAutoCreate()) 1431 this.type = new CodeableConcept(); // cc 1432 return this.type; 1433 } 1434 1435 public boolean hasType() { 1436 return this.type != null && !this.type.isEmpty(); 1437 } 1438 1439 /** 1440 * @param value {@link #type} (The name of the Output parameter.) 1441 */ 1442 public TaskOutputComponent setType(CodeableConcept value) { 1443 this.type = value; 1444 return this; 1445 } 1446 1447 /** 1448 * @return {@link #value} (The value of the Output parameter as a basic type.) 1449 */ 1450 public org.hl7.fhir.r4.model.Type getValue() { 1451 return this.value; 1452 } 1453 1454 public boolean hasValue() { 1455 return this.value != null && !this.value.isEmpty(); 1456 } 1457 1458 /** 1459 * @param value {@link #value} (The value of the Output parameter as a basic type.) 1460 */ 1461 public TaskOutputComponent setValue(org.hl7.fhir.r4.model.Type value) { 1462 this.value = value; 1463 return this; 1464 } 1465 1466 protected void listChildren(List<Property> children) { 1467 super.listChildren(children); 1468 children.add(new Property("type", "CodeableConcept", "The name of the Output parameter.", 0, 1, type)); 1469 children.add(new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value)); 1470 } 1471 1472 @Override 1473 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1474 switch (_hash) { 1475 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The name of the Output parameter.", 0, 1, type); 1476 case -1410166417: /*value[x]*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1477 case 111972721: /*value*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1478 case -1535024575: /*valueBase64Binary*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1479 case 733421943: /*valueBoolean*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1480 case -786218365: /*valueCanonical*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1481 case -766209282: /*valueCode*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1482 case -766192449: /*valueDate*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1483 case 1047929900: /*valueDateTime*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1484 case -2083993440: /*valueDecimal*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1485 case 231604844: /*valueId*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1486 case -1668687056: /*valueInstant*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1487 case -1668204915: /*valueInteger*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1488 case -497880704: /*valueMarkdown*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1489 case -1410178407: /*valueOid*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1490 case -1249932027: /*valuePositiveInt*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1491 case -1424603934: /*valueString*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1492 case -765708322: /*valueTime*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1493 case 26529417: /*valueUnsignedInt*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1494 case -1410172357: /*valueUri*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1495 case -1410172354: /*valueUrl*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1496 case -765667124: /*valueUuid*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1497 case -478981821: /*valueAddress*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1498 case -67108992: /*valueAnnotation*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1499 case -475566732: /*valueAttachment*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1500 case 924902896: /*valueCodeableConcept*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1501 case -1887705029: /*valueCoding*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1502 case 944904545: /*valueContactPoint*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1503 case -2026205465: /*valueHumanName*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1504 case -130498310: /*valueIdentifier*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1505 case -1524344174: /*valuePeriod*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1506 case -2029823716: /*valueQuantity*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1507 case 2030761548: /*valueRange*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1508 case 2030767386: /*valueRatio*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1509 case 1755241690: /*valueReference*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1510 case -962229101: /*valueSampledData*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1511 case -540985785: /*valueSignature*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1512 case -1406282469: /*valueTiming*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1513 case -1858636920: /*valueDosage*/ return new Property("value[x]", "*", "The value of the Output parameter as a basic type.", 0, 1, value); 1514 default: return super.getNamedProperty(_hash, _name, _checkValid); 1515 } 1516 1517 } 1518 1519 @Override 1520 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1521 switch (hash) { 1522 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1523 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // org.hl7.fhir.r4.model.Type 1524 default: return super.getProperty(hash, name, checkValid); 1525 } 1526 1527 } 1528 1529 @Override 1530 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1531 switch (hash) { 1532 case 3575610: // type 1533 this.type = castToCodeableConcept(value); // CodeableConcept 1534 return value; 1535 case 111972721: // value 1536 this.value = castToType(value); // org.hl7.fhir.r4.model.Type 1537 return value; 1538 default: return super.setProperty(hash, name, value); 1539 } 1540 1541 } 1542 1543 @Override 1544 public Base setProperty(String name, Base value) throws FHIRException { 1545 if (name.equals("type")) { 1546 this.type = castToCodeableConcept(value); // CodeableConcept 1547 } else if (name.equals("value[x]")) { 1548 this.value = castToType(value); // org.hl7.fhir.r4.model.Type 1549 } else 1550 return super.setProperty(name, value); 1551 return value; 1552 } 1553 1554 @Override 1555 public Base makeProperty(int hash, String name) throws FHIRException { 1556 switch (hash) { 1557 case 3575610: return getType(); 1558 case -1410166417: return getValue(); 1559 case 111972721: return getValue(); 1560 default: return super.makeProperty(hash, name); 1561 } 1562 1563 } 1564 1565 @Override 1566 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1567 switch (hash) { 1568 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1569 case 111972721: /*value*/ return new String[] {"*"}; 1570 default: return super.getTypesForProperty(hash, name); 1571 } 1572 1573 } 1574 1575 @Override 1576 public Base addChild(String name) throws FHIRException { 1577 if (name.equals("type")) { 1578 this.type = new CodeableConcept(); 1579 return this.type; 1580 } 1581 else if (name.equals("valueBase64Binary")) { 1582 this.value = new Base64BinaryType(); 1583 return this.value; 1584 } 1585 else if (name.equals("valueBoolean")) { 1586 this.value = new BooleanType(); 1587 return this.value; 1588 } 1589 else if (name.equals("valueCanonical")) { 1590 this.value = new CanonicalType(); 1591 return this.value; 1592 } 1593 else if (name.equals("valueCode")) { 1594 this.value = new CodeType(); 1595 return this.value; 1596 } 1597 else if (name.equals("valueDate")) { 1598 this.value = new DateType(); 1599 return this.value; 1600 } 1601 else if (name.equals("valueDateTime")) { 1602 this.value = new DateTimeType(); 1603 return this.value; 1604 } 1605 else if (name.equals("valueDecimal")) { 1606 this.value = new DecimalType(); 1607 return this.value; 1608 } 1609 else if (name.equals("valueId")) { 1610 this.value = new IdType(); 1611 return this.value; 1612 } 1613 else if (name.equals("valueInstant")) { 1614 this.value = new InstantType(); 1615 return this.value; 1616 } 1617 else if (name.equals("valueInteger")) { 1618 this.value = new IntegerType(); 1619 return this.value; 1620 } 1621 else if (name.equals("valueMarkdown")) { 1622 this.value = new MarkdownType(); 1623 return this.value; 1624 } 1625 else if (name.equals("valueOid")) { 1626 this.value = new OidType(); 1627 return this.value; 1628 } 1629 else if (name.equals("valuePositiveInt")) { 1630 this.value = new PositiveIntType(); 1631 return this.value; 1632 } 1633 else if (name.equals("valueString")) { 1634 this.value = new StringType(); 1635 return this.value; 1636 } 1637 else if (name.equals("valueTime")) { 1638 this.value = new TimeType(); 1639 return this.value; 1640 } 1641 else if (name.equals("valueUnsignedInt")) { 1642 this.value = new UnsignedIntType(); 1643 return this.value; 1644 } 1645 else if (name.equals("valueUri")) { 1646 this.value = new UriType(); 1647 return this.value; 1648 } 1649 else if (name.equals("valueUrl")) { 1650 this.value = new UrlType(); 1651 return this.value; 1652 } 1653 else if (name.equals("valueUuid")) { 1654 this.value = new UuidType(); 1655 return this.value; 1656 } 1657 else if (name.equals("valueAddress")) { 1658 this.value = new Address(); 1659 return this.value; 1660 } 1661 else if (name.equals("valueAge")) { 1662 this.value = new Age(); 1663 return this.value; 1664 } 1665 else if (name.equals("valueAnnotation")) { 1666 this.value = new Annotation(); 1667 return this.value; 1668 } 1669 else if (name.equals("valueAttachment")) { 1670 this.value = new Attachment(); 1671 return this.value; 1672 } 1673 else if (name.equals("valueCodeableConcept")) { 1674 this.value = new CodeableConcept(); 1675 return this.value; 1676 } 1677 else if (name.equals("valueCoding")) { 1678 this.value = new Coding(); 1679 return this.value; 1680 } 1681 else if (name.equals("valueContactPoint")) { 1682 this.value = new ContactPoint(); 1683 return this.value; 1684 } 1685 else if (name.equals("valueCount")) { 1686 this.value = new Count(); 1687 return this.value; 1688 } 1689 else if (name.equals("valueDistance")) { 1690 this.value = new Distance(); 1691 return this.value; 1692 } 1693 else if (name.equals("valueDuration")) { 1694 this.value = new Duration(); 1695 return this.value; 1696 } 1697 else if (name.equals("valueHumanName")) { 1698 this.value = new HumanName(); 1699 return this.value; 1700 } 1701 else if (name.equals("valueIdentifier")) { 1702 this.value = new Identifier(); 1703 return this.value; 1704 } 1705 else if (name.equals("valueMoney")) { 1706 this.value = new Money(); 1707 return this.value; 1708 } 1709 else if (name.equals("valuePeriod")) { 1710 this.value = new Period(); 1711 return this.value; 1712 } 1713 else if (name.equals("valueQuantity")) { 1714 this.value = new Quantity(); 1715 return this.value; 1716 } 1717 else if (name.equals("valueRange")) { 1718 this.value = new Range(); 1719 return this.value; 1720 } 1721 else if (name.equals("valueRatio")) { 1722 this.value = new Ratio(); 1723 return this.value; 1724 } 1725 else if (name.equals("valueReference")) { 1726 this.value = new Reference(); 1727 return this.value; 1728 } 1729 else if (name.equals("valueSampledData")) { 1730 this.value = new SampledData(); 1731 return this.value; 1732 } 1733 else if (name.equals("valueSignature")) { 1734 this.value = new Signature(); 1735 return this.value; 1736 } 1737 else if (name.equals("valueTiming")) { 1738 this.value = new Timing(); 1739 return this.value; 1740 } 1741 else if (name.equals("valueContactDetail")) { 1742 this.value = new ContactDetail(); 1743 return this.value; 1744 } 1745 else if (name.equals("valueContributor")) { 1746 this.value = new Contributor(); 1747 return this.value; 1748 } 1749 else if (name.equals("valueDataRequirement")) { 1750 this.value = new DataRequirement(); 1751 return this.value; 1752 } 1753 else if (name.equals("valueExpression")) { 1754 this.value = new Expression(); 1755 return this.value; 1756 } 1757 else if (name.equals("valueParameterDefinition")) { 1758 this.value = new ParameterDefinition(); 1759 return this.value; 1760 } 1761 else if (name.equals("valueRelatedArtifact")) { 1762 this.value = new RelatedArtifact(); 1763 return this.value; 1764 } 1765 else if (name.equals("valueTriggerDefinition")) { 1766 this.value = new TriggerDefinition(); 1767 return this.value; 1768 } 1769 else if (name.equals("valueUsageContext")) { 1770 this.value = new UsageContext(); 1771 return this.value; 1772 } 1773 else if (name.equals("valueDosage")) { 1774 this.value = new Dosage(); 1775 return this.value; 1776 } 1777 else if (name.equals("valueMeta")) { 1778 this.value = new Meta(); 1779 return this.value; 1780 } 1781 else 1782 return super.addChild(name); 1783 } 1784 1785 public TaskOutputComponent copy() { 1786 TaskOutputComponent dst = new TaskOutputComponent(); 1787 copyValues(dst); 1788 return dst; 1789 } 1790 1791 public void copyValues(TaskOutputComponent dst) { 1792 super.copyValues(dst); 1793 dst.type = type == null ? null : type.copy(); 1794 dst.value = value == null ? null : value.copy(); 1795 } 1796 1797 @Override 1798 public boolean equalsDeep(Base other_) { 1799 if (!super.equalsDeep(other_)) 1800 return false; 1801 if (!(other_ instanceof TaskOutputComponent)) 1802 return false; 1803 TaskOutputComponent o = (TaskOutputComponent) other_; 1804 return compareDeep(type, o.type, true) && compareDeep(value, o.value, true); 1805 } 1806 1807 @Override 1808 public boolean equalsShallow(Base other_) { 1809 if (!super.equalsShallow(other_)) 1810 return false; 1811 if (!(other_ instanceof TaskOutputComponent)) 1812 return false; 1813 TaskOutputComponent o = (TaskOutputComponent) other_; 1814 return true; 1815 } 1816 1817 public boolean isEmpty() { 1818 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, value); 1819 } 1820 1821 public String fhirType() { 1822 return "Task.output"; 1823 1824 } 1825 1826 } 1827 1828 /** 1829 * The business identifier for this task. 1830 */ 1831 @Child(name = "identifier", type = {Identifier.class}, order=0, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1832 @Description(shortDefinition="Task Instance Identifier", formalDefinition="The business identifier for this task." ) 1833 protected List<Identifier> identifier; 1834 1835 /** 1836 * The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 1837 */ 1838 @Child(name = "instantiatesCanonical", type = {CanonicalType.class}, order=1, min=0, max=1, modifier=false, summary=true) 1839 @Description(shortDefinition="Formal definition of task", formalDefinition="The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task." ) 1840 protected CanonicalType instantiatesCanonical; 1841 1842 /** 1843 * The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 1844 */ 1845 @Child(name = "instantiatesUri", type = {UriType.class}, order=2, min=0, max=1, modifier=false, summary=true) 1846 @Description(shortDefinition="Formal definition of task", formalDefinition="The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task." ) 1847 protected UriType instantiatesUri; 1848 1849 /** 1850 * BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a "request" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the "request" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient. 1851 */ 1852 @Child(name = "basedOn", type = {Reference.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1853 @Description(shortDefinition="Request fulfilled by this task", formalDefinition="BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a \"request\" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the \"request\" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient." ) 1854 protected List<Reference> basedOn; 1855 /** 1856 * The actual objects that are the target of the reference (BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a "request" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the "request" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient.) 1857 */ 1858 protected List<Resource> basedOnTarget; 1859 1860 1861 /** 1862 * An identifier that links together multiple tasks and other requests that were created in the same context. 1863 */ 1864 @Child(name = "groupIdentifier", type = {Identifier.class}, order=4, min=0, max=1, modifier=false, summary=true) 1865 @Description(shortDefinition="Requisition or grouper id", formalDefinition="An identifier that links together multiple tasks and other requests that were created in the same context." ) 1866 protected Identifier groupIdentifier; 1867 1868 /** 1869 * Task that this particular task is part of. 1870 */ 1871 @Child(name = "partOf", type = {Task.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1872 @Description(shortDefinition="Composite task", formalDefinition="Task that this particular task is part of." ) 1873 protected List<Reference> partOf; 1874 /** 1875 * The actual objects that are the target of the reference (Task that this particular task is part of.) 1876 */ 1877 protected List<Task> partOfTarget; 1878 1879 1880 /** 1881 * The current status of the task. 1882 */ 1883 @Child(name = "status", type = {CodeType.class}, order=6, min=1, max=1, modifier=true, summary=true) 1884 @Description(shortDefinition="draft | requested | received | accepted | +", formalDefinition="The current status of the task." ) 1885 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/task-status") 1886 protected Enumeration<TaskStatus> status; 1887 1888 /** 1889 * An explanation as to why this task is held, failed, was refused, etc. 1890 */ 1891 @Child(name = "statusReason", type = {CodeableConcept.class}, order=7, min=0, max=1, modifier=false, summary=true) 1892 @Description(shortDefinition="Reason for current status", formalDefinition="An explanation as to why this task is held, failed, was refused, etc." ) 1893 protected CodeableConcept statusReason; 1894 1895 /** 1896 * Contains business-specific nuances of the business state. 1897 */ 1898 @Child(name = "businessStatus", type = {CodeableConcept.class}, order=8, min=0, max=1, modifier=false, summary=true) 1899 @Description(shortDefinition="E.g. \"Specimen collected\", \"IV prepped\"", formalDefinition="Contains business-specific nuances of the business state." ) 1900 protected CodeableConcept businessStatus; 1901 1902 /** 1903 * Indicates the "level" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc. 1904 */ 1905 @Child(name = "intent", type = {CodeType.class}, order=9, min=1, max=1, modifier=false, summary=true) 1906 @Description(shortDefinition="unknown | proposal | plan | order | original-order | reflex-order | filler-order | instance-order | option", formalDefinition="Indicates the \"level\" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc." ) 1907 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/task-intent") 1908 protected Enumeration<TaskIntent> intent; 1909 1910 /** 1911 * Indicates how quickly the Task should be addressed with respect to other requests. 1912 */ 1913 @Child(name = "priority", type = {CodeType.class}, order=10, min=0, max=1, modifier=false, summary=false) 1914 @Description(shortDefinition="routine | urgent | asap | stat", formalDefinition="Indicates how quickly the Task should be addressed with respect to other requests." ) 1915 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/request-priority") 1916 protected Enumeration<TaskPriority> priority; 1917 1918 /** 1919 * A name or code (or both) briefly describing what the task involves. 1920 */ 1921 @Child(name = "code", type = {CodeableConcept.class}, order=11, min=0, max=1, modifier=false, summary=true) 1922 @Description(shortDefinition="Task Type", formalDefinition="A name or code (or both) briefly describing what the task involves." ) 1923 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/task-code") 1924 protected CodeableConcept code; 1925 1926 /** 1927 * A free-text description of what is to be performed. 1928 */ 1929 @Child(name = "description", type = {StringType.class}, order=12, min=0, max=1, modifier=false, summary=true) 1930 @Description(shortDefinition="Human-readable explanation of task", formalDefinition="A free-text description of what is to be performed." ) 1931 protected StringType description; 1932 1933 /** 1934 * The request being actioned or the resource being manipulated by this task. 1935 */ 1936 @Child(name = "focus", type = {Reference.class}, order=13, min=0, max=1, modifier=false, summary=true) 1937 @Description(shortDefinition="What task is acting on", formalDefinition="The request being actioned or the resource being manipulated by this task." ) 1938 protected Reference focus; 1939 1940 /** 1941 * The actual object that is the target of the reference (The request being actioned or the resource being manipulated by this task.) 1942 */ 1943 protected Resource focusTarget; 1944 1945 /** 1946 * The entity who benefits from the performance of the service specified in the task (e.g., the patient). 1947 */ 1948 @Child(name = "for", type = {Reference.class}, order=14, min=0, max=1, modifier=false, summary=true) 1949 @Description(shortDefinition="Beneficiary of the Task", formalDefinition="The entity who benefits from the performance of the service specified in the task (e.g., the patient)." ) 1950 protected Reference for_; 1951 1952 /** 1953 * The actual object that is the target of the reference (The entity who benefits from the performance of the service specified in the task (e.g., the patient).) 1954 */ 1955 protected Resource for_Target; 1956 1957 /** 1958 * The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created. 1959 */ 1960 @Child(name = "encounter", type = {Encounter.class}, order=15, min=0, max=1, modifier=false, summary=true) 1961 @Description(shortDefinition="Healthcare event during which this task originated", formalDefinition="The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created." ) 1962 protected Reference encounter; 1963 1964 /** 1965 * The actual object that is the target of the reference (The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.) 1966 */ 1967 protected Encounter encounterTarget; 1968 1969 /** 1970 * Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end). 1971 */ 1972 @Child(name = "executionPeriod", type = {Period.class}, order=16, min=0, max=1, modifier=false, summary=true) 1973 @Description(shortDefinition="Start and end time of execution", formalDefinition="Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end)." ) 1974 protected Period executionPeriod; 1975 1976 /** 1977 * The date and time this task was created. 1978 */ 1979 @Child(name = "authoredOn", type = {DateTimeType.class}, order=17, min=0, max=1, modifier=false, summary=false) 1980 @Description(shortDefinition="Task Creation Date", formalDefinition="The date and time this task was created." ) 1981 protected DateTimeType authoredOn; 1982 1983 /** 1984 * The date and time of last modification to this task. 1985 */ 1986 @Child(name = "lastModified", type = {DateTimeType.class}, order=18, min=0, max=1, modifier=false, summary=true) 1987 @Description(shortDefinition="Task Last Modified Date", formalDefinition="The date and time of last modification to this task." ) 1988 protected DateTimeType lastModified; 1989 1990 /** 1991 * The creator of the task. 1992 */ 1993 @Child(name = "requester", type = {Device.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class}, order=19, min=0, max=1, modifier=false, summary=true) 1994 @Description(shortDefinition="Who is asking for task to be done", formalDefinition="The creator of the task." ) 1995 protected Reference requester; 1996 1997 /** 1998 * The actual object that is the target of the reference (The creator of the task.) 1999 */ 2000 protected Resource requesterTarget; 2001 2002 /** 2003 * The kind of participant that should perform the task. 2004 */ 2005 @Child(name = "performerType", type = {CodeableConcept.class}, order=20, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2006 @Description(shortDefinition="Requested performer", formalDefinition="The kind of participant that should perform the task." ) 2007 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/performer-role") 2008 protected List<CodeableConcept> performerType; 2009 2010 /** 2011 * Individual organization or Device currently responsible for task execution. 2012 */ 2013 @Child(name = "owner", type = {Practitioner.class, PractitionerRole.class, Organization.class, CareTeam.class, HealthcareService.class, Patient.class, Device.class, RelatedPerson.class}, order=21, min=0, max=1, modifier=false, summary=true) 2014 @Description(shortDefinition="Responsible individual", formalDefinition="Individual organization or Device currently responsible for task execution." ) 2015 protected Reference owner; 2016 2017 /** 2018 * The actual object that is the target of the reference (Individual organization or Device currently responsible for task execution.) 2019 */ 2020 protected Resource ownerTarget; 2021 2022 /** 2023 * Principal physical location where the this task is performed. 2024 */ 2025 @Child(name = "location", type = {Location.class}, order=22, min=0, max=1, modifier=false, summary=true) 2026 @Description(shortDefinition="Where task occurs", formalDefinition="Principal physical location where the this task is performed." ) 2027 protected Reference location; 2028 2029 /** 2030 * The actual object that is the target of the reference (Principal physical location where the this task is performed.) 2031 */ 2032 protected Location locationTarget; 2033 2034 /** 2035 * A description or code indicating why this task needs to be performed. 2036 */ 2037 @Child(name = "reasonCode", type = {CodeableConcept.class}, order=23, min=0, max=1, modifier=false, summary=false) 2038 @Description(shortDefinition="Why task is needed", formalDefinition="A description or code indicating why this task needs to be performed." ) 2039 protected CodeableConcept reasonCode; 2040 2041 /** 2042 * A resource reference indicating why this task needs to be performed. 2043 */ 2044 @Child(name = "reasonReference", type = {Reference.class}, order=24, min=0, max=1, modifier=false, summary=false) 2045 @Description(shortDefinition="Why task is needed", formalDefinition="A resource reference indicating why this task needs to be performed." ) 2046 protected Reference reasonReference; 2047 2048 /** 2049 * The actual object that is the target of the reference (A resource reference indicating why this task needs to be performed.) 2050 */ 2051 protected Resource reasonReferenceTarget; 2052 2053 /** 2054 * Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task. 2055 */ 2056 @Child(name = "insurance", type = {Coverage.class, ClaimResponse.class}, order=25, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2057 @Description(shortDefinition="Associated insurance coverage", formalDefinition="Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task." ) 2058 protected List<Reference> insurance; 2059 /** 2060 * The actual objects that are the target of the reference (Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task.) 2061 */ 2062 protected List<Resource> insuranceTarget; 2063 2064 2065 /** 2066 * Free-text information captured about the task as it progresses. 2067 */ 2068 @Child(name = "note", type = {Annotation.class}, order=26, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2069 @Description(shortDefinition="Comments made about the task", formalDefinition="Free-text information captured about the task as it progresses." ) 2070 protected List<Annotation> note; 2071 2072 /** 2073 * Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task. 2074 */ 2075 @Child(name = "relevantHistory", type = {Provenance.class}, order=27, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2076 @Description(shortDefinition="Key events in history of the Task", formalDefinition="Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task." ) 2077 protected List<Reference> relevantHistory; 2078 /** 2079 * The actual objects that are the target of the reference (Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task.) 2080 */ 2081 protected List<Provenance> relevantHistoryTarget; 2082 2083 2084 /** 2085 * If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned. 2086 */ 2087 @Child(name = "restriction", type = {}, order=28, min=0, max=1, modifier=false, summary=false) 2088 @Description(shortDefinition="Constraints on fulfillment tasks", formalDefinition="If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned." ) 2089 protected TaskRestrictionComponent restriction; 2090 2091 /** 2092 * Additional information that may be needed in the execution of the task. 2093 */ 2094 @Child(name = "input", type = {}, order=29, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2095 @Description(shortDefinition="Information used to perform task", formalDefinition="Additional information that may be needed in the execution of the task." ) 2096 protected List<ParameterComponent> input; 2097 2098 /** 2099 * Outputs produced by the Task. 2100 */ 2101 @Child(name = "output", type = {}, order=30, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 2102 @Description(shortDefinition="Information produced as part of task", formalDefinition="Outputs produced by the Task." ) 2103 protected List<TaskOutputComponent> output; 2104 2105 private static final long serialVersionUID = -765029272L; 2106 2107 /** 2108 * Constructor 2109 */ 2110 public Task() { 2111 super(); 2112 } 2113 2114 /** 2115 * Constructor 2116 */ 2117 public Task(Enumeration<TaskStatus> status, Enumeration<TaskIntent> intent) { 2118 super(); 2119 this.status = status; 2120 this.intent = intent; 2121 } 2122 2123 /** 2124 * @return {@link #identifier} (The business identifier for this task.) 2125 */ 2126 public List<Identifier> getIdentifier() { 2127 if (this.identifier == null) 2128 this.identifier = new ArrayList<Identifier>(); 2129 return this.identifier; 2130 } 2131 2132 /** 2133 * @return Returns a reference to <code>this</code> for easy method chaining 2134 */ 2135 public Task setIdentifier(List<Identifier> theIdentifier) { 2136 this.identifier = theIdentifier; 2137 return this; 2138 } 2139 2140 public boolean hasIdentifier() { 2141 if (this.identifier == null) 2142 return false; 2143 for (Identifier item : this.identifier) 2144 if (!item.isEmpty()) 2145 return true; 2146 return false; 2147 } 2148 2149 public Identifier addIdentifier() { //3 2150 Identifier t = new Identifier(); 2151 if (this.identifier == null) 2152 this.identifier = new ArrayList<Identifier>(); 2153 this.identifier.add(t); 2154 return t; 2155 } 2156 2157 public Task addIdentifier(Identifier t) { //3 2158 if (t == null) 2159 return this; 2160 if (this.identifier == null) 2161 this.identifier = new ArrayList<Identifier>(); 2162 this.identifier.add(t); 2163 return this; 2164 } 2165 2166 /** 2167 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist 2168 */ 2169 public Identifier getIdentifierFirstRep() { 2170 if (getIdentifier().isEmpty()) { 2171 addIdentifier(); 2172 } 2173 return getIdentifier().get(0); 2174 } 2175 2176 /** 2177 * @return {@link #instantiatesCanonical} (The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 2178 */ 2179 public CanonicalType getInstantiatesCanonicalElement() { 2180 if (this.instantiatesCanonical == null) 2181 if (Configuration.errorOnAutoCreate()) 2182 throw new Error("Attempt to auto-create Task.instantiatesCanonical"); 2183 else if (Configuration.doAutoCreate()) 2184 this.instantiatesCanonical = new CanonicalType(); // bb 2185 return this.instantiatesCanonical; 2186 } 2187 2188 public boolean hasInstantiatesCanonicalElement() { 2189 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 2190 } 2191 2192 public boolean hasInstantiatesCanonical() { 2193 return this.instantiatesCanonical != null && !this.instantiatesCanonical.isEmpty(); 2194 } 2195 2196 /** 2197 * @param value {@link #instantiatesCanonical} (The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesCanonical" gives direct access to the value 2198 */ 2199 public Task setInstantiatesCanonicalElement(CanonicalType value) { 2200 this.instantiatesCanonical = value; 2201 return this; 2202 } 2203 2204 /** 2205 * @return The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 2206 */ 2207 public String getInstantiatesCanonical() { 2208 return this.instantiatesCanonical == null ? null : this.instantiatesCanonical.getValue(); 2209 } 2210 2211 /** 2212 * @param value The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 2213 */ 2214 public Task setInstantiatesCanonical(String value) { 2215 if (Utilities.noString(value)) 2216 this.instantiatesCanonical = null; 2217 else { 2218 if (this.instantiatesCanonical == null) 2219 this.instantiatesCanonical = new CanonicalType(); 2220 this.instantiatesCanonical.setValue(value); 2221 } 2222 return this; 2223 } 2224 2225 /** 2226 * @return {@link #instantiatesUri} (The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 2227 */ 2228 public UriType getInstantiatesUriElement() { 2229 if (this.instantiatesUri == null) 2230 if (Configuration.errorOnAutoCreate()) 2231 throw new Error("Attempt to auto-create Task.instantiatesUri"); 2232 else if (Configuration.doAutoCreate()) 2233 this.instantiatesUri = new UriType(); // bb 2234 return this.instantiatesUri; 2235 } 2236 2237 public boolean hasInstantiatesUriElement() { 2238 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 2239 } 2240 2241 public boolean hasInstantiatesUri() { 2242 return this.instantiatesUri != null && !this.instantiatesUri.isEmpty(); 2243 } 2244 2245 /** 2246 * @param value {@link #instantiatesUri} (The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.). This is the underlying object with id, value and extensions. The accessor "getInstantiatesUri" gives direct access to the value 2247 */ 2248 public Task setInstantiatesUriElement(UriType value) { 2249 this.instantiatesUri = value; 2250 return this; 2251 } 2252 2253 /** 2254 * @return The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 2255 */ 2256 public String getInstantiatesUri() { 2257 return this.instantiatesUri == null ? null : this.instantiatesUri.getValue(); 2258 } 2259 2260 /** 2261 * @param value The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task. 2262 */ 2263 public Task setInstantiatesUri(String value) { 2264 if (Utilities.noString(value)) 2265 this.instantiatesUri = null; 2266 else { 2267 if (this.instantiatesUri == null) 2268 this.instantiatesUri = new UriType(); 2269 this.instantiatesUri.setValue(value); 2270 } 2271 return this; 2272 } 2273 2274 /** 2275 * @return {@link #basedOn} (BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a "request" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the "request" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient.) 2276 */ 2277 public List<Reference> getBasedOn() { 2278 if (this.basedOn == null) 2279 this.basedOn = new ArrayList<Reference>(); 2280 return this.basedOn; 2281 } 2282 2283 /** 2284 * @return Returns a reference to <code>this</code> for easy method chaining 2285 */ 2286 public Task setBasedOn(List<Reference> theBasedOn) { 2287 this.basedOn = theBasedOn; 2288 return this; 2289 } 2290 2291 public boolean hasBasedOn() { 2292 if (this.basedOn == null) 2293 return false; 2294 for (Reference item : this.basedOn) 2295 if (!item.isEmpty()) 2296 return true; 2297 return false; 2298 } 2299 2300 public Reference addBasedOn() { //3 2301 Reference t = new Reference(); 2302 if (this.basedOn == null) 2303 this.basedOn = new ArrayList<Reference>(); 2304 this.basedOn.add(t); 2305 return t; 2306 } 2307 2308 public Task addBasedOn(Reference t) { //3 2309 if (t == null) 2310 return this; 2311 if (this.basedOn == null) 2312 this.basedOn = new ArrayList<Reference>(); 2313 this.basedOn.add(t); 2314 return this; 2315 } 2316 2317 /** 2318 * @return The first repetition of repeating field {@link #basedOn}, creating it if it does not already exist 2319 */ 2320 public Reference getBasedOnFirstRep() { 2321 if (getBasedOn().isEmpty()) { 2322 addBasedOn(); 2323 } 2324 return getBasedOn().get(0); 2325 } 2326 2327 /** 2328 * @deprecated Use Reference#setResource(IBaseResource) instead 2329 */ 2330 @Deprecated 2331 public List<Resource> getBasedOnTarget() { 2332 if (this.basedOnTarget == null) 2333 this.basedOnTarget = new ArrayList<Resource>(); 2334 return this.basedOnTarget; 2335 } 2336 2337 /** 2338 * @return {@link #groupIdentifier} (An identifier that links together multiple tasks and other requests that were created in the same context.) 2339 */ 2340 public Identifier getGroupIdentifier() { 2341 if (this.groupIdentifier == null) 2342 if (Configuration.errorOnAutoCreate()) 2343 throw new Error("Attempt to auto-create Task.groupIdentifier"); 2344 else if (Configuration.doAutoCreate()) 2345 this.groupIdentifier = new Identifier(); // cc 2346 return this.groupIdentifier; 2347 } 2348 2349 public boolean hasGroupIdentifier() { 2350 return this.groupIdentifier != null && !this.groupIdentifier.isEmpty(); 2351 } 2352 2353 /** 2354 * @param value {@link #groupIdentifier} (An identifier that links together multiple tasks and other requests that were created in the same context.) 2355 */ 2356 public Task setGroupIdentifier(Identifier value) { 2357 this.groupIdentifier = value; 2358 return this; 2359 } 2360 2361 /** 2362 * @return {@link #partOf} (Task that this particular task is part of.) 2363 */ 2364 public List<Reference> getPartOf() { 2365 if (this.partOf == null) 2366 this.partOf = new ArrayList<Reference>(); 2367 return this.partOf; 2368 } 2369 2370 /** 2371 * @return Returns a reference to <code>this</code> for easy method chaining 2372 */ 2373 public Task setPartOf(List<Reference> thePartOf) { 2374 this.partOf = thePartOf; 2375 return this; 2376 } 2377 2378 public boolean hasPartOf() { 2379 if (this.partOf == null) 2380 return false; 2381 for (Reference item : this.partOf) 2382 if (!item.isEmpty()) 2383 return true; 2384 return false; 2385 } 2386 2387 public Reference addPartOf() { //3 2388 Reference t = new Reference(); 2389 if (this.partOf == null) 2390 this.partOf = new ArrayList<Reference>(); 2391 this.partOf.add(t); 2392 return t; 2393 } 2394 2395 public Task addPartOf(Reference t) { //3 2396 if (t == null) 2397 return this; 2398 if (this.partOf == null) 2399 this.partOf = new ArrayList<Reference>(); 2400 this.partOf.add(t); 2401 return this; 2402 } 2403 2404 /** 2405 * @return The first repetition of repeating field {@link #partOf}, creating it if it does not already exist 2406 */ 2407 public Reference getPartOfFirstRep() { 2408 if (getPartOf().isEmpty()) { 2409 addPartOf(); 2410 } 2411 return getPartOf().get(0); 2412 } 2413 2414 /** 2415 * @deprecated Use Reference#setResource(IBaseResource) instead 2416 */ 2417 @Deprecated 2418 public List<Task> getPartOfTarget() { 2419 if (this.partOfTarget == null) 2420 this.partOfTarget = new ArrayList<Task>(); 2421 return this.partOfTarget; 2422 } 2423 2424 /** 2425 * @deprecated Use Reference#setResource(IBaseResource) instead 2426 */ 2427 @Deprecated 2428 public Task addPartOfTarget() { 2429 Task r = new Task(); 2430 if (this.partOfTarget == null) 2431 this.partOfTarget = new ArrayList<Task>(); 2432 this.partOfTarget.add(r); 2433 return r; 2434 } 2435 2436 /** 2437 * @return {@link #status} (The current status of the task.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2438 */ 2439 public Enumeration<TaskStatus> getStatusElement() { 2440 if (this.status == null) 2441 if (Configuration.errorOnAutoCreate()) 2442 throw new Error("Attempt to auto-create Task.status"); 2443 else if (Configuration.doAutoCreate()) 2444 this.status = new Enumeration<TaskStatus>(new TaskStatusEnumFactory()); // bb 2445 return this.status; 2446 } 2447 2448 public boolean hasStatusElement() { 2449 return this.status != null && !this.status.isEmpty(); 2450 } 2451 2452 public boolean hasStatus() { 2453 return this.status != null && !this.status.isEmpty(); 2454 } 2455 2456 /** 2457 * @param value {@link #status} (The current status of the task.). This is the underlying object with id, value and extensions. The accessor "getStatus" gives direct access to the value 2458 */ 2459 public Task setStatusElement(Enumeration<TaskStatus> value) { 2460 this.status = value; 2461 return this; 2462 } 2463 2464 /** 2465 * @return The current status of the task. 2466 */ 2467 public TaskStatus getStatus() { 2468 return this.status == null ? null : this.status.getValue(); 2469 } 2470 2471 /** 2472 * @param value The current status of the task. 2473 */ 2474 public Task setStatus(TaskStatus value) { 2475 if (this.status == null) 2476 this.status = new Enumeration<TaskStatus>(new TaskStatusEnumFactory()); 2477 this.status.setValue(value); 2478 return this; 2479 } 2480 2481 /** 2482 * @return {@link #statusReason} (An explanation as to why this task is held, failed, was refused, etc.) 2483 */ 2484 public CodeableConcept getStatusReason() { 2485 if (this.statusReason == null) 2486 if (Configuration.errorOnAutoCreate()) 2487 throw new Error("Attempt to auto-create Task.statusReason"); 2488 else if (Configuration.doAutoCreate()) 2489 this.statusReason = new CodeableConcept(); // cc 2490 return this.statusReason; 2491 } 2492 2493 public boolean hasStatusReason() { 2494 return this.statusReason != null && !this.statusReason.isEmpty(); 2495 } 2496 2497 /** 2498 * @param value {@link #statusReason} (An explanation as to why this task is held, failed, was refused, etc.) 2499 */ 2500 public Task setStatusReason(CodeableConcept value) { 2501 this.statusReason = value; 2502 return this; 2503 } 2504 2505 /** 2506 * @return {@link #businessStatus} (Contains business-specific nuances of the business state.) 2507 */ 2508 public CodeableConcept getBusinessStatus() { 2509 if (this.businessStatus == null) 2510 if (Configuration.errorOnAutoCreate()) 2511 throw new Error("Attempt to auto-create Task.businessStatus"); 2512 else if (Configuration.doAutoCreate()) 2513 this.businessStatus = new CodeableConcept(); // cc 2514 return this.businessStatus; 2515 } 2516 2517 public boolean hasBusinessStatus() { 2518 return this.businessStatus != null && !this.businessStatus.isEmpty(); 2519 } 2520 2521 /** 2522 * @param value {@link #businessStatus} (Contains business-specific nuances of the business state.) 2523 */ 2524 public Task setBusinessStatus(CodeableConcept value) { 2525 this.businessStatus = value; 2526 return this; 2527 } 2528 2529 /** 2530 * @return {@link #intent} (Indicates the "level" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc.). This is the underlying object with id, value and extensions. The accessor "getIntent" gives direct access to the value 2531 */ 2532 public Enumeration<TaskIntent> getIntentElement() { 2533 if (this.intent == null) 2534 if (Configuration.errorOnAutoCreate()) 2535 throw new Error("Attempt to auto-create Task.intent"); 2536 else if (Configuration.doAutoCreate()) 2537 this.intent = new Enumeration<TaskIntent>(new TaskIntentEnumFactory()); // bb 2538 return this.intent; 2539 } 2540 2541 public boolean hasIntentElement() { 2542 return this.intent != null && !this.intent.isEmpty(); 2543 } 2544 2545 public boolean hasIntent() { 2546 return this.intent != null && !this.intent.isEmpty(); 2547 } 2548 2549 /** 2550 * @param value {@link #intent} (Indicates the "level" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc.). This is the underlying object with id, value and extensions. The accessor "getIntent" gives direct access to the value 2551 */ 2552 public Task setIntentElement(Enumeration<TaskIntent> value) { 2553 this.intent = value; 2554 return this; 2555 } 2556 2557 /** 2558 * @return Indicates the "level" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc. 2559 */ 2560 public TaskIntent getIntent() { 2561 return this.intent == null ? null : this.intent.getValue(); 2562 } 2563 2564 /** 2565 * @param value Indicates the "level" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc. 2566 */ 2567 public Task setIntent(TaskIntent value) { 2568 if (this.intent == null) 2569 this.intent = new Enumeration<TaskIntent>(new TaskIntentEnumFactory()); 2570 this.intent.setValue(value); 2571 return this; 2572 } 2573 2574 /** 2575 * @return {@link #priority} (Indicates how quickly the Task should be addressed with respect to other requests.). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value 2576 */ 2577 public Enumeration<TaskPriority> getPriorityElement() { 2578 if (this.priority == null) 2579 if (Configuration.errorOnAutoCreate()) 2580 throw new Error("Attempt to auto-create Task.priority"); 2581 else if (Configuration.doAutoCreate()) 2582 this.priority = new Enumeration<TaskPriority>(new TaskPriorityEnumFactory()); // bb 2583 return this.priority; 2584 } 2585 2586 public boolean hasPriorityElement() { 2587 return this.priority != null && !this.priority.isEmpty(); 2588 } 2589 2590 public boolean hasPriority() { 2591 return this.priority != null && !this.priority.isEmpty(); 2592 } 2593 2594 /** 2595 * @param value {@link #priority} (Indicates how quickly the Task should be addressed with respect to other requests.). This is the underlying object with id, value and extensions. The accessor "getPriority" gives direct access to the value 2596 */ 2597 public Task setPriorityElement(Enumeration<TaskPriority> value) { 2598 this.priority = value; 2599 return this; 2600 } 2601 2602 /** 2603 * @return Indicates how quickly the Task should be addressed with respect to other requests. 2604 */ 2605 public TaskPriority getPriority() { 2606 return this.priority == null ? null : this.priority.getValue(); 2607 } 2608 2609 /** 2610 * @param value Indicates how quickly the Task should be addressed with respect to other requests. 2611 */ 2612 public Task setPriority(TaskPriority value) { 2613 if (value == null) 2614 this.priority = null; 2615 else { 2616 if (this.priority == null) 2617 this.priority = new Enumeration<TaskPriority>(new TaskPriorityEnumFactory()); 2618 this.priority.setValue(value); 2619 } 2620 return this; 2621 } 2622 2623 /** 2624 * @return {@link #code} (A name or code (or both) briefly describing what the task involves.) 2625 */ 2626 public CodeableConcept getCode() { 2627 if (this.code == null) 2628 if (Configuration.errorOnAutoCreate()) 2629 throw new Error("Attempt to auto-create Task.code"); 2630 else if (Configuration.doAutoCreate()) 2631 this.code = new CodeableConcept(); // cc 2632 return this.code; 2633 } 2634 2635 public boolean hasCode() { 2636 return this.code != null && !this.code.isEmpty(); 2637 } 2638 2639 /** 2640 * @param value {@link #code} (A name or code (or both) briefly describing what the task involves.) 2641 */ 2642 public Task setCode(CodeableConcept value) { 2643 this.code = value; 2644 return this; 2645 } 2646 2647 /** 2648 * @return {@link #description} (A free-text description of what is to be performed.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2649 */ 2650 public StringType getDescriptionElement() { 2651 if (this.description == null) 2652 if (Configuration.errorOnAutoCreate()) 2653 throw new Error("Attempt to auto-create Task.description"); 2654 else if (Configuration.doAutoCreate()) 2655 this.description = new StringType(); // bb 2656 return this.description; 2657 } 2658 2659 public boolean hasDescriptionElement() { 2660 return this.description != null && !this.description.isEmpty(); 2661 } 2662 2663 public boolean hasDescription() { 2664 return this.description != null && !this.description.isEmpty(); 2665 } 2666 2667 /** 2668 * @param value {@link #description} (A free-text description of what is to be performed.). This is the underlying object with id, value and extensions. The accessor "getDescription" gives direct access to the value 2669 */ 2670 public Task setDescriptionElement(StringType value) { 2671 this.description = value; 2672 return this; 2673 } 2674 2675 /** 2676 * @return A free-text description of what is to be performed. 2677 */ 2678 public String getDescription() { 2679 return this.description == null ? null : this.description.getValue(); 2680 } 2681 2682 /** 2683 * @param value A free-text description of what is to be performed. 2684 */ 2685 public Task setDescription(String value) { 2686 if (Utilities.noString(value)) 2687 this.description = null; 2688 else { 2689 if (this.description == null) 2690 this.description = new StringType(); 2691 this.description.setValue(value); 2692 } 2693 return this; 2694 } 2695 2696 /** 2697 * @return {@link #focus} (The request being actioned or the resource being manipulated by this task.) 2698 */ 2699 public Reference getFocus() { 2700 if (this.focus == null) 2701 if (Configuration.errorOnAutoCreate()) 2702 throw new Error("Attempt to auto-create Task.focus"); 2703 else if (Configuration.doAutoCreate()) 2704 this.focus = new Reference(); // cc 2705 return this.focus; 2706 } 2707 2708 public boolean hasFocus() { 2709 return this.focus != null && !this.focus.isEmpty(); 2710 } 2711 2712 /** 2713 * @param value {@link #focus} (The request being actioned or the resource being manipulated by this task.) 2714 */ 2715 public Task setFocus(Reference value) { 2716 this.focus = value; 2717 return this; 2718 } 2719 2720 /** 2721 * @return {@link #focus} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The request being actioned or the resource being manipulated by this task.) 2722 */ 2723 public Resource getFocusTarget() { 2724 return this.focusTarget; 2725 } 2726 2727 /** 2728 * @param value {@link #focus} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The request being actioned or the resource being manipulated by this task.) 2729 */ 2730 public Task setFocusTarget(Resource value) { 2731 this.focusTarget = value; 2732 return this; 2733 } 2734 2735 /** 2736 * @return {@link #for_} (The entity who benefits from the performance of the service specified in the task (e.g., the patient).) 2737 */ 2738 public Reference getFor() { 2739 if (this.for_ == null) 2740 if (Configuration.errorOnAutoCreate()) 2741 throw new Error("Attempt to auto-create Task.for_"); 2742 else if (Configuration.doAutoCreate()) 2743 this.for_ = new Reference(); // cc 2744 return this.for_; 2745 } 2746 2747 public boolean hasFor() { 2748 return this.for_ != null && !this.for_.isEmpty(); 2749 } 2750 2751 /** 2752 * @param value {@link #for_} (The entity who benefits from the performance of the service specified in the task (e.g., the patient).) 2753 */ 2754 public Task setFor(Reference value) { 2755 this.for_ = value; 2756 return this; 2757 } 2758 2759 /** 2760 * @return {@link #for_} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The entity who benefits from the performance of the service specified in the task (e.g., the patient).) 2761 */ 2762 public Resource getForTarget() { 2763 return this.for_Target; 2764 } 2765 2766 /** 2767 * @param value {@link #for_} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The entity who benefits from the performance of the service specified in the task (e.g., the patient).) 2768 */ 2769 public Task setForTarget(Resource value) { 2770 this.for_Target = value; 2771 return this; 2772 } 2773 2774 /** 2775 * @return {@link #encounter} (The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.) 2776 */ 2777 public Reference getEncounter() { 2778 if (this.encounter == null) 2779 if (Configuration.errorOnAutoCreate()) 2780 throw new Error("Attempt to auto-create Task.encounter"); 2781 else if (Configuration.doAutoCreate()) 2782 this.encounter = new Reference(); // cc 2783 return this.encounter; 2784 } 2785 2786 public boolean hasEncounter() { 2787 return this.encounter != null && !this.encounter.isEmpty(); 2788 } 2789 2790 /** 2791 * @param value {@link #encounter} (The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.) 2792 */ 2793 public Task setEncounter(Reference value) { 2794 this.encounter = value; 2795 return this; 2796 } 2797 2798 /** 2799 * @return {@link #encounter} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.) 2800 */ 2801 public Encounter getEncounterTarget() { 2802 if (this.encounterTarget == null) 2803 if (Configuration.errorOnAutoCreate()) 2804 throw new Error("Attempt to auto-create Task.encounter"); 2805 else if (Configuration.doAutoCreate()) 2806 this.encounterTarget = new Encounter(); // aa 2807 return this.encounterTarget; 2808 } 2809 2810 /** 2811 * @param value {@link #encounter} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.) 2812 */ 2813 public Task setEncounterTarget(Encounter value) { 2814 this.encounterTarget = value; 2815 return this; 2816 } 2817 2818 /** 2819 * @return {@link #executionPeriod} (Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end).) 2820 */ 2821 public Period getExecutionPeriod() { 2822 if (this.executionPeriod == null) 2823 if (Configuration.errorOnAutoCreate()) 2824 throw new Error("Attempt to auto-create Task.executionPeriod"); 2825 else if (Configuration.doAutoCreate()) 2826 this.executionPeriod = new Period(); // cc 2827 return this.executionPeriod; 2828 } 2829 2830 public boolean hasExecutionPeriod() { 2831 return this.executionPeriod != null && !this.executionPeriod.isEmpty(); 2832 } 2833 2834 /** 2835 * @param value {@link #executionPeriod} (Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end).) 2836 */ 2837 public Task setExecutionPeriod(Period value) { 2838 this.executionPeriod = value; 2839 return this; 2840 } 2841 2842 /** 2843 * @return {@link #authoredOn} (The date and time this task was created.). This is the underlying object with id, value and extensions. The accessor "getAuthoredOn" gives direct access to the value 2844 */ 2845 public DateTimeType getAuthoredOnElement() { 2846 if (this.authoredOn == null) 2847 if (Configuration.errorOnAutoCreate()) 2848 throw new Error("Attempt to auto-create Task.authoredOn"); 2849 else if (Configuration.doAutoCreate()) 2850 this.authoredOn = new DateTimeType(); // bb 2851 return this.authoredOn; 2852 } 2853 2854 public boolean hasAuthoredOnElement() { 2855 return this.authoredOn != null && !this.authoredOn.isEmpty(); 2856 } 2857 2858 public boolean hasAuthoredOn() { 2859 return this.authoredOn != null && !this.authoredOn.isEmpty(); 2860 } 2861 2862 /** 2863 * @param value {@link #authoredOn} (The date and time this task was created.). This is the underlying object with id, value and extensions. The accessor "getAuthoredOn" gives direct access to the value 2864 */ 2865 public Task setAuthoredOnElement(DateTimeType value) { 2866 this.authoredOn = value; 2867 return this; 2868 } 2869 2870 /** 2871 * @return The date and time this task was created. 2872 */ 2873 public Date getAuthoredOn() { 2874 return this.authoredOn == null ? null : this.authoredOn.getValue(); 2875 } 2876 2877 /** 2878 * @param value The date and time this task was created. 2879 */ 2880 public Task setAuthoredOn(Date value) { 2881 if (value == null) 2882 this.authoredOn = null; 2883 else { 2884 if (this.authoredOn == null) 2885 this.authoredOn = new DateTimeType(); 2886 this.authoredOn.setValue(value); 2887 } 2888 return this; 2889 } 2890 2891 /** 2892 * @return {@link #lastModified} (The date and time of last modification to this task.). This is the underlying object with id, value and extensions. The accessor "getLastModified" gives direct access to the value 2893 */ 2894 public DateTimeType getLastModifiedElement() { 2895 if (this.lastModified == null) 2896 if (Configuration.errorOnAutoCreate()) 2897 throw new Error("Attempt to auto-create Task.lastModified"); 2898 else if (Configuration.doAutoCreate()) 2899 this.lastModified = new DateTimeType(); // bb 2900 return this.lastModified; 2901 } 2902 2903 public boolean hasLastModifiedElement() { 2904 return this.lastModified != null && !this.lastModified.isEmpty(); 2905 } 2906 2907 public boolean hasLastModified() { 2908 return this.lastModified != null && !this.lastModified.isEmpty(); 2909 } 2910 2911 /** 2912 * @param value {@link #lastModified} (The date and time of last modification to this task.). This is the underlying object with id, value and extensions. The accessor "getLastModified" gives direct access to the value 2913 */ 2914 public Task setLastModifiedElement(DateTimeType value) { 2915 this.lastModified = value; 2916 return this; 2917 } 2918 2919 /** 2920 * @return The date and time of last modification to this task. 2921 */ 2922 public Date getLastModified() { 2923 return this.lastModified == null ? null : this.lastModified.getValue(); 2924 } 2925 2926 /** 2927 * @param value The date and time of last modification to this task. 2928 */ 2929 public Task setLastModified(Date value) { 2930 if (value == null) 2931 this.lastModified = null; 2932 else { 2933 if (this.lastModified == null) 2934 this.lastModified = new DateTimeType(); 2935 this.lastModified.setValue(value); 2936 } 2937 return this; 2938 } 2939 2940 /** 2941 * @return {@link #requester} (The creator of the task.) 2942 */ 2943 public Reference getRequester() { 2944 if (this.requester == null) 2945 if (Configuration.errorOnAutoCreate()) 2946 throw new Error("Attempt to auto-create Task.requester"); 2947 else if (Configuration.doAutoCreate()) 2948 this.requester = new Reference(); // cc 2949 return this.requester; 2950 } 2951 2952 public boolean hasRequester() { 2953 return this.requester != null && !this.requester.isEmpty(); 2954 } 2955 2956 /** 2957 * @param value {@link #requester} (The creator of the task.) 2958 */ 2959 public Task setRequester(Reference value) { 2960 this.requester = value; 2961 return this; 2962 } 2963 2964 /** 2965 * @return {@link #requester} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (The creator of the task.) 2966 */ 2967 public Resource getRequesterTarget() { 2968 return this.requesterTarget; 2969 } 2970 2971 /** 2972 * @param value {@link #requester} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (The creator of the task.) 2973 */ 2974 public Task setRequesterTarget(Resource value) { 2975 this.requesterTarget = value; 2976 return this; 2977 } 2978 2979 /** 2980 * @return {@link #performerType} (The kind of participant that should perform the task.) 2981 */ 2982 public List<CodeableConcept> getPerformerType() { 2983 if (this.performerType == null) 2984 this.performerType = new ArrayList<CodeableConcept>(); 2985 return this.performerType; 2986 } 2987 2988 /** 2989 * @return Returns a reference to <code>this</code> for easy method chaining 2990 */ 2991 public Task setPerformerType(List<CodeableConcept> thePerformerType) { 2992 this.performerType = thePerformerType; 2993 return this; 2994 } 2995 2996 public boolean hasPerformerType() { 2997 if (this.performerType == null) 2998 return false; 2999 for (CodeableConcept item : this.performerType) 3000 if (!item.isEmpty()) 3001 return true; 3002 return false; 3003 } 3004 3005 public CodeableConcept addPerformerType() { //3 3006 CodeableConcept t = new CodeableConcept(); 3007 if (this.performerType == null) 3008 this.performerType = new ArrayList<CodeableConcept>(); 3009 this.performerType.add(t); 3010 return t; 3011 } 3012 3013 public Task addPerformerType(CodeableConcept t) { //3 3014 if (t == null) 3015 return this; 3016 if (this.performerType == null) 3017 this.performerType = new ArrayList<CodeableConcept>(); 3018 this.performerType.add(t); 3019 return this; 3020 } 3021 3022 /** 3023 * @return The first repetition of repeating field {@link #performerType}, creating it if it does not already exist 3024 */ 3025 public CodeableConcept getPerformerTypeFirstRep() { 3026 if (getPerformerType().isEmpty()) { 3027 addPerformerType(); 3028 } 3029 return getPerformerType().get(0); 3030 } 3031 3032 /** 3033 * @return {@link #owner} (Individual organization or Device currently responsible for task execution.) 3034 */ 3035 public Reference getOwner() { 3036 if (this.owner == null) 3037 if (Configuration.errorOnAutoCreate()) 3038 throw new Error("Attempt to auto-create Task.owner"); 3039 else if (Configuration.doAutoCreate()) 3040 this.owner = new Reference(); // cc 3041 return this.owner; 3042 } 3043 3044 public boolean hasOwner() { 3045 return this.owner != null && !this.owner.isEmpty(); 3046 } 3047 3048 /** 3049 * @param value {@link #owner} (Individual organization or Device currently responsible for task execution.) 3050 */ 3051 public Task setOwner(Reference value) { 3052 this.owner = value; 3053 return this; 3054 } 3055 3056 /** 3057 * @return {@link #owner} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Individual organization or Device currently responsible for task execution.) 3058 */ 3059 public Resource getOwnerTarget() { 3060 return this.ownerTarget; 3061 } 3062 3063 /** 3064 * @param value {@link #owner} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Individual organization or Device currently responsible for task execution.) 3065 */ 3066 public Task setOwnerTarget(Resource value) { 3067 this.ownerTarget = value; 3068 return this; 3069 } 3070 3071 /** 3072 * @return {@link #location} (Principal physical location where the this task is performed.) 3073 */ 3074 public Reference getLocation() { 3075 if (this.location == null) 3076 if (Configuration.errorOnAutoCreate()) 3077 throw new Error("Attempt to auto-create Task.location"); 3078 else if (Configuration.doAutoCreate()) 3079 this.location = new Reference(); // cc 3080 return this.location; 3081 } 3082 3083 public boolean hasLocation() { 3084 return this.location != null && !this.location.isEmpty(); 3085 } 3086 3087 /** 3088 * @param value {@link #location} (Principal physical location where the this task is performed.) 3089 */ 3090 public Task setLocation(Reference value) { 3091 this.location = value; 3092 return this; 3093 } 3094 3095 /** 3096 * @return {@link #location} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (Principal physical location where the this task is performed.) 3097 */ 3098 public Location getLocationTarget() { 3099 if (this.locationTarget == null) 3100 if (Configuration.errorOnAutoCreate()) 3101 throw new Error("Attempt to auto-create Task.location"); 3102 else if (Configuration.doAutoCreate()) 3103 this.locationTarget = new Location(); // aa 3104 return this.locationTarget; 3105 } 3106 3107 /** 3108 * @param value {@link #location} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (Principal physical location where the this task is performed.) 3109 */ 3110 public Task setLocationTarget(Location value) { 3111 this.locationTarget = value; 3112 return this; 3113 } 3114 3115 /** 3116 * @return {@link #reasonCode} (A description or code indicating why this task needs to be performed.) 3117 */ 3118 public CodeableConcept getReasonCode() { 3119 if (this.reasonCode == null) 3120 if (Configuration.errorOnAutoCreate()) 3121 throw new Error("Attempt to auto-create Task.reasonCode"); 3122 else if (Configuration.doAutoCreate()) 3123 this.reasonCode = new CodeableConcept(); // cc 3124 return this.reasonCode; 3125 } 3126 3127 public boolean hasReasonCode() { 3128 return this.reasonCode != null && !this.reasonCode.isEmpty(); 3129 } 3130 3131 /** 3132 * @param value {@link #reasonCode} (A description or code indicating why this task needs to be performed.) 3133 */ 3134 public Task setReasonCode(CodeableConcept value) { 3135 this.reasonCode = value; 3136 return this; 3137 } 3138 3139 /** 3140 * @return {@link #reasonReference} (A resource reference indicating why this task needs to be performed.) 3141 */ 3142 public Reference getReasonReference() { 3143 if (this.reasonReference == null) 3144 if (Configuration.errorOnAutoCreate()) 3145 throw new Error("Attempt to auto-create Task.reasonReference"); 3146 else if (Configuration.doAutoCreate()) 3147 this.reasonReference = new Reference(); // cc 3148 return this.reasonReference; 3149 } 3150 3151 public boolean hasReasonReference() { 3152 return this.reasonReference != null && !this.reasonReference.isEmpty(); 3153 } 3154 3155 /** 3156 * @param value {@link #reasonReference} (A resource reference indicating why this task needs to be performed.) 3157 */ 3158 public Task setReasonReference(Reference value) { 3159 this.reasonReference = value; 3160 return this; 3161 } 3162 3163 /** 3164 * @return {@link #reasonReference} The actual object that is the target of the reference. The reference library doesn't populate this, but you can use it to hold the resource if you resolve it. (A resource reference indicating why this task needs to be performed.) 3165 */ 3166 public Resource getReasonReferenceTarget() { 3167 return this.reasonReferenceTarget; 3168 } 3169 3170 /** 3171 * @param value {@link #reasonReference} The actual object that is the target of the reference. The reference library doesn't use these, but you can use it to hold the resource if you resolve it. (A resource reference indicating why this task needs to be performed.) 3172 */ 3173 public Task setReasonReferenceTarget(Resource value) { 3174 this.reasonReferenceTarget = value; 3175 return this; 3176 } 3177 3178 /** 3179 * @return {@link #insurance} (Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task.) 3180 */ 3181 public List<Reference> getInsurance() { 3182 if (this.insurance == null) 3183 this.insurance = new ArrayList<Reference>(); 3184 return this.insurance; 3185 } 3186 3187 /** 3188 * @return Returns a reference to <code>this</code> for easy method chaining 3189 */ 3190 public Task setInsurance(List<Reference> theInsurance) { 3191 this.insurance = theInsurance; 3192 return this; 3193 } 3194 3195 public boolean hasInsurance() { 3196 if (this.insurance == null) 3197 return false; 3198 for (Reference item : this.insurance) 3199 if (!item.isEmpty()) 3200 return true; 3201 return false; 3202 } 3203 3204 public Reference addInsurance() { //3 3205 Reference t = new Reference(); 3206 if (this.insurance == null) 3207 this.insurance = new ArrayList<Reference>(); 3208 this.insurance.add(t); 3209 return t; 3210 } 3211 3212 public Task addInsurance(Reference t) { //3 3213 if (t == null) 3214 return this; 3215 if (this.insurance == null) 3216 this.insurance = new ArrayList<Reference>(); 3217 this.insurance.add(t); 3218 return this; 3219 } 3220 3221 /** 3222 * @return The first repetition of repeating field {@link #insurance}, creating it if it does not already exist 3223 */ 3224 public Reference getInsuranceFirstRep() { 3225 if (getInsurance().isEmpty()) { 3226 addInsurance(); 3227 } 3228 return getInsurance().get(0); 3229 } 3230 3231 /** 3232 * @deprecated Use Reference#setResource(IBaseResource) instead 3233 */ 3234 @Deprecated 3235 public List<Resource> getInsuranceTarget() { 3236 if (this.insuranceTarget == null) 3237 this.insuranceTarget = new ArrayList<Resource>(); 3238 return this.insuranceTarget; 3239 } 3240 3241 /** 3242 * @return {@link #note} (Free-text information captured about the task as it progresses.) 3243 */ 3244 public List<Annotation> getNote() { 3245 if (this.note == null) 3246 this.note = new ArrayList<Annotation>(); 3247 return this.note; 3248 } 3249 3250 /** 3251 * @return Returns a reference to <code>this</code> for easy method chaining 3252 */ 3253 public Task setNote(List<Annotation> theNote) { 3254 this.note = theNote; 3255 return this; 3256 } 3257 3258 public boolean hasNote() { 3259 if (this.note == null) 3260 return false; 3261 for (Annotation item : this.note) 3262 if (!item.isEmpty()) 3263 return true; 3264 return false; 3265 } 3266 3267 public Annotation addNote() { //3 3268 Annotation t = new Annotation(); 3269 if (this.note == null) 3270 this.note = new ArrayList<Annotation>(); 3271 this.note.add(t); 3272 return t; 3273 } 3274 3275 public Task addNote(Annotation t) { //3 3276 if (t == null) 3277 return this; 3278 if (this.note == null) 3279 this.note = new ArrayList<Annotation>(); 3280 this.note.add(t); 3281 return this; 3282 } 3283 3284 /** 3285 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist 3286 */ 3287 public Annotation getNoteFirstRep() { 3288 if (getNote().isEmpty()) { 3289 addNote(); 3290 } 3291 return getNote().get(0); 3292 } 3293 3294 /** 3295 * @return {@link #relevantHistory} (Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task.) 3296 */ 3297 public List<Reference> getRelevantHistory() { 3298 if (this.relevantHistory == null) 3299 this.relevantHistory = new ArrayList<Reference>(); 3300 return this.relevantHistory; 3301 } 3302 3303 /** 3304 * @return Returns a reference to <code>this</code> for easy method chaining 3305 */ 3306 public Task setRelevantHistory(List<Reference> theRelevantHistory) { 3307 this.relevantHistory = theRelevantHistory; 3308 return this; 3309 } 3310 3311 public boolean hasRelevantHistory() { 3312 if (this.relevantHistory == null) 3313 return false; 3314 for (Reference item : this.relevantHistory) 3315 if (!item.isEmpty()) 3316 return true; 3317 return false; 3318 } 3319 3320 public Reference addRelevantHistory() { //3 3321 Reference t = new Reference(); 3322 if (this.relevantHistory == null) 3323 this.relevantHistory = new ArrayList<Reference>(); 3324 this.relevantHistory.add(t); 3325 return t; 3326 } 3327 3328 public Task addRelevantHistory(Reference t) { //3 3329 if (t == null) 3330 return this; 3331 if (this.relevantHistory == null) 3332 this.relevantHistory = new ArrayList<Reference>(); 3333 this.relevantHistory.add(t); 3334 return this; 3335 } 3336 3337 /** 3338 * @return The first repetition of repeating field {@link #relevantHistory}, creating it if it does not already exist 3339 */ 3340 public Reference getRelevantHistoryFirstRep() { 3341 if (getRelevantHistory().isEmpty()) { 3342 addRelevantHistory(); 3343 } 3344 return getRelevantHistory().get(0); 3345 } 3346 3347 /** 3348 * @deprecated Use Reference#setResource(IBaseResource) instead 3349 */ 3350 @Deprecated 3351 public List<Provenance> getRelevantHistoryTarget() { 3352 if (this.relevantHistoryTarget == null) 3353 this.relevantHistoryTarget = new ArrayList<Provenance>(); 3354 return this.relevantHistoryTarget; 3355 } 3356 3357 /** 3358 * @deprecated Use Reference#setResource(IBaseResource) instead 3359 */ 3360 @Deprecated 3361 public Provenance addRelevantHistoryTarget() { 3362 Provenance r = new Provenance(); 3363 if (this.relevantHistoryTarget == null) 3364 this.relevantHistoryTarget = new ArrayList<Provenance>(); 3365 this.relevantHistoryTarget.add(r); 3366 return r; 3367 } 3368 3369 /** 3370 * @return {@link #restriction} (If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned.) 3371 */ 3372 public TaskRestrictionComponent getRestriction() { 3373 if (this.restriction == null) 3374 if (Configuration.errorOnAutoCreate()) 3375 throw new Error("Attempt to auto-create Task.restriction"); 3376 else if (Configuration.doAutoCreate()) 3377 this.restriction = new TaskRestrictionComponent(); // cc 3378 return this.restriction; 3379 } 3380 3381 public boolean hasRestriction() { 3382 return this.restriction != null && !this.restriction.isEmpty(); 3383 } 3384 3385 /** 3386 * @param value {@link #restriction} (If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned.) 3387 */ 3388 public Task setRestriction(TaskRestrictionComponent value) { 3389 this.restriction = value; 3390 return this; 3391 } 3392 3393 /** 3394 * @return {@link #input} (Additional information that may be needed in the execution of the task.) 3395 */ 3396 public List<ParameterComponent> getInput() { 3397 if (this.input == null) 3398 this.input = new ArrayList<ParameterComponent>(); 3399 return this.input; 3400 } 3401 3402 /** 3403 * @return Returns a reference to <code>this</code> for easy method chaining 3404 */ 3405 public Task setInput(List<ParameterComponent> theInput) { 3406 this.input = theInput; 3407 return this; 3408 } 3409 3410 public boolean hasInput() { 3411 if (this.input == null) 3412 return false; 3413 for (ParameterComponent item : this.input) 3414 if (!item.isEmpty()) 3415 return true; 3416 return false; 3417 } 3418 3419 public ParameterComponent addInput() { //3 3420 ParameterComponent t = new ParameterComponent(); 3421 if (this.input == null) 3422 this.input = new ArrayList<ParameterComponent>(); 3423 this.input.add(t); 3424 return t; 3425 } 3426 3427 public Task addInput(ParameterComponent t) { //3 3428 if (t == null) 3429 return this; 3430 if (this.input == null) 3431 this.input = new ArrayList<ParameterComponent>(); 3432 this.input.add(t); 3433 return this; 3434 } 3435 3436 /** 3437 * @return The first repetition of repeating field {@link #input}, creating it if it does not already exist 3438 */ 3439 public ParameterComponent getInputFirstRep() { 3440 if (getInput().isEmpty()) { 3441 addInput(); 3442 } 3443 return getInput().get(0); 3444 } 3445 3446 /** 3447 * @return {@link #output} (Outputs produced by the Task.) 3448 */ 3449 public List<TaskOutputComponent> getOutput() { 3450 if (this.output == null) 3451 this.output = new ArrayList<TaskOutputComponent>(); 3452 return this.output; 3453 } 3454 3455 /** 3456 * @return Returns a reference to <code>this</code> for easy method chaining 3457 */ 3458 public Task setOutput(List<TaskOutputComponent> theOutput) { 3459 this.output = theOutput; 3460 return this; 3461 } 3462 3463 public boolean hasOutput() { 3464 if (this.output == null) 3465 return false; 3466 for (TaskOutputComponent item : this.output) 3467 if (!item.isEmpty()) 3468 return true; 3469 return false; 3470 } 3471 3472 public TaskOutputComponent addOutput() { //3 3473 TaskOutputComponent t = new TaskOutputComponent(); 3474 if (this.output == null) 3475 this.output = new ArrayList<TaskOutputComponent>(); 3476 this.output.add(t); 3477 return t; 3478 } 3479 3480 public Task addOutput(TaskOutputComponent t) { //3 3481 if (t == null) 3482 return this; 3483 if (this.output == null) 3484 this.output = new ArrayList<TaskOutputComponent>(); 3485 this.output.add(t); 3486 return this; 3487 } 3488 3489 /** 3490 * @return The first repetition of repeating field {@link #output}, creating it if it does not already exist 3491 */ 3492 public TaskOutputComponent getOutputFirstRep() { 3493 if (getOutput().isEmpty()) { 3494 addOutput(); 3495 } 3496 return getOutput().get(0); 3497 } 3498 3499 protected void listChildren(List<Property> children) { 3500 super.listChildren(children); 3501 children.add(new Property("identifier", "Identifier", "The business identifier for this task.", 0, java.lang.Integer.MAX_VALUE, identifier)); 3502 children.add(new Property("instantiatesCanonical", "canonical(ActivityDefinition)", "The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.", 0, 1, instantiatesCanonical)); 3503 children.add(new Property("instantiatesUri", "uri", "The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.", 0, 1, instantiatesUri)); 3504 children.add(new Property("basedOn", "Reference(Any)", "BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a \"request\" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the \"request\" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient.", 0, java.lang.Integer.MAX_VALUE, basedOn)); 3505 children.add(new Property("groupIdentifier", "Identifier", "An identifier that links together multiple tasks and other requests that were created in the same context.", 0, 1, groupIdentifier)); 3506 children.add(new Property("partOf", "Reference(Task)", "Task that this particular task is part of.", 0, java.lang.Integer.MAX_VALUE, partOf)); 3507 children.add(new Property("status", "code", "The current status of the task.", 0, 1, status)); 3508 children.add(new Property("statusReason", "CodeableConcept", "An explanation as to why this task is held, failed, was refused, etc.", 0, 1, statusReason)); 3509 children.add(new Property("businessStatus", "CodeableConcept", "Contains business-specific nuances of the business state.", 0, 1, businessStatus)); 3510 children.add(new Property("intent", "code", "Indicates the \"level\" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc.", 0, 1, intent)); 3511 children.add(new Property("priority", "code", "Indicates how quickly the Task should be addressed with respect to other requests.", 0, 1, priority)); 3512 children.add(new Property("code", "CodeableConcept", "A name or code (or both) briefly describing what the task involves.", 0, 1, code)); 3513 children.add(new Property("description", "string", "A free-text description of what is to be performed.", 0, 1, description)); 3514 children.add(new Property("focus", "Reference(Any)", "The request being actioned or the resource being manipulated by this task.", 0, 1, focus)); 3515 children.add(new Property("for", "Reference(Any)", "The entity who benefits from the performance of the service specified in the task (e.g., the patient).", 0, 1, for_)); 3516 children.add(new Property("encounter", "Reference(Encounter)", "The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.", 0, 1, encounter)); 3517 children.add(new Property("executionPeriod", "Period", "Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end).", 0, 1, executionPeriod)); 3518 children.add(new Property("authoredOn", "dateTime", "The date and time this task was created.", 0, 1, authoredOn)); 3519 children.add(new Property("lastModified", "dateTime", "The date and time of last modification to this task.", 0, 1, lastModified)); 3520 children.add(new Property("requester", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson)", "The creator of the task.", 0, 1, requester)); 3521 children.add(new Property("performerType", "CodeableConcept", "The kind of participant that should perform the task.", 0, java.lang.Integer.MAX_VALUE, performerType)); 3522 children.add(new Property("owner", "Reference(Practitioner|PractitionerRole|Organization|CareTeam|HealthcareService|Patient|Device|RelatedPerson)", "Individual organization or Device currently responsible for task execution.", 0, 1, owner)); 3523 children.add(new Property("location", "Reference(Location)", "Principal physical location where the this task is performed.", 0, 1, location)); 3524 children.add(new Property("reasonCode", "CodeableConcept", "A description or code indicating why this task needs to be performed.", 0, 1, reasonCode)); 3525 children.add(new Property("reasonReference", "Reference(Any)", "A resource reference indicating why this task needs to be performed.", 0, 1, reasonReference)); 3526 children.add(new Property("insurance", "Reference(Coverage|ClaimResponse)", "Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task.", 0, java.lang.Integer.MAX_VALUE, insurance)); 3527 children.add(new Property("note", "Annotation", "Free-text information captured about the task as it progresses.", 0, java.lang.Integer.MAX_VALUE, note)); 3528 children.add(new Property("relevantHistory", "Reference(Provenance)", "Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task.", 0, java.lang.Integer.MAX_VALUE, relevantHistory)); 3529 children.add(new Property("restriction", "", "If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned.", 0, 1, restriction)); 3530 children.add(new Property("input", "", "Additional information that may be needed in the execution of the task.", 0, java.lang.Integer.MAX_VALUE, input)); 3531 children.add(new Property("output", "", "Outputs produced by the Task.", 0, java.lang.Integer.MAX_VALUE, output)); 3532 } 3533 3534 @Override 3535 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3536 switch (_hash) { 3537 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "The business identifier for this task.", 0, java.lang.Integer.MAX_VALUE, identifier); 3538 case 8911915: /*instantiatesCanonical*/ return new Property("instantiatesCanonical", "canonical(ActivityDefinition)", "The URL pointing to a *FHIR*-defined protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.", 0, 1, instantiatesCanonical); 3539 case -1926393373: /*instantiatesUri*/ return new Property("instantiatesUri", "uri", "The URL pointing to an *externally* maintained protocol, guideline, orderset or other definition that is adhered to in whole or in part by this Task.", 0, 1, instantiatesUri); 3540 case -332612366: /*basedOn*/ return new Property("basedOn", "Reference(Any)", "BasedOn refers to a higher-level authorization that triggered the creation of the task. It references a \"request\" resource such as a ServiceRequest, MedicationRequest, ServiceRequest, CarePlan, etc. which is distinct from the \"request\" resource the task is seeking to fulfill. This latter resource is referenced by FocusOn. For example, based on a ServiceRequest (= BasedOn), a task is created to fulfill a procedureRequest ( = FocusOn ) to collect a specimen from a patient.", 0, java.lang.Integer.MAX_VALUE, basedOn); 3541 case -445338488: /*groupIdentifier*/ return new Property("groupIdentifier", "Identifier", "An identifier that links together multiple tasks and other requests that were created in the same context.", 0, 1, groupIdentifier); 3542 case -995410646: /*partOf*/ return new Property("partOf", "Reference(Task)", "Task that this particular task is part of.", 0, java.lang.Integer.MAX_VALUE, partOf); 3543 case -892481550: /*status*/ return new Property("status", "code", "The current status of the task.", 0, 1, status); 3544 case 2051346646: /*statusReason*/ return new Property("statusReason", "CodeableConcept", "An explanation as to why this task is held, failed, was refused, etc.", 0, 1, statusReason); 3545 case 2008591314: /*businessStatus*/ return new Property("businessStatus", "CodeableConcept", "Contains business-specific nuances of the business state.", 0, 1, businessStatus); 3546 case -1183762788: /*intent*/ return new Property("intent", "code", "Indicates the \"level\" of actionability associated with the Task, i.e. i+R[9]Cs this a proposed task, a planned task, an actionable task, etc.", 0, 1, intent); 3547 case -1165461084: /*priority*/ return new Property("priority", "code", "Indicates how quickly the Task should be addressed with respect to other requests.", 0, 1, priority); 3548 case 3059181: /*code*/ return new Property("code", "CodeableConcept", "A name or code (or both) briefly describing what the task involves.", 0, 1, code); 3549 case -1724546052: /*description*/ return new Property("description", "string", "A free-text description of what is to be performed.", 0, 1, description); 3550 case 97604824: /*focus*/ return new Property("focus", "Reference(Any)", "The request being actioned or the resource being manipulated by this task.", 0, 1, focus); 3551 case 101577: /*for*/ return new Property("for", "Reference(Any)", "The entity who benefits from the performance of the service specified in the task (e.g., the patient).", 0, 1, for_); 3552 case 1524132147: /*encounter*/ return new Property("encounter", "Reference(Encounter)", "The healthcare event (e.g. a patient and healthcare provider interaction) during which this task was created.", 0, 1, encounter); 3553 case 1218624249: /*executionPeriod*/ return new Property("executionPeriod", "Period", "Identifies the time action was first taken against the task (start) and/or the time final action was taken against the task prior to marking it as completed (end).", 0, 1, executionPeriod); 3554 case -1500852503: /*authoredOn*/ return new Property("authoredOn", "dateTime", "The date and time this task was created.", 0, 1, authoredOn); 3555 case 1959003007: /*lastModified*/ return new Property("lastModified", "dateTime", "The date and time of last modification to this task.", 0, 1, lastModified); 3556 case 693933948: /*requester*/ return new Property("requester", "Reference(Device|Organization|Patient|Practitioner|PractitionerRole|RelatedPerson)", "The creator of the task.", 0, 1, requester); 3557 case -901444568: /*performerType*/ return new Property("performerType", "CodeableConcept", "The kind of participant that should perform the task.", 0, java.lang.Integer.MAX_VALUE, performerType); 3558 case 106164915: /*owner*/ return new Property("owner", "Reference(Practitioner|PractitionerRole|Organization|CareTeam|HealthcareService|Patient|Device|RelatedPerson)", "Individual organization or Device currently responsible for task execution.", 0, 1, owner); 3559 case 1901043637: /*location*/ return new Property("location", "Reference(Location)", "Principal physical location where the this task is performed.", 0, 1, location); 3560 case 722137681: /*reasonCode*/ return new Property("reasonCode", "CodeableConcept", "A description or code indicating why this task needs to be performed.", 0, 1, reasonCode); 3561 case -1146218137: /*reasonReference*/ return new Property("reasonReference", "Reference(Any)", "A resource reference indicating why this task needs to be performed.", 0, 1, reasonReference); 3562 case 73049818: /*insurance*/ return new Property("insurance", "Reference(Coverage|ClaimResponse)", "Insurance plans, coverage extensions, pre-authorizations and/or pre-determinations that may be relevant to the Task.", 0, java.lang.Integer.MAX_VALUE, insurance); 3563 case 3387378: /*note*/ return new Property("note", "Annotation", "Free-text information captured about the task as it progresses.", 0, java.lang.Integer.MAX_VALUE, note); 3564 case 1538891575: /*relevantHistory*/ return new Property("relevantHistory", "Reference(Provenance)", "Links to Provenance records for past versions of this Task that identify key state transitions or updates that are likely to be relevant to a user looking at the current version of the task.", 0, java.lang.Integer.MAX_VALUE, relevantHistory); 3565 case -1561062452: /*restriction*/ return new Property("restriction", "", "If the Task.focus is a request resource and the task is seeking fulfillment (i.e. is asking for the request to be actioned), this element identifies any limitations on what parts of the referenced request should be actioned.", 0, 1, restriction); 3566 case 100358090: /*input*/ return new Property("input", "", "Additional information that may be needed in the execution of the task.", 0, java.lang.Integer.MAX_VALUE, input); 3567 case -1005512447: /*output*/ return new Property("output", "", "Outputs produced by the Task.", 0, java.lang.Integer.MAX_VALUE, output); 3568 default: return super.getNamedProperty(_hash, _name, _checkValid); 3569 } 3570 3571 } 3572 3573 @Override 3574 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3575 switch (hash) { 3576 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 3577 case 8911915: /*instantiatesCanonical*/ return this.instantiatesCanonical == null ? new Base[0] : new Base[] {this.instantiatesCanonical}; // CanonicalType 3578 case -1926393373: /*instantiatesUri*/ return this.instantiatesUri == null ? new Base[0] : new Base[] {this.instantiatesUri}; // UriType 3579 case -332612366: /*basedOn*/ return this.basedOn == null ? new Base[0] : this.basedOn.toArray(new Base[this.basedOn.size()]); // Reference 3580 case -445338488: /*groupIdentifier*/ return this.groupIdentifier == null ? new Base[0] : new Base[] {this.groupIdentifier}; // Identifier 3581 case -995410646: /*partOf*/ return this.partOf == null ? new Base[0] : this.partOf.toArray(new Base[this.partOf.size()]); // Reference 3582 case -892481550: /*status*/ return this.status == null ? new Base[0] : new Base[] {this.status}; // Enumeration<TaskStatus> 3583 case 2051346646: /*statusReason*/ return this.statusReason == null ? new Base[0] : new Base[] {this.statusReason}; // CodeableConcept 3584 case 2008591314: /*businessStatus*/ return this.businessStatus == null ? new Base[0] : new Base[] {this.businessStatus}; // CodeableConcept 3585 case -1183762788: /*intent*/ return this.intent == null ? new Base[0] : new Base[] {this.intent}; // Enumeration<TaskIntent> 3586 case -1165461084: /*priority*/ return this.priority == null ? new Base[0] : new Base[] {this.priority}; // Enumeration<TaskPriority> 3587 case 3059181: /*code*/ return this.code == null ? new Base[0] : new Base[] {this.code}; // CodeableConcept 3588 case -1724546052: /*description*/ return this.description == null ? new Base[0] : new Base[] {this.description}; // StringType 3589 case 97604824: /*focus*/ return this.focus == null ? new Base[0] : new Base[] {this.focus}; // Reference 3590 case 101577: /*for*/ return this.for_ == null ? new Base[0] : new Base[] {this.for_}; // Reference 3591 case 1524132147: /*encounter*/ return this.encounter == null ? new Base[0] : new Base[] {this.encounter}; // Reference 3592 case 1218624249: /*executionPeriod*/ return this.executionPeriod == null ? new Base[0] : new Base[] {this.executionPeriod}; // Period 3593 case -1500852503: /*authoredOn*/ return this.authoredOn == null ? new Base[0] : new Base[] {this.authoredOn}; // DateTimeType 3594 case 1959003007: /*lastModified*/ return this.lastModified == null ? new Base[0] : new Base[] {this.lastModified}; // DateTimeType 3595 case 693933948: /*requester*/ return this.requester == null ? new Base[0] : new Base[] {this.requester}; // Reference 3596 case -901444568: /*performerType*/ return this.performerType == null ? new Base[0] : this.performerType.toArray(new Base[this.performerType.size()]); // CodeableConcept 3597 case 106164915: /*owner*/ return this.owner == null ? new Base[0] : new Base[] {this.owner}; // Reference 3598 case 1901043637: /*location*/ return this.location == null ? new Base[0] : new Base[] {this.location}; // Reference 3599 case 722137681: /*reasonCode*/ return this.reasonCode == null ? new Base[0] : new Base[] {this.reasonCode}; // CodeableConcept 3600 case -1146218137: /*reasonReference*/ return this.reasonReference == null ? new Base[0] : new Base[] {this.reasonReference}; // Reference 3601 case 73049818: /*insurance*/ return this.insurance == null ? new Base[0] : this.insurance.toArray(new Base[this.insurance.size()]); // Reference 3602 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 3603 case 1538891575: /*relevantHistory*/ return this.relevantHistory == null ? new Base[0] : this.relevantHistory.toArray(new Base[this.relevantHistory.size()]); // Reference 3604 case -1561062452: /*restriction*/ return this.restriction == null ? new Base[0] : new Base[] {this.restriction}; // TaskRestrictionComponent 3605 case 100358090: /*input*/ return this.input == null ? new Base[0] : this.input.toArray(new Base[this.input.size()]); // ParameterComponent 3606 case -1005512447: /*output*/ return this.output == null ? new Base[0] : this.output.toArray(new Base[this.output.size()]); // TaskOutputComponent 3607 default: return super.getProperty(hash, name, checkValid); 3608 } 3609 3610 } 3611 3612 @Override 3613 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3614 switch (hash) { 3615 case -1618432855: // identifier 3616 this.getIdentifier().add(castToIdentifier(value)); // Identifier 3617 return value; 3618 case 8911915: // instantiatesCanonical 3619 this.instantiatesCanonical = castToCanonical(value); // CanonicalType 3620 return value; 3621 case -1926393373: // instantiatesUri 3622 this.instantiatesUri = castToUri(value); // UriType 3623 return value; 3624 case -332612366: // basedOn 3625 this.getBasedOn().add(castToReference(value)); // Reference 3626 return value; 3627 case -445338488: // groupIdentifier 3628 this.groupIdentifier = castToIdentifier(value); // Identifier 3629 return value; 3630 case -995410646: // partOf 3631 this.getPartOf().add(castToReference(value)); // Reference 3632 return value; 3633 case -892481550: // status 3634 value = new TaskStatusEnumFactory().fromType(castToCode(value)); 3635 this.status = (Enumeration) value; // Enumeration<TaskStatus> 3636 return value; 3637 case 2051346646: // statusReason 3638 this.statusReason = castToCodeableConcept(value); // CodeableConcept 3639 return value; 3640 case 2008591314: // businessStatus 3641 this.businessStatus = castToCodeableConcept(value); // CodeableConcept 3642 return value; 3643 case -1183762788: // intent 3644 value = new TaskIntentEnumFactory().fromType(castToCode(value)); 3645 this.intent = (Enumeration) value; // Enumeration<TaskIntent> 3646 return value; 3647 case -1165461084: // priority 3648 value = new TaskPriorityEnumFactory().fromType(castToCode(value)); 3649 this.priority = (Enumeration) value; // Enumeration<TaskPriority> 3650 return value; 3651 case 3059181: // code 3652 this.code = castToCodeableConcept(value); // CodeableConcept 3653 return value; 3654 case -1724546052: // description 3655 this.description = castToString(value); // StringType 3656 return value; 3657 case 97604824: // focus 3658 this.focus = castToReference(value); // Reference 3659 return value; 3660 case 101577: // for 3661 this.for_ = castToReference(value); // Reference 3662 return value; 3663 case 1524132147: // encounter 3664 this.encounter = castToReference(value); // Reference 3665 return value; 3666 case 1218624249: // executionPeriod 3667 this.executionPeriod = castToPeriod(value); // Period 3668 return value; 3669 case -1500852503: // authoredOn 3670 this.authoredOn = castToDateTime(value); // DateTimeType 3671 return value; 3672 case 1959003007: // lastModified 3673 this.lastModified = castToDateTime(value); // DateTimeType 3674 return value; 3675 case 693933948: // requester 3676 this.requester = castToReference(value); // Reference 3677 return value; 3678 case -901444568: // performerType 3679 this.getPerformerType().add(castToCodeableConcept(value)); // CodeableConcept 3680 return value; 3681 case 106164915: // owner 3682 this.owner = castToReference(value); // Reference 3683 return value; 3684 case 1901043637: // location 3685 this.location = castToReference(value); // Reference 3686 return value; 3687 case 722137681: // reasonCode 3688 this.reasonCode = castToCodeableConcept(value); // CodeableConcept 3689 return value; 3690 case -1146218137: // reasonReference 3691 this.reasonReference = castToReference(value); // Reference 3692 return value; 3693 case 73049818: // insurance 3694 this.getInsurance().add(castToReference(value)); // Reference 3695 return value; 3696 case 3387378: // note 3697 this.getNote().add(castToAnnotation(value)); // Annotation 3698 return value; 3699 case 1538891575: // relevantHistory 3700 this.getRelevantHistory().add(castToReference(value)); // Reference 3701 return value; 3702 case -1561062452: // restriction 3703 this.restriction = (TaskRestrictionComponent) value; // TaskRestrictionComponent 3704 return value; 3705 case 100358090: // input 3706 this.getInput().add((ParameterComponent) value); // ParameterComponent 3707 return value; 3708 case -1005512447: // output 3709 this.getOutput().add((TaskOutputComponent) value); // TaskOutputComponent 3710 return value; 3711 default: return super.setProperty(hash, name, value); 3712 } 3713 3714 } 3715 3716 @Override 3717 public Base setProperty(String name, Base value) throws FHIRException { 3718 if (name.equals("identifier")) { 3719 this.getIdentifier().add(castToIdentifier(value)); 3720 } else if (name.equals("instantiatesCanonical")) { 3721 this.instantiatesCanonical = castToCanonical(value); // CanonicalType 3722 } else if (name.equals("instantiatesUri")) { 3723 this.instantiatesUri = castToUri(value); // UriType 3724 } else if (name.equals("basedOn")) { 3725 this.getBasedOn().add(castToReference(value)); 3726 } else if (name.equals("groupIdentifier")) { 3727 this.groupIdentifier = castToIdentifier(value); // Identifier 3728 } else if (name.equals("partOf")) { 3729 this.getPartOf().add(castToReference(value)); 3730 } else if (name.equals("status")) { 3731 value = new TaskStatusEnumFactory().fromType(castToCode(value)); 3732 this.status = (Enumeration) value; // Enumeration<TaskStatus> 3733 } else if (name.equals("statusReason")) { 3734 this.statusReason = castToCodeableConcept(value); // CodeableConcept 3735 } else if (name.equals("businessStatus")) { 3736 this.businessStatus = castToCodeableConcept(value); // CodeableConcept 3737 } else if (name.equals("intent")) { 3738 value = new TaskIntentEnumFactory().fromType(castToCode(value)); 3739 this.intent = (Enumeration) value; // Enumeration<TaskIntent> 3740 } else if (name.equals("priority")) { 3741 value = new TaskPriorityEnumFactory().fromType(castToCode(value)); 3742 this.priority = (Enumeration) value; // Enumeration<TaskPriority> 3743 } else if (name.equals("code")) { 3744 this.code = castToCodeableConcept(value); // CodeableConcept 3745 } else if (name.equals("description")) { 3746 this.description = castToString(value); // StringType 3747 } else if (name.equals("focus")) { 3748 this.focus = castToReference(value); // Reference 3749 } else if (name.equals("for")) { 3750 this.for_ = castToReference(value); // Reference 3751 } else if (name.equals("encounter")) { 3752 this.encounter = castToReference(value); // Reference 3753 } else if (name.equals("executionPeriod")) { 3754 this.executionPeriod = castToPeriod(value); // Period 3755 } else if (name.equals("authoredOn")) { 3756 this.authoredOn = castToDateTime(value); // DateTimeType 3757 } else if (name.equals("lastModified")) { 3758 this.lastModified = castToDateTime(value); // DateTimeType 3759 } else if (name.equals("requester")) { 3760 this.requester = castToReference(value); // Reference 3761 } else if (name.equals("performerType")) { 3762 this.getPerformerType().add(castToCodeableConcept(value)); 3763 } else if (name.equals("owner")) { 3764 this.owner = castToReference(value); // Reference 3765 } else if (name.equals("location")) { 3766 this.location = castToReference(value); // Reference 3767 } else if (name.equals("reasonCode")) { 3768 this.reasonCode = castToCodeableConcept(value); // CodeableConcept 3769 } else if (name.equals("reasonReference")) { 3770 this.reasonReference = castToReference(value); // Reference 3771 } else if (name.equals("insurance")) { 3772 this.getInsurance().add(castToReference(value)); 3773 } else if (name.equals("note")) { 3774 this.getNote().add(castToAnnotation(value)); 3775 } else if (name.equals("relevantHistory")) { 3776 this.getRelevantHistory().add(castToReference(value)); 3777 } else if (name.equals("restriction")) { 3778 this.restriction = (TaskRestrictionComponent) value; // TaskRestrictionComponent 3779 } else if (name.equals("input")) { 3780 this.getInput().add((ParameterComponent) value); 3781 } else if (name.equals("output")) { 3782 this.getOutput().add((TaskOutputComponent) value); 3783 } else 3784 return super.setProperty(name, value); 3785 return value; 3786 } 3787 3788 @Override 3789 public Base makeProperty(int hash, String name) throws FHIRException { 3790 switch (hash) { 3791 case -1618432855: return addIdentifier(); 3792 case 8911915: return getInstantiatesCanonicalElement(); 3793 case -1926393373: return getInstantiatesUriElement(); 3794 case -332612366: return addBasedOn(); 3795 case -445338488: return getGroupIdentifier(); 3796 case -995410646: return addPartOf(); 3797 case -892481550: return getStatusElement(); 3798 case 2051346646: return getStatusReason(); 3799 case 2008591314: return getBusinessStatus(); 3800 case -1183762788: return getIntentElement(); 3801 case -1165461084: return getPriorityElement(); 3802 case 3059181: return getCode(); 3803 case -1724546052: return getDescriptionElement(); 3804 case 97604824: return getFocus(); 3805 case 101577: return getFor(); 3806 case 1524132147: return getEncounter(); 3807 case 1218624249: return getExecutionPeriod(); 3808 case -1500852503: return getAuthoredOnElement(); 3809 case 1959003007: return getLastModifiedElement(); 3810 case 693933948: return getRequester(); 3811 case -901444568: return addPerformerType(); 3812 case 106164915: return getOwner(); 3813 case 1901043637: return getLocation(); 3814 case 722137681: return getReasonCode(); 3815 case -1146218137: return getReasonReference(); 3816 case 73049818: return addInsurance(); 3817 case 3387378: return addNote(); 3818 case 1538891575: return addRelevantHistory(); 3819 case -1561062452: return getRestriction(); 3820 case 100358090: return addInput(); 3821 case -1005512447: return addOutput(); 3822 default: return super.makeProperty(hash, name); 3823 } 3824 3825 } 3826 3827 @Override 3828 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3829 switch (hash) { 3830 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 3831 case 8911915: /*instantiatesCanonical*/ return new String[] {"canonical"}; 3832 case -1926393373: /*instantiatesUri*/ return new String[] {"uri"}; 3833 case -332612366: /*basedOn*/ return new String[] {"Reference"}; 3834 case -445338488: /*groupIdentifier*/ return new String[] {"Identifier"}; 3835 case -995410646: /*partOf*/ return new String[] {"Reference"}; 3836 case -892481550: /*status*/ return new String[] {"code"}; 3837 case 2051346646: /*statusReason*/ return new String[] {"CodeableConcept"}; 3838 case 2008591314: /*businessStatus*/ return new String[] {"CodeableConcept"}; 3839 case -1183762788: /*intent*/ return new String[] {"code"}; 3840 case -1165461084: /*priority*/ return new String[] {"code"}; 3841 case 3059181: /*code*/ return new String[] {"CodeableConcept"}; 3842 case -1724546052: /*description*/ return new String[] {"string"}; 3843 case 97604824: /*focus*/ return new String[] {"Reference"}; 3844 case 101577: /*for*/ return new String[] {"Reference"}; 3845 case 1524132147: /*encounter*/ return new String[] {"Reference"}; 3846 case 1218624249: /*executionPeriod*/ return new String[] {"Period"}; 3847 case -1500852503: /*authoredOn*/ return new String[] {"dateTime"}; 3848 case 1959003007: /*lastModified*/ return new String[] {"dateTime"}; 3849 case 693933948: /*requester*/ return new String[] {"Reference"}; 3850 case -901444568: /*performerType*/ return new String[] {"CodeableConcept"}; 3851 case 106164915: /*owner*/ return new String[] {"Reference"}; 3852 case 1901043637: /*location*/ return new String[] {"Reference"}; 3853 case 722137681: /*reasonCode*/ return new String[] {"CodeableConcept"}; 3854 case -1146218137: /*reasonReference*/ return new String[] {"Reference"}; 3855 case 73049818: /*insurance*/ return new String[] {"Reference"}; 3856 case 3387378: /*note*/ return new String[] {"Annotation"}; 3857 case 1538891575: /*relevantHistory*/ return new String[] {"Reference"}; 3858 case -1561062452: /*restriction*/ return new String[] {}; 3859 case 100358090: /*input*/ return new String[] {}; 3860 case -1005512447: /*output*/ return new String[] {}; 3861 default: return super.getTypesForProperty(hash, name); 3862 } 3863 3864 } 3865 3866 @Override 3867 public Base addChild(String name) throws FHIRException { 3868 if (name.equals("identifier")) { 3869 return addIdentifier(); 3870 } 3871 else if (name.equals("instantiatesCanonical")) { 3872 throw new FHIRException("Cannot call addChild on a primitive type Task.instantiatesCanonical"); 3873 } 3874 else if (name.equals("instantiatesUri")) { 3875 throw new FHIRException("Cannot call addChild on a primitive type Task.instantiatesUri"); 3876 } 3877 else if (name.equals("basedOn")) { 3878 return addBasedOn(); 3879 } 3880 else if (name.equals("groupIdentifier")) { 3881 this.groupIdentifier = new Identifier(); 3882 return this.groupIdentifier; 3883 } 3884 else if (name.equals("partOf")) { 3885 return addPartOf(); 3886 } 3887 else if (name.equals("status")) { 3888 throw new FHIRException("Cannot call addChild on a primitive type Task.status"); 3889 } 3890 else if (name.equals("statusReason")) { 3891 this.statusReason = new CodeableConcept(); 3892 return this.statusReason; 3893 } 3894 else if (name.equals("businessStatus")) { 3895 this.businessStatus = new CodeableConcept(); 3896 return this.businessStatus; 3897 } 3898 else if (name.equals("intent")) { 3899 throw new FHIRException("Cannot call addChild on a primitive type Task.intent"); 3900 } 3901 else if (name.equals("priority")) { 3902 throw new FHIRException("Cannot call addChild on a primitive type Task.priority"); 3903 } 3904 else if (name.equals("code")) { 3905 this.code = new CodeableConcept(); 3906 return this.code; 3907 } 3908 else if (name.equals("description")) { 3909 throw new FHIRException("Cannot call addChild on a primitive type Task.description"); 3910 } 3911 else if (name.equals("focus")) { 3912 this.focus = new Reference(); 3913 return this.focus; 3914 } 3915 else if (name.equals("for")) { 3916 this.for_ = new Reference(); 3917 return this.for_; 3918 } 3919 else if (name.equals("encounter")) { 3920 this.encounter = new Reference(); 3921 return this.encounter; 3922 } 3923 else if (name.equals("executionPeriod")) { 3924 this.executionPeriod = new Period(); 3925 return this.executionPeriod; 3926 } 3927 else if (name.equals("authoredOn")) { 3928 throw new FHIRException("Cannot call addChild on a primitive type Task.authoredOn"); 3929 } 3930 else if (name.equals("lastModified")) { 3931 throw new FHIRException("Cannot call addChild on a primitive type Task.lastModified"); 3932 } 3933 else if (name.equals("requester")) { 3934 this.requester = new Reference(); 3935 return this.requester; 3936 } 3937 else if (name.equals("performerType")) { 3938 return addPerformerType(); 3939 } 3940 else if (name.equals("owner")) { 3941 this.owner = new Reference(); 3942 return this.owner; 3943 } 3944 else if (name.equals("location")) { 3945 this.location = new Reference(); 3946 return this.location; 3947 } 3948 else if (name.equals("reasonCode")) { 3949 this.reasonCode = new CodeableConcept(); 3950 return this.reasonCode; 3951 } 3952 else if (name.equals("reasonReference")) { 3953 this.reasonReference = new Reference(); 3954 return this.reasonReference; 3955 } 3956 else if (name.equals("insurance")) { 3957 return addInsurance(); 3958 } 3959 else if (name.equals("note")) { 3960 return addNote(); 3961 } 3962 else if (name.equals("relevantHistory")) { 3963 return addRelevantHistory(); 3964 } 3965 else if (name.equals("restriction")) { 3966 this.restriction = new TaskRestrictionComponent(); 3967 return this.restriction; 3968 } 3969 else if (name.equals("input")) { 3970 return addInput(); 3971 } 3972 else if (name.equals("output")) { 3973 return addOutput(); 3974 } 3975 else 3976 return super.addChild(name); 3977 } 3978 3979 public String fhirType() { 3980 return "Task"; 3981 3982 } 3983 3984 public Task copy() { 3985 Task dst = new Task(); 3986 copyValues(dst); 3987 return dst; 3988 } 3989 3990 public void copyValues(Task dst) { 3991 super.copyValues(dst); 3992 if (identifier != null) { 3993 dst.identifier = new ArrayList<Identifier>(); 3994 for (Identifier i : identifier) 3995 dst.identifier.add(i.copy()); 3996 }; 3997 dst.instantiatesCanonical = instantiatesCanonical == null ? null : instantiatesCanonical.copy(); 3998 dst.instantiatesUri = instantiatesUri == null ? null : instantiatesUri.copy(); 3999 if (basedOn != null) { 4000 dst.basedOn = new ArrayList<Reference>(); 4001 for (Reference i : basedOn) 4002 dst.basedOn.add(i.copy()); 4003 }; 4004 dst.groupIdentifier = groupIdentifier == null ? null : groupIdentifier.copy(); 4005 if (partOf != null) { 4006 dst.partOf = new ArrayList<Reference>(); 4007 for (Reference i : partOf) 4008 dst.partOf.add(i.copy()); 4009 }; 4010 dst.status = status == null ? null : status.copy(); 4011 dst.statusReason = statusReason == null ? null : statusReason.copy(); 4012 dst.businessStatus = businessStatus == null ? null : businessStatus.copy(); 4013 dst.intent = intent == null ? null : intent.copy(); 4014 dst.priority = priority == null ? null : priority.copy(); 4015 dst.code = code == null ? null : code.copy(); 4016 dst.description = description == null ? null : description.copy(); 4017 dst.focus = focus == null ? null : focus.copy(); 4018 dst.for_ = for_ == null ? null : for_.copy(); 4019 dst.encounter = encounter == null ? null : encounter.copy(); 4020 dst.executionPeriod = executionPeriod == null ? null : executionPeriod.copy(); 4021 dst.authoredOn = authoredOn == null ? null : authoredOn.copy(); 4022 dst.lastModified = lastModified == null ? null : lastModified.copy(); 4023 dst.requester = requester == null ? null : requester.copy(); 4024 if (performerType != null) { 4025 dst.performerType = new ArrayList<CodeableConcept>(); 4026 for (CodeableConcept i : performerType) 4027 dst.performerType.add(i.copy()); 4028 }; 4029 dst.owner = owner == null ? null : owner.copy(); 4030 dst.location = location == null ? null : location.copy(); 4031 dst.reasonCode = reasonCode == null ? null : reasonCode.copy(); 4032 dst.reasonReference = reasonReference == null ? null : reasonReference.copy(); 4033 if (insurance != null) { 4034 dst.insurance = new ArrayList<Reference>(); 4035 for (Reference i : insurance) 4036 dst.insurance.add(i.copy()); 4037 }; 4038 if (note != null) { 4039 dst.note = new ArrayList<Annotation>(); 4040 for (Annotation i : note) 4041 dst.note.add(i.copy()); 4042 }; 4043 if (relevantHistory != null) { 4044 dst.relevantHistory = new ArrayList<Reference>(); 4045 for (Reference i : relevantHistory) 4046 dst.relevantHistory.add(i.copy()); 4047 }; 4048 dst.restriction = restriction == null ? null : restriction.copy(); 4049 if (input != null) { 4050 dst.input = new ArrayList<ParameterComponent>(); 4051 for (ParameterComponent i : input) 4052 dst.input.add(i.copy()); 4053 }; 4054 if (output != null) { 4055 dst.output = new ArrayList<TaskOutputComponent>(); 4056 for (TaskOutputComponent i : output) 4057 dst.output.add(i.copy()); 4058 }; 4059 } 4060 4061 protected Task typedCopy() { 4062 return copy(); 4063 } 4064 4065 @Override 4066 public boolean equalsDeep(Base other_) { 4067 if (!super.equalsDeep(other_)) 4068 return false; 4069 if (!(other_ instanceof Task)) 4070 return false; 4071 Task o = (Task) other_; 4072 return compareDeep(identifier, o.identifier, true) && compareDeep(instantiatesCanonical, o.instantiatesCanonical, true) 4073 && compareDeep(instantiatesUri, o.instantiatesUri, true) && compareDeep(basedOn, o.basedOn, true) 4074 && compareDeep(groupIdentifier, o.groupIdentifier, true) && compareDeep(partOf, o.partOf, true) 4075 && compareDeep(status, o.status, true) && compareDeep(statusReason, o.statusReason, true) && compareDeep(businessStatus, o.businessStatus, true) 4076 && compareDeep(intent, o.intent, true) && compareDeep(priority, o.priority, true) && compareDeep(code, o.code, true) 4077 && compareDeep(description, o.description, true) && compareDeep(focus, o.focus, true) && compareDeep(for_, o.for_, true) 4078 && compareDeep(encounter, o.encounter, true) && compareDeep(executionPeriod, o.executionPeriod, true) 4079 && compareDeep(authoredOn, o.authoredOn, true) && compareDeep(lastModified, o.lastModified, true) 4080 && compareDeep(requester, o.requester, true) && compareDeep(performerType, o.performerType, true) 4081 && compareDeep(owner, o.owner, true) && compareDeep(location, o.location, true) && compareDeep(reasonCode, o.reasonCode, true) 4082 && compareDeep(reasonReference, o.reasonReference, true) && compareDeep(insurance, o.insurance, true) 4083 && compareDeep(note, o.note, true) && compareDeep(relevantHistory, o.relevantHistory, true) && compareDeep(restriction, o.restriction, true) 4084 && compareDeep(input, o.input, true) && compareDeep(output, o.output, true); 4085 } 4086 4087 @Override 4088 public boolean equalsShallow(Base other_) { 4089 if (!super.equalsShallow(other_)) 4090 return false; 4091 if (!(other_ instanceof Task)) 4092 return false; 4093 Task o = (Task) other_; 4094 return compareValues(instantiatesUri, o.instantiatesUri, true) && compareValues(status, o.status, true) 4095 && compareValues(intent, o.intent, true) && compareValues(priority, o.priority, true) && compareValues(description, o.description, true) 4096 && compareValues(authoredOn, o.authoredOn, true) && compareValues(lastModified, o.lastModified, true) 4097 ; 4098 } 4099 4100 public boolean isEmpty() { 4101 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, instantiatesCanonical 4102 , instantiatesUri, basedOn, groupIdentifier, partOf, status, statusReason, businessStatus 4103 , intent, priority, code, description, focus, for_, encounter, executionPeriod 4104 , authoredOn, lastModified, requester, performerType, owner, location, reasonCode 4105 , reasonReference, insurance, note, relevantHistory, restriction, input, output 4106 ); 4107 } 4108 4109 @Override 4110 public ResourceType getResourceType() { 4111 return ResourceType.Task; 4112 } 4113 4114 /** 4115 * Search parameter: <b>owner</b> 4116 * <p> 4117 * Description: <b>Search by task owner</b><br> 4118 * Type: <b>reference</b><br> 4119 * Path: <b>Task.owner</b><br> 4120 * </p> 4121 */ 4122 @SearchParamDefinition(name="owner", path="Task.owner", description="Search by task owner", type="reference", target={CareTeam.class, Device.class, HealthcareService.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 4123 public static final String SP_OWNER = "owner"; 4124 /** 4125 * <b>Fluent Client</b> search parameter constant for <b>owner</b> 4126 * <p> 4127 * Description: <b>Search by task owner</b><br> 4128 * Type: <b>reference</b><br> 4129 * Path: <b>Task.owner</b><br> 4130 * </p> 4131 */ 4132 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam OWNER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_OWNER); 4133 4134/** 4135 * Constant for fluent queries to be used to add include statements. Specifies 4136 * the path value of "<b>Task:owner</b>". 4137 */ 4138 public static final ca.uhn.fhir.model.api.Include INCLUDE_OWNER = new ca.uhn.fhir.model.api.Include("Task:owner").toLocked(); 4139 4140 /** 4141 * Search parameter: <b>requester</b> 4142 * <p> 4143 * Description: <b>Search by task requester</b><br> 4144 * Type: <b>reference</b><br> 4145 * Path: <b>Task.requester</b><br> 4146 * </p> 4147 */ 4148 @SearchParamDefinition(name="requester", path="Task.requester", description="Search by task requester", type="reference", target={Device.class, Organization.class, Patient.class, Practitioner.class, PractitionerRole.class, RelatedPerson.class } ) 4149 public static final String SP_REQUESTER = "requester"; 4150 /** 4151 * <b>Fluent Client</b> search parameter constant for <b>requester</b> 4152 * <p> 4153 * Description: <b>Search by task requester</b><br> 4154 * Type: <b>reference</b><br> 4155 * Path: <b>Task.requester</b><br> 4156 * </p> 4157 */ 4158 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam REQUESTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_REQUESTER); 4159 4160/** 4161 * Constant for fluent queries to be used to add include statements. Specifies 4162 * the path value of "<b>Task:requester</b>". 4163 */ 4164 public static final ca.uhn.fhir.model.api.Include INCLUDE_REQUESTER = new ca.uhn.fhir.model.api.Include("Task:requester").toLocked(); 4165 4166 /** 4167 * Search parameter: <b>identifier</b> 4168 * <p> 4169 * Description: <b>Search for a task instance by its business identifier</b><br> 4170 * Type: <b>token</b><br> 4171 * Path: <b>Task.identifier</b><br> 4172 * </p> 4173 */ 4174 @SearchParamDefinition(name="identifier", path="Task.identifier", description="Search for a task instance by its business identifier", type="token" ) 4175 public static final String SP_IDENTIFIER = "identifier"; 4176 /** 4177 * <b>Fluent Client</b> search parameter constant for <b>identifier</b> 4178 * <p> 4179 * Description: <b>Search for a task instance by its business identifier</b><br> 4180 * Type: <b>token</b><br> 4181 * Path: <b>Task.identifier</b><br> 4182 * </p> 4183 */ 4184 public static final ca.uhn.fhir.rest.gclient.TokenClientParam IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_IDENTIFIER); 4185 4186 /** 4187 * Search parameter: <b>business-status</b> 4188 * <p> 4189 * Description: <b>Search by business status</b><br> 4190 * Type: <b>token</b><br> 4191 * Path: <b>Task.businessStatus</b><br> 4192 * </p> 4193 */ 4194 @SearchParamDefinition(name="business-status", path="Task.businessStatus", description="Search by business status", type="token" ) 4195 public static final String SP_BUSINESS_STATUS = "business-status"; 4196 /** 4197 * <b>Fluent Client</b> search parameter constant for <b>business-status</b> 4198 * <p> 4199 * Description: <b>Search by business status</b><br> 4200 * Type: <b>token</b><br> 4201 * Path: <b>Task.businessStatus</b><br> 4202 * </p> 4203 */ 4204 public static final ca.uhn.fhir.rest.gclient.TokenClientParam BUSINESS_STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_BUSINESS_STATUS); 4205 4206 /** 4207 * Search parameter: <b>period</b> 4208 * <p> 4209 * Description: <b>Search by period Task is/was underway</b><br> 4210 * Type: <b>date</b><br> 4211 * Path: <b>Task.executionPeriod</b><br> 4212 * </p> 4213 */ 4214 @SearchParamDefinition(name="period", path="Task.executionPeriod", description="Search by period Task is/was underway", type="date" ) 4215 public static final String SP_PERIOD = "period"; 4216 /** 4217 * <b>Fluent Client</b> search parameter constant for <b>period</b> 4218 * <p> 4219 * Description: <b>Search by period Task is/was underway</b><br> 4220 * Type: <b>date</b><br> 4221 * Path: <b>Task.executionPeriod</b><br> 4222 * </p> 4223 */ 4224 public static final ca.uhn.fhir.rest.gclient.DateClientParam PERIOD = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_PERIOD); 4225 4226 /** 4227 * Search parameter: <b>code</b> 4228 * <p> 4229 * Description: <b>Search by task code</b><br> 4230 * Type: <b>token</b><br> 4231 * Path: <b>Task.code</b><br> 4232 * </p> 4233 */ 4234 @SearchParamDefinition(name="code", path="Task.code", description="Search by task code", type="token" ) 4235 public static final String SP_CODE = "code"; 4236 /** 4237 * <b>Fluent Client</b> search parameter constant for <b>code</b> 4238 * <p> 4239 * Description: <b>Search by task code</b><br> 4240 * Type: <b>token</b><br> 4241 * Path: <b>Task.code</b><br> 4242 * </p> 4243 */ 4244 public static final ca.uhn.fhir.rest.gclient.TokenClientParam CODE = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_CODE); 4245 4246 /** 4247 * Search parameter: <b>performer</b> 4248 * <p> 4249 * Description: <b>Search by recommended type of performer (e.g., Requester, Performer, Scheduler).</b><br> 4250 * Type: <b>token</b><br> 4251 * Path: <b>Task.performerType</b><br> 4252 * </p> 4253 */ 4254 @SearchParamDefinition(name="performer", path="Task.performerType", description="Search by recommended type of performer (e.g., Requester, Performer, Scheduler).", type="token" ) 4255 public static final String SP_PERFORMER = "performer"; 4256 /** 4257 * <b>Fluent Client</b> search parameter constant for <b>performer</b> 4258 * <p> 4259 * Description: <b>Search by recommended type of performer (e.g., Requester, Performer, Scheduler).</b><br> 4260 * Type: <b>token</b><br> 4261 * Path: <b>Task.performerType</b><br> 4262 * </p> 4263 */ 4264 public static final ca.uhn.fhir.rest.gclient.TokenClientParam PERFORMER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PERFORMER); 4265 4266 /** 4267 * Search parameter: <b>subject</b> 4268 * <p> 4269 * Description: <b>Search by subject</b><br> 4270 * Type: <b>reference</b><br> 4271 * Path: <b>Task.for</b><br> 4272 * </p> 4273 */ 4274 @SearchParamDefinition(name="subject", path="Task.for", description="Search by subject", type="reference" ) 4275 public static final String SP_SUBJECT = "subject"; 4276 /** 4277 * <b>Fluent Client</b> search parameter constant for <b>subject</b> 4278 * <p> 4279 * Description: <b>Search by subject</b><br> 4280 * Type: <b>reference</b><br> 4281 * Path: <b>Task.for</b><br> 4282 * </p> 4283 */ 4284 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam SUBJECT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_SUBJECT); 4285 4286/** 4287 * Constant for fluent queries to be used to add include statements. Specifies 4288 * the path value of "<b>Task:subject</b>". 4289 */ 4290 public static final ca.uhn.fhir.model.api.Include INCLUDE_SUBJECT = new ca.uhn.fhir.model.api.Include("Task:subject").toLocked(); 4291 4292 /** 4293 * Search parameter: <b>focus</b> 4294 * <p> 4295 * Description: <b>Search by task focus</b><br> 4296 * Type: <b>reference</b><br> 4297 * Path: <b>Task.focus</b><br> 4298 * </p> 4299 */ 4300 @SearchParamDefinition(name="focus", path="Task.focus", description="Search by task focus", type="reference" ) 4301 public static final String SP_FOCUS = "focus"; 4302 /** 4303 * <b>Fluent Client</b> search parameter constant for <b>focus</b> 4304 * <p> 4305 * Description: <b>Search by task focus</b><br> 4306 * Type: <b>reference</b><br> 4307 * Path: <b>Task.focus</b><br> 4308 * </p> 4309 */ 4310 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam FOCUS = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_FOCUS); 4311 4312/** 4313 * Constant for fluent queries to be used to add include statements. Specifies 4314 * the path value of "<b>Task:focus</b>". 4315 */ 4316 public static final ca.uhn.fhir.model.api.Include INCLUDE_FOCUS = new ca.uhn.fhir.model.api.Include("Task:focus").toLocked(); 4317 4318 /** 4319 * Search parameter: <b>part-of</b> 4320 * <p> 4321 * Description: <b>Search by task this task is part of</b><br> 4322 * Type: <b>reference</b><br> 4323 * Path: <b>Task.partOf</b><br> 4324 * </p> 4325 */ 4326 @SearchParamDefinition(name="part-of", path="Task.partOf", description="Search by task this task is part of", type="reference", target={Task.class } ) 4327 public static final String SP_PART_OF = "part-of"; 4328 /** 4329 * <b>Fluent Client</b> search parameter constant for <b>part-of</b> 4330 * <p> 4331 * Description: <b>Search by task this task is part of</b><br> 4332 * Type: <b>reference</b><br> 4333 * Path: <b>Task.partOf</b><br> 4334 * </p> 4335 */ 4336 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PART_OF = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PART_OF); 4337 4338/** 4339 * Constant for fluent queries to be used to add include statements. Specifies 4340 * the path value of "<b>Task:part-of</b>". 4341 */ 4342 public static final ca.uhn.fhir.model.api.Include INCLUDE_PART_OF = new ca.uhn.fhir.model.api.Include("Task:part-of").toLocked(); 4343 4344 /** 4345 * Search parameter: <b>encounter</b> 4346 * <p> 4347 * Description: <b>Search by encounter</b><br> 4348 * Type: <b>reference</b><br> 4349 * Path: <b>Task.encounter</b><br> 4350 * </p> 4351 */ 4352 @SearchParamDefinition(name="encounter", path="Task.encounter", description="Search by encounter", type="reference", target={Encounter.class } ) 4353 public static final String SP_ENCOUNTER = "encounter"; 4354 /** 4355 * <b>Fluent Client</b> search parameter constant for <b>encounter</b> 4356 * <p> 4357 * Description: <b>Search by encounter</b><br> 4358 * Type: <b>reference</b><br> 4359 * Path: <b>Task.encounter</b><br> 4360 * </p> 4361 */ 4362 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam ENCOUNTER = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_ENCOUNTER); 4363 4364/** 4365 * Constant for fluent queries to be used to add include statements. Specifies 4366 * the path value of "<b>Task:encounter</b>". 4367 */ 4368 public static final ca.uhn.fhir.model.api.Include INCLUDE_ENCOUNTER = new ca.uhn.fhir.model.api.Include("Task:encounter").toLocked(); 4369 4370 /** 4371 * Search parameter: <b>priority</b> 4372 * <p> 4373 * Description: <b>Search by task priority</b><br> 4374 * Type: <b>token</b><br> 4375 * Path: <b>Task.priority</b><br> 4376 * </p> 4377 */ 4378 @SearchParamDefinition(name="priority", path="Task.priority", description="Search by task priority", type="token" ) 4379 public static final String SP_PRIORITY = "priority"; 4380 /** 4381 * <b>Fluent Client</b> search parameter constant for <b>priority</b> 4382 * <p> 4383 * Description: <b>Search by task priority</b><br> 4384 * Type: <b>token</b><br> 4385 * Path: <b>Task.priority</b><br> 4386 * </p> 4387 */ 4388 public static final ca.uhn.fhir.rest.gclient.TokenClientParam PRIORITY = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_PRIORITY); 4389 4390 /** 4391 * Search parameter: <b>authored-on</b> 4392 * <p> 4393 * Description: <b>Search by creation date</b><br> 4394 * Type: <b>date</b><br> 4395 * Path: <b>Task.authoredOn</b><br> 4396 * </p> 4397 */ 4398 @SearchParamDefinition(name="authored-on", path="Task.authoredOn", description="Search by creation date", type="date" ) 4399 public static final String SP_AUTHORED_ON = "authored-on"; 4400 /** 4401 * <b>Fluent Client</b> search parameter constant for <b>authored-on</b> 4402 * <p> 4403 * Description: <b>Search by creation date</b><br> 4404 * Type: <b>date</b><br> 4405 * Path: <b>Task.authoredOn</b><br> 4406 * </p> 4407 */ 4408 public static final ca.uhn.fhir.rest.gclient.DateClientParam AUTHORED_ON = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_AUTHORED_ON); 4409 4410 /** 4411 * Search parameter: <b>intent</b> 4412 * <p> 4413 * Description: <b>Search by task intent</b><br> 4414 * Type: <b>token</b><br> 4415 * Path: <b>Task.intent</b><br> 4416 * </p> 4417 */ 4418 @SearchParamDefinition(name="intent", path="Task.intent", description="Search by task intent", type="token" ) 4419 public static final String SP_INTENT = "intent"; 4420 /** 4421 * <b>Fluent Client</b> search parameter constant for <b>intent</b> 4422 * <p> 4423 * Description: <b>Search by task intent</b><br> 4424 * Type: <b>token</b><br> 4425 * Path: <b>Task.intent</b><br> 4426 * </p> 4427 */ 4428 public static final ca.uhn.fhir.rest.gclient.TokenClientParam INTENT = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_INTENT); 4429 4430 /** 4431 * Search parameter: <b>group-identifier</b> 4432 * <p> 4433 * Description: <b>Search by group identifier</b><br> 4434 * Type: <b>token</b><br> 4435 * Path: <b>Task.groupIdentifier</b><br> 4436 * </p> 4437 */ 4438 @SearchParamDefinition(name="group-identifier", path="Task.groupIdentifier", description="Search by group identifier", type="token" ) 4439 public static final String SP_GROUP_IDENTIFIER = "group-identifier"; 4440 /** 4441 * <b>Fluent Client</b> search parameter constant for <b>group-identifier</b> 4442 * <p> 4443 * Description: <b>Search by group identifier</b><br> 4444 * Type: <b>token</b><br> 4445 * Path: <b>Task.groupIdentifier</b><br> 4446 * </p> 4447 */ 4448 public static final ca.uhn.fhir.rest.gclient.TokenClientParam GROUP_IDENTIFIER = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_GROUP_IDENTIFIER); 4449 4450 /** 4451 * Search parameter: <b>based-on</b> 4452 * <p> 4453 * Description: <b>Search by requests this task is based on</b><br> 4454 * Type: <b>reference</b><br> 4455 * Path: <b>Task.basedOn</b><br> 4456 * </p> 4457 */ 4458 @SearchParamDefinition(name="based-on", path="Task.basedOn", description="Search by requests this task is based on", type="reference" ) 4459 public static final String SP_BASED_ON = "based-on"; 4460 /** 4461 * <b>Fluent Client</b> search parameter constant for <b>based-on</b> 4462 * <p> 4463 * Description: <b>Search by requests this task is based on</b><br> 4464 * Type: <b>reference</b><br> 4465 * Path: <b>Task.basedOn</b><br> 4466 * </p> 4467 */ 4468 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam BASED_ON = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_BASED_ON); 4469 4470/** 4471 * Constant for fluent queries to be used to add include statements. Specifies 4472 * the path value of "<b>Task:based-on</b>". 4473 */ 4474 public static final ca.uhn.fhir.model.api.Include INCLUDE_BASED_ON = new ca.uhn.fhir.model.api.Include("Task:based-on").toLocked(); 4475 4476 /** 4477 * Search parameter: <b>patient</b> 4478 * <p> 4479 * Description: <b>Search by patient</b><br> 4480 * Type: <b>reference</b><br> 4481 * Path: <b>Task.for</b><br> 4482 * </p> 4483 */ 4484 @SearchParamDefinition(name="patient", path="Task.for.where(resolve() is Patient)", description="Search by patient", type="reference", target={Patient.class } ) 4485 public static final String SP_PATIENT = "patient"; 4486 /** 4487 * <b>Fluent Client</b> search parameter constant for <b>patient</b> 4488 * <p> 4489 * Description: <b>Search by patient</b><br> 4490 * Type: <b>reference</b><br> 4491 * Path: <b>Task.for</b><br> 4492 * </p> 4493 */ 4494 public static final ca.uhn.fhir.rest.gclient.ReferenceClientParam PATIENT = new ca.uhn.fhir.rest.gclient.ReferenceClientParam(SP_PATIENT); 4495 4496/** 4497 * Constant for fluent queries to be used to add include statements. Specifies 4498 * the path value of "<b>Task:patient</b>". 4499 */ 4500 public static final ca.uhn.fhir.model.api.Include INCLUDE_PATIENT = new ca.uhn.fhir.model.api.Include("Task:patient").toLocked(); 4501 4502 /** 4503 * Search parameter: <b>modified</b> 4504 * <p> 4505 * Description: <b>Search by last modification date</b><br> 4506 * Type: <b>date</b><br> 4507 * Path: <b>Task.lastModified</b><br> 4508 * </p> 4509 */ 4510 @SearchParamDefinition(name="modified", path="Task.lastModified", description="Search by last modification date", type="date" ) 4511 public static final String SP_MODIFIED = "modified"; 4512 /** 4513 * <b>Fluent Client</b> search parameter constant for <b>modified</b> 4514 * <p> 4515 * Description: <b>Search by last modification date</b><br> 4516 * Type: <b>date</b><br> 4517 * Path: <b>Task.lastModified</b><br> 4518 * </p> 4519 */ 4520 public static final ca.uhn.fhir.rest.gclient.DateClientParam MODIFIED = new ca.uhn.fhir.rest.gclient.DateClientParam(SP_MODIFIED); 4521 4522 /** 4523 * Search parameter: <b>status</b> 4524 * <p> 4525 * Description: <b>Search by task status</b><br> 4526 * Type: <b>token</b><br> 4527 * Path: <b>Task.status</b><br> 4528 * </p> 4529 */ 4530 @SearchParamDefinition(name="status", path="Task.status", description="Search by task status", type="token" ) 4531 public static final String SP_STATUS = "status"; 4532 /** 4533 * <b>Fluent Client</b> search parameter constant for <b>status</b> 4534 * <p> 4535 * Description: <b>Search by task status</b><br> 4536 * Type: <b>token</b><br> 4537 * Path: <b>Task.status</b><br> 4538 * </p> 4539 */ 4540 public static final ca.uhn.fhir.rest.gclient.TokenClientParam STATUS = new ca.uhn.fhir.rest.gclient.TokenClientParam(SP_STATUS); 4541 4542 4543}