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