001package org.hl7.fhir.dstu2.model; 002 003/*- 004 * #%L 005 * org.hl7.fhir.dstu2 006 * %% 007 * Copyright (C) 2014 - 2019 Health Level 7 008 * %% 009 * Licensed under the Apache License, Version 2.0 (the "License"); 010 * you may not use this file except in compliance with the License. 011 * You may obtain a copy of the License at 012 * 013 * http://www.apache.org/licenses/LICENSE-2.0 014 * 015 * Unless required by applicable law or agreed to in writing, software 016 * distributed under the License is distributed on an "AS IS" BASIS, 017 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 018 * See the License for the specific language governing permissions and 019 * limitations under the License. 020 * #L% 021 */ 022 023 024/* 025 Copyright (c) 2011+, HL7, Inc. 026 All rights reserved. 027 028 Redistribution and use in source and binary forms, with or without modification, 029 are permitted provided that the following conditions are met: 030 031 * Redistributions of source code must retain the above copyright notice, this 032 list of conditions and the following disclaimer. 033 * Redistributions in binary form must reproduce the above copyright notice, 034 this list of conditions and the following disclaimer in the documentation 035 and/or other materials provided with the distribution. 036 * Neither the name of HL7 nor the names of its contributors may be used to 037 endorse or promote products derived from this software without specific 038 prior written permission. 039 040 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 041 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 042 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 043 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 044 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 045 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 046 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 047 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 048 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 049 POSSIBILITY OF SUCH DAMAGE. 050 051*/ 052 053// Generated on Wed, Jul 13, 2016 05:32+1000 for FHIR v1.0.2 054import java.util.ArrayList; 055import java.util.Date; 056import java.util.List; 057 058import ca.uhn.fhir.model.api.annotation.Block; 059import ca.uhn.fhir.model.api.annotation.Child; 060import ca.uhn.fhir.model.api.annotation.Description; 061import ca.uhn.fhir.model.api.annotation.ResourceDef; 062import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 063import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 064import org.hl7.fhir.exceptions.FHIRException; 065import org.hl7.fhir.utilities.Utilities; 066/** 067 * This resource provides the target, request and response, and action details for an action to be performed by the target on or about existing resources. 068 */ 069@ResourceDef(name="ProcessRequest", profile="http://hl7.org/fhir/Profile/ProcessRequest") 070public class ProcessRequest extends DomainResource { 071 072 public enum ActionList { 073 /** 074 * Cancel, reverse or nullify the target resource. 075 */ 076 CANCEL, 077 /** 078 * Check for previously un-read/ not-retrieved resources. 079 */ 080 POLL, 081 /** 082 * Re-process the target resource. 083 */ 084 REPROCESS, 085 /** 086 * Retrieve the processing status of the target resource. 087 */ 088 STATUS, 089 /** 090 * added to help the parsers 091 */ 092 NULL; 093 public static ActionList fromCode(String codeString) throws FHIRException { 094 if (codeString == null || "".equals(codeString)) 095 return null; 096 if ("cancel".equals(codeString)) 097 return CANCEL; 098 if ("poll".equals(codeString)) 099 return POLL; 100 if ("reprocess".equals(codeString)) 101 return REPROCESS; 102 if ("status".equals(codeString)) 103 return STATUS; 104 throw new FHIRException("Unknown ActionList code '"+codeString+"'"); 105 } 106 public String toCode() { 107 switch (this) { 108 case CANCEL: return "cancel"; 109 case POLL: return "poll"; 110 case REPROCESS: return "reprocess"; 111 case STATUS: return "status"; 112 default: return "?"; 113 } 114 } 115 public String getSystem() { 116 switch (this) { 117 case CANCEL: return "http://hl7.org/fhir/actionlist"; 118 case POLL: return "http://hl7.org/fhir/actionlist"; 119 case REPROCESS: return "http://hl7.org/fhir/actionlist"; 120 case STATUS: return "http://hl7.org/fhir/actionlist"; 121 default: return "?"; 122 } 123 } 124 public String getDefinition() { 125 switch (this) { 126 case CANCEL: return "Cancel, reverse or nullify the target resource."; 127 case POLL: return "Check for previously un-read/ not-retrieved resources."; 128 case REPROCESS: return "Re-process the target resource."; 129 case STATUS: return "Retrieve the processing status of the target resource."; 130 default: return "?"; 131 } 132 } 133 public String getDisplay() { 134 switch (this) { 135 case CANCEL: return "Cancel, Reverse or Nullify"; 136 case POLL: return "Poll"; 137 case REPROCESS: return "Re-Process"; 138 case STATUS: return "Status Check"; 139 default: return "?"; 140 } 141 } 142 } 143 144 public static class ActionListEnumFactory implements EnumFactory<ActionList> { 145 public ActionList fromCode(String codeString) throws IllegalArgumentException { 146 if (codeString == null || "".equals(codeString)) 147 if (codeString == null || "".equals(codeString)) 148 return null; 149 if ("cancel".equals(codeString)) 150 return ActionList.CANCEL; 151 if ("poll".equals(codeString)) 152 return ActionList.POLL; 153 if ("reprocess".equals(codeString)) 154 return ActionList.REPROCESS; 155 if ("status".equals(codeString)) 156 return ActionList.STATUS; 157 throw new IllegalArgumentException("Unknown ActionList code '"+codeString+"'"); 158 } 159 public Enumeration<ActionList> fromType(Base code) throws FHIRException { 160 if (code == null || code.isEmpty()) 161 return null; 162 String codeString = ((PrimitiveType) code).asStringValue(); 163 if (codeString == null || "".equals(codeString)) 164 return null; 165 if ("cancel".equals(codeString)) 166 return new Enumeration<ActionList>(this, ActionList.CANCEL); 167 if ("poll".equals(codeString)) 168 return new Enumeration<ActionList>(this, ActionList.POLL); 169 if ("reprocess".equals(codeString)) 170 return new Enumeration<ActionList>(this, ActionList.REPROCESS); 171 if ("status".equals(codeString)) 172 return new Enumeration<ActionList>(this, ActionList.STATUS); 173 throw new FHIRException("Unknown ActionList code '"+codeString+"'"); 174 } 175 public String toCode(ActionList code) { 176 if (code == ActionList.CANCEL) 177 return "cancel"; 178 if (code == ActionList.POLL) 179 return "poll"; 180 if (code == ActionList.REPROCESS) 181 return "reprocess"; 182 if (code == ActionList.STATUS) 183 return "status"; 184 return "?"; 185 } 186 } 187 188 @Block() 189 public static class ItemsComponent extends BackboneElement implements IBaseBackboneElement { 190 /** 191 * A service line number. 192 */ 193 @Child(name = "sequenceLinkId", type = {IntegerType.class}, order=1, min=1, max=1, modifier=false, summary=true) 194 @Description(shortDefinition="Service instance", formalDefinition="A service line number." ) 195 protected IntegerType sequenceLinkId; 196 197 private static final long serialVersionUID = -1598360600L; 198 199 /* 200 * Constructor 201 */ 202 public ItemsComponent() { 203 super(); 204 } 205 206 /* 207 * Constructor 208 */ 209 public ItemsComponent(IntegerType sequenceLinkId) { 210 super(); 211 this.sequenceLinkId = sequenceLinkId; 212 } 213 214 /** 215 * @return {@link #sequenceLinkId} (A service line number.). This is the underlying object with id, value and extensions. The accessor "getSequenceLinkId" gives direct access to the value 216 */ 217 public IntegerType getSequenceLinkIdElement() { 218 if (this.sequenceLinkId == null) 219 if (Configuration.errorOnAutoCreate()) 220 throw new Error("Attempt to auto-create ItemsComponent.sequenceLinkId"); 221 else if (Configuration.doAutoCreate()) 222 this.sequenceLinkId = new IntegerType(); // bb 223 return this.sequenceLinkId; 224 } 225 226 public boolean hasSequenceLinkIdElement() { 227 return this.sequenceLinkId != null && !this.sequenceLinkId.isEmpty(); 228 } 229 230 public boolean hasSequenceLinkId() { 231 return this.sequenceLinkId != null && !this.sequenceLinkId.isEmpty(); 232 } 233 234 /** 235 * @param value {@link #sequenceLinkId} (A service line number.). This is the underlying object with id, value and extensions. The accessor "getSequenceLinkId" gives direct access to the value 236 */ 237 public ItemsComponent setSequenceLinkIdElement(IntegerType value) { 238 this.sequenceLinkId = value; 239 return this; 240 } 241 242 /** 243 * @return A service line number. 244 */ 245 public int getSequenceLinkId() { 246 return this.sequenceLinkId == null || this.sequenceLinkId.isEmpty() ? 0 : this.sequenceLinkId.getValue(); 247 } 248 249 /** 250 * @param value A service line number. 251 */ 252 public ItemsComponent setSequenceLinkId(int value) { 253 if (this.sequenceLinkId == null) 254 this.sequenceLinkId = new IntegerType(); 255 this.sequenceLinkId.setValue(value); 256 return this; 257 } 258 259 protected void listChildren(List<Property> childrenList) { 260 super.listChildren(childrenList); 261 childrenList.add(new Property("sequenceLinkId", "integer", "A service line number.", 0, java.lang.Integer.MAX_VALUE, sequenceLinkId)); 262 } 263 264 @Override 265 public void setProperty(String name, Base value) throws FHIRException { 266 if (name.equals("sequenceLinkId")) 267 this.sequenceLinkId = castToInteger(value); // IntegerType 268 else 269 super.setProperty(name, value); 270 } 271 272 @Override 273 public Base addChild(String name) throws FHIRException { 274 if (name.equals("sequenceLinkId")) { 275 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.sequenceLinkId"); 276 } 277 else 278 return super.addChild(name); 279 } 280 281 public ItemsComponent copy() { 282 ItemsComponent dst = new ItemsComponent(); 283 copyValues(dst); 284 dst.sequenceLinkId = sequenceLinkId == null ? null : sequenceLinkId.copy(); 285 return dst; 286 } 287 288 @Override 289 public boolean equalsDeep(Base other) { 290 if (!super.equalsDeep(other)) 291 return false; 292 if (!(other instanceof ItemsComponent)) 293 return false; 294 ItemsComponent o = (ItemsComponent) other; 295 return compareDeep(sequenceLinkId, o.sequenceLinkId, true); 296 } 297 298 @Override 299 public boolean equalsShallow(Base other) { 300 if (!super.equalsShallow(other)) 301 return false; 302 if (!(other instanceof ItemsComponent)) 303 return false; 304 ItemsComponent o = (ItemsComponent) other; 305 return compareValues(sequenceLinkId, o.sequenceLinkId, true); 306 } 307 308 public boolean isEmpty() { 309 return super.isEmpty() && (sequenceLinkId == null || sequenceLinkId.isEmpty()); 310 } 311 312 public String fhirType() { 313 return "ProcessRequest.item"; 314 315 } 316 317 } 318 319 /** 320 * The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest. 321 */ 322 @Child(name = "action", type = {CodeType.class}, order=0, min=1, max=1, modifier=false, summary=true) 323 @Description(shortDefinition="cancel | poll | reprocess | status", formalDefinition="The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest." ) 324 protected Enumeration<ActionList> action; 325 326 /** 327 * The ProcessRequest business identifier. 328 */ 329 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 330 @Description(shortDefinition="Business Identifier", formalDefinition="The ProcessRequest business identifier." ) 331 protected List<Identifier> identifier; 332 333 /** 334 * The version of the style of resource contents. This should be mapped to the allowable profiles for this and supporting resources. 335 */ 336 @Child(name = "ruleset", type = {Coding.class}, order=2, min=0, max=1, modifier=false, summary=true) 337 @Description(shortDefinition="Resource version", formalDefinition="The version of the style of resource contents. This should be mapped to the allowable profiles for this and supporting resources." ) 338 protected Coding ruleset; 339 340 /** 341 * The style (standard) and version of the original material which was converted into this resource. 342 */ 343 @Child(name = "originalRuleset", type = {Coding.class}, order=3, min=0, max=1, modifier=false, summary=true) 344 @Description(shortDefinition="Original version", formalDefinition="The style (standard) and version of the original material which was converted into this resource." ) 345 protected Coding originalRuleset; 346 347 /** 348 * The date when this resource was created. 349 */ 350 @Child(name = "created", type = {DateTimeType.class}, order=4, min=0, max=1, modifier=false, summary=true) 351 @Description(shortDefinition="Creation date", formalDefinition="The date when this resource was created." ) 352 protected DateTimeType created; 353 354 /** 355 * The organization which is the target of the request. 356 */ 357 @Child(name = "target", type = {Organization.class}, order=5, min=0, max=1, modifier=false, summary=true) 358 @Description(shortDefinition="Target of the request", formalDefinition="The organization which is the target of the request." ) 359 protected Reference target; 360 361 /** 362 * The actual object that is the target of the reference (The organization which is the target of the request.) 363 */ 364 protected Organization targetTarget; 365 366 /** 367 * The practitioner who is responsible for the action specified in thise request. 368 */ 369 @Child(name = "provider", type = {Practitioner.class}, order=6, min=0, max=1, modifier=false, summary=true) 370 @Description(shortDefinition="Responsible practitioner", formalDefinition="The practitioner who is responsible for the action specified in thise request." ) 371 protected Reference provider; 372 373 /** 374 * The actual object that is the target of the reference (The practitioner who is responsible for the action specified in thise request.) 375 */ 376 protected Practitioner providerTarget; 377 378 /** 379 * The organization which is responsible for the action speccified in thise request. 380 */ 381 @Child(name = "organization", type = {Organization.class}, order=7, min=0, max=1, modifier=false, summary=true) 382 @Description(shortDefinition="Responsible organization", formalDefinition="The organization which is responsible for the action speccified in thise request." ) 383 protected Reference organization; 384 385 /** 386 * The actual object that is the target of the reference (The organization which is responsible for the action speccified in thise request.) 387 */ 388 protected Organization organizationTarget; 389 390 /** 391 * Reference of resource which is the target or subject of this action. 392 */ 393 @Child(name = "request", type = {}, order=8, min=0, max=1, modifier=false, summary=true) 394 @Description(shortDefinition="Request reference", formalDefinition="Reference of resource which is the target or subject of this action." ) 395 protected Reference request; 396 397 /** 398 * The actual object that is the target of the reference (Reference of resource which is the target or subject of this action.) 399 */ 400 protected Resource requestTarget; 401 402 /** 403 * Reference of a prior response to resource which is the target or subject of this action. 404 */ 405 @Child(name = "response", type = {}, order=9, min=0, max=1, modifier=false, summary=true) 406 @Description(shortDefinition="Response reference", formalDefinition="Reference of a prior response to resource which is the target or subject of this action." ) 407 protected Reference response; 408 409 /** 410 * The actual object that is the target of the reference (Reference of a prior response to resource which is the target or subject of this action.) 411 */ 412 protected Resource responseTarget; 413 414 /** 415 * If true remove all history excluding audit. 416 */ 417 @Child(name = "nullify", type = {BooleanType.class}, order=10, min=0, max=1, modifier=false, summary=true) 418 @Description(shortDefinition="Nullify", formalDefinition="If true remove all history excluding audit." ) 419 protected BooleanType nullify; 420 421 /** 422 * A reference to supply which authenticates the process. 423 */ 424 @Child(name = "reference", type = {StringType.class}, order=11, min=0, max=1, modifier=false, summary=true) 425 @Description(shortDefinition="Reference number/string", formalDefinition="A reference to supply which authenticates the process." ) 426 protected StringType reference; 427 428 /** 429 * List of top level items to be re-adjudicated, if none specified then the entire submission is re-adjudicated. 430 */ 431 @Child(name = "item", type = {}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 432 @Description(shortDefinition="Items to re-adjudicate", formalDefinition="List of top level items to be re-adjudicated, if none specified then the entire submission is re-adjudicated." ) 433 protected List<ItemsComponent> item; 434 435 /** 436 * Names of resource types to include. 437 */ 438 @Child(name = "include", type = {StringType.class}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 439 @Description(shortDefinition="Resource type(s) to include", formalDefinition="Names of resource types to include." ) 440 protected List<StringType> include; 441 442 /** 443 * Names of resource types to exclude. 444 */ 445 @Child(name = "exclude", type = {StringType.class}, order=14, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 446 @Description(shortDefinition="Resource type(s) to exclude", formalDefinition="Names of resource types to exclude." ) 447 protected List<StringType> exclude; 448 449 /** 450 * A period of time during which the fulfilling resources would have been created. 451 */ 452 @Child(name = "period", type = {Period.class}, order=15, min=0, max=1, modifier=false, summary=true) 453 @Description(shortDefinition="Period", formalDefinition="A period of time during which the fulfilling resources would have been created." ) 454 protected Period period; 455 456 private static final long serialVersionUID = -1332331220L; 457 458 /* 459 * Constructor 460 */ 461 public ProcessRequest() { 462 super(); 463 } 464 465 /* 466 * Constructor 467 */ 468 public ProcessRequest(Enumeration<ActionList> action) { 469 super(); 470 this.action = action; 471 } 472 473 /** 474 * @return {@link #action} (The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest.). This is the underlying object with id, value and extensions. The accessor "getAction" gives direct access to the value 475 */ 476 public Enumeration<ActionList> getActionElement() { 477 if (this.action == null) 478 if (Configuration.errorOnAutoCreate()) 479 throw new Error("Attempt to auto-create ProcessRequest.action"); 480 else if (Configuration.doAutoCreate()) 481 this.action = new Enumeration<ActionList>(new ActionListEnumFactory()); // bb 482 return this.action; 483 } 484 485 public boolean hasActionElement() { 486 return this.action != null && !this.action.isEmpty(); 487 } 488 489 public boolean hasAction() { 490 return this.action != null && !this.action.isEmpty(); 491 } 492 493 /** 494 * @param value {@link #action} (The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest.). This is the underlying object with id, value and extensions. The accessor "getAction" gives direct access to the value 495 */ 496 public ProcessRequest setActionElement(Enumeration<ActionList> value) { 497 this.action = value; 498 return this; 499 } 500 501 /** 502 * @return The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest. 503 */ 504 public ActionList getAction() { 505 return this.action == null ? null : this.action.getValue(); 506 } 507 508 /** 509 * @param value The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest. 510 */ 511 public ProcessRequest setAction(ActionList value) { 512 if (this.action == null) 513 this.action = new Enumeration<ActionList>(new ActionListEnumFactory()); 514 this.action.setValue(value); 515 return this; 516 } 517 518 /** 519 * @return {@link #identifier} (The ProcessRequest business identifier.) 520 */ 521 public List<Identifier> getIdentifier() { 522 if (this.identifier == null) 523 this.identifier = new ArrayList<Identifier>(); 524 return this.identifier; 525 } 526 527 public boolean hasIdentifier() { 528 if (this.identifier == null) 529 return false; 530 for (Identifier item : this.identifier) 531 if (!item.isEmpty()) 532 return true; 533 return false; 534 } 535 536 /** 537 * @return {@link #identifier} (The ProcessRequest business identifier.) 538 */ 539 // syntactic sugar 540 public Identifier addIdentifier() { //3 541 Identifier t = new Identifier(); 542 if (this.identifier == null) 543 this.identifier = new ArrayList<Identifier>(); 544 this.identifier.add(t); 545 return t; 546 } 547 548 // syntactic sugar 549 public ProcessRequest addIdentifier(Identifier t) { //3 550 if (t == null) 551 return this; 552 if (this.identifier == null) 553 this.identifier = new ArrayList<Identifier>(); 554 this.identifier.add(t); 555 return this; 556 } 557 558 /** 559 * @return {@link #ruleset} (The version of the style of resource contents. This should be mapped to the allowable profiles for this and supporting resources.) 560 */ 561 public Coding getRuleset() { 562 if (this.ruleset == null) 563 if (Configuration.errorOnAutoCreate()) 564 throw new Error("Attempt to auto-create ProcessRequest.ruleset"); 565 else if (Configuration.doAutoCreate()) 566 this.ruleset = new Coding(); // cc 567 return this.ruleset; 568 } 569 570 public boolean hasRuleset() { 571 return this.ruleset != null && !this.ruleset.isEmpty(); 572 } 573 574 /** 575 * @param value {@link #ruleset} (The version of the style of resource contents. This should be mapped to the allowable profiles for this and supporting resources.) 576 */ 577 public ProcessRequest setRuleset(Coding value) { 578 this.ruleset = value; 579 return this; 580 } 581 582 /** 583 * @return {@link #originalRuleset} (The style (standard) and version of the original material which was converted into this resource.) 584 */ 585 public Coding getOriginalRuleset() { 586 if (this.originalRuleset == null) 587 if (Configuration.errorOnAutoCreate()) 588 throw new Error("Attempt to auto-create ProcessRequest.originalRuleset"); 589 else if (Configuration.doAutoCreate()) 590 this.originalRuleset = new Coding(); // cc 591 return this.originalRuleset; 592 } 593 594 public boolean hasOriginalRuleset() { 595 return this.originalRuleset != null && !this.originalRuleset.isEmpty(); 596 } 597 598 /** 599 * @param value {@link #originalRuleset} (The style (standard) and version of the original material which was converted into this resource.) 600 */ 601 public ProcessRequest setOriginalRuleset(Coding value) { 602 this.originalRuleset = value; 603 return this; 604 } 605 606 /** 607 * @return {@link #created} (The date when this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 608 */ 609 public DateTimeType getCreatedElement() { 610 if (this.created == null) 611 if (Configuration.errorOnAutoCreate()) 612 throw new Error("Attempt to auto-create ProcessRequest.created"); 613 else if (Configuration.doAutoCreate()) 614 this.created = new DateTimeType(); // bb 615 return this.created; 616 } 617 618 public boolean hasCreatedElement() { 619 return this.created != null && !this.created.isEmpty(); 620 } 621 622 public boolean hasCreated() { 623 return this.created != null && !this.created.isEmpty(); 624 } 625 626 /** 627 * @param value {@link #created} (The date when this resource was created.). This is the underlying object with id, value and extensions. The accessor "getCreated" gives direct access to the value 628 */ 629 public ProcessRequest setCreatedElement(DateTimeType value) { 630 this.created = value; 631 return this; 632 } 633 634 /** 635 * @return The date when this resource was created. 636 */ 637 public Date getCreated() { 638 return this.created == null ? null : this.created.getValue(); 639 } 640 641 /** 642 * @param value The date when this resource was created. 643 */ 644 public ProcessRequest setCreated(Date value) { 645 if (value == null) 646 this.created = null; 647 else { 648 if (this.created == null) 649 this.created = new DateTimeType(); 650 this.created.setValue(value); 651 } 652 return this; 653 } 654 655 /** 656 * @return {@link #target} (The organization which is the target of the request.) 657 */ 658 public Reference getTarget() { 659 if (this.target == null) 660 if (Configuration.errorOnAutoCreate()) 661 throw new Error("Attempt to auto-create ProcessRequest.target"); 662 else if (Configuration.doAutoCreate()) 663 this.target = new Reference(); // cc 664 return this.target; 665 } 666 667 public boolean hasTarget() { 668 return this.target != null && !this.target.isEmpty(); 669 } 670 671 /** 672 * @param value {@link #target} (The organization which is the target of the request.) 673 */ 674 public ProcessRequest setTarget(Reference value) { 675 this.target = value; 676 return this; 677 } 678 679 /** 680 * @return {@link #target} 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 organization which is the target of the request.) 681 */ 682 public Organization getTargetTarget() { 683 if (this.targetTarget == null) 684 if (Configuration.errorOnAutoCreate()) 685 throw new Error("Attempt to auto-create ProcessRequest.target"); 686 else if (Configuration.doAutoCreate()) 687 this.targetTarget = new Organization(); // aa 688 return this.targetTarget; 689 } 690 691 /** 692 * @param value {@link #target} 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 organization which is the target of the request.) 693 */ 694 public ProcessRequest setTargetTarget(Organization value) { 695 this.targetTarget = value; 696 return this; 697 } 698 699 /** 700 * @return {@link #provider} (The practitioner who is responsible for the action specified in thise request.) 701 */ 702 public Reference getProvider() { 703 if (this.provider == null) 704 if (Configuration.errorOnAutoCreate()) 705 throw new Error("Attempt to auto-create ProcessRequest.provider"); 706 else if (Configuration.doAutoCreate()) 707 this.provider = new Reference(); // cc 708 return this.provider; 709 } 710 711 public boolean hasProvider() { 712 return this.provider != null && !this.provider.isEmpty(); 713 } 714 715 /** 716 * @param value {@link #provider} (The practitioner who is responsible for the action specified in thise request.) 717 */ 718 public ProcessRequest setProvider(Reference value) { 719 this.provider = value; 720 return this; 721 } 722 723 /** 724 * @return {@link #provider} 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 practitioner who is responsible for the action specified in thise request.) 725 */ 726 public Practitioner getProviderTarget() { 727 if (this.providerTarget == null) 728 if (Configuration.errorOnAutoCreate()) 729 throw new Error("Attempt to auto-create ProcessRequest.provider"); 730 else if (Configuration.doAutoCreate()) 731 this.providerTarget = new Practitioner(); // aa 732 return this.providerTarget; 733 } 734 735 /** 736 * @param value {@link #provider} 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 practitioner who is responsible for the action specified in thise request.) 737 */ 738 public ProcessRequest setProviderTarget(Practitioner value) { 739 this.providerTarget = value; 740 return this; 741 } 742 743 /** 744 * @return {@link #organization} (The organization which is responsible for the action speccified in thise request.) 745 */ 746 public Reference getOrganization() { 747 if (this.organization == null) 748 if (Configuration.errorOnAutoCreate()) 749 throw new Error("Attempt to auto-create ProcessRequest.organization"); 750 else if (Configuration.doAutoCreate()) 751 this.organization = new Reference(); // cc 752 return this.organization; 753 } 754 755 public boolean hasOrganization() { 756 return this.organization != null && !this.organization.isEmpty(); 757 } 758 759 /** 760 * @param value {@link #organization} (The organization which is responsible for the action speccified in thise request.) 761 */ 762 public ProcessRequest setOrganization(Reference value) { 763 this.organization = value; 764 return this; 765 } 766 767 /** 768 * @return {@link #organization} 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 organization which is responsible for the action speccified in thise request.) 769 */ 770 public Organization getOrganizationTarget() { 771 if (this.organizationTarget == null) 772 if (Configuration.errorOnAutoCreate()) 773 throw new Error("Attempt to auto-create ProcessRequest.organization"); 774 else if (Configuration.doAutoCreate()) 775 this.organizationTarget = new Organization(); // aa 776 return this.organizationTarget; 777 } 778 779 /** 780 * @param value {@link #organization} 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 organization which is responsible for the action speccified in thise request.) 781 */ 782 public ProcessRequest setOrganizationTarget(Organization value) { 783 this.organizationTarget = value; 784 return this; 785 } 786 787 /** 788 * @return {@link #request} (Reference of resource which is the target or subject of this action.) 789 */ 790 public Reference getRequest() { 791 if (this.request == null) 792 if (Configuration.errorOnAutoCreate()) 793 throw new Error("Attempt to auto-create ProcessRequest.request"); 794 else if (Configuration.doAutoCreate()) 795 this.request = new Reference(); // cc 796 return this.request; 797 } 798 799 public boolean hasRequest() { 800 return this.request != null && !this.request.isEmpty(); 801 } 802 803 /** 804 * @param value {@link #request} (Reference of resource which is the target or subject of this action.) 805 */ 806 public ProcessRequest setRequest(Reference value) { 807 this.request = value; 808 return this; 809 } 810 811 /** 812 * @return {@link #request} 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. (Reference of resource which is the target or subject of this action.) 813 */ 814 public Resource getRequestTarget() { 815 return this.requestTarget; 816 } 817 818 /** 819 * @param value {@link #request} 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. (Reference of resource which is the target or subject of this action.) 820 */ 821 public ProcessRequest setRequestTarget(Resource value) { 822 this.requestTarget = value; 823 return this; 824 } 825 826 /** 827 * @return {@link #response} (Reference of a prior response to resource which is the target or subject of this action.) 828 */ 829 public Reference getResponse() { 830 if (this.response == null) 831 if (Configuration.errorOnAutoCreate()) 832 throw new Error("Attempt to auto-create ProcessRequest.response"); 833 else if (Configuration.doAutoCreate()) 834 this.response = new Reference(); // cc 835 return this.response; 836 } 837 838 public boolean hasResponse() { 839 return this.response != null && !this.response.isEmpty(); 840 } 841 842 /** 843 * @param value {@link #response} (Reference of a prior response to resource which is the target or subject of this action.) 844 */ 845 public ProcessRequest setResponse(Reference value) { 846 this.response = value; 847 return this; 848 } 849 850 /** 851 * @return {@link #response} 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. (Reference of a prior response to resource which is the target or subject of this action.) 852 */ 853 public Resource getResponseTarget() { 854 return this.responseTarget; 855 } 856 857 /** 858 * @param value {@link #response} 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. (Reference of a prior response to resource which is the target or subject of this action.) 859 */ 860 public ProcessRequest setResponseTarget(Resource value) { 861 this.responseTarget = value; 862 return this; 863 } 864 865 /** 866 * @return {@link #nullify} (If true remove all history excluding audit.). This is the underlying object with id, value and extensions. The accessor "getNullify" gives direct access to the value 867 */ 868 public BooleanType getNullifyElement() { 869 if (this.nullify == null) 870 if (Configuration.errorOnAutoCreate()) 871 throw new Error("Attempt to auto-create ProcessRequest.nullify"); 872 else if (Configuration.doAutoCreate()) 873 this.nullify = new BooleanType(); // bb 874 return this.nullify; 875 } 876 877 public boolean hasNullifyElement() { 878 return this.nullify != null && !this.nullify.isEmpty(); 879 } 880 881 public boolean hasNullify() { 882 return this.nullify != null && !this.nullify.isEmpty(); 883 } 884 885 /** 886 * @param value {@link #nullify} (If true remove all history excluding audit.). This is the underlying object with id, value and extensions. The accessor "getNullify" gives direct access to the value 887 */ 888 public ProcessRequest setNullifyElement(BooleanType value) { 889 this.nullify = value; 890 return this; 891 } 892 893 /** 894 * @return If true remove all history excluding audit. 895 */ 896 public boolean getNullify() { 897 return this.nullify == null || this.nullify.isEmpty() ? false : this.nullify.getValue(); 898 } 899 900 /** 901 * @param value If true remove all history excluding audit. 902 */ 903 public ProcessRequest setNullify(boolean value) { 904 if (this.nullify == null) 905 this.nullify = new BooleanType(); 906 this.nullify.setValue(value); 907 return this; 908 } 909 910 /** 911 * @return {@link #reference} (A reference to supply which authenticates the process.). This is the underlying object with id, value and extensions. The accessor "getReference" gives direct access to the value 912 */ 913 public StringType getReferenceElement() { 914 if (this.reference == null) 915 if (Configuration.errorOnAutoCreate()) 916 throw new Error("Attempt to auto-create ProcessRequest.reference"); 917 else if (Configuration.doAutoCreate()) 918 this.reference = new StringType(); // bb 919 return this.reference; 920 } 921 922 public boolean hasReferenceElement() { 923 return this.reference != null && !this.reference.isEmpty(); 924 } 925 926 public boolean hasReference() { 927 return this.reference != null && !this.reference.isEmpty(); 928 } 929 930 /** 931 * @param value {@link #reference} (A reference to supply which authenticates the process.). This is the underlying object with id, value and extensions. The accessor "getReference" gives direct access to the value 932 */ 933 public ProcessRequest setReferenceElement(StringType value) { 934 this.reference = value; 935 return this; 936 } 937 938 /** 939 * @return A reference to supply which authenticates the process. 940 */ 941 public String getReference() { 942 return this.reference == null ? null : this.reference.getValue(); 943 } 944 945 /** 946 * @param value A reference to supply which authenticates the process. 947 */ 948 public ProcessRequest setReference(String value) { 949 if (Utilities.noString(value)) 950 this.reference = null; 951 else { 952 if (this.reference == null) 953 this.reference = new StringType(); 954 this.reference.setValue(value); 955 } 956 return this; 957 } 958 959 /** 960 * @return {@link #item} (List of top level items to be re-adjudicated, if none specified then the entire submission is re-adjudicated.) 961 */ 962 public List<ItemsComponent> getItem() { 963 if (this.item == null) 964 this.item = new ArrayList<ItemsComponent>(); 965 return this.item; 966 } 967 968 public boolean hasItem() { 969 if (this.item == null) 970 return false; 971 for (ItemsComponent item : this.item) 972 if (!item.isEmpty()) 973 return true; 974 return false; 975 } 976 977 /** 978 * @return {@link #item} (List of top level items to be re-adjudicated, if none specified then the entire submission is re-adjudicated.) 979 */ 980 // syntactic sugar 981 public ItemsComponent addItem() { //3 982 ItemsComponent t = new ItemsComponent(); 983 if (this.item == null) 984 this.item = new ArrayList<ItemsComponent>(); 985 this.item.add(t); 986 return t; 987 } 988 989 // syntactic sugar 990 public ProcessRequest addItem(ItemsComponent t) { //3 991 if (t == null) 992 return this; 993 if (this.item == null) 994 this.item = new ArrayList<ItemsComponent>(); 995 this.item.add(t); 996 return this; 997 } 998 999 /** 1000 * @return {@link #include} (Names of resource types to include.) 1001 */ 1002 public List<StringType> getInclude() { 1003 if (this.include == null) 1004 this.include = new ArrayList<StringType>(); 1005 return this.include; 1006 } 1007 1008 public boolean hasInclude() { 1009 if (this.include == null) 1010 return false; 1011 for (StringType item : this.include) 1012 if (!item.isEmpty()) 1013 return true; 1014 return false; 1015 } 1016 1017 /** 1018 * @return {@link #include} (Names of resource types to include.) 1019 */ 1020 // syntactic sugar 1021 public StringType addIncludeElement() {//2 1022 StringType t = new StringType(); 1023 if (this.include == null) 1024 this.include = new ArrayList<StringType>(); 1025 this.include.add(t); 1026 return t; 1027 } 1028 1029 /** 1030 * @param value {@link #include} (Names of resource types to include.) 1031 */ 1032 public ProcessRequest addInclude(String value) { //1 1033 StringType t = new StringType(); 1034 t.setValue(value); 1035 if (this.include == null) 1036 this.include = new ArrayList<StringType>(); 1037 this.include.add(t); 1038 return this; 1039 } 1040 1041 /** 1042 * @param value {@link #include} (Names of resource types to include.) 1043 */ 1044 public boolean hasInclude(String value) { 1045 if (this.include == null) 1046 return false; 1047 for (StringType v : this.include) 1048 if (v.equals(value)) // string 1049 return true; 1050 return false; 1051 } 1052 1053 /** 1054 * @return {@link #exclude} (Names of resource types to exclude.) 1055 */ 1056 public List<StringType> getExclude() { 1057 if (this.exclude == null) 1058 this.exclude = new ArrayList<StringType>(); 1059 return this.exclude; 1060 } 1061 1062 public boolean hasExclude() { 1063 if (this.exclude == null) 1064 return false; 1065 for (StringType item : this.exclude) 1066 if (!item.isEmpty()) 1067 return true; 1068 return false; 1069 } 1070 1071 /** 1072 * @return {@link #exclude} (Names of resource types to exclude.) 1073 */ 1074 // syntactic sugar 1075 public StringType addExcludeElement() {//2 1076 StringType t = new StringType(); 1077 if (this.exclude == null) 1078 this.exclude = new ArrayList<StringType>(); 1079 this.exclude.add(t); 1080 return t; 1081 } 1082 1083 /** 1084 * @param value {@link #exclude} (Names of resource types to exclude.) 1085 */ 1086 public ProcessRequest addExclude(String value) { //1 1087 StringType t = new StringType(); 1088 t.setValue(value); 1089 if (this.exclude == null) 1090 this.exclude = new ArrayList<StringType>(); 1091 this.exclude.add(t); 1092 return this; 1093 } 1094 1095 /** 1096 * @param value {@link #exclude} (Names of resource types to exclude.) 1097 */ 1098 public boolean hasExclude(String value) { 1099 if (this.exclude == null) 1100 return false; 1101 for (StringType v : this.exclude) 1102 if (v.equals(value)) // string 1103 return true; 1104 return false; 1105 } 1106 1107 /** 1108 * @return {@link #period} (A period of time during which the fulfilling resources would have been created.) 1109 */ 1110 public Period getPeriod() { 1111 if (this.period == null) 1112 if (Configuration.errorOnAutoCreate()) 1113 throw new Error("Attempt to auto-create ProcessRequest.period"); 1114 else if (Configuration.doAutoCreate()) 1115 this.period = new Period(); // cc 1116 return this.period; 1117 } 1118 1119 public boolean hasPeriod() { 1120 return this.period != null && !this.period.isEmpty(); 1121 } 1122 1123 /** 1124 * @param value {@link #period} (A period of time during which the fulfilling resources would have been created.) 1125 */ 1126 public ProcessRequest setPeriod(Period value) { 1127 this.period = value; 1128 return this; 1129 } 1130 1131 protected void listChildren(List<Property> childrenList) { 1132 super.listChildren(childrenList); 1133 childrenList.add(new Property("action", "code", "The type of processing action being requested, for example Reversal, Readjudication, StatusRequest,PendedRequest.", 0, java.lang.Integer.MAX_VALUE, action)); 1134 childrenList.add(new Property("identifier", "Identifier", "The ProcessRequest business identifier.", 0, java.lang.Integer.MAX_VALUE, identifier)); 1135 childrenList.add(new Property("ruleset", "Coding", "The version of the style of resource contents. This should be mapped to the allowable profiles for this and supporting resources.", 0, java.lang.Integer.MAX_VALUE, ruleset)); 1136 childrenList.add(new Property("originalRuleset", "Coding", "The style (standard) and version of the original material which was converted into this resource.", 0, java.lang.Integer.MAX_VALUE, originalRuleset)); 1137 childrenList.add(new Property("created", "dateTime", "The date when this resource was created.", 0, java.lang.Integer.MAX_VALUE, created)); 1138 childrenList.add(new Property("target", "Reference(Organization)", "The organization which is the target of the request.", 0, java.lang.Integer.MAX_VALUE, target)); 1139 childrenList.add(new Property("provider", "Reference(Practitioner)", "The practitioner who is responsible for the action specified in thise request.", 0, java.lang.Integer.MAX_VALUE, provider)); 1140 childrenList.add(new Property("organization", "Reference(Organization)", "The organization which is responsible for the action speccified in thise request.", 0, java.lang.Integer.MAX_VALUE, organization)); 1141 childrenList.add(new Property("request", "Reference(Any)", "Reference of resource which is the target or subject of this action.", 0, java.lang.Integer.MAX_VALUE, request)); 1142 childrenList.add(new Property("response", "Reference(Any)", "Reference of a prior response to resource which is the target or subject of this action.", 0, java.lang.Integer.MAX_VALUE, response)); 1143 childrenList.add(new Property("nullify", "boolean", "If true remove all history excluding audit.", 0, java.lang.Integer.MAX_VALUE, nullify)); 1144 childrenList.add(new Property("reference", "string", "A reference to supply which authenticates the process.", 0, java.lang.Integer.MAX_VALUE, reference)); 1145 childrenList.add(new Property("item", "", "List of top level items to be re-adjudicated, if none specified then the entire submission is re-adjudicated.", 0, java.lang.Integer.MAX_VALUE, item)); 1146 childrenList.add(new Property("include", "string", "Names of resource types to include.", 0, java.lang.Integer.MAX_VALUE, include)); 1147 childrenList.add(new Property("exclude", "string", "Names of resource types to exclude.", 0, java.lang.Integer.MAX_VALUE, exclude)); 1148 childrenList.add(new Property("period", "Period", "A period of time during which the fulfilling resources would have been created.", 0, java.lang.Integer.MAX_VALUE, period)); 1149 } 1150 1151 @Override 1152 public void setProperty(String name, Base value) throws FHIRException { 1153 if (name.equals("action")) 1154 this.action = new ActionListEnumFactory().fromType(value); // Enumeration<ActionList> 1155 else if (name.equals("identifier")) 1156 this.getIdentifier().add(castToIdentifier(value)); 1157 else if (name.equals("ruleset")) 1158 this.ruleset = castToCoding(value); // Coding 1159 else if (name.equals("originalRuleset")) 1160 this.originalRuleset = castToCoding(value); // Coding 1161 else if (name.equals("created")) 1162 this.created = castToDateTime(value); // DateTimeType 1163 else if (name.equals("target")) 1164 this.target = castToReference(value); // Reference 1165 else if (name.equals("provider")) 1166 this.provider = castToReference(value); // Reference 1167 else if (name.equals("organization")) 1168 this.organization = castToReference(value); // Reference 1169 else if (name.equals("request")) 1170 this.request = castToReference(value); // Reference 1171 else if (name.equals("response")) 1172 this.response = castToReference(value); // Reference 1173 else if (name.equals("nullify")) 1174 this.nullify = castToBoolean(value); // BooleanType 1175 else if (name.equals("reference")) 1176 this.reference = castToString(value); // StringType 1177 else if (name.equals("item")) 1178 this.getItem().add((ItemsComponent) value); 1179 else if (name.equals("include")) 1180 this.getInclude().add(castToString(value)); 1181 else if (name.equals("exclude")) 1182 this.getExclude().add(castToString(value)); 1183 else if (name.equals("period")) 1184 this.period = castToPeriod(value); // Period 1185 else 1186 super.setProperty(name, value); 1187 } 1188 1189 @Override 1190 public Base addChild(String name) throws FHIRException { 1191 if (name.equals("action")) { 1192 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.action"); 1193 } 1194 else if (name.equals("identifier")) { 1195 return addIdentifier(); 1196 } 1197 else if (name.equals("ruleset")) { 1198 this.ruleset = new Coding(); 1199 return this.ruleset; 1200 } 1201 else if (name.equals("originalRuleset")) { 1202 this.originalRuleset = new Coding(); 1203 return this.originalRuleset; 1204 } 1205 else if (name.equals("created")) { 1206 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.created"); 1207 } 1208 else if (name.equals("target")) { 1209 this.target = new Reference(); 1210 return this.target; 1211 } 1212 else if (name.equals("provider")) { 1213 this.provider = new Reference(); 1214 return this.provider; 1215 } 1216 else if (name.equals("organization")) { 1217 this.organization = new Reference(); 1218 return this.organization; 1219 } 1220 else if (name.equals("request")) { 1221 this.request = new Reference(); 1222 return this.request; 1223 } 1224 else if (name.equals("response")) { 1225 this.response = new Reference(); 1226 return this.response; 1227 } 1228 else if (name.equals("nullify")) { 1229 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.nullify"); 1230 } 1231 else if (name.equals("reference")) { 1232 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.reference"); 1233 } 1234 else if (name.equals("item")) { 1235 return addItem(); 1236 } 1237 else if (name.equals("include")) { 1238 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.include"); 1239 } 1240 else if (name.equals("exclude")) { 1241 throw new FHIRException("Cannot call addChild on a primitive type ProcessRequest.exclude"); 1242 } 1243 else if (name.equals("period")) { 1244 this.period = new Period(); 1245 return this.period; 1246 } 1247 else 1248 return super.addChild(name); 1249 } 1250 1251 public String fhirType() { 1252 return "ProcessRequest"; 1253 1254 } 1255 1256 public ProcessRequest copy() { 1257 ProcessRequest dst = new ProcessRequest(); 1258 copyValues(dst); 1259 dst.action = action == null ? null : action.copy(); 1260 if (identifier != null) { 1261 dst.identifier = new ArrayList<Identifier>(); 1262 for (Identifier i : identifier) 1263 dst.identifier.add(i.copy()); 1264 }; 1265 dst.ruleset = ruleset == null ? null : ruleset.copy(); 1266 dst.originalRuleset = originalRuleset == null ? null : originalRuleset.copy(); 1267 dst.created = created == null ? null : created.copy(); 1268 dst.target = target == null ? null : target.copy(); 1269 dst.provider = provider == null ? null : provider.copy(); 1270 dst.organization = organization == null ? null : organization.copy(); 1271 dst.request = request == null ? null : request.copy(); 1272 dst.response = response == null ? null : response.copy(); 1273 dst.nullify = nullify == null ? null : nullify.copy(); 1274 dst.reference = reference == null ? null : reference.copy(); 1275 if (item != null) { 1276 dst.item = new ArrayList<ItemsComponent>(); 1277 for (ItemsComponent i : item) 1278 dst.item.add(i.copy()); 1279 }; 1280 if (include != null) { 1281 dst.include = new ArrayList<StringType>(); 1282 for (StringType i : include) 1283 dst.include.add(i.copy()); 1284 }; 1285 if (exclude != null) { 1286 dst.exclude = new ArrayList<StringType>(); 1287 for (StringType i : exclude) 1288 dst.exclude.add(i.copy()); 1289 }; 1290 dst.period = period == null ? null : period.copy(); 1291 return dst; 1292 } 1293 1294 protected ProcessRequest typedCopy() { 1295 return copy(); 1296 } 1297 1298 @Override 1299 public boolean equalsDeep(Base other) { 1300 if (!super.equalsDeep(other)) 1301 return false; 1302 if (!(other instanceof ProcessRequest)) 1303 return false; 1304 ProcessRequest o = (ProcessRequest) other; 1305 return compareDeep(action, o.action, true) && compareDeep(identifier, o.identifier, true) && compareDeep(ruleset, o.ruleset, true) 1306 && compareDeep(originalRuleset, o.originalRuleset, true) && compareDeep(created, o.created, true) 1307 && compareDeep(target, o.target, true) && compareDeep(provider, o.provider, true) && compareDeep(organization, o.organization, true) 1308 && compareDeep(request, o.request, true) && compareDeep(response, o.response, true) && compareDeep(nullify, o.nullify, true) 1309 && compareDeep(reference, o.reference, true) && compareDeep(item, o.item, true) && compareDeep(include, o.include, true) 1310 && compareDeep(exclude, o.exclude, true) && compareDeep(period, o.period, true); 1311 } 1312 1313 @Override 1314 public boolean equalsShallow(Base other) { 1315 if (!super.equalsShallow(other)) 1316 return false; 1317 if (!(other instanceof ProcessRequest)) 1318 return false; 1319 ProcessRequest o = (ProcessRequest) other; 1320 return compareValues(action, o.action, true) && compareValues(created, o.created, true) && compareValues(nullify, o.nullify, true) 1321 && compareValues(reference, o.reference, true) && compareValues(include, o.include, true) && compareValues(exclude, o.exclude, true) 1322 ; 1323 } 1324 1325 public boolean isEmpty() { 1326 return super.isEmpty() && (action == null || action.isEmpty()) && (identifier == null || identifier.isEmpty()) 1327 && (ruleset == null || ruleset.isEmpty()) && (originalRuleset == null || originalRuleset.isEmpty()) 1328 && (created == null || created.isEmpty()) && (target == null || target.isEmpty()) && (provider == null || provider.isEmpty()) 1329 && (organization == null || organization.isEmpty()) && (request == null || request.isEmpty()) 1330 && (response == null || response.isEmpty()) && (nullify == null || nullify.isEmpty()) && (reference == null || reference.isEmpty()) 1331 && (item == null || item.isEmpty()) && (include == null || include.isEmpty()) && (exclude == null || exclude.isEmpty()) 1332 && (period == null || period.isEmpty()); 1333 } 1334 1335 @Override 1336 public ResourceType getResourceType() { 1337 return ResourceType.ProcessRequest; 1338 } 1339 1340 @SearchParamDefinition(name="identifier", path="ProcessRequest.identifier", description="The business identifier of the ProcessRequest", type="token" ) 1341 public static final String SP_IDENTIFIER = "identifier"; 1342 @SearchParamDefinition(name="provider", path="ProcessRequest.provider", description="The provider who regenerated this request", type="reference" ) 1343 public static final String SP_PROVIDER = "provider"; 1344 @SearchParamDefinition(name="organization", path="ProcessRequest.organization", description="The organization who generated this request", type="reference" ) 1345 public static final String SP_ORGANIZATION = "organization"; 1346 @SearchParamDefinition(name="action", path="ProcessRequest.action", description="The action requested by this resource", type="token" ) 1347 public static final String SP_ACTION = "action"; 1348 1349} 1350