
001package org.hl7.fhir.r5.model; 002 003 004/* 005 Copyright (c) 2011+, HL7, Inc. 006 All rights reserved. 007 008 Redistribution and use in source and binary forms, with or without modification, \ 009 are permitted provided that the following conditions are met: 010 011 * Redistributions of source code must retain the above copyright notice, this \ 012 list of conditions and the following disclaimer. 013 * Redistributions in binary form must reproduce the above copyright notice, \ 014 this list of conditions and the following disclaimer in the documentation \ 015 and/or other materials provided with the distribution. 016 * Neither the name of HL7 nor the names of its contributors may be used to 017 endorse or promote products derived from this software without specific 018 prior written permission. 019 020 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS \"AS IS\" AND \ 021 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED \ 022 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. \ 023 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, \ 024 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT \ 025 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR \ 026 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, \ 027 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) \ 028 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE \ 029 POSSIBILITY OF SUCH DAMAGE. 030 */ 031 032// Generated on Sat, Nov 5, 2022 10:47+1100 for FHIR v5.0.0-ballot 033 034import java.util.ArrayList; 035import java.util.Date; 036import java.util.List; 037import org.hl7.fhir.utilities.Utilities; 038import org.hl7.fhir.r5.model.Enumerations.*; 039import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 040import org.hl7.fhir.exceptions.FHIRException; 041import org.hl7.fhir.instance.model.api.ICompositeType; 042import ca.uhn.fhir.model.api.annotation.ResourceDef; 043import ca.uhn.fhir.model.api.annotation.SearchParamDefinition; 044import org.hl7.fhir.instance.model.api.IBaseBackboneElement; 045import ca.uhn.fhir.model.api.annotation.Child; 046import ca.uhn.fhir.model.api.annotation.ChildOrder; 047import ca.uhn.fhir.model.api.annotation.Description; 048import ca.uhn.fhir.model.api.annotation.Block; 049 050/** 051 * The Citation Resource enables reference to any knowledge artifact for purposes of identification and attribution. The Citation Resource supports existing reference structures and developing publication practices such as versioning, expressing complex contributorship roles, and referencing computable resources. 052 */ 053@ResourceDef(name="Citation", profile="http://hl7.org/fhir/StructureDefinition/Citation") 054public class Citation extends MetadataResource { 055 056 public enum RelatedArtifactTypeExpanded { 057 /** 058 * Additional documentation for the knowledge resource. This would include additional instructions on usage as well as additional information on clinical context or appropriateness. 059 */ 060 DOCUMENTATION, 061 /** 062 * The target artifact is a summary of the justification for the knowledge resource including supporting evidence, relevant guidelines, or other clinically important information. This information is intended to provide a way to make the justification for the knowledge resource available to the consumer of interventions or results produced by the knowledge resource. 063 */ 064 JUSTIFICATION, 065 /** 066 * Bibliographic citation for papers, references, or other relevant material for the knowledge resource. This is intended to allow for citation of related material, but that was not necessarily specifically prepared in connection with this knowledge resource. 067 */ 068 CITATION, 069 /** 070 * The previous version of the knowledge artifact, used to establish an ordering of versions of an artifact, independent of the status of each version. 071 */ 072 PREDECESSOR, 073 /** 074 * The subsequent version of the knowledge artfact, used to establish an ordering of versions of an artifact, independent of the status of each version. 075 */ 076 SUCCESSOR, 077 /** 078 * This artifact is derived from the target artifact. This is intended to capture the relationship in which a particular knowledge resource is based on the content of another artifact, but is modified to capture either a different set of overall requirements, or a more specific set of requirements such as those involved in a particular institution or clinical setting. The artifact may be derived from one or more target artifacts. 079 */ 080 DERIVEDFROM, 081 /** 082 * This artifact depends on the target artifact. There is a requirement to use the target artifact in the creation or interpretation of this artifact. 083 */ 084 DEPENDSON, 085 /** 086 * This artifact is composed of the target artifact. This artifact is constructed with the target artifact as a component. The target artifact is a part of this artifact. (A dataset is composed of data.). 087 */ 088 COMPOSEDOF, 089 /** 090 * This artifact is a part of the target artifact. The target artifact is composed of this artifact (and possibly other artifacts). 091 */ 092 PARTOF, 093 /** 094 * This artifact amends or changes the target artifact. This artifact adds additional information that is functionally expected to replace information in the target artifact. This artifact replaces a part but not all of the target artifact. 095 */ 096 AMENDS, 097 /** 098 * This artifact is amended with or changed by the target artifact. There is information in this artifact that should be functionally replaced with information in the target artifact. 099 */ 100 AMENDEDWITH, 101 /** 102 * This artifact adds additional information to the target artifact. The additional information does not replace or change information in the target artifact. 103 */ 104 APPENDS, 105 /** 106 * This artifact has additional information in the target artifact. 107 */ 108 APPENDEDWITH, 109 /** 110 * This artifact cites the target artifact. This may be a bibliographic citation for papers, references, or other relevant material for the knowledge resource. This is intended to allow for citation of related material, but that was not necessarily specifically prepared in connection with this knowledge resource. 111 */ 112 CITES, 113 /** 114 * This artifact is cited by the target artifact. 115 */ 116 CITEDBY, 117 /** 118 * This artifact contains comments about the target artifact. 119 */ 120 COMMENTSON, 121 /** 122 * This artifact has comments about it in the target artifact. The type of comments may be expressed in the targetClassifier element such as reply, review, editorial, feedback, solicited, unsolicited, structured, unstructured. 123 */ 124 COMMENTIN, 125 /** 126 * This artifact is a container in which the target artifact is contained. A container is a data structure whose instances are collections of other objects. (A database contains the dataset.). 127 */ 128 CONTAINS, 129 /** 130 * This artifact is contained in the target artifact. The target artifact is a data structure whose instances are collections of other objects. 131 */ 132 CONTAINEDIN, 133 /** 134 * This artifact identifies errors and replacement content for the target artifact. 135 */ 136 CORRECTS, 137 /** 138 * This artifact has corrections to it in the target artifact. The target artifact identifies errors and replacement content for this artifact. 139 */ 140 CORRECTIONIN, 141 /** 142 * This artifact replaces or supersedes the target artifact. The target artifact may be considered deprecated. 143 */ 144 REPLACES, 145 /** 146 * This artifact is replaced with or superseded by the target artifact. This artifact may be considered deprecated. 147 */ 148 REPLACEDWITH, 149 /** 150 * This artifact retracts the target artifact. The content that was published in the target artifact should be considered removed from publication and should no longer be considered part of the public record. 151 */ 152 RETRACTS, 153 /** 154 * This artifact is retracted by the target artifact. The content that was published in this artifact should be considered removed from publication and should no longer be considered part of the public record. 155 */ 156 RETRACTEDBY, 157 /** 158 * This artifact is a signature of the target artifact. 159 */ 160 SIGNS, 161 /** 162 * This artifact has characteristics in common with the target artifact. This relationship may be used in systems to ?deduplicate? knowledge artifacts from different sources, or in systems to show ?similar items?. 163 */ 164 SIMILARTO, 165 /** 166 * This artifact provides additional support for the target artifact. The type of support is not documentation as it does not describe, explain, or instruct regarding the target artifact. 167 */ 168 SUPPORTS, 169 /** 170 * The target artifact contains additional information related to the knowledge artifact but is not documentation as the additional information does not describe, explain, or instruct regarding the knowledge artifact content or application. This could include an associated dataset. 171 */ 172 SUPPORTEDWITH, 173 /** 174 * This artifact was generated by transforming the target artifact (e.g., format or language conversion). This is intended to capture the relationship in which a particular knowledge resource is based on the content of another artifact, but changes are only apparent in form and there is only one target artifact with the ?transforms? relationship type. 175 */ 176 TRANSFORMS, 177 /** 178 * This artifact was transformed into the target artifact (e.g., by format or language conversion). 179 */ 180 TRANSFORMEDINTO, 181 /** 182 * This artifact was generated by transforming a related artifact (e.g., format or language conversion), noted separately with the ?transforms? relationship type. This transformation used the target artifact to inform the transformation. The target artifact may be a conversion script or translation guide. 183 */ 184 TRANSFORMEDWITH, 185 /** 186 * This artifact provides additional documentation for the target artifact. This could include additional instructions on usage as well as additional information on clinical context or appropriateness. 187 */ 188 DOCUMENTS, 189 /** 190 * The target artifact is a precise description of a concept in this artifact. This may be used when the RelatedArtifact datatype is used in elements contained in this artifact. 191 */ 192 SPECIFICATIONOF, 193 /** 194 * This artifact was created with the target artifact. The target artifact is a tool or support material used in the creation of the artifact, and not content that the artifact was derived from. 195 */ 196 CREATEDWITH, 197 /** 198 * The related artifact is the citation for this artifact. 199 */ 200 CITEAS, 201 /** 202 * A copy of the artifact in a publication with a different artifact identifier. 203 */ 204 REPRINT, 205 /** 206 * The original version of record for which the current artifact is a copy. 207 */ 208 REPRINTOF, 209 /** 210 * added to help the parsers with the generic types 211 */ 212 NULL; 213 public static RelatedArtifactTypeExpanded fromCode(String codeString) throws FHIRException { 214 if (codeString == null || "".equals(codeString)) 215 return null; 216 if ("documentation".equals(codeString)) 217 return DOCUMENTATION; 218 if ("justification".equals(codeString)) 219 return JUSTIFICATION; 220 if ("citation".equals(codeString)) 221 return CITATION; 222 if ("predecessor".equals(codeString)) 223 return PREDECESSOR; 224 if ("successor".equals(codeString)) 225 return SUCCESSOR; 226 if ("derived-from".equals(codeString)) 227 return DERIVEDFROM; 228 if ("depends-on".equals(codeString)) 229 return DEPENDSON; 230 if ("composed-of".equals(codeString)) 231 return COMPOSEDOF; 232 if ("part-of".equals(codeString)) 233 return PARTOF; 234 if ("amends".equals(codeString)) 235 return AMENDS; 236 if ("amended-with".equals(codeString)) 237 return AMENDEDWITH; 238 if ("appends".equals(codeString)) 239 return APPENDS; 240 if ("appended-with".equals(codeString)) 241 return APPENDEDWITH; 242 if ("cites".equals(codeString)) 243 return CITES; 244 if ("cited-by".equals(codeString)) 245 return CITEDBY; 246 if ("comments-on".equals(codeString)) 247 return COMMENTSON; 248 if ("comment-in".equals(codeString)) 249 return COMMENTIN; 250 if ("contains".equals(codeString)) 251 return CONTAINS; 252 if ("contained-in".equals(codeString)) 253 return CONTAINEDIN; 254 if ("corrects".equals(codeString)) 255 return CORRECTS; 256 if ("correction-in".equals(codeString)) 257 return CORRECTIONIN; 258 if ("replaces".equals(codeString)) 259 return REPLACES; 260 if ("replaced-with".equals(codeString)) 261 return REPLACEDWITH; 262 if ("retracts".equals(codeString)) 263 return RETRACTS; 264 if ("retracted-by".equals(codeString)) 265 return RETRACTEDBY; 266 if ("signs".equals(codeString)) 267 return SIGNS; 268 if ("similar-to".equals(codeString)) 269 return SIMILARTO; 270 if ("supports".equals(codeString)) 271 return SUPPORTS; 272 if ("supported-with".equals(codeString)) 273 return SUPPORTEDWITH; 274 if ("transforms".equals(codeString)) 275 return TRANSFORMS; 276 if ("transformed-into".equals(codeString)) 277 return TRANSFORMEDINTO; 278 if ("transformed-with".equals(codeString)) 279 return TRANSFORMEDWITH; 280 if ("documents".equals(codeString)) 281 return DOCUMENTS; 282 if ("specification-of".equals(codeString)) 283 return SPECIFICATIONOF; 284 if ("created-with".equals(codeString)) 285 return CREATEDWITH; 286 if ("cite-as".equals(codeString)) 287 return CITEAS; 288 if ("reprint".equals(codeString)) 289 return REPRINT; 290 if ("reprint-of".equals(codeString)) 291 return REPRINTOF; 292 if (Configuration.isAcceptInvalidEnums()) 293 return null; 294 else 295 throw new FHIRException("Unknown RelatedArtifactTypeExpanded code '"+codeString+"'"); 296 } 297 public String toCode() { 298 switch (this) { 299 case DOCUMENTATION: return "documentation"; 300 case JUSTIFICATION: return "justification"; 301 case CITATION: return "citation"; 302 case PREDECESSOR: return "predecessor"; 303 case SUCCESSOR: return "successor"; 304 case DERIVEDFROM: return "derived-from"; 305 case DEPENDSON: return "depends-on"; 306 case COMPOSEDOF: return "composed-of"; 307 case PARTOF: return "part-of"; 308 case AMENDS: return "amends"; 309 case AMENDEDWITH: return "amended-with"; 310 case APPENDS: return "appends"; 311 case APPENDEDWITH: return "appended-with"; 312 case CITES: return "cites"; 313 case CITEDBY: return "cited-by"; 314 case COMMENTSON: return "comments-on"; 315 case COMMENTIN: return "comment-in"; 316 case CONTAINS: return "contains"; 317 case CONTAINEDIN: return "contained-in"; 318 case CORRECTS: return "corrects"; 319 case CORRECTIONIN: return "correction-in"; 320 case REPLACES: return "replaces"; 321 case REPLACEDWITH: return "replaced-with"; 322 case RETRACTS: return "retracts"; 323 case RETRACTEDBY: return "retracted-by"; 324 case SIGNS: return "signs"; 325 case SIMILARTO: return "similar-to"; 326 case SUPPORTS: return "supports"; 327 case SUPPORTEDWITH: return "supported-with"; 328 case TRANSFORMS: return "transforms"; 329 case TRANSFORMEDINTO: return "transformed-into"; 330 case TRANSFORMEDWITH: return "transformed-with"; 331 case DOCUMENTS: return "documents"; 332 case SPECIFICATIONOF: return "specification-of"; 333 case CREATEDWITH: return "created-with"; 334 case CITEAS: return "cite-as"; 335 case REPRINT: return "reprint"; 336 case REPRINTOF: return "reprint-of"; 337 case NULL: return null; 338 default: return "?"; 339 } 340 } 341 public String getSystem() { 342 switch (this) { 343 case DOCUMENTATION: return "http://hl7.org/fhir/related-artifact-type"; 344 case JUSTIFICATION: return "http://hl7.org/fhir/related-artifact-type"; 345 case CITATION: return "http://hl7.org/fhir/related-artifact-type"; 346 case PREDECESSOR: return "http://hl7.org/fhir/related-artifact-type"; 347 case SUCCESSOR: return "http://hl7.org/fhir/related-artifact-type"; 348 case DERIVEDFROM: return "http://hl7.org/fhir/related-artifact-type"; 349 case DEPENDSON: return "http://hl7.org/fhir/related-artifact-type"; 350 case COMPOSEDOF: return "http://hl7.org/fhir/related-artifact-type"; 351 case PARTOF: return "http://hl7.org/fhir/related-artifact-type"; 352 case AMENDS: return "http://hl7.org/fhir/related-artifact-type"; 353 case AMENDEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 354 case APPENDS: return "http://hl7.org/fhir/related-artifact-type"; 355 case APPENDEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 356 case CITES: return "http://hl7.org/fhir/related-artifact-type"; 357 case CITEDBY: return "http://hl7.org/fhir/related-artifact-type"; 358 case COMMENTSON: return "http://hl7.org/fhir/related-artifact-type"; 359 case COMMENTIN: return "http://hl7.org/fhir/related-artifact-type"; 360 case CONTAINS: return "http://hl7.org/fhir/related-artifact-type"; 361 case CONTAINEDIN: return "http://hl7.org/fhir/related-artifact-type"; 362 case CORRECTS: return "http://hl7.org/fhir/related-artifact-type"; 363 case CORRECTIONIN: return "http://hl7.org/fhir/related-artifact-type"; 364 case REPLACES: return "http://hl7.org/fhir/related-artifact-type"; 365 case REPLACEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 366 case RETRACTS: return "http://hl7.org/fhir/related-artifact-type"; 367 case RETRACTEDBY: return "http://hl7.org/fhir/related-artifact-type"; 368 case SIGNS: return "http://hl7.org/fhir/related-artifact-type"; 369 case SIMILARTO: return "http://hl7.org/fhir/related-artifact-type"; 370 case SUPPORTS: return "http://hl7.org/fhir/related-artifact-type"; 371 case SUPPORTEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 372 case TRANSFORMS: return "http://hl7.org/fhir/related-artifact-type"; 373 case TRANSFORMEDINTO: return "http://hl7.org/fhir/related-artifact-type"; 374 case TRANSFORMEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 375 case DOCUMENTS: return "http://hl7.org/fhir/related-artifact-type"; 376 case SPECIFICATIONOF: return "http://hl7.org/fhir/related-artifact-type"; 377 case CREATEDWITH: return "http://hl7.org/fhir/related-artifact-type"; 378 case CITEAS: return "http://hl7.org/fhir/related-artifact-type"; 379 case REPRINT: return "http://terminology.hl7.org/CodeSystem/related-artifact-type-expanded"; 380 case REPRINTOF: return "http://terminology.hl7.org/CodeSystem/related-artifact-type-expanded"; 381 case NULL: return null; 382 default: return "?"; 383 } 384 } 385 public String getDefinition() { 386 switch (this) { 387 case DOCUMENTATION: return "Additional documentation for the knowledge resource. This would include additional instructions on usage as well as additional information on clinical context or appropriateness."; 388 case JUSTIFICATION: return "The target artifact is a summary of the justification for the knowledge resource including supporting evidence, relevant guidelines, or other clinically important information. This information is intended to provide a way to make the justification for the knowledge resource available to the consumer of interventions or results produced by the knowledge resource."; 389 case CITATION: return "Bibliographic citation for papers, references, or other relevant material for the knowledge resource. This is intended to allow for citation of related material, but that was not necessarily specifically prepared in connection with this knowledge resource."; 390 case PREDECESSOR: return "The previous version of the knowledge artifact, used to establish an ordering of versions of an artifact, independent of the status of each version."; 391 case SUCCESSOR: return "The subsequent version of the knowledge artfact, used to establish an ordering of versions of an artifact, independent of the status of each version."; 392 case DERIVEDFROM: return "This artifact is derived from the target artifact. This is intended to capture the relationship in which a particular knowledge resource is based on the content of another artifact, but is modified to capture either a different set of overall requirements, or a more specific set of requirements such as those involved in a particular institution or clinical setting. The artifact may be derived from one or more target artifacts."; 393 case DEPENDSON: return "This artifact depends on the target artifact. There is a requirement to use the target artifact in the creation or interpretation of this artifact."; 394 case COMPOSEDOF: return "This artifact is composed of the target artifact. This artifact is constructed with the target artifact as a component. The target artifact is a part of this artifact. (A dataset is composed of data.)."; 395 case PARTOF: return "This artifact is a part of the target artifact. The target artifact is composed of this artifact (and possibly other artifacts)."; 396 case AMENDS: return "This artifact amends or changes the target artifact. This artifact adds additional information that is functionally expected to replace information in the target artifact. This artifact replaces a part but not all of the target artifact."; 397 case AMENDEDWITH: return "This artifact is amended with or changed by the target artifact. There is information in this artifact that should be functionally replaced with information in the target artifact."; 398 case APPENDS: return "This artifact adds additional information to the target artifact. The additional information does not replace or change information in the target artifact."; 399 case APPENDEDWITH: return "This artifact has additional information in the target artifact."; 400 case CITES: return "This artifact cites the target artifact. This may be a bibliographic citation for papers, references, or other relevant material for the knowledge resource. This is intended to allow for citation of related material, but that was not necessarily specifically prepared in connection with this knowledge resource."; 401 case CITEDBY: return "This artifact is cited by the target artifact."; 402 case COMMENTSON: return "This artifact contains comments about the target artifact."; 403 case COMMENTIN: return "This artifact has comments about it in the target artifact. The type of comments may be expressed in the targetClassifier element such as reply, review, editorial, feedback, solicited, unsolicited, structured, unstructured."; 404 case CONTAINS: return "This artifact is a container in which the target artifact is contained. A container is a data structure whose instances are collections of other objects. (A database contains the dataset.)."; 405 case CONTAINEDIN: return "This artifact is contained in the target artifact. The target artifact is a data structure whose instances are collections of other objects."; 406 case CORRECTS: return "This artifact identifies errors and replacement content for the target artifact."; 407 case CORRECTIONIN: return "This artifact has corrections to it in the target artifact. The target artifact identifies errors and replacement content for this artifact."; 408 case REPLACES: return "This artifact replaces or supersedes the target artifact. The target artifact may be considered deprecated."; 409 case REPLACEDWITH: return "This artifact is replaced with or superseded by the target artifact. This artifact may be considered deprecated."; 410 case RETRACTS: return "This artifact retracts the target artifact. The content that was published in the target artifact should be considered removed from publication and should no longer be considered part of the public record."; 411 case RETRACTEDBY: return "This artifact is retracted by the target artifact. The content that was published in this artifact should be considered removed from publication and should no longer be considered part of the public record."; 412 case SIGNS: return "This artifact is a signature of the target artifact."; 413 case SIMILARTO: return "This artifact has characteristics in common with the target artifact. This relationship may be used in systems to ?deduplicate? knowledge artifacts from different sources, or in systems to show ?similar items?."; 414 case SUPPORTS: return "This artifact provides additional support for the target artifact. The type of support is not documentation as it does not describe, explain, or instruct regarding the target artifact."; 415 case SUPPORTEDWITH: return "The target artifact contains additional information related to the knowledge artifact but is not documentation as the additional information does not describe, explain, or instruct regarding the knowledge artifact content or application. This could include an associated dataset."; 416 case TRANSFORMS: return "This artifact was generated by transforming the target artifact (e.g., format or language conversion). This is intended to capture the relationship in which a particular knowledge resource is based on the content of another artifact, but changes are only apparent in form and there is only one target artifact with the ?transforms? relationship type."; 417 case TRANSFORMEDINTO: return "This artifact was transformed into the target artifact (e.g., by format or language conversion)."; 418 case TRANSFORMEDWITH: return "This artifact was generated by transforming a related artifact (e.g., format or language conversion), noted separately with the ?transforms? relationship type. This transformation used the target artifact to inform the transformation. The target artifact may be a conversion script or translation guide."; 419 case DOCUMENTS: return "This artifact provides additional documentation for the target artifact. This could include additional instructions on usage as well as additional information on clinical context or appropriateness."; 420 case SPECIFICATIONOF: return "The target artifact is a precise description of a concept in this artifact. This may be used when the RelatedArtifact datatype is used in elements contained in this artifact."; 421 case CREATEDWITH: return "This artifact was created with the target artifact. The target artifact is a tool or support material used in the creation of the artifact, and not content that the artifact was derived from."; 422 case CITEAS: return "The related artifact is the citation for this artifact."; 423 case REPRINT: return "A copy of the artifact in a publication with a different artifact identifier."; 424 case REPRINTOF: return "The original version of record for which the current artifact is a copy."; 425 case NULL: return null; 426 default: return "?"; 427 } 428 } 429 public String getDisplay() { 430 switch (this) { 431 case DOCUMENTATION: return "Documentation"; 432 case JUSTIFICATION: return "Justification"; 433 case CITATION: return "Citation"; 434 case PREDECESSOR: return "Predecessor"; 435 case SUCCESSOR: return "Successor"; 436 case DERIVEDFROM: return "Derived From"; 437 case DEPENDSON: return "Depends On"; 438 case COMPOSEDOF: return "Composed Of"; 439 case PARTOF: return "Part Of"; 440 case AMENDS: return "Amends"; 441 case AMENDEDWITH: return "Amended With"; 442 case APPENDS: return "Appends"; 443 case APPENDEDWITH: return "Appended With"; 444 case CITES: return "Cites"; 445 case CITEDBY: return "Cited By"; 446 case COMMENTSON: return "Is Comment On"; 447 case COMMENTIN: return "Has Comment In"; 448 case CONTAINS: return "Contains"; 449 case CONTAINEDIN: return "Contained In"; 450 case CORRECTS: return "Corrects"; 451 case CORRECTIONIN: return "Correction In"; 452 case REPLACES: return "Replaces"; 453 case REPLACEDWITH: return "Replaced With"; 454 case RETRACTS: return "Retracts"; 455 case RETRACTEDBY: return "Retracted By"; 456 case SIGNS: return "Signs"; 457 case SIMILARTO: return "Similar To"; 458 case SUPPORTS: return "Supports"; 459 case SUPPORTEDWITH: return "Supported With"; 460 case TRANSFORMS: return "Transforms"; 461 case TRANSFORMEDINTO: return "Transformed Into"; 462 case TRANSFORMEDWITH: return "Transformed With"; 463 case DOCUMENTS: return "Documents"; 464 case SPECIFICATIONOF: return "Specification Of"; 465 case CREATEDWITH: return "Created With"; 466 case CITEAS: return "Cite As"; 467 case REPRINT: return "Reprint"; 468 case REPRINTOF: return "Reprint Of"; 469 case NULL: return null; 470 default: return "?"; 471 } 472 } 473 } 474 475 public static class RelatedArtifactTypeExpandedEnumFactory implements EnumFactory<RelatedArtifactTypeExpanded> { 476 public RelatedArtifactTypeExpanded fromCode(String codeString) throws IllegalArgumentException { 477 if (codeString == null || "".equals(codeString)) 478 if (codeString == null || "".equals(codeString)) 479 return null; 480 if ("documentation".equals(codeString)) 481 return RelatedArtifactTypeExpanded.DOCUMENTATION; 482 if ("justification".equals(codeString)) 483 return RelatedArtifactTypeExpanded.JUSTIFICATION; 484 if ("citation".equals(codeString)) 485 return RelatedArtifactTypeExpanded.CITATION; 486 if ("predecessor".equals(codeString)) 487 return RelatedArtifactTypeExpanded.PREDECESSOR; 488 if ("successor".equals(codeString)) 489 return RelatedArtifactTypeExpanded.SUCCESSOR; 490 if ("derived-from".equals(codeString)) 491 return RelatedArtifactTypeExpanded.DERIVEDFROM; 492 if ("depends-on".equals(codeString)) 493 return RelatedArtifactTypeExpanded.DEPENDSON; 494 if ("composed-of".equals(codeString)) 495 return RelatedArtifactTypeExpanded.COMPOSEDOF; 496 if ("part-of".equals(codeString)) 497 return RelatedArtifactTypeExpanded.PARTOF; 498 if ("amends".equals(codeString)) 499 return RelatedArtifactTypeExpanded.AMENDS; 500 if ("amended-with".equals(codeString)) 501 return RelatedArtifactTypeExpanded.AMENDEDWITH; 502 if ("appends".equals(codeString)) 503 return RelatedArtifactTypeExpanded.APPENDS; 504 if ("appended-with".equals(codeString)) 505 return RelatedArtifactTypeExpanded.APPENDEDWITH; 506 if ("cites".equals(codeString)) 507 return RelatedArtifactTypeExpanded.CITES; 508 if ("cited-by".equals(codeString)) 509 return RelatedArtifactTypeExpanded.CITEDBY; 510 if ("comments-on".equals(codeString)) 511 return RelatedArtifactTypeExpanded.COMMENTSON; 512 if ("comment-in".equals(codeString)) 513 return RelatedArtifactTypeExpanded.COMMENTIN; 514 if ("contains".equals(codeString)) 515 return RelatedArtifactTypeExpanded.CONTAINS; 516 if ("contained-in".equals(codeString)) 517 return RelatedArtifactTypeExpanded.CONTAINEDIN; 518 if ("corrects".equals(codeString)) 519 return RelatedArtifactTypeExpanded.CORRECTS; 520 if ("correction-in".equals(codeString)) 521 return RelatedArtifactTypeExpanded.CORRECTIONIN; 522 if ("replaces".equals(codeString)) 523 return RelatedArtifactTypeExpanded.REPLACES; 524 if ("replaced-with".equals(codeString)) 525 return RelatedArtifactTypeExpanded.REPLACEDWITH; 526 if ("retracts".equals(codeString)) 527 return RelatedArtifactTypeExpanded.RETRACTS; 528 if ("retracted-by".equals(codeString)) 529 return RelatedArtifactTypeExpanded.RETRACTEDBY; 530 if ("signs".equals(codeString)) 531 return RelatedArtifactTypeExpanded.SIGNS; 532 if ("similar-to".equals(codeString)) 533 return RelatedArtifactTypeExpanded.SIMILARTO; 534 if ("supports".equals(codeString)) 535 return RelatedArtifactTypeExpanded.SUPPORTS; 536 if ("supported-with".equals(codeString)) 537 return RelatedArtifactTypeExpanded.SUPPORTEDWITH; 538 if ("transforms".equals(codeString)) 539 return RelatedArtifactTypeExpanded.TRANSFORMS; 540 if ("transformed-into".equals(codeString)) 541 return RelatedArtifactTypeExpanded.TRANSFORMEDINTO; 542 if ("transformed-with".equals(codeString)) 543 return RelatedArtifactTypeExpanded.TRANSFORMEDWITH; 544 if ("documents".equals(codeString)) 545 return RelatedArtifactTypeExpanded.DOCUMENTS; 546 if ("specification-of".equals(codeString)) 547 return RelatedArtifactTypeExpanded.SPECIFICATIONOF; 548 if ("created-with".equals(codeString)) 549 return RelatedArtifactTypeExpanded.CREATEDWITH; 550 if ("cite-as".equals(codeString)) 551 return RelatedArtifactTypeExpanded.CITEAS; 552 if ("reprint".equals(codeString)) 553 return RelatedArtifactTypeExpanded.REPRINT; 554 if ("reprint-of".equals(codeString)) 555 return RelatedArtifactTypeExpanded.REPRINTOF; 556 throw new IllegalArgumentException("Unknown RelatedArtifactTypeExpanded code '"+codeString+"'"); 557 } 558 public Enumeration<RelatedArtifactTypeExpanded> fromType(Base code) throws FHIRException { 559 if (code == null) 560 return null; 561 if (code.isEmpty()) 562 return new Enumeration<RelatedArtifactTypeExpanded>(this); 563 String codeString = ((PrimitiveType) code).asStringValue(); 564 if (codeString == null || "".equals(codeString)) 565 return null; 566 if ("documentation".equals(codeString)) 567 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.DOCUMENTATION); 568 if ("justification".equals(codeString)) 569 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.JUSTIFICATION); 570 if ("citation".equals(codeString)) 571 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CITATION); 572 if ("predecessor".equals(codeString)) 573 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.PREDECESSOR); 574 if ("successor".equals(codeString)) 575 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SUCCESSOR); 576 if ("derived-from".equals(codeString)) 577 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.DERIVEDFROM); 578 if ("depends-on".equals(codeString)) 579 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.DEPENDSON); 580 if ("composed-of".equals(codeString)) 581 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.COMPOSEDOF); 582 if ("part-of".equals(codeString)) 583 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.PARTOF); 584 if ("amends".equals(codeString)) 585 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.AMENDS); 586 if ("amended-with".equals(codeString)) 587 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.AMENDEDWITH); 588 if ("appends".equals(codeString)) 589 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.APPENDS); 590 if ("appended-with".equals(codeString)) 591 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.APPENDEDWITH); 592 if ("cites".equals(codeString)) 593 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CITES); 594 if ("cited-by".equals(codeString)) 595 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CITEDBY); 596 if ("comments-on".equals(codeString)) 597 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.COMMENTSON); 598 if ("comment-in".equals(codeString)) 599 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.COMMENTIN); 600 if ("contains".equals(codeString)) 601 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CONTAINS); 602 if ("contained-in".equals(codeString)) 603 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CONTAINEDIN); 604 if ("corrects".equals(codeString)) 605 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CORRECTS); 606 if ("correction-in".equals(codeString)) 607 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CORRECTIONIN); 608 if ("replaces".equals(codeString)) 609 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.REPLACES); 610 if ("replaced-with".equals(codeString)) 611 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.REPLACEDWITH); 612 if ("retracts".equals(codeString)) 613 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.RETRACTS); 614 if ("retracted-by".equals(codeString)) 615 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.RETRACTEDBY); 616 if ("signs".equals(codeString)) 617 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SIGNS); 618 if ("similar-to".equals(codeString)) 619 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SIMILARTO); 620 if ("supports".equals(codeString)) 621 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SUPPORTS); 622 if ("supported-with".equals(codeString)) 623 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SUPPORTEDWITH); 624 if ("transforms".equals(codeString)) 625 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.TRANSFORMS); 626 if ("transformed-into".equals(codeString)) 627 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.TRANSFORMEDINTO); 628 if ("transformed-with".equals(codeString)) 629 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.TRANSFORMEDWITH); 630 if ("documents".equals(codeString)) 631 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.DOCUMENTS); 632 if ("specification-of".equals(codeString)) 633 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.SPECIFICATIONOF); 634 if ("created-with".equals(codeString)) 635 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CREATEDWITH); 636 if ("cite-as".equals(codeString)) 637 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.CITEAS); 638 if ("reprint".equals(codeString)) 639 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.REPRINT); 640 if ("reprint-of".equals(codeString)) 641 return new Enumeration<RelatedArtifactTypeExpanded>(this, RelatedArtifactTypeExpanded.REPRINTOF); 642 throw new FHIRException("Unknown RelatedArtifactTypeExpanded code '"+codeString+"'"); 643 } 644 public String toCode(RelatedArtifactTypeExpanded code) { 645 if (code == RelatedArtifactTypeExpanded.DOCUMENTATION) 646 return "documentation"; 647 if (code == RelatedArtifactTypeExpanded.JUSTIFICATION) 648 return "justification"; 649 if (code == RelatedArtifactTypeExpanded.CITATION) 650 return "citation"; 651 if (code == RelatedArtifactTypeExpanded.PREDECESSOR) 652 return "predecessor"; 653 if (code == RelatedArtifactTypeExpanded.SUCCESSOR) 654 return "successor"; 655 if (code == RelatedArtifactTypeExpanded.DERIVEDFROM) 656 return "derived-from"; 657 if (code == RelatedArtifactTypeExpanded.DEPENDSON) 658 return "depends-on"; 659 if (code == RelatedArtifactTypeExpanded.COMPOSEDOF) 660 return "composed-of"; 661 if (code == RelatedArtifactTypeExpanded.PARTOF) 662 return "part-of"; 663 if (code == RelatedArtifactTypeExpanded.AMENDS) 664 return "amends"; 665 if (code == RelatedArtifactTypeExpanded.AMENDEDWITH) 666 return "amended-with"; 667 if (code == RelatedArtifactTypeExpanded.APPENDS) 668 return "appends"; 669 if (code == RelatedArtifactTypeExpanded.APPENDEDWITH) 670 return "appended-with"; 671 if (code == RelatedArtifactTypeExpanded.CITES) 672 return "cites"; 673 if (code == RelatedArtifactTypeExpanded.CITEDBY) 674 return "cited-by"; 675 if (code == RelatedArtifactTypeExpanded.COMMENTSON) 676 return "comments-on"; 677 if (code == RelatedArtifactTypeExpanded.COMMENTIN) 678 return "comment-in"; 679 if (code == RelatedArtifactTypeExpanded.CONTAINS) 680 return "contains"; 681 if (code == RelatedArtifactTypeExpanded.CONTAINEDIN) 682 return "contained-in"; 683 if (code == RelatedArtifactTypeExpanded.CORRECTS) 684 return "corrects"; 685 if (code == RelatedArtifactTypeExpanded.CORRECTIONIN) 686 return "correction-in"; 687 if (code == RelatedArtifactTypeExpanded.REPLACES) 688 return "replaces"; 689 if (code == RelatedArtifactTypeExpanded.REPLACEDWITH) 690 return "replaced-with"; 691 if (code == RelatedArtifactTypeExpanded.RETRACTS) 692 return "retracts"; 693 if (code == RelatedArtifactTypeExpanded.RETRACTEDBY) 694 return "retracted-by"; 695 if (code == RelatedArtifactTypeExpanded.SIGNS) 696 return "signs"; 697 if (code == RelatedArtifactTypeExpanded.SIMILARTO) 698 return "similar-to"; 699 if (code == RelatedArtifactTypeExpanded.SUPPORTS) 700 return "supports"; 701 if (code == RelatedArtifactTypeExpanded.SUPPORTEDWITH) 702 return "supported-with"; 703 if (code == RelatedArtifactTypeExpanded.TRANSFORMS) 704 return "transforms"; 705 if (code == RelatedArtifactTypeExpanded.TRANSFORMEDINTO) 706 return "transformed-into"; 707 if (code == RelatedArtifactTypeExpanded.TRANSFORMEDWITH) 708 return "transformed-with"; 709 if (code == RelatedArtifactTypeExpanded.DOCUMENTS) 710 return "documents"; 711 if (code == RelatedArtifactTypeExpanded.SPECIFICATIONOF) 712 return "specification-of"; 713 if (code == RelatedArtifactTypeExpanded.CREATEDWITH) 714 return "created-with"; 715 if (code == RelatedArtifactTypeExpanded.CITEAS) 716 return "cite-as"; 717 if (code == RelatedArtifactTypeExpanded.REPRINT) 718 return "reprint"; 719 if (code == RelatedArtifactTypeExpanded.REPRINTOF) 720 return "reprint-of"; 721 return "?"; 722 } 723 public String toSystem(RelatedArtifactTypeExpanded code) { 724 return code.getSystem(); 725 } 726 } 727 728 @Block() 729 public static class CitationSummaryComponent extends BackboneElement implements IBaseBackboneElement { 730 /** 731 * Format for display of the citation. 732 */ 733 @Child(name = "style", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 734 @Description(shortDefinition="Format for display of the citation", formalDefinition="Format for display of the citation." ) 735 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-summary-style") 736 protected CodeableConcept style; 737 738 /** 739 * The human-readable display of the citation. 740 */ 741 @Child(name = "text", type = {MarkdownType.class}, order=2, min=1, max=1, modifier=false, summary=true) 742 @Description(shortDefinition="The human-readable display of the citation", formalDefinition="The human-readable display of the citation." ) 743 protected MarkdownType text; 744 745 private static final long serialVersionUID = 123416446L; 746 747 /** 748 * Constructor 749 */ 750 public CitationSummaryComponent() { 751 super(); 752 } 753 754 /** 755 * Constructor 756 */ 757 public CitationSummaryComponent(String text) { 758 super(); 759 this.setText(text); 760 } 761 762 /** 763 * @return {@link #style} (Format for display of the citation.) 764 */ 765 public CodeableConcept getStyle() { 766 if (this.style == null) 767 if (Configuration.errorOnAutoCreate()) 768 throw new Error("Attempt to auto-create CitationSummaryComponent.style"); 769 else if (Configuration.doAutoCreate()) 770 this.style = new CodeableConcept(); // cc 771 return this.style; 772 } 773 774 public boolean hasStyle() { 775 return this.style != null && !this.style.isEmpty(); 776 } 777 778 /** 779 * @param value {@link #style} (Format for display of the citation.) 780 */ 781 public CitationSummaryComponent setStyle(CodeableConcept value) { 782 this.style = value; 783 return this; 784 } 785 786 /** 787 * @return {@link #text} (The human-readable display of the citation.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 788 */ 789 public MarkdownType getTextElement() { 790 if (this.text == null) 791 if (Configuration.errorOnAutoCreate()) 792 throw new Error("Attempt to auto-create CitationSummaryComponent.text"); 793 else if (Configuration.doAutoCreate()) 794 this.text = new MarkdownType(); // bb 795 return this.text; 796 } 797 798 public boolean hasTextElement() { 799 return this.text != null && !this.text.isEmpty(); 800 } 801 802 public boolean hasText() { 803 return this.text != null && !this.text.isEmpty(); 804 } 805 806 /** 807 * @param value {@link #text} (The human-readable display of the citation.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 808 */ 809 public CitationSummaryComponent setTextElement(MarkdownType value) { 810 this.text = value; 811 return this; 812 } 813 814 /** 815 * @return The human-readable display of the citation. 816 */ 817 public String getText() { 818 return this.text == null ? null : this.text.getValue(); 819 } 820 821 /** 822 * @param value The human-readable display of the citation. 823 */ 824 public CitationSummaryComponent setText(String value) { 825 if (this.text == null) 826 this.text = new MarkdownType(); 827 this.text.setValue(value); 828 return this; 829 } 830 831 protected void listChildren(List<Property> children) { 832 super.listChildren(children); 833 children.add(new Property("style", "CodeableConcept", "Format for display of the citation.", 0, 1, style)); 834 children.add(new Property("text", "markdown", "The human-readable display of the citation.", 0, 1, text)); 835 } 836 837 @Override 838 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 839 switch (_hash) { 840 case 109780401: /*style*/ return new Property("style", "CodeableConcept", "Format for display of the citation.", 0, 1, style); 841 case 3556653: /*text*/ return new Property("text", "markdown", "The human-readable display of the citation.", 0, 1, text); 842 default: return super.getNamedProperty(_hash, _name, _checkValid); 843 } 844 845 } 846 847 @Override 848 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 849 switch (hash) { 850 case 109780401: /*style*/ return this.style == null ? new Base[0] : new Base[] {this.style}; // CodeableConcept 851 case 3556653: /*text*/ return this.text == null ? new Base[0] : new Base[] {this.text}; // MarkdownType 852 default: return super.getProperty(hash, name, checkValid); 853 } 854 855 } 856 857 @Override 858 public Base setProperty(int hash, String name, Base value) throws FHIRException { 859 switch (hash) { 860 case 109780401: // style 861 this.style = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 862 return value; 863 case 3556653: // text 864 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 865 return value; 866 default: return super.setProperty(hash, name, value); 867 } 868 869 } 870 871 @Override 872 public Base setProperty(String name, Base value) throws FHIRException { 873 if (name.equals("style")) { 874 this.style = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 875 } else if (name.equals("text")) { 876 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 877 } else 878 return super.setProperty(name, value); 879 return value; 880 } 881 882 @Override 883 public Base makeProperty(int hash, String name) throws FHIRException { 884 switch (hash) { 885 case 109780401: return getStyle(); 886 case 3556653: return getTextElement(); 887 default: return super.makeProperty(hash, name); 888 } 889 890 } 891 892 @Override 893 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 894 switch (hash) { 895 case 109780401: /*style*/ return new String[] {"CodeableConcept"}; 896 case 3556653: /*text*/ return new String[] {"markdown"}; 897 default: return super.getTypesForProperty(hash, name); 898 } 899 900 } 901 902 @Override 903 public Base addChild(String name) throws FHIRException { 904 if (name.equals("style")) { 905 this.style = new CodeableConcept(); 906 return this.style; 907 } 908 else if (name.equals("text")) { 909 throw new FHIRException("Cannot call addChild on a primitive type Citation.summary.text"); 910 } 911 else 912 return super.addChild(name); 913 } 914 915 public CitationSummaryComponent copy() { 916 CitationSummaryComponent dst = new CitationSummaryComponent(); 917 copyValues(dst); 918 return dst; 919 } 920 921 public void copyValues(CitationSummaryComponent dst) { 922 super.copyValues(dst); 923 dst.style = style == null ? null : style.copy(); 924 dst.text = text == null ? null : text.copy(); 925 } 926 927 @Override 928 public boolean equalsDeep(Base other_) { 929 if (!super.equalsDeep(other_)) 930 return false; 931 if (!(other_ instanceof CitationSummaryComponent)) 932 return false; 933 CitationSummaryComponent o = (CitationSummaryComponent) other_; 934 return compareDeep(style, o.style, true) && compareDeep(text, o.text, true); 935 } 936 937 @Override 938 public boolean equalsShallow(Base other_) { 939 if (!super.equalsShallow(other_)) 940 return false; 941 if (!(other_ instanceof CitationSummaryComponent)) 942 return false; 943 CitationSummaryComponent o = (CitationSummaryComponent) other_; 944 return compareValues(text, o.text, true); 945 } 946 947 public boolean isEmpty() { 948 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(style, text); 949 } 950 951 public String fhirType() { 952 return "Citation.summary"; 953 954 } 955 956 } 957 958 @Block() 959 public static class CitationClassificationComponent extends BackboneElement implements IBaseBackboneElement { 960 /** 961 * The kind of classifier (e.g. publication type, keyword). 962 */ 963 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 964 @Description(shortDefinition="The kind of classifier (e.g. publication type, keyword)", formalDefinition="The kind of classifier (e.g. publication type, keyword)." ) 965 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-classification-type") 966 protected CodeableConcept type; 967 968 /** 969 * The specific classification value. 970 */ 971 @Child(name = "classifier", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 972 @Description(shortDefinition="The specific classification value", formalDefinition="The specific classification value." ) 973 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-artifact-classifier") 974 protected List<CodeableConcept> classifier; 975 976 private static final long serialVersionUID = -283121869L; 977 978 /** 979 * Constructor 980 */ 981 public CitationClassificationComponent() { 982 super(); 983 } 984 985 /** 986 * @return {@link #type} (The kind of classifier (e.g. publication type, keyword).) 987 */ 988 public CodeableConcept getType() { 989 if (this.type == null) 990 if (Configuration.errorOnAutoCreate()) 991 throw new Error("Attempt to auto-create CitationClassificationComponent.type"); 992 else if (Configuration.doAutoCreate()) 993 this.type = new CodeableConcept(); // cc 994 return this.type; 995 } 996 997 public boolean hasType() { 998 return this.type != null && !this.type.isEmpty(); 999 } 1000 1001 /** 1002 * @param value {@link #type} (The kind of classifier (e.g. publication type, keyword).) 1003 */ 1004 public CitationClassificationComponent setType(CodeableConcept value) { 1005 this.type = value; 1006 return this; 1007 } 1008 1009 /** 1010 * @return {@link #classifier} (The specific classification value.) 1011 */ 1012 public List<CodeableConcept> getClassifier() { 1013 if (this.classifier == null) 1014 this.classifier = new ArrayList<CodeableConcept>(); 1015 return this.classifier; 1016 } 1017 1018 /** 1019 * @return Returns a reference to <code>this</code> for easy method chaining 1020 */ 1021 public CitationClassificationComponent setClassifier(List<CodeableConcept> theClassifier) { 1022 this.classifier = theClassifier; 1023 return this; 1024 } 1025 1026 public boolean hasClassifier() { 1027 if (this.classifier == null) 1028 return false; 1029 for (CodeableConcept item : this.classifier) 1030 if (!item.isEmpty()) 1031 return true; 1032 return false; 1033 } 1034 1035 public CodeableConcept addClassifier() { //3 1036 CodeableConcept t = new CodeableConcept(); 1037 if (this.classifier == null) 1038 this.classifier = new ArrayList<CodeableConcept>(); 1039 this.classifier.add(t); 1040 return t; 1041 } 1042 1043 public CitationClassificationComponent addClassifier(CodeableConcept t) { //3 1044 if (t == null) 1045 return this; 1046 if (this.classifier == null) 1047 this.classifier = new ArrayList<CodeableConcept>(); 1048 this.classifier.add(t); 1049 return this; 1050 } 1051 1052 /** 1053 * @return The first repetition of repeating field {@link #classifier}, creating it if it does not already exist {3} 1054 */ 1055 public CodeableConcept getClassifierFirstRep() { 1056 if (getClassifier().isEmpty()) { 1057 addClassifier(); 1058 } 1059 return getClassifier().get(0); 1060 } 1061 1062 protected void listChildren(List<Property> children) { 1063 super.listChildren(children); 1064 children.add(new Property("type", "CodeableConcept", "The kind of classifier (e.g. publication type, keyword).", 0, 1, type)); 1065 children.add(new Property("classifier", "CodeableConcept", "The specific classification value.", 0, java.lang.Integer.MAX_VALUE, classifier)); 1066 } 1067 1068 @Override 1069 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1070 switch (_hash) { 1071 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The kind of classifier (e.g. publication type, keyword).", 0, 1, type); 1072 case -281470431: /*classifier*/ return new Property("classifier", "CodeableConcept", "The specific classification value.", 0, java.lang.Integer.MAX_VALUE, classifier); 1073 default: return super.getNamedProperty(_hash, _name, _checkValid); 1074 } 1075 1076 } 1077 1078 @Override 1079 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1080 switch (hash) { 1081 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 1082 case -281470431: /*classifier*/ return this.classifier == null ? new Base[0] : this.classifier.toArray(new Base[this.classifier.size()]); // CodeableConcept 1083 default: return super.getProperty(hash, name, checkValid); 1084 } 1085 1086 } 1087 1088 @Override 1089 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1090 switch (hash) { 1091 case 3575610: // type 1092 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1093 return value; 1094 case -281470431: // classifier 1095 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 1096 return value; 1097 default: return super.setProperty(hash, name, value); 1098 } 1099 1100 } 1101 1102 @Override 1103 public Base setProperty(String name, Base value) throws FHIRException { 1104 if (name.equals("type")) { 1105 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1106 } else if (name.equals("classifier")) { 1107 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); 1108 } else 1109 return super.setProperty(name, value); 1110 return value; 1111 } 1112 1113 @Override 1114 public Base makeProperty(int hash, String name) throws FHIRException { 1115 switch (hash) { 1116 case 3575610: return getType(); 1117 case -281470431: return addClassifier(); 1118 default: return super.makeProperty(hash, name); 1119 } 1120 1121 } 1122 1123 @Override 1124 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1125 switch (hash) { 1126 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 1127 case -281470431: /*classifier*/ return new String[] {"CodeableConcept"}; 1128 default: return super.getTypesForProperty(hash, name); 1129 } 1130 1131 } 1132 1133 @Override 1134 public Base addChild(String name) throws FHIRException { 1135 if (name.equals("type")) { 1136 this.type = new CodeableConcept(); 1137 return this.type; 1138 } 1139 else if (name.equals("classifier")) { 1140 return addClassifier(); 1141 } 1142 else 1143 return super.addChild(name); 1144 } 1145 1146 public CitationClassificationComponent copy() { 1147 CitationClassificationComponent dst = new CitationClassificationComponent(); 1148 copyValues(dst); 1149 return dst; 1150 } 1151 1152 public void copyValues(CitationClassificationComponent dst) { 1153 super.copyValues(dst); 1154 dst.type = type == null ? null : type.copy(); 1155 if (classifier != null) { 1156 dst.classifier = new ArrayList<CodeableConcept>(); 1157 for (CodeableConcept i : classifier) 1158 dst.classifier.add(i.copy()); 1159 }; 1160 } 1161 1162 @Override 1163 public boolean equalsDeep(Base other_) { 1164 if (!super.equalsDeep(other_)) 1165 return false; 1166 if (!(other_ instanceof CitationClassificationComponent)) 1167 return false; 1168 CitationClassificationComponent o = (CitationClassificationComponent) other_; 1169 return compareDeep(type, o.type, true) && compareDeep(classifier, o.classifier, true); 1170 } 1171 1172 @Override 1173 public boolean equalsShallow(Base other_) { 1174 if (!super.equalsShallow(other_)) 1175 return false; 1176 if (!(other_ instanceof CitationClassificationComponent)) 1177 return false; 1178 CitationClassificationComponent o = (CitationClassificationComponent) other_; 1179 return true; 1180 } 1181 1182 public boolean isEmpty() { 1183 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, classifier); 1184 } 1185 1186 public String fhirType() { 1187 return "Citation.classification"; 1188 1189 } 1190 1191 } 1192 1193 @Block() 1194 public static class CitationStatusDateComponent extends BackboneElement implements IBaseBackboneElement { 1195 /** 1196 * Classification of the status. 1197 */ 1198 @Child(name = "activity", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 1199 @Description(shortDefinition="Classification of the status", formalDefinition="Classification of the status." ) 1200 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-status-type") 1201 protected CodeableConcept activity; 1202 1203 /** 1204 * Either occurred or expected. 1205 */ 1206 @Child(name = "actual", type = {BooleanType.class}, order=2, min=0, max=1, modifier=false, summary=false) 1207 @Description(shortDefinition="Either occurred or expected", formalDefinition="Either occurred or expected." ) 1208 protected BooleanType actual; 1209 1210 /** 1211 * When the status started and/or ended. 1212 */ 1213 @Child(name = "period", type = {Period.class}, order=3, min=1, max=1, modifier=false, summary=false) 1214 @Description(shortDefinition="When the status started and/or ended", formalDefinition="When the status started and/or ended." ) 1215 protected Period period; 1216 1217 private static final long serialVersionUID = 1123586924L; 1218 1219 /** 1220 * Constructor 1221 */ 1222 public CitationStatusDateComponent() { 1223 super(); 1224 } 1225 1226 /** 1227 * Constructor 1228 */ 1229 public CitationStatusDateComponent(CodeableConcept activity, Period period) { 1230 super(); 1231 this.setActivity(activity); 1232 this.setPeriod(period); 1233 } 1234 1235 /** 1236 * @return {@link #activity} (Classification of the status.) 1237 */ 1238 public CodeableConcept getActivity() { 1239 if (this.activity == null) 1240 if (Configuration.errorOnAutoCreate()) 1241 throw new Error("Attempt to auto-create CitationStatusDateComponent.activity"); 1242 else if (Configuration.doAutoCreate()) 1243 this.activity = new CodeableConcept(); // cc 1244 return this.activity; 1245 } 1246 1247 public boolean hasActivity() { 1248 return this.activity != null && !this.activity.isEmpty(); 1249 } 1250 1251 /** 1252 * @param value {@link #activity} (Classification of the status.) 1253 */ 1254 public CitationStatusDateComponent setActivity(CodeableConcept value) { 1255 this.activity = value; 1256 return this; 1257 } 1258 1259 /** 1260 * @return {@link #actual} (Either occurred or expected.). This is the underlying object with id, value and extensions. The accessor "getActual" gives direct access to the value 1261 */ 1262 public BooleanType getActualElement() { 1263 if (this.actual == null) 1264 if (Configuration.errorOnAutoCreate()) 1265 throw new Error("Attempt to auto-create CitationStatusDateComponent.actual"); 1266 else if (Configuration.doAutoCreate()) 1267 this.actual = new BooleanType(); // bb 1268 return this.actual; 1269 } 1270 1271 public boolean hasActualElement() { 1272 return this.actual != null && !this.actual.isEmpty(); 1273 } 1274 1275 public boolean hasActual() { 1276 return this.actual != null && !this.actual.isEmpty(); 1277 } 1278 1279 /** 1280 * @param value {@link #actual} (Either occurred or expected.). This is the underlying object with id, value and extensions. The accessor "getActual" gives direct access to the value 1281 */ 1282 public CitationStatusDateComponent setActualElement(BooleanType value) { 1283 this.actual = value; 1284 return this; 1285 } 1286 1287 /** 1288 * @return Either occurred or expected. 1289 */ 1290 public boolean getActual() { 1291 return this.actual == null || this.actual.isEmpty() ? false : this.actual.getValue(); 1292 } 1293 1294 /** 1295 * @param value Either occurred or expected. 1296 */ 1297 public CitationStatusDateComponent setActual(boolean value) { 1298 if (this.actual == null) 1299 this.actual = new BooleanType(); 1300 this.actual.setValue(value); 1301 return this; 1302 } 1303 1304 /** 1305 * @return {@link #period} (When the status started and/or ended.) 1306 */ 1307 public Period getPeriod() { 1308 if (this.period == null) 1309 if (Configuration.errorOnAutoCreate()) 1310 throw new Error("Attempt to auto-create CitationStatusDateComponent.period"); 1311 else if (Configuration.doAutoCreate()) 1312 this.period = new Period(); // cc 1313 return this.period; 1314 } 1315 1316 public boolean hasPeriod() { 1317 return this.period != null && !this.period.isEmpty(); 1318 } 1319 1320 /** 1321 * @param value {@link #period} (When the status started and/or ended.) 1322 */ 1323 public CitationStatusDateComponent setPeriod(Period value) { 1324 this.period = value; 1325 return this; 1326 } 1327 1328 protected void listChildren(List<Property> children) { 1329 super.listChildren(children); 1330 children.add(new Property("activity", "CodeableConcept", "Classification of the status.", 0, 1, activity)); 1331 children.add(new Property("actual", "boolean", "Either occurred or expected.", 0, 1, actual)); 1332 children.add(new Property("period", "Period", "When the status started and/or ended.", 0, 1, period)); 1333 } 1334 1335 @Override 1336 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 1337 switch (_hash) { 1338 case -1655966961: /*activity*/ return new Property("activity", "CodeableConcept", "Classification of the status.", 0, 1, activity); 1339 case -1422939762: /*actual*/ return new Property("actual", "boolean", "Either occurred or expected.", 0, 1, actual); 1340 case -991726143: /*period*/ return new Property("period", "Period", "When the status started and/or ended.", 0, 1, period); 1341 default: return super.getNamedProperty(_hash, _name, _checkValid); 1342 } 1343 1344 } 1345 1346 @Override 1347 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 1348 switch (hash) { 1349 case -1655966961: /*activity*/ return this.activity == null ? new Base[0] : new Base[] {this.activity}; // CodeableConcept 1350 case -1422939762: /*actual*/ return this.actual == null ? new Base[0] : new Base[] {this.actual}; // BooleanType 1351 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 1352 default: return super.getProperty(hash, name, checkValid); 1353 } 1354 1355 } 1356 1357 @Override 1358 public Base setProperty(int hash, String name, Base value) throws FHIRException { 1359 switch (hash) { 1360 case -1655966961: // activity 1361 this.activity = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1362 return value; 1363 case -1422939762: // actual 1364 this.actual = TypeConvertor.castToBoolean(value); // BooleanType 1365 return value; 1366 case -991726143: // period 1367 this.period = TypeConvertor.castToPeriod(value); // Period 1368 return value; 1369 default: return super.setProperty(hash, name, value); 1370 } 1371 1372 } 1373 1374 @Override 1375 public Base setProperty(String name, Base value) throws FHIRException { 1376 if (name.equals("activity")) { 1377 this.activity = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 1378 } else if (name.equals("actual")) { 1379 this.actual = TypeConvertor.castToBoolean(value); // BooleanType 1380 } else if (name.equals("period")) { 1381 this.period = TypeConvertor.castToPeriod(value); // Period 1382 } else 1383 return super.setProperty(name, value); 1384 return value; 1385 } 1386 1387 @Override 1388 public Base makeProperty(int hash, String name) throws FHIRException { 1389 switch (hash) { 1390 case -1655966961: return getActivity(); 1391 case -1422939762: return getActualElement(); 1392 case -991726143: return getPeriod(); 1393 default: return super.makeProperty(hash, name); 1394 } 1395 1396 } 1397 1398 @Override 1399 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 1400 switch (hash) { 1401 case -1655966961: /*activity*/ return new String[] {"CodeableConcept"}; 1402 case -1422939762: /*actual*/ return new String[] {"boolean"}; 1403 case -991726143: /*period*/ return new String[] {"Period"}; 1404 default: return super.getTypesForProperty(hash, name); 1405 } 1406 1407 } 1408 1409 @Override 1410 public Base addChild(String name) throws FHIRException { 1411 if (name.equals("activity")) { 1412 this.activity = new CodeableConcept(); 1413 return this.activity; 1414 } 1415 else if (name.equals("actual")) { 1416 throw new FHIRException("Cannot call addChild on a primitive type Citation.statusDate.actual"); 1417 } 1418 else if (name.equals("period")) { 1419 this.period = new Period(); 1420 return this.period; 1421 } 1422 else 1423 return super.addChild(name); 1424 } 1425 1426 public CitationStatusDateComponent copy() { 1427 CitationStatusDateComponent dst = new CitationStatusDateComponent(); 1428 copyValues(dst); 1429 return dst; 1430 } 1431 1432 public void copyValues(CitationStatusDateComponent dst) { 1433 super.copyValues(dst); 1434 dst.activity = activity == null ? null : activity.copy(); 1435 dst.actual = actual == null ? null : actual.copy(); 1436 dst.period = period == null ? null : period.copy(); 1437 } 1438 1439 @Override 1440 public boolean equalsDeep(Base other_) { 1441 if (!super.equalsDeep(other_)) 1442 return false; 1443 if (!(other_ instanceof CitationStatusDateComponent)) 1444 return false; 1445 CitationStatusDateComponent o = (CitationStatusDateComponent) other_; 1446 return compareDeep(activity, o.activity, true) && compareDeep(actual, o.actual, true) && compareDeep(period, o.period, true) 1447 ; 1448 } 1449 1450 @Override 1451 public boolean equalsShallow(Base other_) { 1452 if (!super.equalsShallow(other_)) 1453 return false; 1454 if (!(other_ instanceof CitationStatusDateComponent)) 1455 return false; 1456 CitationStatusDateComponent o = (CitationStatusDateComponent) other_; 1457 return compareValues(actual, o.actual, true); 1458 } 1459 1460 public boolean isEmpty() { 1461 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(activity, actual, period 1462 ); 1463 } 1464 1465 public String fhirType() { 1466 return "Citation.statusDate"; 1467 1468 } 1469 1470 } 1471 1472 @Block() 1473 public static class CitationCitedArtifactComponent extends BackboneElement implements IBaseBackboneElement { 1474 /** 1475 * A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance. 1476 */ 1477 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1478 @Description(shortDefinition="May include DOI, PMID, PMCID, etc.", formalDefinition="A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance." ) 1479 protected List<Identifier> identifier; 1480 1481 /** 1482 * A formal identifier that is used to identify things closely related to this citation. 1483 */ 1484 @Child(name = "relatedIdentifier", type = {Identifier.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 1485 @Description(shortDefinition="May include trial registry identifiers", formalDefinition="A formal identifier that is used to identify things closely related to this citation." ) 1486 protected List<Identifier> relatedIdentifier; 1487 1488 /** 1489 * When the cited artifact was accessed. 1490 */ 1491 @Child(name = "dateAccessed", type = {DateTimeType.class}, order=3, min=0, max=1, modifier=false, summary=true) 1492 @Description(shortDefinition="When the cited artifact was accessed", formalDefinition="When the cited artifact was accessed." ) 1493 protected DateTimeType dateAccessed; 1494 1495 /** 1496 * The defined version of the cited artifact. 1497 */ 1498 @Child(name = "version", type = {}, order=4, min=0, max=1, modifier=false, summary=false) 1499 @Description(shortDefinition="The defined version of the cited artifact", formalDefinition="The defined version of the cited artifact." ) 1500 protected CitationCitedArtifactVersionComponent version; 1501 1502 /** 1503 * The status of the cited artifact. 1504 */ 1505 @Child(name = "currentState", type = {CodeableConcept.class}, order=5, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1506 @Description(shortDefinition="The status of the cited artifact", formalDefinition="The status of the cited artifact." ) 1507 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-artifact-status-type") 1508 protected List<CodeableConcept> currentState; 1509 1510 /** 1511 * An effective date or period for a status of the cited artifact. 1512 */ 1513 @Child(name = "statusDate", type = {}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1514 @Description(shortDefinition="An effective date or period for a status of the cited artifact", formalDefinition="An effective date or period for a status of the cited artifact." ) 1515 protected List<CitationCitedArtifactStatusDateComponent> statusDate; 1516 1517 /** 1518 * The title details of the article or artifact. 1519 */ 1520 @Child(name = "title", type = {}, order=7, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1521 @Description(shortDefinition="The title details of the article or artifact", formalDefinition="The title details of the article or artifact." ) 1522 protected List<CitationCitedArtifactTitleComponent> title; 1523 1524 /** 1525 * Summary of the article or artifact. 1526 */ 1527 @Child(name = "abstract", type = {}, order=8, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1528 @Description(shortDefinition="Summary of the article or artifact", formalDefinition="Summary of the article or artifact." ) 1529 protected List<CitationCitedArtifactAbstractComponent> abstract_; 1530 1531 /** 1532 * The component of the article or artifact. 1533 */ 1534 @Child(name = "part", type = {}, order=9, min=0, max=1, modifier=false, summary=false) 1535 @Description(shortDefinition="The component of the article or artifact", formalDefinition="The component of the article or artifact." ) 1536 protected CitationCitedArtifactPartComponent part; 1537 1538 /** 1539 * The artifact related to the cited artifact. 1540 */ 1541 @Child(name = "relatesTo", type = {}, order=10, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1542 @Description(shortDefinition="The artifact related to the cited artifact", formalDefinition="The artifact related to the cited artifact." ) 1543 protected List<CitationCitedArtifactRelatesToComponent> relatesTo; 1544 1545 /** 1546 * If multiple, used to represent alternative forms of the article that are not separate citations. 1547 */ 1548 @Child(name = "publicationForm", type = {}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1549 @Description(shortDefinition="If multiple, used to represent alternative forms of the article that are not separate citations", formalDefinition="If multiple, used to represent alternative forms of the article that are not separate citations." ) 1550 protected List<CitationCitedArtifactPublicationFormComponent> publicationForm; 1551 1552 /** 1553 * Used for any URL for the article or artifact cited. 1554 */ 1555 @Child(name = "webLocation", type = {}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1556 @Description(shortDefinition="Used for any URL for the article or artifact cited", formalDefinition="Used for any URL for the article or artifact cited." ) 1557 protected List<CitationCitedArtifactWebLocationComponent> webLocation; 1558 1559 /** 1560 * The assignment to an organizing scheme. 1561 */ 1562 @Child(name = "classification", type = {}, order=13, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1563 @Description(shortDefinition="The assignment to an organizing scheme", formalDefinition="The assignment to an organizing scheme." ) 1564 protected List<CitationCitedArtifactClassificationComponent> classification; 1565 1566 /** 1567 * This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements. 1568 */ 1569 @Child(name = "contributorship", type = {}, order=14, min=0, max=1, modifier=false, summary=false) 1570 @Description(shortDefinition="Attribution of authors and other contributors", formalDefinition="This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements." ) 1571 protected CitationCitedArtifactContributorshipComponent contributorship; 1572 1573 /** 1574 * Any additional information or content for the article or artifact. 1575 */ 1576 @Child(name = "note", type = {Annotation.class}, order=15, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 1577 @Description(shortDefinition="Any additional information or content for the article or artifact", formalDefinition="Any additional information or content for the article or artifact." ) 1578 protected List<Annotation> note; 1579 1580 private static final long serialVersionUID = -1685890486L; 1581 1582 /** 1583 * Constructor 1584 */ 1585 public CitationCitedArtifactComponent() { 1586 super(); 1587 } 1588 1589 /** 1590 * @return {@link #identifier} (A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance.) 1591 */ 1592 public List<Identifier> getIdentifier() { 1593 if (this.identifier == null) 1594 this.identifier = new ArrayList<Identifier>(); 1595 return this.identifier; 1596 } 1597 1598 /** 1599 * @return Returns a reference to <code>this</code> for easy method chaining 1600 */ 1601 public CitationCitedArtifactComponent setIdentifier(List<Identifier> theIdentifier) { 1602 this.identifier = theIdentifier; 1603 return this; 1604 } 1605 1606 public boolean hasIdentifier() { 1607 if (this.identifier == null) 1608 return false; 1609 for (Identifier item : this.identifier) 1610 if (!item.isEmpty()) 1611 return true; 1612 return false; 1613 } 1614 1615 public Identifier addIdentifier() { //3 1616 Identifier t = new Identifier(); 1617 if (this.identifier == null) 1618 this.identifier = new ArrayList<Identifier>(); 1619 this.identifier.add(t); 1620 return t; 1621 } 1622 1623 public CitationCitedArtifactComponent addIdentifier(Identifier t) { //3 1624 if (t == null) 1625 return this; 1626 if (this.identifier == null) 1627 this.identifier = new ArrayList<Identifier>(); 1628 this.identifier.add(t); 1629 return this; 1630 } 1631 1632 /** 1633 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 1634 */ 1635 public Identifier getIdentifierFirstRep() { 1636 if (getIdentifier().isEmpty()) { 1637 addIdentifier(); 1638 } 1639 return getIdentifier().get(0); 1640 } 1641 1642 /** 1643 * @return {@link #relatedIdentifier} (A formal identifier that is used to identify things closely related to this citation.) 1644 */ 1645 public List<Identifier> getRelatedIdentifier() { 1646 if (this.relatedIdentifier == null) 1647 this.relatedIdentifier = new ArrayList<Identifier>(); 1648 return this.relatedIdentifier; 1649 } 1650 1651 /** 1652 * @return Returns a reference to <code>this</code> for easy method chaining 1653 */ 1654 public CitationCitedArtifactComponent setRelatedIdentifier(List<Identifier> theRelatedIdentifier) { 1655 this.relatedIdentifier = theRelatedIdentifier; 1656 return this; 1657 } 1658 1659 public boolean hasRelatedIdentifier() { 1660 if (this.relatedIdentifier == null) 1661 return false; 1662 for (Identifier item : this.relatedIdentifier) 1663 if (!item.isEmpty()) 1664 return true; 1665 return false; 1666 } 1667 1668 public Identifier addRelatedIdentifier() { //3 1669 Identifier t = new Identifier(); 1670 if (this.relatedIdentifier == null) 1671 this.relatedIdentifier = new ArrayList<Identifier>(); 1672 this.relatedIdentifier.add(t); 1673 return t; 1674 } 1675 1676 public CitationCitedArtifactComponent addRelatedIdentifier(Identifier t) { //3 1677 if (t == null) 1678 return this; 1679 if (this.relatedIdentifier == null) 1680 this.relatedIdentifier = new ArrayList<Identifier>(); 1681 this.relatedIdentifier.add(t); 1682 return this; 1683 } 1684 1685 /** 1686 * @return The first repetition of repeating field {@link #relatedIdentifier}, creating it if it does not already exist {3} 1687 */ 1688 public Identifier getRelatedIdentifierFirstRep() { 1689 if (getRelatedIdentifier().isEmpty()) { 1690 addRelatedIdentifier(); 1691 } 1692 return getRelatedIdentifier().get(0); 1693 } 1694 1695 /** 1696 * @return {@link #dateAccessed} (When the cited artifact was accessed.). This is the underlying object with id, value and extensions. The accessor "getDateAccessed" gives direct access to the value 1697 */ 1698 public DateTimeType getDateAccessedElement() { 1699 if (this.dateAccessed == null) 1700 if (Configuration.errorOnAutoCreate()) 1701 throw new Error("Attempt to auto-create CitationCitedArtifactComponent.dateAccessed"); 1702 else if (Configuration.doAutoCreate()) 1703 this.dateAccessed = new DateTimeType(); // bb 1704 return this.dateAccessed; 1705 } 1706 1707 public boolean hasDateAccessedElement() { 1708 return this.dateAccessed != null && !this.dateAccessed.isEmpty(); 1709 } 1710 1711 public boolean hasDateAccessed() { 1712 return this.dateAccessed != null && !this.dateAccessed.isEmpty(); 1713 } 1714 1715 /** 1716 * @param value {@link #dateAccessed} (When the cited artifact was accessed.). This is the underlying object with id, value and extensions. The accessor "getDateAccessed" gives direct access to the value 1717 */ 1718 public CitationCitedArtifactComponent setDateAccessedElement(DateTimeType value) { 1719 this.dateAccessed = value; 1720 return this; 1721 } 1722 1723 /** 1724 * @return When the cited artifact was accessed. 1725 */ 1726 public Date getDateAccessed() { 1727 return this.dateAccessed == null ? null : this.dateAccessed.getValue(); 1728 } 1729 1730 /** 1731 * @param value When the cited artifact was accessed. 1732 */ 1733 public CitationCitedArtifactComponent setDateAccessed(Date value) { 1734 if (value == null) 1735 this.dateAccessed = null; 1736 else { 1737 if (this.dateAccessed == null) 1738 this.dateAccessed = new DateTimeType(); 1739 this.dateAccessed.setValue(value); 1740 } 1741 return this; 1742 } 1743 1744 /** 1745 * @return {@link #version} (The defined version of the cited artifact.) 1746 */ 1747 public CitationCitedArtifactVersionComponent getVersion() { 1748 if (this.version == null) 1749 if (Configuration.errorOnAutoCreate()) 1750 throw new Error("Attempt to auto-create CitationCitedArtifactComponent.version"); 1751 else if (Configuration.doAutoCreate()) 1752 this.version = new CitationCitedArtifactVersionComponent(); // cc 1753 return this.version; 1754 } 1755 1756 public boolean hasVersion() { 1757 return this.version != null && !this.version.isEmpty(); 1758 } 1759 1760 /** 1761 * @param value {@link #version} (The defined version of the cited artifact.) 1762 */ 1763 public CitationCitedArtifactComponent setVersion(CitationCitedArtifactVersionComponent value) { 1764 this.version = value; 1765 return this; 1766 } 1767 1768 /** 1769 * @return {@link #currentState} (The status of the cited artifact.) 1770 */ 1771 public List<CodeableConcept> getCurrentState() { 1772 if (this.currentState == null) 1773 this.currentState = new ArrayList<CodeableConcept>(); 1774 return this.currentState; 1775 } 1776 1777 /** 1778 * @return Returns a reference to <code>this</code> for easy method chaining 1779 */ 1780 public CitationCitedArtifactComponent setCurrentState(List<CodeableConcept> theCurrentState) { 1781 this.currentState = theCurrentState; 1782 return this; 1783 } 1784 1785 public boolean hasCurrentState() { 1786 if (this.currentState == null) 1787 return false; 1788 for (CodeableConcept item : this.currentState) 1789 if (!item.isEmpty()) 1790 return true; 1791 return false; 1792 } 1793 1794 public CodeableConcept addCurrentState() { //3 1795 CodeableConcept t = new CodeableConcept(); 1796 if (this.currentState == null) 1797 this.currentState = new ArrayList<CodeableConcept>(); 1798 this.currentState.add(t); 1799 return t; 1800 } 1801 1802 public CitationCitedArtifactComponent addCurrentState(CodeableConcept t) { //3 1803 if (t == null) 1804 return this; 1805 if (this.currentState == null) 1806 this.currentState = new ArrayList<CodeableConcept>(); 1807 this.currentState.add(t); 1808 return this; 1809 } 1810 1811 /** 1812 * @return The first repetition of repeating field {@link #currentState}, creating it if it does not already exist {3} 1813 */ 1814 public CodeableConcept getCurrentStateFirstRep() { 1815 if (getCurrentState().isEmpty()) { 1816 addCurrentState(); 1817 } 1818 return getCurrentState().get(0); 1819 } 1820 1821 /** 1822 * @return {@link #statusDate} (An effective date or period for a status of the cited artifact.) 1823 */ 1824 public List<CitationCitedArtifactStatusDateComponent> getStatusDate() { 1825 if (this.statusDate == null) 1826 this.statusDate = new ArrayList<CitationCitedArtifactStatusDateComponent>(); 1827 return this.statusDate; 1828 } 1829 1830 /** 1831 * @return Returns a reference to <code>this</code> for easy method chaining 1832 */ 1833 public CitationCitedArtifactComponent setStatusDate(List<CitationCitedArtifactStatusDateComponent> theStatusDate) { 1834 this.statusDate = theStatusDate; 1835 return this; 1836 } 1837 1838 public boolean hasStatusDate() { 1839 if (this.statusDate == null) 1840 return false; 1841 for (CitationCitedArtifactStatusDateComponent item : this.statusDate) 1842 if (!item.isEmpty()) 1843 return true; 1844 return false; 1845 } 1846 1847 public CitationCitedArtifactStatusDateComponent addStatusDate() { //3 1848 CitationCitedArtifactStatusDateComponent t = new CitationCitedArtifactStatusDateComponent(); 1849 if (this.statusDate == null) 1850 this.statusDate = new ArrayList<CitationCitedArtifactStatusDateComponent>(); 1851 this.statusDate.add(t); 1852 return t; 1853 } 1854 1855 public CitationCitedArtifactComponent addStatusDate(CitationCitedArtifactStatusDateComponent t) { //3 1856 if (t == null) 1857 return this; 1858 if (this.statusDate == null) 1859 this.statusDate = new ArrayList<CitationCitedArtifactStatusDateComponent>(); 1860 this.statusDate.add(t); 1861 return this; 1862 } 1863 1864 /** 1865 * @return The first repetition of repeating field {@link #statusDate}, creating it if it does not already exist {3} 1866 */ 1867 public CitationCitedArtifactStatusDateComponent getStatusDateFirstRep() { 1868 if (getStatusDate().isEmpty()) { 1869 addStatusDate(); 1870 } 1871 return getStatusDate().get(0); 1872 } 1873 1874 /** 1875 * @return {@link #title} (The title details of the article or artifact.) 1876 */ 1877 public List<CitationCitedArtifactTitleComponent> getTitle() { 1878 if (this.title == null) 1879 this.title = new ArrayList<CitationCitedArtifactTitleComponent>(); 1880 return this.title; 1881 } 1882 1883 /** 1884 * @return Returns a reference to <code>this</code> for easy method chaining 1885 */ 1886 public CitationCitedArtifactComponent setTitle(List<CitationCitedArtifactTitleComponent> theTitle) { 1887 this.title = theTitle; 1888 return this; 1889 } 1890 1891 public boolean hasTitle() { 1892 if (this.title == null) 1893 return false; 1894 for (CitationCitedArtifactTitleComponent item : this.title) 1895 if (!item.isEmpty()) 1896 return true; 1897 return false; 1898 } 1899 1900 public CitationCitedArtifactTitleComponent addTitle() { //3 1901 CitationCitedArtifactTitleComponent t = new CitationCitedArtifactTitleComponent(); 1902 if (this.title == null) 1903 this.title = new ArrayList<CitationCitedArtifactTitleComponent>(); 1904 this.title.add(t); 1905 return t; 1906 } 1907 1908 public CitationCitedArtifactComponent addTitle(CitationCitedArtifactTitleComponent t) { //3 1909 if (t == null) 1910 return this; 1911 if (this.title == null) 1912 this.title = new ArrayList<CitationCitedArtifactTitleComponent>(); 1913 this.title.add(t); 1914 return this; 1915 } 1916 1917 /** 1918 * @return The first repetition of repeating field {@link #title}, creating it if it does not already exist {3} 1919 */ 1920 public CitationCitedArtifactTitleComponent getTitleFirstRep() { 1921 if (getTitle().isEmpty()) { 1922 addTitle(); 1923 } 1924 return getTitle().get(0); 1925 } 1926 1927 /** 1928 * @return {@link #abstract_} (Summary of the article or artifact.) 1929 */ 1930 public List<CitationCitedArtifactAbstractComponent> getAbstract() { 1931 if (this.abstract_ == null) 1932 this.abstract_ = new ArrayList<CitationCitedArtifactAbstractComponent>(); 1933 return this.abstract_; 1934 } 1935 1936 /** 1937 * @return Returns a reference to <code>this</code> for easy method chaining 1938 */ 1939 public CitationCitedArtifactComponent setAbstract(List<CitationCitedArtifactAbstractComponent> theAbstract) { 1940 this.abstract_ = theAbstract; 1941 return this; 1942 } 1943 1944 public boolean hasAbstract() { 1945 if (this.abstract_ == null) 1946 return false; 1947 for (CitationCitedArtifactAbstractComponent item : this.abstract_) 1948 if (!item.isEmpty()) 1949 return true; 1950 return false; 1951 } 1952 1953 public CitationCitedArtifactAbstractComponent addAbstract() { //3 1954 CitationCitedArtifactAbstractComponent t = new CitationCitedArtifactAbstractComponent(); 1955 if (this.abstract_ == null) 1956 this.abstract_ = new ArrayList<CitationCitedArtifactAbstractComponent>(); 1957 this.abstract_.add(t); 1958 return t; 1959 } 1960 1961 public CitationCitedArtifactComponent addAbstract(CitationCitedArtifactAbstractComponent t) { //3 1962 if (t == null) 1963 return this; 1964 if (this.abstract_ == null) 1965 this.abstract_ = new ArrayList<CitationCitedArtifactAbstractComponent>(); 1966 this.abstract_.add(t); 1967 return this; 1968 } 1969 1970 /** 1971 * @return The first repetition of repeating field {@link #abstract_}, creating it if it does not already exist {3} 1972 */ 1973 public CitationCitedArtifactAbstractComponent getAbstractFirstRep() { 1974 if (getAbstract().isEmpty()) { 1975 addAbstract(); 1976 } 1977 return getAbstract().get(0); 1978 } 1979 1980 /** 1981 * @return {@link #part} (The component of the article or artifact.) 1982 */ 1983 public CitationCitedArtifactPartComponent getPart() { 1984 if (this.part == null) 1985 if (Configuration.errorOnAutoCreate()) 1986 throw new Error("Attempt to auto-create CitationCitedArtifactComponent.part"); 1987 else if (Configuration.doAutoCreate()) 1988 this.part = new CitationCitedArtifactPartComponent(); // cc 1989 return this.part; 1990 } 1991 1992 public boolean hasPart() { 1993 return this.part != null && !this.part.isEmpty(); 1994 } 1995 1996 /** 1997 * @param value {@link #part} (The component of the article or artifact.) 1998 */ 1999 public CitationCitedArtifactComponent setPart(CitationCitedArtifactPartComponent value) { 2000 this.part = value; 2001 return this; 2002 } 2003 2004 /** 2005 * @return {@link #relatesTo} (The artifact related to the cited artifact.) 2006 */ 2007 public List<CitationCitedArtifactRelatesToComponent> getRelatesTo() { 2008 if (this.relatesTo == null) 2009 this.relatesTo = new ArrayList<CitationCitedArtifactRelatesToComponent>(); 2010 return this.relatesTo; 2011 } 2012 2013 /** 2014 * @return Returns a reference to <code>this</code> for easy method chaining 2015 */ 2016 public CitationCitedArtifactComponent setRelatesTo(List<CitationCitedArtifactRelatesToComponent> theRelatesTo) { 2017 this.relatesTo = theRelatesTo; 2018 return this; 2019 } 2020 2021 public boolean hasRelatesTo() { 2022 if (this.relatesTo == null) 2023 return false; 2024 for (CitationCitedArtifactRelatesToComponent item : this.relatesTo) 2025 if (!item.isEmpty()) 2026 return true; 2027 return false; 2028 } 2029 2030 public CitationCitedArtifactRelatesToComponent addRelatesTo() { //3 2031 CitationCitedArtifactRelatesToComponent t = new CitationCitedArtifactRelatesToComponent(); 2032 if (this.relatesTo == null) 2033 this.relatesTo = new ArrayList<CitationCitedArtifactRelatesToComponent>(); 2034 this.relatesTo.add(t); 2035 return t; 2036 } 2037 2038 public CitationCitedArtifactComponent addRelatesTo(CitationCitedArtifactRelatesToComponent t) { //3 2039 if (t == null) 2040 return this; 2041 if (this.relatesTo == null) 2042 this.relatesTo = new ArrayList<CitationCitedArtifactRelatesToComponent>(); 2043 this.relatesTo.add(t); 2044 return this; 2045 } 2046 2047 /** 2048 * @return The first repetition of repeating field {@link #relatesTo}, creating it if it does not already exist {3} 2049 */ 2050 public CitationCitedArtifactRelatesToComponent getRelatesToFirstRep() { 2051 if (getRelatesTo().isEmpty()) { 2052 addRelatesTo(); 2053 } 2054 return getRelatesTo().get(0); 2055 } 2056 2057 /** 2058 * @return {@link #publicationForm} (If multiple, used to represent alternative forms of the article that are not separate citations.) 2059 */ 2060 public List<CitationCitedArtifactPublicationFormComponent> getPublicationForm() { 2061 if (this.publicationForm == null) 2062 this.publicationForm = new ArrayList<CitationCitedArtifactPublicationFormComponent>(); 2063 return this.publicationForm; 2064 } 2065 2066 /** 2067 * @return Returns a reference to <code>this</code> for easy method chaining 2068 */ 2069 public CitationCitedArtifactComponent setPublicationForm(List<CitationCitedArtifactPublicationFormComponent> thePublicationForm) { 2070 this.publicationForm = thePublicationForm; 2071 return this; 2072 } 2073 2074 public boolean hasPublicationForm() { 2075 if (this.publicationForm == null) 2076 return false; 2077 for (CitationCitedArtifactPublicationFormComponent item : this.publicationForm) 2078 if (!item.isEmpty()) 2079 return true; 2080 return false; 2081 } 2082 2083 public CitationCitedArtifactPublicationFormComponent addPublicationForm() { //3 2084 CitationCitedArtifactPublicationFormComponent t = new CitationCitedArtifactPublicationFormComponent(); 2085 if (this.publicationForm == null) 2086 this.publicationForm = new ArrayList<CitationCitedArtifactPublicationFormComponent>(); 2087 this.publicationForm.add(t); 2088 return t; 2089 } 2090 2091 public CitationCitedArtifactComponent addPublicationForm(CitationCitedArtifactPublicationFormComponent t) { //3 2092 if (t == null) 2093 return this; 2094 if (this.publicationForm == null) 2095 this.publicationForm = new ArrayList<CitationCitedArtifactPublicationFormComponent>(); 2096 this.publicationForm.add(t); 2097 return this; 2098 } 2099 2100 /** 2101 * @return The first repetition of repeating field {@link #publicationForm}, creating it if it does not already exist {3} 2102 */ 2103 public CitationCitedArtifactPublicationFormComponent getPublicationFormFirstRep() { 2104 if (getPublicationForm().isEmpty()) { 2105 addPublicationForm(); 2106 } 2107 return getPublicationForm().get(0); 2108 } 2109 2110 /** 2111 * @return {@link #webLocation} (Used for any URL for the article or artifact cited.) 2112 */ 2113 public List<CitationCitedArtifactWebLocationComponent> getWebLocation() { 2114 if (this.webLocation == null) 2115 this.webLocation = new ArrayList<CitationCitedArtifactWebLocationComponent>(); 2116 return this.webLocation; 2117 } 2118 2119 /** 2120 * @return Returns a reference to <code>this</code> for easy method chaining 2121 */ 2122 public CitationCitedArtifactComponent setWebLocation(List<CitationCitedArtifactWebLocationComponent> theWebLocation) { 2123 this.webLocation = theWebLocation; 2124 return this; 2125 } 2126 2127 public boolean hasWebLocation() { 2128 if (this.webLocation == null) 2129 return false; 2130 for (CitationCitedArtifactWebLocationComponent item : this.webLocation) 2131 if (!item.isEmpty()) 2132 return true; 2133 return false; 2134 } 2135 2136 public CitationCitedArtifactWebLocationComponent addWebLocation() { //3 2137 CitationCitedArtifactWebLocationComponent t = new CitationCitedArtifactWebLocationComponent(); 2138 if (this.webLocation == null) 2139 this.webLocation = new ArrayList<CitationCitedArtifactWebLocationComponent>(); 2140 this.webLocation.add(t); 2141 return t; 2142 } 2143 2144 public CitationCitedArtifactComponent addWebLocation(CitationCitedArtifactWebLocationComponent t) { //3 2145 if (t == null) 2146 return this; 2147 if (this.webLocation == null) 2148 this.webLocation = new ArrayList<CitationCitedArtifactWebLocationComponent>(); 2149 this.webLocation.add(t); 2150 return this; 2151 } 2152 2153 /** 2154 * @return The first repetition of repeating field {@link #webLocation}, creating it if it does not already exist {3} 2155 */ 2156 public CitationCitedArtifactWebLocationComponent getWebLocationFirstRep() { 2157 if (getWebLocation().isEmpty()) { 2158 addWebLocation(); 2159 } 2160 return getWebLocation().get(0); 2161 } 2162 2163 /** 2164 * @return {@link #classification} (The assignment to an organizing scheme.) 2165 */ 2166 public List<CitationCitedArtifactClassificationComponent> getClassification() { 2167 if (this.classification == null) 2168 this.classification = new ArrayList<CitationCitedArtifactClassificationComponent>(); 2169 return this.classification; 2170 } 2171 2172 /** 2173 * @return Returns a reference to <code>this</code> for easy method chaining 2174 */ 2175 public CitationCitedArtifactComponent setClassification(List<CitationCitedArtifactClassificationComponent> theClassification) { 2176 this.classification = theClassification; 2177 return this; 2178 } 2179 2180 public boolean hasClassification() { 2181 if (this.classification == null) 2182 return false; 2183 for (CitationCitedArtifactClassificationComponent item : this.classification) 2184 if (!item.isEmpty()) 2185 return true; 2186 return false; 2187 } 2188 2189 public CitationCitedArtifactClassificationComponent addClassification() { //3 2190 CitationCitedArtifactClassificationComponent t = new CitationCitedArtifactClassificationComponent(); 2191 if (this.classification == null) 2192 this.classification = new ArrayList<CitationCitedArtifactClassificationComponent>(); 2193 this.classification.add(t); 2194 return t; 2195 } 2196 2197 public CitationCitedArtifactComponent addClassification(CitationCitedArtifactClassificationComponent t) { //3 2198 if (t == null) 2199 return this; 2200 if (this.classification == null) 2201 this.classification = new ArrayList<CitationCitedArtifactClassificationComponent>(); 2202 this.classification.add(t); 2203 return this; 2204 } 2205 2206 /** 2207 * @return The first repetition of repeating field {@link #classification}, creating it if it does not already exist {3} 2208 */ 2209 public CitationCitedArtifactClassificationComponent getClassificationFirstRep() { 2210 if (getClassification().isEmpty()) { 2211 addClassification(); 2212 } 2213 return getClassification().get(0); 2214 } 2215 2216 /** 2217 * @return {@link #contributorship} (This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements.) 2218 */ 2219 public CitationCitedArtifactContributorshipComponent getContributorship() { 2220 if (this.contributorship == null) 2221 if (Configuration.errorOnAutoCreate()) 2222 throw new Error("Attempt to auto-create CitationCitedArtifactComponent.contributorship"); 2223 else if (Configuration.doAutoCreate()) 2224 this.contributorship = new CitationCitedArtifactContributorshipComponent(); // cc 2225 return this.contributorship; 2226 } 2227 2228 public boolean hasContributorship() { 2229 return this.contributorship != null && !this.contributorship.isEmpty(); 2230 } 2231 2232 /** 2233 * @param value {@link #contributorship} (This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements.) 2234 */ 2235 public CitationCitedArtifactComponent setContributorship(CitationCitedArtifactContributorshipComponent value) { 2236 this.contributorship = value; 2237 return this; 2238 } 2239 2240 /** 2241 * @return {@link #note} (Any additional information or content for the article or artifact.) 2242 */ 2243 public List<Annotation> getNote() { 2244 if (this.note == null) 2245 this.note = new ArrayList<Annotation>(); 2246 return this.note; 2247 } 2248 2249 /** 2250 * @return Returns a reference to <code>this</code> for easy method chaining 2251 */ 2252 public CitationCitedArtifactComponent setNote(List<Annotation> theNote) { 2253 this.note = theNote; 2254 return this; 2255 } 2256 2257 public boolean hasNote() { 2258 if (this.note == null) 2259 return false; 2260 for (Annotation item : this.note) 2261 if (!item.isEmpty()) 2262 return true; 2263 return false; 2264 } 2265 2266 public Annotation addNote() { //3 2267 Annotation t = new Annotation(); 2268 if (this.note == null) 2269 this.note = new ArrayList<Annotation>(); 2270 this.note.add(t); 2271 return t; 2272 } 2273 2274 public CitationCitedArtifactComponent addNote(Annotation t) { //3 2275 if (t == null) 2276 return this; 2277 if (this.note == null) 2278 this.note = new ArrayList<Annotation>(); 2279 this.note.add(t); 2280 return this; 2281 } 2282 2283 /** 2284 * @return The first repetition of repeating field {@link #note}, creating it if it does not already exist {3} 2285 */ 2286 public Annotation getNoteFirstRep() { 2287 if (getNote().isEmpty()) { 2288 addNote(); 2289 } 2290 return getNote().get(0); 2291 } 2292 2293 protected void listChildren(List<Property> children) { 2294 super.listChildren(children); 2295 children.add(new Property("identifier", "Identifier", "A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier)); 2296 children.add(new Property("relatedIdentifier", "Identifier", "A formal identifier that is used to identify things closely related to this citation.", 0, java.lang.Integer.MAX_VALUE, relatedIdentifier)); 2297 children.add(new Property("dateAccessed", "dateTime", "When the cited artifact was accessed.", 0, 1, dateAccessed)); 2298 children.add(new Property("version", "", "The defined version of the cited artifact.", 0, 1, version)); 2299 children.add(new Property("currentState", "CodeableConcept", "The status of the cited artifact.", 0, java.lang.Integer.MAX_VALUE, currentState)); 2300 children.add(new Property("statusDate", "", "An effective date or period for a status of the cited artifact.", 0, java.lang.Integer.MAX_VALUE, statusDate)); 2301 children.add(new Property("title", "", "The title details of the article or artifact.", 0, java.lang.Integer.MAX_VALUE, title)); 2302 children.add(new Property("abstract", "", "Summary of the article or artifact.", 0, java.lang.Integer.MAX_VALUE, abstract_)); 2303 children.add(new Property("part", "", "The component of the article or artifact.", 0, 1, part)); 2304 children.add(new Property("relatesTo", "", "The artifact related to the cited artifact.", 0, java.lang.Integer.MAX_VALUE, relatesTo)); 2305 children.add(new Property("publicationForm", "", "If multiple, used to represent alternative forms of the article that are not separate citations.", 0, java.lang.Integer.MAX_VALUE, publicationForm)); 2306 children.add(new Property("webLocation", "", "Used for any URL for the article or artifact cited.", 0, java.lang.Integer.MAX_VALUE, webLocation)); 2307 children.add(new Property("classification", "", "The assignment to an organizing scheme.", 0, java.lang.Integer.MAX_VALUE, classification)); 2308 children.add(new Property("contributorship", "", "This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements.", 0, 1, contributorship)); 2309 children.add(new Property("note", "Annotation", "Any additional information or content for the article or artifact.", 0, java.lang.Integer.MAX_VALUE, note)); 2310 } 2311 2312 @Override 2313 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2314 switch (_hash) { 2315 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance.", 0, java.lang.Integer.MAX_VALUE, identifier); 2316 case -1007604940: /*relatedIdentifier*/ return new Property("relatedIdentifier", "Identifier", "A formal identifier that is used to identify things closely related to this citation.", 0, java.lang.Integer.MAX_VALUE, relatedIdentifier); 2317 case 540917457: /*dateAccessed*/ return new Property("dateAccessed", "dateTime", "When the cited artifact was accessed.", 0, 1, dateAccessed); 2318 case 351608024: /*version*/ return new Property("version", "", "The defined version of the cited artifact.", 0, 1, version); 2319 case 1457822360: /*currentState*/ return new Property("currentState", "CodeableConcept", "The status of the cited artifact.", 0, java.lang.Integer.MAX_VALUE, currentState); 2320 case 247524032: /*statusDate*/ return new Property("statusDate", "", "An effective date or period for a status of the cited artifact.", 0, java.lang.Integer.MAX_VALUE, statusDate); 2321 case 110371416: /*title*/ return new Property("title", "", "The title details of the article or artifact.", 0, java.lang.Integer.MAX_VALUE, title); 2322 case 1732898850: /*abstract*/ return new Property("abstract", "", "Summary of the article or artifact.", 0, java.lang.Integer.MAX_VALUE, abstract_); 2323 case 3433459: /*part*/ return new Property("part", "", "The component of the article or artifact.", 0, 1, part); 2324 case -7765931: /*relatesTo*/ return new Property("relatesTo", "", "The artifact related to the cited artifact.", 0, java.lang.Integer.MAX_VALUE, relatesTo); 2325 case 1470639376: /*publicationForm*/ return new Property("publicationForm", "", "If multiple, used to represent alternative forms of the article that are not separate citations.", 0, java.lang.Integer.MAX_VALUE, publicationForm); 2326 case -828032215: /*webLocation*/ return new Property("webLocation", "", "Used for any URL for the article or artifact cited.", 0, java.lang.Integer.MAX_VALUE, webLocation); 2327 case 382350310: /*classification*/ return new Property("classification", "", "The assignment to an organizing scheme.", 0, java.lang.Integer.MAX_VALUE, classification); 2328 case 538727831: /*contributorship*/ return new Property("contributorship", "", "This element is used to list authors and other contributors, their contact information, specific contributions, and summary statements.", 0, 1, contributorship); 2329 case 3387378: /*note*/ return new Property("note", "Annotation", "Any additional information or content for the article or artifact.", 0, java.lang.Integer.MAX_VALUE, note); 2330 default: return super.getNamedProperty(_hash, _name, _checkValid); 2331 } 2332 2333 } 2334 2335 @Override 2336 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2337 switch (hash) { 2338 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 2339 case -1007604940: /*relatedIdentifier*/ return this.relatedIdentifier == null ? new Base[0] : this.relatedIdentifier.toArray(new Base[this.relatedIdentifier.size()]); // Identifier 2340 case 540917457: /*dateAccessed*/ return this.dateAccessed == null ? new Base[0] : new Base[] {this.dateAccessed}; // DateTimeType 2341 case 351608024: /*version*/ return this.version == null ? new Base[0] : new Base[] {this.version}; // CitationCitedArtifactVersionComponent 2342 case 1457822360: /*currentState*/ return this.currentState == null ? new Base[0] : this.currentState.toArray(new Base[this.currentState.size()]); // CodeableConcept 2343 case 247524032: /*statusDate*/ return this.statusDate == null ? new Base[0] : this.statusDate.toArray(new Base[this.statusDate.size()]); // CitationCitedArtifactStatusDateComponent 2344 case 110371416: /*title*/ return this.title == null ? new Base[0] : this.title.toArray(new Base[this.title.size()]); // CitationCitedArtifactTitleComponent 2345 case 1732898850: /*abstract*/ return this.abstract_ == null ? new Base[0] : this.abstract_.toArray(new Base[this.abstract_.size()]); // CitationCitedArtifactAbstractComponent 2346 case 3433459: /*part*/ return this.part == null ? new Base[0] : new Base[] {this.part}; // CitationCitedArtifactPartComponent 2347 case -7765931: /*relatesTo*/ return this.relatesTo == null ? new Base[0] : this.relatesTo.toArray(new Base[this.relatesTo.size()]); // CitationCitedArtifactRelatesToComponent 2348 case 1470639376: /*publicationForm*/ return this.publicationForm == null ? new Base[0] : this.publicationForm.toArray(new Base[this.publicationForm.size()]); // CitationCitedArtifactPublicationFormComponent 2349 case -828032215: /*webLocation*/ return this.webLocation == null ? new Base[0] : this.webLocation.toArray(new Base[this.webLocation.size()]); // CitationCitedArtifactWebLocationComponent 2350 case 382350310: /*classification*/ return this.classification == null ? new Base[0] : this.classification.toArray(new Base[this.classification.size()]); // CitationCitedArtifactClassificationComponent 2351 case 538727831: /*contributorship*/ return this.contributorship == null ? new Base[0] : new Base[] {this.contributorship}; // CitationCitedArtifactContributorshipComponent 2352 case 3387378: /*note*/ return this.note == null ? new Base[0] : this.note.toArray(new Base[this.note.size()]); // Annotation 2353 default: return super.getProperty(hash, name, checkValid); 2354 } 2355 2356 } 2357 2358 @Override 2359 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2360 switch (hash) { 2361 case -1618432855: // identifier 2362 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 2363 return value; 2364 case -1007604940: // relatedIdentifier 2365 this.getRelatedIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 2366 return value; 2367 case 540917457: // dateAccessed 2368 this.dateAccessed = TypeConvertor.castToDateTime(value); // DateTimeType 2369 return value; 2370 case 351608024: // version 2371 this.version = (CitationCitedArtifactVersionComponent) value; // CitationCitedArtifactVersionComponent 2372 return value; 2373 case 1457822360: // currentState 2374 this.getCurrentState().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 2375 return value; 2376 case 247524032: // statusDate 2377 this.getStatusDate().add((CitationCitedArtifactStatusDateComponent) value); // CitationCitedArtifactStatusDateComponent 2378 return value; 2379 case 110371416: // title 2380 this.getTitle().add((CitationCitedArtifactTitleComponent) value); // CitationCitedArtifactTitleComponent 2381 return value; 2382 case 1732898850: // abstract 2383 this.getAbstract().add((CitationCitedArtifactAbstractComponent) value); // CitationCitedArtifactAbstractComponent 2384 return value; 2385 case 3433459: // part 2386 this.part = (CitationCitedArtifactPartComponent) value; // CitationCitedArtifactPartComponent 2387 return value; 2388 case -7765931: // relatesTo 2389 this.getRelatesTo().add((CitationCitedArtifactRelatesToComponent) value); // CitationCitedArtifactRelatesToComponent 2390 return value; 2391 case 1470639376: // publicationForm 2392 this.getPublicationForm().add((CitationCitedArtifactPublicationFormComponent) value); // CitationCitedArtifactPublicationFormComponent 2393 return value; 2394 case -828032215: // webLocation 2395 this.getWebLocation().add((CitationCitedArtifactWebLocationComponent) value); // CitationCitedArtifactWebLocationComponent 2396 return value; 2397 case 382350310: // classification 2398 this.getClassification().add((CitationCitedArtifactClassificationComponent) value); // CitationCitedArtifactClassificationComponent 2399 return value; 2400 case 538727831: // contributorship 2401 this.contributorship = (CitationCitedArtifactContributorshipComponent) value; // CitationCitedArtifactContributorshipComponent 2402 return value; 2403 case 3387378: // note 2404 this.getNote().add(TypeConvertor.castToAnnotation(value)); // Annotation 2405 return value; 2406 default: return super.setProperty(hash, name, value); 2407 } 2408 2409 } 2410 2411 @Override 2412 public Base setProperty(String name, Base value) throws FHIRException { 2413 if (name.equals("identifier")) { 2414 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 2415 } else if (name.equals("relatedIdentifier")) { 2416 this.getRelatedIdentifier().add(TypeConvertor.castToIdentifier(value)); 2417 } else if (name.equals("dateAccessed")) { 2418 this.dateAccessed = TypeConvertor.castToDateTime(value); // DateTimeType 2419 } else if (name.equals("version")) { 2420 this.version = (CitationCitedArtifactVersionComponent) value; // CitationCitedArtifactVersionComponent 2421 } else if (name.equals("currentState")) { 2422 this.getCurrentState().add(TypeConvertor.castToCodeableConcept(value)); 2423 } else if (name.equals("statusDate")) { 2424 this.getStatusDate().add((CitationCitedArtifactStatusDateComponent) value); 2425 } else if (name.equals("title")) { 2426 this.getTitle().add((CitationCitedArtifactTitleComponent) value); 2427 } else if (name.equals("abstract")) { 2428 this.getAbstract().add((CitationCitedArtifactAbstractComponent) value); 2429 } else if (name.equals("part")) { 2430 this.part = (CitationCitedArtifactPartComponent) value; // CitationCitedArtifactPartComponent 2431 } else if (name.equals("relatesTo")) { 2432 this.getRelatesTo().add((CitationCitedArtifactRelatesToComponent) value); 2433 } else if (name.equals("publicationForm")) { 2434 this.getPublicationForm().add((CitationCitedArtifactPublicationFormComponent) value); 2435 } else if (name.equals("webLocation")) { 2436 this.getWebLocation().add((CitationCitedArtifactWebLocationComponent) value); 2437 } else if (name.equals("classification")) { 2438 this.getClassification().add((CitationCitedArtifactClassificationComponent) value); 2439 } else if (name.equals("contributorship")) { 2440 this.contributorship = (CitationCitedArtifactContributorshipComponent) value; // CitationCitedArtifactContributorshipComponent 2441 } else if (name.equals("note")) { 2442 this.getNote().add(TypeConvertor.castToAnnotation(value)); 2443 } else 2444 return super.setProperty(name, value); 2445 return value; 2446 } 2447 2448 @Override 2449 public Base makeProperty(int hash, String name) throws FHIRException { 2450 switch (hash) { 2451 case -1618432855: return addIdentifier(); 2452 case -1007604940: return addRelatedIdentifier(); 2453 case 540917457: return getDateAccessedElement(); 2454 case 351608024: return getVersion(); 2455 case 1457822360: return addCurrentState(); 2456 case 247524032: return addStatusDate(); 2457 case 110371416: return addTitle(); 2458 case 1732898850: return addAbstract(); 2459 case 3433459: return getPart(); 2460 case -7765931: return addRelatesTo(); 2461 case 1470639376: return addPublicationForm(); 2462 case -828032215: return addWebLocation(); 2463 case 382350310: return addClassification(); 2464 case 538727831: return getContributorship(); 2465 case 3387378: return addNote(); 2466 default: return super.makeProperty(hash, name); 2467 } 2468 2469 } 2470 2471 @Override 2472 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2473 switch (hash) { 2474 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 2475 case -1007604940: /*relatedIdentifier*/ return new String[] {"Identifier"}; 2476 case 540917457: /*dateAccessed*/ return new String[] {"dateTime"}; 2477 case 351608024: /*version*/ return new String[] {}; 2478 case 1457822360: /*currentState*/ return new String[] {"CodeableConcept"}; 2479 case 247524032: /*statusDate*/ return new String[] {}; 2480 case 110371416: /*title*/ return new String[] {}; 2481 case 1732898850: /*abstract*/ return new String[] {}; 2482 case 3433459: /*part*/ return new String[] {}; 2483 case -7765931: /*relatesTo*/ return new String[] {}; 2484 case 1470639376: /*publicationForm*/ return new String[] {}; 2485 case -828032215: /*webLocation*/ return new String[] {}; 2486 case 382350310: /*classification*/ return new String[] {}; 2487 case 538727831: /*contributorship*/ return new String[] {}; 2488 case 3387378: /*note*/ return new String[] {"Annotation"}; 2489 default: return super.getTypesForProperty(hash, name); 2490 } 2491 2492 } 2493 2494 @Override 2495 public Base addChild(String name) throws FHIRException { 2496 if (name.equals("identifier")) { 2497 return addIdentifier(); 2498 } 2499 else if (name.equals("relatedIdentifier")) { 2500 return addRelatedIdentifier(); 2501 } 2502 else if (name.equals("dateAccessed")) { 2503 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.dateAccessed"); 2504 } 2505 else if (name.equals("version")) { 2506 this.version = new CitationCitedArtifactVersionComponent(); 2507 return this.version; 2508 } 2509 else if (name.equals("currentState")) { 2510 return addCurrentState(); 2511 } 2512 else if (name.equals("statusDate")) { 2513 return addStatusDate(); 2514 } 2515 else if (name.equals("title")) { 2516 return addTitle(); 2517 } 2518 else if (name.equals("abstract")) { 2519 return addAbstract(); 2520 } 2521 else if (name.equals("part")) { 2522 this.part = new CitationCitedArtifactPartComponent(); 2523 return this.part; 2524 } 2525 else if (name.equals("relatesTo")) { 2526 return addRelatesTo(); 2527 } 2528 else if (name.equals("publicationForm")) { 2529 return addPublicationForm(); 2530 } 2531 else if (name.equals("webLocation")) { 2532 return addWebLocation(); 2533 } 2534 else if (name.equals("classification")) { 2535 return addClassification(); 2536 } 2537 else if (name.equals("contributorship")) { 2538 this.contributorship = new CitationCitedArtifactContributorshipComponent(); 2539 return this.contributorship; 2540 } 2541 else if (name.equals("note")) { 2542 return addNote(); 2543 } 2544 else 2545 return super.addChild(name); 2546 } 2547 2548 public CitationCitedArtifactComponent copy() { 2549 CitationCitedArtifactComponent dst = new CitationCitedArtifactComponent(); 2550 copyValues(dst); 2551 return dst; 2552 } 2553 2554 public void copyValues(CitationCitedArtifactComponent dst) { 2555 super.copyValues(dst); 2556 if (identifier != null) { 2557 dst.identifier = new ArrayList<Identifier>(); 2558 for (Identifier i : identifier) 2559 dst.identifier.add(i.copy()); 2560 }; 2561 if (relatedIdentifier != null) { 2562 dst.relatedIdentifier = new ArrayList<Identifier>(); 2563 for (Identifier i : relatedIdentifier) 2564 dst.relatedIdentifier.add(i.copy()); 2565 }; 2566 dst.dateAccessed = dateAccessed == null ? null : dateAccessed.copy(); 2567 dst.version = version == null ? null : version.copy(); 2568 if (currentState != null) { 2569 dst.currentState = new ArrayList<CodeableConcept>(); 2570 for (CodeableConcept i : currentState) 2571 dst.currentState.add(i.copy()); 2572 }; 2573 if (statusDate != null) { 2574 dst.statusDate = new ArrayList<CitationCitedArtifactStatusDateComponent>(); 2575 for (CitationCitedArtifactStatusDateComponent i : statusDate) 2576 dst.statusDate.add(i.copy()); 2577 }; 2578 if (title != null) { 2579 dst.title = new ArrayList<CitationCitedArtifactTitleComponent>(); 2580 for (CitationCitedArtifactTitleComponent i : title) 2581 dst.title.add(i.copy()); 2582 }; 2583 if (abstract_ != null) { 2584 dst.abstract_ = new ArrayList<CitationCitedArtifactAbstractComponent>(); 2585 for (CitationCitedArtifactAbstractComponent i : abstract_) 2586 dst.abstract_.add(i.copy()); 2587 }; 2588 dst.part = part == null ? null : part.copy(); 2589 if (relatesTo != null) { 2590 dst.relatesTo = new ArrayList<CitationCitedArtifactRelatesToComponent>(); 2591 for (CitationCitedArtifactRelatesToComponent i : relatesTo) 2592 dst.relatesTo.add(i.copy()); 2593 }; 2594 if (publicationForm != null) { 2595 dst.publicationForm = new ArrayList<CitationCitedArtifactPublicationFormComponent>(); 2596 for (CitationCitedArtifactPublicationFormComponent i : publicationForm) 2597 dst.publicationForm.add(i.copy()); 2598 }; 2599 if (webLocation != null) { 2600 dst.webLocation = new ArrayList<CitationCitedArtifactWebLocationComponent>(); 2601 for (CitationCitedArtifactWebLocationComponent i : webLocation) 2602 dst.webLocation.add(i.copy()); 2603 }; 2604 if (classification != null) { 2605 dst.classification = new ArrayList<CitationCitedArtifactClassificationComponent>(); 2606 for (CitationCitedArtifactClassificationComponent i : classification) 2607 dst.classification.add(i.copy()); 2608 }; 2609 dst.contributorship = contributorship == null ? null : contributorship.copy(); 2610 if (note != null) { 2611 dst.note = new ArrayList<Annotation>(); 2612 for (Annotation i : note) 2613 dst.note.add(i.copy()); 2614 }; 2615 } 2616 2617 @Override 2618 public boolean equalsDeep(Base other_) { 2619 if (!super.equalsDeep(other_)) 2620 return false; 2621 if (!(other_ instanceof CitationCitedArtifactComponent)) 2622 return false; 2623 CitationCitedArtifactComponent o = (CitationCitedArtifactComponent) other_; 2624 return compareDeep(identifier, o.identifier, true) && compareDeep(relatedIdentifier, o.relatedIdentifier, true) 2625 && compareDeep(dateAccessed, o.dateAccessed, true) && compareDeep(version, o.version, true) && compareDeep(currentState, o.currentState, true) 2626 && compareDeep(statusDate, o.statusDate, true) && compareDeep(title, o.title, true) && compareDeep(abstract_, o.abstract_, true) 2627 && compareDeep(part, o.part, true) && compareDeep(relatesTo, o.relatesTo, true) && compareDeep(publicationForm, o.publicationForm, true) 2628 && compareDeep(webLocation, o.webLocation, true) && compareDeep(classification, o.classification, true) 2629 && compareDeep(contributorship, o.contributorship, true) && compareDeep(note, o.note, true); 2630 } 2631 2632 @Override 2633 public boolean equalsShallow(Base other_) { 2634 if (!super.equalsShallow(other_)) 2635 return false; 2636 if (!(other_ instanceof CitationCitedArtifactComponent)) 2637 return false; 2638 CitationCitedArtifactComponent o = (CitationCitedArtifactComponent) other_; 2639 return compareValues(dateAccessed, o.dateAccessed, true); 2640 } 2641 2642 public boolean isEmpty() { 2643 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(identifier, relatedIdentifier 2644 , dateAccessed, version, currentState, statusDate, title, abstract_, part, relatesTo 2645 , publicationForm, webLocation, classification, contributorship, note); 2646 } 2647 2648 public String fhirType() { 2649 return "Citation.citedArtifact"; 2650 2651 } 2652 2653 } 2654 2655 @Block() 2656 public static class CitationCitedArtifactVersionComponent extends BackboneElement implements IBaseBackboneElement { 2657 /** 2658 * The version number or other version identifier. 2659 */ 2660 @Child(name = "value", type = {StringType.class}, order=1, min=1, max=1, modifier=false, summary=false) 2661 @Description(shortDefinition="The version number or other version identifier", formalDefinition="The version number or other version identifier." ) 2662 protected StringType value; 2663 2664 /** 2665 * Citation for the main version of the cited artifact. 2666 */ 2667 @Child(name = "baseCitation", type = {Citation.class}, order=2, min=0, max=1, modifier=false, summary=false) 2668 @Description(shortDefinition="Citation for the main version of the cited artifact", formalDefinition="Citation for the main version of the cited artifact." ) 2669 protected Reference baseCitation; 2670 2671 private static final long serialVersionUID = 1437090319L; 2672 2673 /** 2674 * Constructor 2675 */ 2676 public CitationCitedArtifactVersionComponent() { 2677 super(); 2678 } 2679 2680 /** 2681 * Constructor 2682 */ 2683 public CitationCitedArtifactVersionComponent(String value) { 2684 super(); 2685 this.setValue(value); 2686 } 2687 2688 /** 2689 * @return {@link #value} (The version number or other version identifier.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 2690 */ 2691 public StringType getValueElement() { 2692 if (this.value == null) 2693 if (Configuration.errorOnAutoCreate()) 2694 throw new Error("Attempt to auto-create CitationCitedArtifactVersionComponent.value"); 2695 else if (Configuration.doAutoCreate()) 2696 this.value = new StringType(); // bb 2697 return this.value; 2698 } 2699 2700 public boolean hasValueElement() { 2701 return this.value != null && !this.value.isEmpty(); 2702 } 2703 2704 public boolean hasValue() { 2705 return this.value != null && !this.value.isEmpty(); 2706 } 2707 2708 /** 2709 * @param value {@link #value} (The version number or other version identifier.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 2710 */ 2711 public CitationCitedArtifactVersionComponent setValueElement(StringType value) { 2712 this.value = value; 2713 return this; 2714 } 2715 2716 /** 2717 * @return The version number or other version identifier. 2718 */ 2719 public String getValue() { 2720 return this.value == null ? null : this.value.getValue(); 2721 } 2722 2723 /** 2724 * @param value The version number or other version identifier. 2725 */ 2726 public CitationCitedArtifactVersionComponent setValue(String value) { 2727 if (this.value == null) 2728 this.value = new StringType(); 2729 this.value.setValue(value); 2730 return this; 2731 } 2732 2733 /** 2734 * @return {@link #baseCitation} (Citation for the main version of the cited artifact.) 2735 */ 2736 public Reference getBaseCitation() { 2737 if (this.baseCitation == null) 2738 if (Configuration.errorOnAutoCreate()) 2739 throw new Error("Attempt to auto-create CitationCitedArtifactVersionComponent.baseCitation"); 2740 else if (Configuration.doAutoCreate()) 2741 this.baseCitation = new Reference(); // cc 2742 return this.baseCitation; 2743 } 2744 2745 public boolean hasBaseCitation() { 2746 return this.baseCitation != null && !this.baseCitation.isEmpty(); 2747 } 2748 2749 /** 2750 * @param value {@link #baseCitation} (Citation for the main version of the cited artifact.) 2751 */ 2752 public CitationCitedArtifactVersionComponent setBaseCitation(Reference value) { 2753 this.baseCitation = value; 2754 return this; 2755 } 2756 2757 protected void listChildren(List<Property> children) { 2758 super.listChildren(children); 2759 children.add(new Property("value", "string", "The version number or other version identifier.", 0, 1, value)); 2760 children.add(new Property("baseCitation", "Reference(Citation)", "Citation for the main version of the cited artifact.", 0, 1, baseCitation)); 2761 } 2762 2763 @Override 2764 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 2765 switch (_hash) { 2766 case 111972721: /*value*/ return new Property("value", "string", "The version number or other version identifier.", 0, 1, value); 2767 case 1182995672: /*baseCitation*/ return new Property("baseCitation", "Reference(Citation)", "Citation for the main version of the cited artifact.", 0, 1, baseCitation); 2768 default: return super.getNamedProperty(_hash, _name, _checkValid); 2769 } 2770 2771 } 2772 2773 @Override 2774 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 2775 switch (hash) { 2776 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // StringType 2777 case 1182995672: /*baseCitation*/ return this.baseCitation == null ? new Base[0] : new Base[] {this.baseCitation}; // Reference 2778 default: return super.getProperty(hash, name, checkValid); 2779 } 2780 2781 } 2782 2783 @Override 2784 public Base setProperty(int hash, String name, Base value) throws FHIRException { 2785 switch (hash) { 2786 case 111972721: // value 2787 this.value = TypeConvertor.castToString(value); // StringType 2788 return value; 2789 case 1182995672: // baseCitation 2790 this.baseCitation = TypeConvertor.castToReference(value); // Reference 2791 return value; 2792 default: return super.setProperty(hash, name, value); 2793 } 2794 2795 } 2796 2797 @Override 2798 public Base setProperty(String name, Base value) throws FHIRException { 2799 if (name.equals("value")) { 2800 this.value = TypeConvertor.castToString(value); // StringType 2801 } else if (name.equals("baseCitation")) { 2802 this.baseCitation = TypeConvertor.castToReference(value); // Reference 2803 } else 2804 return super.setProperty(name, value); 2805 return value; 2806 } 2807 2808 @Override 2809 public Base makeProperty(int hash, String name) throws FHIRException { 2810 switch (hash) { 2811 case 111972721: return getValueElement(); 2812 case 1182995672: return getBaseCitation(); 2813 default: return super.makeProperty(hash, name); 2814 } 2815 2816 } 2817 2818 @Override 2819 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 2820 switch (hash) { 2821 case 111972721: /*value*/ return new String[] {"string"}; 2822 case 1182995672: /*baseCitation*/ return new String[] {"Reference"}; 2823 default: return super.getTypesForProperty(hash, name); 2824 } 2825 2826 } 2827 2828 @Override 2829 public Base addChild(String name) throws FHIRException { 2830 if (name.equals("value")) { 2831 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.version.value"); 2832 } 2833 else if (name.equals("baseCitation")) { 2834 this.baseCitation = new Reference(); 2835 return this.baseCitation; 2836 } 2837 else 2838 return super.addChild(name); 2839 } 2840 2841 public CitationCitedArtifactVersionComponent copy() { 2842 CitationCitedArtifactVersionComponent dst = new CitationCitedArtifactVersionComponent(); 2843 copyValues(dst); 2844 return dst; 2845 } 2846 2847 public void copyValues(CitationCitedArtifactVersionComponent dst) { 2848 super.copyValues(dst); 2849 dst.value = value == null ? null : value.copy(); 2850 dst.baseCitation = baseCitation == null ? null : baseCitation.copy(); 2851 } 2852 2853 @Override 2854 public boolean equalsDeep(Base other_) { 2855 if (!super.equalsDeep(other_)) 2856 return false; 2857 if (!(other_ instanceof CitationCitedArtifactVersionComponent)) 2858 return false; 2859 CitationCitedArtifactVersionComponent o = (CitationCitedArtifactVersionComponent) other_; 2860 return compareDeep(value, o.value, true) && compareDeep(baseCitation, o.baseCitation, true); 2861 } 2862 2863 @Override 2864 public boolean equalsShallow(Base other_) { 2865 if (!super.equalsShallow(other_)) 2866 return false; 2867 if (!(other_ instanceof CitationCitedArtifactVersionComponent)) 2868 return false; 2869 CitationCitedArtifactVersionComponent o = (CitationCitedArtifactVersionComponent) other_; 2870 return compareValues(value, o.value, true); 2871 } 2872 2873 public boolean isEmpty() { 2874 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(value, baseCitation); 2875 } 2876 2877 public String fhirType() { 2878 return "Citation.citedArtifact.version"; 2879 2880 } 2881 2882 } 2883 2884 @Block() 2885 public static class CitationCitedArtifactStatusDateComponent extends BackboneElement implements IBaseBackboneElement { 2886 /** 2887 * Classification of the status. 2888 */ 2889 @Child(name = "activity", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 2890 @Description(shortDefinition="Classification of the status", formalDefinition="Classification of the status." ) 2891 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-artifact-status-type") 2892 protected CodeableConcept activity; 2893 2894 /** 2895 * Either occurred or expected. 2896 */ 2897 @Child(name = "actual", type = {BooleanType.class}, order=2, min=0, max=1, modifier=false, summary=false) 2898 @Description(shortDefinition="Either occurred or expected", formalDefinition="Either occurred or expected." ) 2899 protected BooleanType actual; 2900 2901 /** 2902 * When the status started and/or ended. 2903 */ 2904 @Child(name = "period", type = {Period.class}, order=3, min=1, max=1, modifier=false, summary=false) 2905 @Description(shortDefinition="When the status started and/or ended", formalDefinition="When the status started and/or ended." ) 2906 protected Period period; 2907 2908 private static final long serialVersionUID = 1123586924L; 2909 2910 /** 2911 * Constructor 2912 */ 2913 public CitationCitedArtifactStatusDateComponent() { 2914 super(); 2915 } 2916 2917 /** 2918 * Constructor 2919 */ 2920 public CitationCitedArtifactStatusDateComponent(CodeableConcept activity, Period period) { 2921 super(); 2922 this.setActivity(activity); 2923 this.setPeriod(period); 2924 } 2925 2926 /** 2927 * @return {@link #activity} (Classification of the status.) 2928 */ 2929 public CodeableConcept getActivity() { 2930 if (this.activity == null) 2931 if (Configuration.errorOnAutoCreate()) 2932 throw new Error("Attempt to auto-create CitationCitedArtifactStatusDateComponent.activity"); 2933 else if (Configuration.doAutoCreate()) 2934 this.activity = new CodeableConcept(); // cc 2935 return this.activity; 2936 } 2937 2938 public boolean hasActivity() { 2939 return this.activity != null && !this.activity.isEmpty(); 2940 } 2941 2942 /** 2943 * @param value {@link #activity} (Classification of the status.) 2944 */ 2945 public CitationCitedArtifactStatusDateComponent setActivity(CodeableConcept value) { 2946 this.activity = value; 2947 return this; 2948 } 2949 2950 /** 2951 * @return {@link #actual} (Either occurred or expected.). This is the underlying object with id, value and extensions. The accessor "getActual" gives direct access to the value 2952 */ 2953 public BooleanType getActualElement() { 2954 if (this.actual == null) 2955 if (Configuration.errorOnAutoCreate()) 2956 throw new Error("Attempt to auto-create CitationCitedArtifactStatusDateComponent.actual"); 2957 else if (Configuration.doAutoCreate()) 2958 this.actual = new BooleanType(); // bb 2959 return this.actual; 2960 } 2961 2962 public boolean hasActualElement() { 2963 return this.actual != null && !this.actual.isEmpty(); 2964 } 2965 2966 public boolean hasActual() { 2967 return this.actual != null && !this.actual.isEmpty(); 2968 } 2969 2970 /** 2971 * @param value {@link #actual} (Either occurred or expected.). This is the underlying object with id, value and extensions. The accessor "getActual" gives direct access to the value 2972 */ 2973 public CitationCitedArtifactStatusDateComponent setActualElement(BooleanType value) { 2974 this.actual = value; 2975 return this; 2976 } 2977 2978 /** 2979 * @return Either occurred or expected. 2980 */ 2981 public boolean getActual() { 2982 return this.actual == null || this.actual.isEmpty() ? false : this.actual.getValue(); 2983 } 2984 2985 /** 2986 * @param value Either occurred or expected. 2987 */ 2988 public CitationCitedArtifactStatusDateComponent setActual(boolean value) { 2989 if (this.actual == null) 2990 this.actual = new BooleanType(); 2991 this.actual.setValue(value); 2992 return this; 2993 } 2994 2995 /** 2996 * @return {@link #period} (When the status started and/or ended.) 2997 */ 2998 public Period getPeriod() { 2999 if (this.period == null) 3000 if (Configuration.errorOnAutoCreate()) 3001 throw new Error("Attempt to auto-create CitationCitedArtifactStatusDateComponent.period"); 3002 else if (Configuration.doAutoCreate()) 3003 this.period = new Period(); // cc 3004 return this.period; 3005 } 3006 3007 public boolean hasPeriod() { 3008 return this.period != null && !this.period.isEmpty(); 3009 } 3010 3011 /** 3012 * @param value {@link #period} (When the status started and/or ended.) 3013 */ 3014 public CitationCitedArtifactStatusDateComponent setPeriod(Period value) { 3015 this.period = value; 3016 return this; 3017 } 3018 3019 protected void listChildren(List<Property> children) { 3020 super.listChildren(children); 3021 children.add(new Property("activity", "CodeableConcept", "Classification of the status.", 0, 1, activity)); 3022 children.add(new Property("actual", "boolean", "Either occurred or expected.", 0, 1, actual)); 3023 children.add(new Property("period", "Period", "When the status started and/or ended.", 0, 1, period)); 3024 } 3025 3026 @Override 3027 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3028 switch (_hash) { 3029 case -1655966961: /*activity*/ return new Property("activity", "CodeableConcept", "Classification of the status.", 0, 1, activity); 3030 case -1422939762: /*actual*/ return new Property("actual", "boolean", "Either occurred or expected.", 0, 1, actual); 3031 case -991726143: /*period*/ return new Property("period", "Period", "When the status started and/or ended.", 0, 1, period); 3032 default: return super.getNamedProperty(_hash, _name, _checkValid); 3033 } 3034 3035 } 3036 3037 @Override 3038 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3039 switch (hash) { 3040 case -1655966961: /*activity*/ return this.activity == null ? new Base[0] : new Base[] {this.activity}; // CodeableConcept 3041 case -1422939762: /*actual*/ return this.actual == null ? new Base[0] : new Base[] {this.actual}; // BooleanType 3042 case -991726143: /*period*/ return this.period == null ? new Base[0] : new Base[] {this.period}; // Period 3043 default: return super.getProperty(hash, name, checkValid); 3044 } 3045 3046 } 3047 3048 @Override 3049 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3050 switch (hash) { 3051 case -1655966961: // activity 3052 this.activity = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3053 return value; 3054 case -1422939762: // actual 3055 this.actual = TypeConvertor.castToBoolean(value); // BooleanType 3056 return value; 3057 case -991726143: // period 3058 this.period = TypeConvertor.castToPeriod(value); // Period 3059 return value; 3060 default: return super.setProperty(hash, name, value); 3061 } 3062 3063 } 3064 3065 @Override 3066 public Base setProperty(String name, Base value) throws FHIRException { 3067 if (name.equals("activity")) { 3068 this.activity = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3069 } else if (name.equals("actual")) { 3070 this.actual = TypeConvertor.castToBoolean(value); // BooleanType 3071 } else if (name.equals("period")) { 3072 this.period = TypeConvertor.castToPeriod(value); // Period 3073 } else 3074 return super.setProperty(name, value); 3075 return value; 3076 } 3077 3078 @Override 3079 public Base makeProperty(int hash, String name) throws FHIRException { 3080 switch (hash) { 3081 case -1655966961: return getActivity(); 3082 case -1422939762: return getActualElement(); 3083 case -991726143: return getPeriod(); 3084 default: return super.makeProperty(hash, name); 3085 } 3086 3087 } 3088 3089 @Override 3090 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3091 switch (hash) { 3092 case -1655966961: /*activity*/ return new String[] {"CodeableConcept"}; 3093 case -1422939762: /*actual*/ return new String[] {"boolean"}; 3094 case -991726143: /*period*/ return new String[] {"Period"}; 3095 default: return super.getTypesForProperty(hash, name); 3096 } 3097 3098 } 3099 3100 @Override 3101 public Base addChild(String name) throws FHIRException { 3102 if (name.equals("activity")) { 3103 this.activity = new CodeableConcept(); 3104 return this.activity; 3105 } 3106 else if (name.equals("actual")) { 3107 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.statusDate.actual"); 3108 } 3109 else if (name.equals("period")) { 3110 this.period = new Period(); 3111 return this.period; 3112 } 3113 else 3114 return super.addChild(name); 3115 } 3116 3117 public CitationCitedArtifactStatusDateComponent copy() { 3118 CitationCitedArtifactStatusDateComponent dst = new CitationCitedArtifactStatusDateComponent(); 3119 copyValues(dst); 3120 return dst; 3121 } 3122 3123 public void copyValues(CitationCitedArtifactStatusDateComponent dst) { 3124 super.copyValues(dst); 3125 dst.activity = activity == null ? null : activity.copy(); 3126 dst.actual = actual == null ? null : actual.copy(); 3127 dst.period = period == null ? null : period.copy(); 3128 } 3129 3130 @Override 3131 public boolean equalsDeep(Base other_) { 3132 if (!super.equalsDeep(other_)) 3133 return false; 3134 if (!(other_ instanceof CitationCitedArtifactStatusDateComponent)) 3135 return false; 3136 CitationCitedArtifactStatusDateComponent o = (CitationCitedArtifactStatusDateComponent) other_; 3137 return compareDeep(activity, o.activity, true) && compareDeep(actual, o.actual, true) && compareDeep(period, o.period, true) 3138 ; 3139 } 3140 3141 @Override 3142 public boolean equalsShallow(Base other_) { 3143 if (!super.equalsShallow(other_)) 3144 return false; 3145 if (!(other_ instanceof CitationCitedArtifactStatusDateComponent)) 3146 return false; 3147 CitationCitedArtifactStatusDateComponent o = (CitationCitedArtifactStatusDateComponent) other_; 3148 return compareValues(actual, o.actual, true); 3149 } 3150 3151 public boolean isEmpty() { 3152 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(activity, actual, period 3153 ); 3154 } 3155 3156 public String fhirType() { 3157 return "Citation.citedArtifact.statusDate"; 3158 3159 } 3160 3161 } 3162 3163 @Block() 3164 public static class CitationCitedArtifactTitleComponent extends BackboneElement implements IBaseBackboneElement { 3165 /** 3166 * Used to express the reason or specific aspect for the title. 3167 */ 3168 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 3169 @Description(shortDefinition="The kind of title", formalDefinition="Used to express the reason or specific aspect for the title." ) 3170 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/title-type") 3171 protected List<CodeableConcept> type; 3172 3173 /** 3174 * Used to express the specific language. 3175 */ 3176 @Child(name = "language", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 3177 @Description(shortDefinition="Used to express the specific language", formalDefinition="Used to express the specific language." ) 3178 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/languages") 3179 protected CodeableConcept language; 3180 3181 /** 3182 * The title of the article or artifact. 3183 */ 3184 @Child(name = "text", type = {MarkdownType.class}, order=3, min=1, max=1, modifier=false, summary=false) 3185 @Description(shortDefinition="The title of the article or artifact", formalDefinition="The title of the article or artifact." ) 3186 protected MarkdownType text; 3187 3188 private static final long serialVersionUID = 1526221998L; 3189 3190 /** 3191 * Constructor 3192 */ 3193 public CitationCitedArtifactTitleComponent() { 3194 super(); 3195 } 3196 3197 /** 3198 * Constructor 3199 */ 3200 public CitationCitedArtifactTitleComponent(String text) { 3201 super(); 3202 this.setText(text); 3203 } 3204 3205 /** 3206 * @return {@link #type} (Used to express the reason or specific aspect for the title.) 3207 */ 3208 public List<CodeableConcept> getType() { 3209 if (this.type == null) 3210 this.type = new ArrayList<CodeableConcept>(); 3211 return this.type; 3212 } 3213 3214 /** 3215 * @return Returns a reference to <code>this</code> for easy method chaining 3216 */ 3217 public CitationCitedArtifactTitleComponent setType(List<CodeableConcept> theType) { 3218 this.type = theType; 3219 return this; 3220 } 3221 3222 public boolean hasType() { 3223 if (this.type == null) 3224 return false; 3225 for (CodeableConcept item : this.type) 3226 if (!item.isEmpty()) 3227 return true; 3228 return false; 3229 } 3230 3231 public CodeableConcept addType() { //3 3232 CodeableConcept t = new CodeableConcept(); 3233 if (this.type == null) 3234 this.type = new ArrayList<CodeableConcept>(); 3235 this.type.add(t); 3236 return t; 3237 } 3238 3239 public CitationCitedArtifactTitleComponent addType(CodeableConcept t) { //3 3240 if (t == null) 3241 return this; 3242 if (this.type == null) 3243 this.type = new ArrayList<CodeableConcept>(); 3244 this.type.add(t); 3245 return this; 3246 } 3247 3248 /** 3249 * @return The first repetition of repeating field {@link #type}, creating it if it does not already exist {3} 3250 */ 3251 public CodeableConcept getTypeFirstRep() { 3252 if (getType().isEmpty()) { 3253 addType(); 3254 } 3255 return getType().get(0); 3256 } 3257 3258 /** 3259 * @return {@link #language} (Used to express the specific language.) 3260 */ 3261 public CodeableConcept getLanguage() { 3262 if (this.language == null) 3263 if (Configuration.errorOnAutoCreate()) 3264 throw new Error("Attempt to auto-create CitationCitedArtifactTitleComponent.language"); 3265 else if (Configuration.doAutoCreate()) 3266 this.language = new CodeableConcept(); // cc 3267 return this.language; 3268 } 3269 3270 public boolean hasLanguage() { 3271 return this.language != null && !this.language.isEmpty(); 3272 } 3273 3274 /** 3275 * @param value {@link #language} (Used to express the specific language.) 3276 */ 3277 public CitationCitedArtifactTitleComponent setLanguage(CodeableConcept value) { 3278 this.language = value; 3279 return this; 3280 } 3281 3282 /** 3283 * @return {@link #text} (The title of the article or artifact.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 3284 */ 3285 public MarkdownType getTextElement() { 3286 if (this.text == null) 3287 if (Configuration.errorOnAutoCreate()) 3288 throw new Error("Attempt to auto-create CitationCitedArtifactTitleComponent.text"); 3289 else if (Configuration.doAutoCreate()) 3290 this.text = new MarkdownType(); // bb 3291 return this.text; 3292 } 3293 3294 public boolean hasTextElement() { 3295 return this.text != null && !this.text.isEmpty(); 3296 } 3297 3298 public boolean hasText() { 3299 return this.text != null && !this.text.isEmpty(); 3300 } 3301 3302 /** 3303 * @param value {@link #text} (The title of the article or artifact.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 3304 */ 3305 public CitationCitedArtifactTitleComponent setTextElement(MarkdownType value) { 3306 this.text = value; 3307 return this; 3308 } 3309 3310 /** 3311 * @return The title of the article or artifact. 3312 */ 3313 public String getText() { 3314 return this.text == null ? null : this.text.getValue(); 3315 } 3316 3317 /** 3318 * @param value The title of the article or artifact. 3319 */ 3320 public CitationCitedArtifactTitleComponent setText(String value) { 3321 if (this.text == null) 3322 this.text = new MarkdownType(); 3323 this.text.setValue(value); 3324 return this; 3325 } 3326 3327 protected void listChildren(List<Property> children) { 3328 super.listChildren(children); 3329 children.add(new Property("type", "CodeableConcept", "Used to express the reason or specific aspect for the title.", 0, java.lang.Integer.MAX_VALUE, type)); 3330 children.add(new Property("language", "CodeableConcept", "Used to express the specific language.", 0, 1, language)); 3331 children.add(new Property("text", "markdown", "The title of the article or artifact.", 0, 1, text)); 3332 } 3333 3334 @Override 3335 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3336 switch (_hash) { 3337 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Used to express the reason or specific aspect for the title.", 0, java.lang.Integer.MAX_VALUE, type); 3338 case -1613589672: /*language*/ return new Property("language", "CodeableConcept", "Used to express the specific language.", 0, 1, language); 3339 case 3556653: /*text*/ return new Property("text", "markdown", "The title of the article or artifact.", 0, 1, text); 3340 default: return super.getNamedProperty(_hash, _name, _checkValid); 3341 } 3342 3343 } 3344 3345 @Override 3346 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3347 switch (hash) { 3348 case 3575610: /*type*/ return this.type == null ? new Base[0] : this.type.toArray(new Base[this.type.size()]); // CodeableConcept 3349 case -1613589672: /*language*/ return this.language == null ? new Base[0] : new Base[] {this.language}; // CodeableConcept 3350 case 3556653: /*text*/ return this.text == null ? new Base[0] : new Base[] {this.text}; // MarkdownType 3351 default: return super.getProperty(hash, name, checkValid); 3352 } 3353 3354 } 3355 3356 @Override 3357 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3358 switch (hash) { 3359 case 3575610: // type 3360 this.getType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 3361 return value; 3362 case -1613589672: // language 3363 this.language = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3364 return value; 3365 case 3556653: // text 3366 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 3367 return value; 3368 default: return super.setProperty(hash, name, value); 3369 } 3370 3371 } 3372 3373 @Override 3374 public Base setProperty(String name, Base value) throws FHIRException { 3375 if (name.equals("type")) { 3376 this.getType().add(TypeConvertor.castToCodeableConcept(value)); 3377 } else if (name.equals("language")) { 3378 this.language = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3379 } else if (name.equals("text")) { 3380 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 3381 } else 3382 return super.setProperty(name, value); 3383 return value; 3384 } 3385 3386 @Override 3387 public Base makeProperty(int hash, String name) throws FHIRException { 3388 switch (hash) { 3389 case 3575610: return addType(); 3390 case -1613589672: return getLanguage(); 3391 case 3556653: return getTextElement(); 3392 default: return super.makeProperty(hash, name); 3393 } 3394 3395 } 3396 3397 @Override 3398 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3399 switch (hash) { 3400 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 3401 case -1613589672: /*language*/ return new String[] {"CodeableConcept"}; 3402 case 3556653: /*text*/ return new String[] {"markdown"}; 3403 default: return super.getTypesForProperty(hash, name); 3404 } 3405 3406 } 3407 3408 @Override 3409 public Base addChild(String name) throws FHIRException { 3410 if (name.equals("type")) { 3411 return addType(); 3412 } 3413 else if (name.equals("language")) { 3414 this.language = new CodeableConcept(); 3415 return this.language; 3416 } 3417 else if (name.equals("text")) { 3418 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.title.text"); 3419 } 3420 else 3421 return super.addChild(name); 3422 } 3423 3424 public CitationCitedArtifactTitleComponent copy() { 3425 CitationCitedArtifactTitleComponent dst = new CitationCitedArtifactTitleComponent(); 3426 copyValues(dst); 3427 return dst; 3428 } 3429 3430 public void copyValues(CitationCitedArtifactTitleComponent dst) { 3431 super.copyValues(dst); 3432 if (type != null) { 3433 dst.type = new ArrayList<CodeableConcept>(); 3434 for (CodeableConcept i : type) 3435 dst.type.add(i.copy()); 3436 }; 3437 dst.language = language == null ? null : language.copy(); 3438 dst.text = text == null ? null : text.copy(); 3439 } 3440 3441 @Override 3442 public boolean equalsDeep(Base other_) { 3443 if (!super.equalsDeep(other_)) 3444 return false; 3445 if (!(other_ instanceof CitationCitedArtifactTitleComponent)) 3446 return false; 3447 CitationCitedArtifactTitleComponent o = (CitationCitedArtifactTitleComponent) other_; 3448 return compareDeep(type, o.type, true) && compareDeep(language, o.language, true) && compareDeep(text, o.text, true) 3449 ; 3450 } 3451 3452 @Override 3453 public boolean equalsShallow(Base other_) { 3454 if (!super.equalsShallow(other_)) 3455 return false; 3456 if (!(other_ instanceof CitationCitedArtifactTitleComponent)) 3457 return false; 3458 CitationCitedArtifactTitleComponent o = (CitationCitedArtifactTitleComponent) other_; 3459 return compareValues(text, o.text, true); 3460 } 3461 3462 public boolean isEmpty() { 3463 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, language, text); 3464 } 3465 3466 public String fhirType() { 3467 return "Citation.citedArtifact.title"; 3468 3469 } 3470 3471 } 3472 3473 @Block() 3474 public static class CitationCitedArtifactAbstractComponent extends BackboneElement implements IBaseBackboneElement { 3475 /** 3476 * Used to express the reason or specific aspect for the abstract. 3477 */ 3478 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 3479 @Description(shortDefinition="The kind of abstract", formalDefinition="Used to express the reason or specific aspect for the abstract." ) 3480 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-artifact-abstract-type") 3481 protected CodeableConcept type; 3482 3483 /** 3484 * Used to express the specific language. 3485 */ 3486 @Child(name = "language", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 3487 @Description(shortDefinition="Used to express the specific language", formalDefinition="Used to express the specific language." ) 3488 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/languages") 3489 protected CodeableConcept language; 3490 3491 /** 3492 * Abstract content. 3493 */ 3494 @Child(name = "text", type = {MarkdownType.class}, order=3, min=1, max=1, modifier=false, summary=false) 3495 @Description(shortDefinition="Abstract content", formalDefinition="Abstract content." ) 3496 protected MarkdownType text; 3497 3498 /** 3499 * Copyright notice for the abstract. 3500 */ 3501 @Child(name = "copyright", type = {MarkdownType.class}, order=4, min=0, max=1, modifier=false, summary=false) 3502 @Description(shortDefinition="Copyright notice for the abstract", formalDefinition="Copyright notice for the abstract." ) 3503 protected MarkdownType copyright; 3504 3505 private static final long serialVersionUID = -1882363442L; 3506 3507 /** 3508 * Constructor 3509 */ 3510 public CitationCitedArtifactAbstractComponent() { 3511 super(); 3512 } 3513 3514 /** 3515 * Constructor 3516 */ 3517 public CitationCitedArtifactAbstractComponent(String text) { 3518 super(); 3519 this.setText(text); 3520 } 3521 3522 /** 3523 * @return {@link #type} (Used to express the reason or specific aspect for the abstract.) 3524 */ 3525 public CodeableConcept getType() { 3526 if (this.type == null) 3527 if (Configuration.errorOnAutoCreate()) 3528 throw new Error("Attempt to auto-create CitationCitedArtifactAbstractComponent.type"); 3529 else if (Configuration.doAutoCreate()) 3530 this.type = new CodeableConcept(); // cc 3531 return this.type; 3532 } 3533 3534 public boolean hasType() { 3535 return this.type != null && !this.type.isEmpty(); 3536 } 3537 3538 /** 3539 * @param value {@link #type} (Used to express the reason or specific aspect for the abstract.) 3540 */ 3541 public CitationCitedArtifactAbstractComponent setType(CodeableConcept value) { 3542 this.type = value; 3543 return this; 3544 } 3545 3546 /** 3547 * @return {@link #language} (Used to express the specific language.) 3548 */ 3549 public CodeableConcept getLanguage() { 3550 if (this.language == null) 3551 if (Configuration.errorOnAutoCreate()) 3552 throw new Error("Attempt to auto-create CitationCitedArtifactAbstractComponent.language"); 3553 else if (Configuration.doAutoCreate()) 3554 this.language = new CodeableConcept(); // cc 3555 return this.language; 3556 } 3557 3558 public boolean hasLanguage() { 3559 return this.language != null && !this.language.isEmpty(); 3560 } 3561 3562 /** 3563 * @param value {@link #language} (Used to express the specific language.) 3564 */ 3565 public CitationCitedArtifactAbstractComponent setLanguage(CodeableConcept value) { 3566 this.language = value; 3567 return this; 3568 } 3569 3570 /** 3571 * @return {@link #text} (Abstract content.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 3572 */ 3573 public MarkdownType getTextElement() { 3574 if (this.text == null) 3575 if (Configuration.errorOnAutoCreate()) 3576 throw new Error("Attempt to auto-create CitationCitedArtifactAbstractComponent.text"); 3577 else if (Configuration.doAutoCreate()) 3578 this.text = new MarkdownType(); // bb 3579 return this.text; 3580 } 3581 3582 public boolean hasTextElement() { 3583 return this.text != null && !this.text.isEmpty(); 3584 } 3585 3586 public boolean hasText() { 3587 return this.text != null && !this.text.isEmpty(); 3588 } 3589 3590 /** 3591 * @param value {@link #text} (Abstract content.). This is the underlying object with id, value and extensions. The accessor "getText" gives direct access to the value 3592 */ 3593 public CitationCitedArtifactAbstractComponent setTextElement(MarkdownType value) { 3594 this.text = value; 3595 return this; 3596 } 3597 3598 /** 3599 * @return Abstract content. 3600 */ 3601 public String getText() { 3602 return this.text == null ? null : this.text.getValue(); 3603 } 3604 3605 /** 3606 * @param value Abstract content. 3607 */ 3608 public CitationCitedArtifactAbstractComponent setText(String value) { 3609 if (this.text == null) 3610 this.text = new MarkdownType(); 3611 this.text.setValue(value); 3612 return this; 3613 } 3614 3615 /** 3616 * @return {@link #copyright} (Copyright notice for the abstract.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 3617 */ 3618 public MarkdownType getCopyrightElement() { 3619 if (this.copyright == null) 3620 if (Configuration.errorOnAutoCreate()) 3621 throw new Error("Attempt to auto-create CitationCitedArtifactAbstractComponent.copyright"); 3622 else if (Configuration.doAutoCreate()) 3623 this.copyright = new MarkdownType(); // bb 3624 return this.copyright; 3625 } 3626 3627 public boolean hasCopyrightElement() { 3628 return this.copyright != null && !this.copyright.isEmpty(); 3629 } 3630 3631 public boolean hasCopyright() { 3632 return this.copyright != null && !this.copyright.isEmpty(); 3633 } 3634 3635 /** 3636 * @param value {@link #copyright} (Copyright notice for the abstract.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 3637 */ 3638 public CitationCitedArtifactAbstractComponent setCopyrightElement(MarkdownType value) { 3639 this.copyright = value; 3640 return this; 3641 } 3642 3643 /** 3644 * @return Copyright notice for the abstract. 3645 */ 3646 public String getCopyright() { 3647 return this.copyright == null ? null : this.copyright.getValue(); 3648 } 3649 3650 /** 3651 * @param value Copyright notice for the abstract. 3652 */ 3653 public CitationCitedArtifactAbstractComponent setCopyright(String value) { 3654 if (value == null) 3655 this.copyright = null; 3656 else { 3657 if (this.copyright == null) 3658 this.copyright = new MarkdownType(); 3659 this.copyright.setValue(value); 3660 } 3661 return this; 3662 } 3663 3664 protected void listChildren(List<Property> children) { 3665 super.listChildren(children); 3666 children.add(new Property("type", "CodeableConcept", "Used to express the reason or specific aspect for the abstract.", 0, 1, type)); 3667 children.add(new Property("language", "CodeableConcept", "Used to express the specific language.", 0, 1, language)); 3668 children.add(new Property("text", "markdown", "Abstract content.", 0, 1, text)); 3669 children.add(new Property("copyright", "markdown", "Copyright notice for the abstract.", 0, 1, copyright)); 3670 } 3671 3672 @Override 3673 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3674 switch (_hash) { 3675 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Used to express the reason or specific aspect for the abstract.", 0, 1, type); 3676 case -1613589672: /*language*/ return new Property("language", "CodeableConcept", "Used to express the specific language.", 0, 1, language); 3677 case 3556653: /*text*/ return new Property("text", "markdown", "Abstract content.", 0, 1, text); 3678 case 1522889671: /*copyright*/ return new Property("copyright", "markdown", "Copyright notice for the abstract.", 0, 1, copyright); 3679 default: return super.getNamedProperty(_hash, _name, _checkValid); 3680 } 3681 3682 } 3683 3684 @Override 3685 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3686 switch (hash) { 3687 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 3688 case -1613589672: /*language*/ return this.language == null ? new Base[0] : new Base[] {this.language}; // CodeableConcept 3689 case 3556653: /*text*/ return this.text == null ? new Base[0] : new Base[] {this.text}; // MarkdownType 3690 case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType 3691 default: return super.getProperty(hash, name, checkValid); 3692 } 3693 3694 } 3695 3696 @Override 3697 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3698 switch (hash) { 3699 case 3575610: // type 3700 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3701 return value; 3702 case -1613589672: // language 3703 this.language = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3704 return value; 3705 case 3556653: // text 3706 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 3707 return value; 3708 case 1522889671: // copyright 3709 this.copyright = TypeConvertor.castToMarkdown(value); // MarkdownType 3710 return value; 3711 default: return super.setProperty(hash, name, value); 3712 } 3713 3714 } 3715 3716 @Override 3717 public Base setProperty(String name, Base value) throws FHIRException { 3718 if (name.equals("type")) { 3719 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3720 } else if (name.equals("language")) { 3721 this.language = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3722 } else if (name.equals("text")) { 3723 this.text = TypeConvertor.castToMarkdown(value); // MarkdownType 3724 } else if (name.equals("copyright")) { 3725 this.copyright = TypeConvertor.castToMarkdown(value); // MarkdownType 3726 } else 3727 return super.setProperty(name, value); 3728 return value; 3729 } 3730 3731 @Override 3732 public Base makeProperty(int hash, String name) throws FHIRException { 3733 switch (hash) { 3734 case 3575610: return getType(); 3735 case -1613589672: return getLanguage(); 3736 case 3556653: return getTextElement(); 3737 case 1522889671: return getCopyrightElement(); 3738 default: return super.makeProperty(hash, name); 3739 } 3740 3741 } 3742 3743 @Override 3744 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 3745 switch (hash) { 3746 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 3747 case -1613589672: /*language*/ return new String[] {"CodeableConcept"}; 3748 case 3556653: /*text*/ return new String[] {"markdown"}; 3749 case 1522889671: /*copyright*/ return new String[] {"markdown"}; 3750 default: return super.getTypesForProperty(hash, name); 3751 } 3752 3753 } 3754 3755 @Override 3756 public Base addChild(String name) throws FHIRException { 3757 if (name.equals("type")) { 3758 this.type = new CodeableConcept(); 3759 return this.type; 3760 } 3761 else if (name.equals("language")) { 3762 this.language = new CodeableConcept(); 3763 return this.language; 3764 } 3765 else if (name.equals("text")) { 3766 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.abstract.text"); 3767 } 3768 else if (name.equals("copyright")) { 3769 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.abstract.copyright"); 3770 } 3771 else 3772 return super.addChild(name); 3773 } 3774 3775 public CitationCitedArtifactAbstractComponent copy() { 3776 CitationCitedArtifactAbstractComponent dst = new CitationCitedArtifactAbstractComponent(); 3777 copyValues(dst); 3778 return dst; 3779 } 3780 3781 public void copyValues(CitationCitedArtifactAbstractComponent dst) { 3782 super.copyValues(dst); 3783 dst.type = type == null ? null : type.copy(); 3784 dst.language = language == null ? null : language.copy(); 3785 dst.text = text == null ? null : text.copy(); 3786 dst.copyright = copyright == null ? null : copyright.copy(); 3787 } 3788 3789 @Override 3790 public boolean equalsDeep(Base other_) { 3791 if (!super.equalsDeep(other_)) 3792 return false; 3793 if (!(other_ instanceof CitationCitedArtifactAbstractComponent)) 3794 return false; 3795 CitationCitedArtifactAbstractComponent o = (CitationCitedArtifactAbstractComponent) other_; 3796 return compareDeep(type, o.type, true) && compareDeep(language, o.language, true) && compareDeep(text, o.text, true) 3797 && compareDeep(copyright, o.copyright, true); 3798 } 3799 3800 @Override 3801 public boolean equalsShallow(Base other_) { 3802 if (!super.equalsShallow(other_)) 3803 return false; 3804 if (!(other_ instanceof CitationCitedArtifactAbstractComponent)) 3805 return false; 3806 CitationCitedArtifactAbstractComponent o = (CitationCitedArtifactAbstractComponent) other_; 3807 return compareValues(text, o.text, true) && compareValues(copyright, o.copyright, true); 3808 } 3809 3810 public boolean isEmpty() { 3811 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, language, text, copyright 3812 ); 3813 } 3814 3815 public String fhirType() { 3816 return "Citation.citedArtifact.abstract"; 3817 3818 } 3819 3820 } 3821 3822 @Block() 3823 public static class CitationCitedArtifactPartComponent extends BackboneElement implements IBaseBackboneElement { 3824 /** 3825 * The kind of component. 3826 */ 3827 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 3828 @Description(shortDefinition="The kind of component", formalDefinition="The kind of component." ) 3829 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-artifact-part-type") 3830 protected CodeableConcept type; 3831 3832 /** 3833 * The specification of the component. 3834 */ 3835 @Child(name = "value", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false) 3836 @Description(shortDefinition="The specification of the component", formalDefinition="The specification of the component." ) 3837 protected StringType value; 3838 3839 /** 3840 * The citation for the full article or artifact. 3841 */ 3842 @Child(name = "baseCitation", type = {Citation.class}, order=3, min=0, max=1, modifier=false, summary=false) 3843 @Description(shortDefinition="The citation for the full article or artifact", formalDefinition="The citation for the full article or artifact." ) 3844 protected Reference baseCitation; 3845 3846 private static final long serialVersionUID = -765350500L; 3847 3848 /** 3849 * Constructor 3850 */ 3851 public CitationCitedArtifactPartComponent() { 3852 super(); 3853 } 3854 3855 /** 3856 * @return {@link #type} (The kind of component.) 3857 */ 3858 public CodeableConcept getType() { 3859 if (this.type == null) 3860 if (Configuration.errorOnAutoCreate()) 3861 throw new Error("Attempt to auto-create CitationCitedArtifactPartComponent.type"); 3862 else if (Configuration.doAutoCreate()) 3863 this.type = new CodeableConcept(); // cc 3864 return this.type; 3865 } 3866 3867 public boolean hasType() { 3868 return this.type != null && !this.type.isEmpty(); 3869 } 3870 3871 /** 3872 * @param value {@link #type} (The kind of component.) 3873 */ 3874 public CitationCitedArtifactPartComponent setType(CodeableConcept value) { 3875 this.type = value; 3876 return this; 3877 } 3878 3879 /** 3880 * @return {@link #value} (The specification of the component.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 3881 */ 3882 public StringType getValueElement() { 3883 if (this.value == null) 3884 if (Configuration.errorOnAutoCreate()) 3885 throw new Error("Attempt to auto-create CitationCitedArtifactPartComponent.value"); 3886 else if (Configuration.doAutoCreate()) 3887 this.value = new StringType(); // bb 3888 return this.value; 3889 } 3890 3891 public boolean hasValueElement() { 3892 return this.value != null && !this.value.isEmpty(); 3893 } 3894 3895 public boolean hasValue() { 3896 return this.value != null && !this.value.isEmpty(); 3897 } 3898 3899 /** 3900 * @param value {@link #value} (The specification of the component.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 3901 */ 3902 public CitationCitedArtifactPartComponent setValueElement(StringType value) { 3903 this.value = value; 3904 return this; 3905 } 3906 3907 /** 3908 * @return The specification of the component. 3909 */ 3910 public String getValue() { 3911 return this.value == null ? null : this.value.getValue(); 3912 } 3913 3914 /** 3915 * @param value The specification of the component. 3916 */ 3917 public CitationCitedArtifactPartComponent setValue(String value) { 3918 if (Utilities.noString(value)) 3919 this.value = null; 3920 else { 3921 if (this.value == null) 3922 this.value = new StringType(); 3923 this.value.setValue(value); 3924 } 3925 return this; 3926 } 3927 3928 /** 3929 * @return {@link #baseCitation} (The citation for the full article or artifact.) 3930 */ 3931 public Reference getBaseCitation() { 3932 if (this.baseCitation == null) 3933 if (Configuration.errorOnAutoCreate()) 3934 throw new Error("Attempt to auto-create CitationCitedArtifactPartComponent.baseCitation"); 3935 else if (Configuration.doAutoCreate()) 3936 this.baseCitation = new Reference(); // cc 3937 return this.baseCitation; 3938 } 3939 3940 public boolean hasBaseCitation() { 3941 return this.baseCitation != null && !this.baseCitation.isEmpty(); 3942 } 3943 3944 /** 3945 * @param value {@link #baseCitation} (The citation for the full article or artifact.) 3946 */ 3947 public CitationCitedArtifactPartComponent setBaseCitation(Reference value) { 3948 this.baseCitation = value; 3949 return this; 3950 } 3951 3952 protected void listChildren(List<Property> children) { 3953 super.listChildren(children); 3954 children.add(new Property("type", "CodeableConcept", "The kind of component.", 0, 1, type)); 3955 children.add(new Property("value", "string", "The specification of the component.", 0, 1, value)); 3956 children.add(new Property("baseCitation", "Reference(Citation)", "The citation for the full article or artifact.", 0, 1, baseCitation)); 3957 } 3958 3959 @Override 3960 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 3961 switch (_hash) { 3962 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The kind of component.", 0, 1, type); 3963 case 111972721: /*value*/ return new Property("value", "string", "The specification of the component.", 0, 1, value); 3964 case 1182995672: /*baseCitation*/ return new Property("baseCitation", "Reference(Citation)", "The citation for the full article or artifact.", 0, 1, baseCitation); 3965 default: return super.getNamedProperty(_hash, _name, _checkValid); 3966 } 3967 3968 } 3969 3970 @Override 3971 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 3972 switch (hash) { 3973 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 3974 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // StringType 3975 case 1182995672: /*baseCitation*/ return this.baseCitation == null ? new Base[0] : new Base[] {this.baseCitation}; // Reference 3976 default: return super.getProperty(hash, name, checkValid); 3977 } 3978 3979 } 3980 3981 @Override 3982 public Base setProperty(int hash, String name, Base value) throws FHIRException { 3983 switch (hash) { 3984 case 3575610: // type 3985 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 3986 return value; 3987 case 111972721: // value 3988 this.value = TypeConvertor.castToString(value); // StringType 3989 return value; 3990 case 1182995672: // baseCitation 3991 this.baseCitation = TypeConvertor.castToReference(value); // Reference 3992 return value; 3993 default: return super.setProperty(hash, name, value); 3994 } 3995 3996 } 3997 3998 @Override 3999 public Base setProperty(String name, Base value) throws FHIRException { 4000 if (name.equals("type")) { 4001 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 4002 } else if (name.equals("value")) { 4003 this.value = TypeConvertor.castToString(value); // StringType 4004 } else if (name.equals("baseCitation")) { 4005 this.baseCitation = TypeConvertor.castToReference(value); // Reference 4006 } else 4007 return super.setProperty(name, value); 4008 return value; 4009 } 4010 4011 @Override 4012 public Base makeProperty(int hash, String name) throws FHIRException { 4013 switch (hash) { 4014 case 3575610: return getType(); 4015 case 111972721: return getValueElement(); 4016 case 1182995672: return getBaseCitation(); 4017 default: return super.makeProperty(hash, name); 4018 } 4019 4020 } 4021 4022 @Override 4023 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 4024 switch (hash) { 4025 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 4026 case 111972721: /*value*/ return new String[] {"string"}; 4027 case 1182995672: /*baseCitation*/ return new String[] {"Reference"}; 4028 default: return super.getTypesForProperty(hash, name); 4029 } 4030 4031 } 4032 4033 @Override 4034 public Base addChild(String name) throws FHIRException { 4035 if (name.equals("type")) { 4036 this.type = new CodeableConcept(); 4037 return this.type; 4038 } 4039 else if (name.equals("value")) { 4040 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.part.value"); 4041 } 4042 else if (name.equals("baseCitation")) { 4043 this.baseCitation = new Reference(); 4044 return this.baseCitation; 4045 } 4046 else 4047 return super.addChild(name); 4048 } 4049 4050 public CitationCitedArtifactPartComponent copy() { 4051 CitationCitedArtifactPartComponent dst = new CitationCitedArtifactPartComponent(); 4052 copyValues(dst); 4053 return dst; 4054 } 4055 4056 public void copyValues(CitationCitedArtifactPartComponent dst) { 4057 super.copyValues(dst); 4058 dst.type = type == null ? null : type.copy(); 4059 dst.value = value == null ? null : value.copy(); 4060 dst.baseCitation = baseCitation == null ? null : baseCitation.copy(); 4061 } 4062 4063 @Override 4064 public boolean equalsDeep(Base other_) { 4065 if (!super.equalsDeep(other_)) 4066 return false; 4067 if (!(other_ instanceof CitationCitedArtifactPartComponent)) 4068 return false; 4069 CitationCitedArtifactPartComponent o = (CitationCitedArtifactPartComponent) other_; 4070 return compareDeep(type, o.type, true) && compareDeep(value, o.value, true) && compareDeep(baseCitation, o.baseCitation, true) 4071 ; 4072 } 4073 4074 @Override 4075 public boolean equalsShallow(Base other_) { 4076 if (!super.equalsShallow(other_)) 4077 return false; 4078 if (!(other_ instanceof CitationCitedArtifactPartComponent)) 4079 return false; 4080 CitationCitedArtifactPartComponent o = (CitationCitedArtifactPartComponent) other_; 4081 return compareValues(value, o.value, true); 4082 } 4083 4084 public boolean isEmpty() { 4085 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, value, baseCitation 4086 ); 4087 } 4088 4089 public String fhirType() { 4090 return "Citation.citedArtifact.part"; 4091 4092 } 4093 4094 } 4095 4096 @Block() 4097 public static class CitationCitedArtifactRelatesToComponent extends BackboneElement implements IBaseBackboneElement { 4098 /** 4099 * The type of relationship to the related artifact. 4100 */ 4101 @Child(name = "type", type = {CodeType.class}, order=1, min=1, max=1, modifier=false, summary=false) 4102 @Description(shortDefinition="documentation | justification | citation | predecessor | successor | derived-from | depends-on | composed-of | part-of | amends | amended-with | appends | appended-with | cites | cited-by | comments-on | comment-in | contains | contained-in | corrects | correction-in | replaces | replaced-with | retracts | retracted-by | signs | similar-to | supports | supported-with | transforms | transformed-into | transformed-with | documents | specification-of | created-with | cite-as | reprint | reprint-of", formalDefinition="The type of relationship to the related artifact." ) 4103 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/related-artifact-type-expanded") 4104 protected Enumeration<RelatedArtifactTypeExpanded> type; 4105 4106 /** 4107 * Provides additional classifiers of the related artifact. 4108 */ 4109 @Child(name = "classifier", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 4110 @Description(shortDefinition="Additional classifiers", formalDefinition="Provides additional classifiers of the related artifact." ) 4111 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-artifact-classifier") 4112 protected List<CodeableConcept> classifier; 4113 4114 /** 4115 * A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index. 4116 */ 4117 @Child(name = "label", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 4118 @Description(shortDefinition="Short label", formalDefinition="A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index." ) 4119 protected StringType label; 4120 4121 /** 4122 * A brief description of the document or knowledge resource being referenced, suitable for display to a consumer. 4123 */ 4124 @Child(name = "display", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false) 4125 @Description(shortDefinition="Brief description of the related artifact", formalDefinition="A brief description of the document or knowledge resource being referenced, suitable for display to a consumer." ) 4126 protected StringType display; 4127 4128 /** 4129 * A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format. 4130 */ 4131 @Child(name = "citation", type = {MarkdownType.class}, order=5, min=0, max=1, modifier=false, summary=false) 4132 @Description(shortDefinition="Bibliographic citation for the artifact", formalDefinition="A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format." ) 4133 protected MarkdownType citation; 4134 4135 /** 4136 * The document being referenced, represented as an attachment. This is exclusive with the resource element. 4137 */ 4138 @Child(name = "document", type = {Attachment.class}, order=6, min=0, max=1, modifier=false, summary=false) 4139 @Description(shortDefinition="What document is being referenced", formalDefinition="The document being referenced, represented as an attachment. This is exclusive with the resource element." ) 4140 protected Attachment document; 4141 4142 /** 4143 * The related artifact, such as a library, value set, profile, or other knowledge resource. 4144 */ 4145 @Child(name = "resource", type = {CanonicalType.class}, order=7, min=0, max=1, modifier=false, summary=false) 4146 @Description(shortDefinition="What artifact is being referenced", formalDefinition="The related artifact, such as a library, value set, profile, or other knowledge resource." ) 4147 protected CanonicalType resource; 4148 4149 /** 4150 * The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource. 4151 */ 4152 @Child(name = "resourceReference", type = {Reference.class}, order=8, min=0, max=1, modifier=false, summary=false) 4153 @Description(shortDefinition="What artifact, if not a conformance resource", formalDefinition="The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource." ) 4154 protected Reference resourceReference; 4155 4156 private static final long serialVersionUID = 1537406923L; 4157 4158 /** 4159 * Constructor 4160 */ 4161 public CitationCitedArtifactRelatesToComponent() { 4162 super(); 4163 } 4164 4165 /** 4166 * Constructor 4167 */ 4168 public CitationCitedArtifactRelatesToComponent(RelatedArtifactTypeExpanded type) { 4169 super(); 4170 this.setType(type); 4171 } 4172 4173 /** 4174 * @return {@link #type} (The type of relationship to the related artifact.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 4175 */ 4176 public Enumeration<RelatedArtifactTypeExpanded> getTypeElement() { 4177 if (this.type == null) 4178 if (Configuration.errorOnAutoCreate()) 4179 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.type"); 4180 else if (Configuration.doAutoCreate()) 4181 this.type = new Enumeration<RelatedArtifactTypeExpanded>(new RelatedArtifactTypeExpandedEnumFactory()); // bb 4182 return this.type; 4183 } 4184 4185 public boolean hasTypeElement() { 4186 return this.type != null && !this.type.isEmpty(); 4187 } 4188 4189 public boolean hasType() { 4190 return this.type != null && !this.type.isEmpty(); 4191 } 4192 4193 /** 4194 * @param value {@link #type} (The type of relationship to the related artifact.). This is the underlying object with id, value and extensions. The accessor "getType" gives direct access to the value 4195 */ 4196 public CitationCitedArtifactRelatesToComponent setTypeElement(Enumeration<RelatedArtifactTypeExpanded> value) { 4197 this.type = value; 4198 return this; 4199 } 4200 4201 /** 4202 * @return The type of relationship to the related artifact. 4203 */ 4204 public RelatedArtifactTypeExpanded getType() { 4205 return this.type == null ? null : this.type.getValue(); 4206 } 4207 4208 /** 4209 * @param value The type of relationship to the related artifact. 4210 */ 4211 public CitationCitedArtifactRelatesToComponent setType(RelatedArtifactTypeExpanded value) { 4212 if (this.type == null) 4213 this.type = new Enumeration<RelatedArtifactTypeExpanded>(new RelatedArtifactTypeExpandedEnumFactory()); 4214 this.type.setValue(value); 4215 return this; 4216 } 4217 4218 /** 4219 * @return {@link #classifier} (Provides additional classifiers of the related artifact.) 4220 */ 4221 public List<CodeableConcept> getClassifier() { 4222 if (this.classifier == null) 4223 this.classifier = new ArrayList<CodeableConcept>(); 4224 return this.classifier; 4225 } 4226 4227 /** 4228 * @return Returns a reference to <code>this</code> for easy method chaining 4229 */ 4230 public CitationCitedArtifactRelatesToComponent setClassifier(List<CodeableConcept> theClassifier) { 4231 this.classifier = theClassifier; 4232 return this; 4233 } 4234 4235 public boolean hasClassifier() { 4236 if (this.classifier == null) 4237 return false; 4238 for (CodeableConcept item : this.classifier) 4239 if (!item.isEmpty()) 4240 return true; 4241 return false; 4242 } 4243 4244 public CodeableConcept addClassifier() { //3 4245 CodeableConcept t = new CodeableConcept(); 4246 if (this.classifier == null) 4247 this.classifier = new ArrayList<CodeableConcept>(); 4248 this.classifier.add(t); 4249 return t; 4250 } 4251 4252 public CitationCitedArtifactRelatesToComponent addClassifier(CodeableConcept t) { //3 4253 if (t == null) 4254 return this; 4255 if (this.classifier == null) 4256 this.classifier = new ArrayList<CodeableConcept>(); 4257 this.classifier.add(t); 4258 return this; 4259 } 4260 4261 /** 4262 * @return The first repetition of repeating field {@link #classifier}, creating it if it does not already exist {3} 4263 */ 4264 public CodeableConcept getClassifierFirstRep() { 4265 if (getClassifier().isEmpty()) { 4266 addClassifier(); 4267 } 4268 return getClassifier().get(0); 4269 } 4270 4271 /** 4272 * @return {@link #label} (A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index.). This is the underlying object with id, value and extensions. The accessor "getLabel" gives direct access to the value 4273 */ 4274 public StringType getLabelElement() { 4275 if (this.label == null) 4276 if (Configuration.errorOnAutoCreate()) 4277 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.label"); 4278 else if (Configuration.doAutoCreate()) 4279 this.label = new StringType(); // bb 4280 return this.label; 4281 } 4282 4283 public boolean hasLabelElement() { 4284 return this.label != null && !this.label.isEmpty(); 4285 } 4286 4287 public boolean hasLabel() { 4288 return this.label != null && !this.label.isEmpty(); 4289 } 4290 4291 /** 4292 * @param value {@link #label} (A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index.). This is the underlying object with id, value and extensions. The accessor "getLabel" gives direct access to the value 4293 */ 4294 public CitationCitedArtifactRelatesToComponent setLabelElement(StringType value) { 4295 this.label = value; 4296 return this; 4297 } 4298 4299 /** 4300 * @return A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index. 4301 */ 4302 public String getLabel() { 4303 return this.label == null ? null : this.label.getValue(); 4304 } 4305 4306 /** 4307 * @param value A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index. 4308 */ 4309 public CitationCitedArtifactRelatesToComponent setLabel(String value) { 4310 if (Utilities.noString(value)) 4311 this.label = null; 4312 else { 4313 if (this.label == null) 4314 this.label = new StringType(); 4315 this.label.setValue(value); 4316 } 4317 return this; 4318 } 4319 4320 /** 4321 * @return {@link #display} (A brief description of the document or knowledge resource being referenced, suitable for display to a consumer.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 4322 */ 4323 public StringType getDisplayElement() { 4324 if (this.display == null) 4325 if (Configuration.errorOnAutoCreate()) 4326 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.display"); 4327 else if (Configuration.doAutoCreate()) 4328 this.display = new StringType(); // bb 4329 return this.display; 4330 } 4331 4332 public boolean hasDisplayElement() { 4333 return this.display != null && !this.display.isEmpty(); 4334 } 4335 4336 public boolean hasDisplay() { 4337 return this.display != null && !this.display.isEmpty(); 4338 } 4339 4340 /** 4341 * @param value {@link #display} (A brief description of the document or knowledge resource being referenced, suitable for display to a consumer.). This is the underlying object with id, value and extensions. The accessor "getDisplay" gives direct access to the value 4342 */ 4343 public CitationCitedArtifactRelatesToComponent setDisplayElement(StringType value) { 4344 this.display = value; 4345 return this; 4346 } 4347 4348 /** 4349 * @return A brief description of the document or knowledge resource being referenced, suitable for display to a consumer. 4350 */ 4351 public String getDisplay() { 4352 return this.display == null ? null : this.display.getValue(); 4353 } 4354 4355 /** 4356 * @param value A brief description of the document or knowledge resource being referenced, suitable for display to a consumer. 4357 */ 4358 public CitationCitedArtifactRelatesToComponent setDisplay(String value) { 4359 if (Utilities.noString(value)) 4360 this.display = null; 4361 else { 4362 if (this.display == null) 4363 this.display = new StringType(); 4364 this.display.setValue(value); 4365 } 4366 return this; 4367 } 4368 4369 /** 4370 * @return {@link #citation} (A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format.). This is the underlying object with id, value and extensions. The accessor "getCitation" gives direct access to the value 4371 */ 4372 public MarkdownType getCitationElement() { 4373 if (this.citation == null) 4374 if (Configuration.errorOnAutoCreate()) 4375 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.citation"); 4376 else if (Configuration.doAutoCreate()) 4377 this.citation = new MarkdownType(); // bb 4378 return this.citation; 4379 } 4380 4381 public boolean hasCitationElement() { 4382 return this.citation != null && !this.citation.isEmpty(); 4383 } 4384 4385 public boolean hasCitation() { 4386 return this.citation != null && !this.citation.isEmpty(); 4387 } 4388 4389 /** 4390 * @param value {@link #citation} (A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format.). This is the underlying object with id, value and extensions. The accessor "getCitation" gives direct access to the value 4391 */ 4392 public CitationCitedArtifactRelatesToComponent setCitationElement(MarkdownType value) { 4393 this.citation = value; 4394 return this; 4395 } 4396 4397 /** 4398 * @return A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format. 4399 */ 4400 public String getCitation() { 4401 return this.citation == null ? null : this.citation.getValue(); 4402 } 4403 4404 /** 4405 * @param value A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format. 4406 */ 4407 public CitationCitedArtifactRelatesToComponent setCitation(String value) { 4408 if (value == null) 4409 this.citation = null; 4410 else { 4411 if (this.citation == null) 4412 this.citation = new MarkdownType(); 4413 this.citation.setValue(value); 4414 } 4415 return this; 4416 } 4417 4418 /** 4419 * @return {@link #document} (The document being referenced, represented as an attachment. This is exclusive with the resource element.) 4420 */ 4421 public Attachment getDocument() { 4422 if (this.document == null) 4423 if (Configuration.errorOnAutoCreate()) 4424 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.document"); 4425 else if (Configuration.doAutoCreate()) 4426 this.document = new Attachment(); // cc 4427 return this.document; 4428 } 4429 4430 public boolean hasDocument() { 4431 return this.document != null && !this.document.isEmpty(); 4432 } 4433 4434 /** 4435 * @param value {@link #document} (The document being referenced, represented as an attachment. This is exclusive with the resource element.) 4436 */ 4437 public CitationCitedArtifactRelatesToComponent setDocument(Attachment value) { 4438 this.document = value; 4439 return this; 4440 } 4441 4442 /** 4443 * @return {@link #resource} (The related artifact, such as a library, value set, profile, or other knowledge resource.). This is the underlying object with id, value and extensions. The accessor "getResource" gives direct access to the value 4444 */ 4445 public CanonicalType getResourceElement() { 4446 if (this.resource == null) 4447 if (Configuration.errorOnAutoCreate()) 4448 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.resource"); 4449 else if (Configuration.doAutoCreate()) 4450 this.resource = new CanonicalType(); // bb 4451 return this.resource; 4452 } 4453 4454 public boolean hasResourceElement() { 4455 return this.resource != null && !this.resource.isEmpty(); 4456 } 4457 4458 public boolean hasResource() { 4459 return this.resource != null && !this.resource.isEmpty(); 4460 } 4461 4462 /** 4463 * @param value {@link #resource} (The related artifact, such as a library, value set, profile, or other knowledge resource.). This is the underlying object with id, value and extensions. The accessor "getResource" gives direct access to the value 4464 */ 4465 public CitationCitedArtifactRelatesToComponent setResourceElement(CanonicalType value) { 4466 this.resource = value; 4467 return this; 4468 } 4469 4470 /** 4471 * @return The related artifact, such as a library, value set, profile, or other knowledge resource. 4472 */ 4473 public String getResource() { 4474 return this.resource == null ? null : this.resource.getValue(); 4475 } 4476 4477 /** 4478 * @param value The related artifact, such as a library, value set, profile, or other knowledge resource. 4479 */ 4480 public CitationCitedArtifactRelatesToComponent setResource(String value) { 4481 if (Utilities.noString(value)) 4482 this.resource = null; 4483 else { 4484 if (this.resource == null) 4485 this.resource = new CanonicalType(); 4486 this.resource.setValue(value); 4487 } 4488 return this; 4489 } 4490 4491 /** 4492 * @return {@link #resourceReference} (The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource.) 4493 */ 4494 public Reference getResourceReference() { 4495 if (this.resourceReference == null) 4496 if (Configuration.errorOnAutoCreate()) 4497 throw new Error("Attempt to auto-create CitationCitedArtifactRelatesToComponent.resourceReference"); 4498 else if (Configuration.doAutoCreate()) 4499 this.resourceReference = new Reference(); // cc 4500 return this.resourceReference; 4501 } 4502 4503 public boolean hasResourceReference() { 4504 return this.resourceReference != null && !this.resourceReference.isEmpty(); 4505 } 4506 4507 /** 4508 * @param value {@link #resourceReference} (The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource.) 4509 */ 4510 public CitationCitedArtifactRelatesToComponent setResourceReference(Reference value) { 4511 this.resourceReference = value; 4512 return this; 4513 } 4514 4515 protected void listChildren(List<Property> children) { 4516 super.listChildren(children); 4517 children.add(new Property("type", "code", "The type of relationship to the related artifact.", 0, 1, type)); 4518 children.add(new Property("classifier", "CodeableConcept", "Provides additional classifiers of the related artifact.", 0, java.lang.Integer.MAX_VALUE, classifier)); 4519 children.add(new Property("label", "string", "A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index.", 0, 1, label)); 4520 children.add(new Property("display", "string", "A brief description of the document or knowledge resource being referenced, suitable for display to a consumer.", 0, 1, display)); 4521 children.add(new Property("citation", "markdown", "A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format.", 0, 1, citation)); 4522 children.add(new Property("document", "Attachment", "The document being referenced, represented as an attachment. This is exclusive with the resource element.", 0, 1, document)); 4523 children.add(new Property("resource", "canonical", "The related artifact, such as a library, value set, profile, or other knowledge resource.", 0, 1, resource)); 4524 children.add(new Property("resourceReference", "Reference", "The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource.", 0, 1, resourceReference)); 4525 } 4526 4527 @Override 4528 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 4529 switch (_hash) { 4530 case 3575610: /*type*/ return new Property("type", "code", "The type of relationship to the related artifact.", 0, 1, type); 4531 case -281470431: /*classifier*/ return new Property("classifier", "CodeableConcept", "Provides additional classifiers of the related artifact.", 0, java.lang.Integer.MAX_VALUE, classifier); 4532 case 102727412: /*label*/ return new Property("label", "string", "A short label that can be used to reference the citation from elsewhere in the containing artifact, such as a footnote index.", 0, 1, label); 4533 case 1671764162: /*display*/ return new Property("display", "string", "A brief description of the document or knowledge resource being referenced, suitable for display to a consumer.", 0, 1, display); 4534 case -1442706713: /*citation*/ return new Property("citation", "markdown", "A bibliographic citation for the related artifact. This text SHOULD be formatted according to an accepted citation format.", 0, 1, citation); 4535 case 861720859: /*document*/ return new Property("document", "Attachment", "The document being referenced, represented as an attachment. This is exclusive with the resource element.", 0, 1, document); 4536 case -341064690: /*resource*/ return new Property("resource", "canonical", "The related artifact, such as a library, value set, profile, or other knowledge resource.", 0, 1, resource); 4537 case -610120995: /*resourceReference*/ return new Property("resourceReference", "Reference", "The related artifact, if the artifact is not a canonical resource, or a resource reference to a canonical resource.", 0, 1, resourceReference); 4538 default: return super.getNamedProperty(_hash, _name, _checkValid); 4539 } 4540 4541 } 4542 4543 @Override 4544 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 4545 switch (hash) { 4546 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // Enumeration<RelatedArtifactTypeExpanded> 4547 case -281470431: /*classifier*/ return this.classifier == null ? new Base[0] : this.classifier.toArray(new Base[this.classifier.size()]); // CodeableConcept 4548 case 102727412: /*label*/ return this.label == null ? new Base[0] : new Base[] {this.label}; // StringType 4549 case 1671764162: /*display*/ return this.display == null ? new Base[0] : new Base[] {this.display}; // StringType 4550 case -1442706713: /*citation*/ return this.citation == null ? new Base[0] : new Base[] {this.citation}; // MarkdownType 4551 case 861720859: /*document*/ return this.document == null ? new Base[0] : new Base[] {this.document}; // Attachment 4552 case -341064690: /*resource*/ return this.resource == null ? new Base[0] : new Base[] {this.resource}; // CanonicalType 4553 case -610120995: /*resourceReference*/ return this.resourceReference == null ? new Base[0] : new Base[] {this.resourceReference}; // Reference 4554 default: return super.getProperty(hash, name, checkValid); 4555 } 4556 4557 } 4558 4559 @Override 4560 public Base setProperty(int hash, String name, Base value) throws FHIRException { 4561 switch (hash) { 4562 case 3575610: // type 4563 value = new RelatedArtifactTypeExpandedEnumFactory().fromType(TypeConvertor.castToCode(value)); 4564 this.type = (Enumeration) value; // Enumeration<RelatedArtifactTypeExpanded> 4565 return value; 4566 case -281470431: // classifier 4567 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 4568 return value; 4569 case 102727412: // label 4570 this.label = TypeConvertor.castToString(value); // StringType 4571 return value; 4572 case 1671764162: // display 4573 this.display = TypeConvertor.castToString(value); // StringType 4574 return value; 4575 case -1442706713: // citation 4576 this.citation = TypeConvertor.castToMarkdown(value); // MarkdownType 4577 return value; 4578 case 861720859: // document 4579 this.document = TypeConvertor.castToAttachment(value); // Attachment 4580 return value; 4581 case -341064690: // resource 4582 this.resource = TypeConvertor.castToCanonical(value); // CanonicalType 4583 return value; 4584 case -610120995: // resourceReference 4585 this.resourceReference = TypeConvertor.castToReference(value); // Reference 4586 return value; 4587 default: return super.setProperty(hash, name, value); 4588 } 4589 4590 } 4591 4592 @Override 4593 public Base setProperty(String name, Base value) throws FHIRException { 4594 if (name.equals("type")) { 4595 value = new RelatedArtifactTypeExpandedEnumFactory().fromType(TypeConvertor.castToCode(value)); 4596 this.type = (Enumeration) value; // Enumeration<RelatedArtifactTypeExpanded> 4597 } else if (name.equals("classifier")) { 4598 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); 4599 } else if (name.equals("label")) { 4600 this.label = TypeConvertor.castToString(value); // StringType 4601 } else if (name.equals("display")) { 4602 this.display = TypeConvertor.castToString(value); // StringType 4603 } else if (name.equals("citation")) { 4604 this.citation = TypeConvertor.castToMarkdown(value); // MarkdownType 4605 } else if (name.equals("document")) { 4606 this.document = TypeConvertor.castToAttachment(value); // Attachment 4607 } else if (name.equals("resource")) { 4608 this.resource = TypeConvertor.castToCanonical(value); // CanonicalType 4609 } else if (name.equals("resourceReference")) { 4610 this.resourceReference = TypeConvertor.castToReference(value); // Reference 4611 } else 4612 return super.setProperty(name, value); 4613 return value; 4614 } 4615 4616 @Override 4617 public Base makeProperty(int hash, String name) throws FHIRException { 4618 switch (hash) { 4619 case 3575610: return getTypeElement(); 4620 case -281470431: return addClassifier(); 4621 case 102727412: return getLabelElement(); 4622 case 1671764162: return getDisplayElement(); 4623 case -1442706713: return getCitationElement(); 4624 case 861720859: return getDocument(); 4625 case -341064690: return getResourceElement(); 4626 case -610120995: return getResourceReference(); 4627 default: return super.makeProperty(hash, name); 4628 } 4629 4630 } 4631 4632 @Override 4633 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 4634 switch (hash) { 4635 case 3575610: /*type*/ return new String[] {"code"}; 4636 case -281470431: /*classifier*/ return new String[] {"CodeableConcept"}; 4637 case 102727412: /*label*/ return new String[] {"string"}; 4638 case 1671764162: /*display*/ return new String[] {"string"}; 4639 case -1442706713: /*citation*/ return new String[] {"markdown"}; 4640 case 861720859: /*document*/ return new String[] {"Attachment"}; 4641 case -341064690: /*resource*/ return new String[] {"canonical"}; 4642 case -610120995: /*resourceReference*/ return new String[] {"Reference"}; 4643 default: return super.getTypesForProperty(hash, name); 4644 } 4645 4646 } 4647 4648 @Override 4649 public Base addChild(String name) throws FHIRException { 4650 if (name.equals("type")) { 4651 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.relatesTo.type"); 4652 } 4653 else if (name.equals("classifier")) { 4654 return addClassifier(); 4655 } 4656 else if (name.equals("label")) { 4657 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.relatesTo.label"); 4658 } 4659 else if (name.equals("display")) { 4660 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.relatesTo.display"); 4661 } 4662 else if (name.equals("citation")) { 4663 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.relatesTo.citation"); 4664 } 4665 else if (name.equals("document")) { 4666 this.document = new Attachment(); 4667 return this.document; 4668 } 4669 else if (name.equals("resource")) { 4670 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.relatesTo.resource"); 4671 } 4672 else if (name.equals("resourceReference")) { 4673 this.resourceReference = new Reference(); 4674 return this.resourceReference; 4675 } 4676 else 4677 return super.addChild(name); 4678 } 4679 4680 public CitationCitedArtifactRelatesToComponent copy() { 4681 CitationCitedArtifactRelatesToComponent dst = new CitationCitedArtifactRelatesToComponent(); 4682 copyValues(dst); 4683 return dst; 4684 } 4685 4686 public void copyValues(CitationCitedArtifactRelatesToComponent dst) { 4687 super.copyValues(dst); 4688 dst.type = type == null ? null : type.copy(); 4689 if (classifier != null) { 4690 dst.classifier = new ArrayList<CodeableConcept>(); 4691 for (CodeableConcept i : classifier) 4692 dst.classifier.add(i.copy()); 4693 }; 4694 dst.label = label == null ? null : label.copy(); 4695 dst.display = display == null ? null : display.copy(); 4696 dst.citation = citation == null ? null : citation.copy(); 4697 dst.document = document == null ? null : document.copy(); 4698 dst.resource = resource == null ? null : resource.copy(); 4699 dst.resourceReference = resourceReference == null ? null : resourceReference.copy(); 4700 } 4701 4702 @Override 4703 public boolean equalsDeep(Base other_) { 4704 if (!super.equalsDeep(other_)) 4705 return false; 4706 if (!(other_ instanceof CitationCitedArtifactRelatesToComponent)) 4707 return false; 4708 CitationCitedArtifactRelatesToComponent o = (CitationCitedArtifactRelatesToComponent) other_; 4709 return compareDeep(type, o.type, true) && compareDeep(classifier, o.classifier, true) && compareDeep(label, o.label, true) 4710 && compareDeep(display, o.display, true) && compareDeep(citation, o.citation, true) && compareDeep(document, o.document, true) 4711 && compareDeep(resource, o.resource, true) && compareDeep(resourceReference, o.resourceReference, true) 4712 ; 4713 } 4714 4715 @Override 4716 public boolean equalsShallow(Base other_) { 4717 if (!super.equalsShallow(other_)) 4718 return false; 4719 if (!(other_ instanceof CitationCitedArtifactRelatesToComponent)) 4720 return false; 4721 CitationCitedArtifactRelatesToComponent o = (CitationCitedArtifactRelatesToComponent) other_; 4722 return compareValues(type, o.type, true) && compareValues(label, o.label, true) && compareValues(display, o.display, true) 4723 && compareValues(citation, o.citation, true) && compareValues(resource, o.resource, true); 4724 } 4725 4726 public boolean isEmpty() { 4727 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, classifier, label 4728 , display, citation, document, resource, resourceReference); 4729 } 4730 4731 public String fhirType() { 4732 return "Citation.citedArtifact.relatesTo"; 4733 4734 } 4735 4736 } 4737 4738 @Block() 4739 public static class CitationCitedArtifactPublicationFormComponent extends BackboneElement implements IBaseBackboneElement { 4740 /** 4741 * The collection the cited article or artifact is published in. 4742 */ 4743 @Child(name = "publishedIn", type = {}, order=1, min=0, max=1, modifier=false, summary=false) 4744 @Description(shortDefinition="The collection the cited article or artifact is published in", formalDefinition="The collection the cited article or artifact is published in." ) 4745 protected CitationCitedArtifactPublicationFormPublishedInComponent publishedIn; 4746 4747 /** 4748 * Describes the form of the medium cited. Common codes are "Internet" or "Print". 4749 */ 4750 @Child(name = "citedMedium", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 4751 @Description(shortDefinition="Internet or Print", formalDefinition="Describes the form of the medium cited. Common codes are \"Internet\" or \"Print\"." ) 4752 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-medium") 4753 protected CodeableConcept citedMedium; 4754 4755 /** 4756 * Volume number of journal in which the article is published. 4757 */ 4758 @Child(name = "volume", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 4759 @Description(shortDefinition="Volume number of journal in which the article is published", formalDefinition="Volume number of journal in which the article is published." ) 4760 protected StringType volume; 4761 4762 /** 4763 * Issue, part or supplement of journal in which the article is published. 4764 */ 4765 @Child(name = "issue", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=false) 4766 @Description(shortDefinition="Issue, part or supplement of journal in which the article is published", formalDefinition="Issue, part or supplement of journal in which the article is published." ) 4767 protected StringType issue; 4768 4769 /** 4770 * Year on which the issue of the journal was published. 4771 */ 4772 @Child(name = "publicationDateYear", type = {StringType.class}, order=5, min=0, max=1, modifier=false, summary=false) 4773 @Description(shortDefinition="Year on which the issue of the journal was published", formalDefinition="Year on which the issue of the journal was published." ) 4774 protected StringType publicationDateYear; 4775 4776 /** 4777 * Month on which the issue of the journal was published. 4778 */ 4779 @Child(name = "publicationDateMonth", type = {StringType.class}, order=6, min=0, max=1, modifier=false, summary=false) 4780 @Description(shortDefinition="Month on which the issue of the journal was published", formalDefinition="Month on which the issue of the journal was published." ) 4781 protected StringType publicationDateMonth; 4782 4783 /** 4784 * Day on which the issue of the journal was published. 4785 */ 4786 @Child(name = "publicationDateDay", type = {StringType.class}, order=7, min=0, max=1, modifier=false, summary=false) 4787 @Description(shortDefinition="Day on which the issue of the journal was published", formalDefinition="Day on which the issue of the journal was published." ) 4788 protected StringType publicationDateDay; 4789 4790 /** 4791 * Spring, Summer, Fall/Autumn, Winter. 4792 */ 4793 @Child(name = "publicationDateSeason", type = {StringType.class}, order=8, min=0, max=1, modifier=false, summary=false) 4794 @Description(shortDefinition="Season on which the issue of the journal was published", formalDefinition="Spring, Summer, Fall/Autumn, Winter." ) 4795 protected StringType publicationDateSeason; 4796 4797 /** 4798 * Text representation of the date of which the issue of the journal was published. 4799 */ 4800 @Child(name = "publicationDateText", type = {StringType.class}, order=9, min=0, max=1, modifier=false, summary=false) 4801 @Description(shortDefinition="Text representation of the date of which the issue of the journal was published", formalDefinition="Text representation of the date of which the issue of the journal was published." ) 4802 protected StringType publicationDateText; 4803 4804 /** 4805 * The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date). 4806 */ 4807 @Child(name = "articleDate", type = {DateTimeType.class}, order=10, min=0, max=1, modifier=false, summary=false) 4808 @Description(shortDefinition="The date the article was added to the database, or the date the article was released", formalDefinition="The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date)." ) 4809 protected DateTimeType articleDate; 4810 4811 /** 4812 * The date the article was last revised or updated in the database. 4813 */ 4814 @Child(name = "lastRevisionDate", type = {DateTimeType.class}, order=11, min=0, max=1, modifier=false, summary=false) 4815 @Description(shortDefinition="The date the article was last revised or updated in the database", formalDefinition="The date the article was last revised or updated in the database." ) 4816 protected DateTimeType lastRevisionDate; 4817 4818 /** 4819 * Language in which this form of the article is published. 4820 */ 4821 @Child(name = "language", type = {CodeableConcept.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 4822 @Description(shortDefinition="Language in which this form of the article is published", formalDefinition="Language in which this form of the article is published." ) 4823 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/languages") 4824 protected List<CodeableConcept> language; 4825 4826 /** 4827 * Entry number or identifier for inclusion in a database. 4828 */ 4829 @Child(name = "accessionNumber", type = {StringType.class}, order=13, min=0, max=1, modifier=false, summary=false) 4830 @Description(shortDefinition="Entry number or identifier for inclusion in a database", formalDefinition="Entry number or identifier for inclusion in a database." ) 4831 protected StringType accessionNumber; 4832 4833 /** 4834 * Used for full display of pagination. 4835 */ 4836 @Child(name = "pageString", type = {StringType.class}, order=14, min=0, max=1, modifier=false, summary=false) 4837 @Description(shortDefinition="Used for full display of pagination", formalDefinition="Used for full display of pagination." ) 4838 protected StringType pageString; 4839 4840 /** 4841 * Used for isolated representation of first page. 4842 */ 4843 @Child(name = "firstPage", type = {StringType.class}, order=15, min=0, max=1, modifier=false, summary=false) 4844 @Description(shortDefinition="Used for isolated representation of first page", formalDefinition="Used for isolated representation of first page." ) 4845 protected StringType firstPage; 4846 4847 /** 4848 * Used for isolated representation of last page. 4849 */ 4850 @Child(name = "lastPage", type = {StringType.class}, order=16, min=0, max=1, modifier=false, summary=false) 4851 @Description(shortDefinition="Used for isolated representation of last page", formalDefinition="Used for isolated representation of last page." ) 4852 protected StringType lastPage; 4853 4854 /** 4855 * Actual or approximate number of pages or screens. 4856 */ 4857 @Child(name = "pageCount", type = {StringType.class}, order=17, min=0, max=1, modifier=false, summary=false) 4858 @Description(shortDefinition="Number of pages or screens", formalDefinition="Actual or approximate number of pages or screens." ) 4859 protected StringType pageCount; 4860 4861 /** 4862 * Copyright notice for the full article or artifact. 4863 */ 4864 @Child(name = "copyright", type = {MarkdownType.class}, order=18, min=0, max=1, modifier=false, summary=false) 4865 @Description(shortDefinition="Copyright notice for the full article or artifact", formalDefinition="Copyright notice for the full article or artifact." ) 4866 protected MarkdownType copyright; 4867 4868 private static final long serialVersionUID = -1750822803L; 4869 4870 /** 4871 * Constructor 4872 */ 4873 public CitationCitedArtifactPublicationFormComponent() { 4874 super(); 4875 } 4876 4877 /** 4878 * @return {@link #publishedIn} (The collection the cited article or artifact is published in.) 4879 */ 4880 public CitationCitedArtifactPublicationFormPublishedInComponent getPublishedIn() { 4881 if (this.publishedIn == null) 4882 if (Configuration.errorOnAutoCreate()) 4883 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publishedIn"); 4884 else if (Configuration.doAutoCreate()) 4885 this.publishedIn = new CitationCitedArtifactPublicationFormPublishedInComponent(); // cc 4886 return this.publishedIn; 4887 } 4888 4889 public boolean hasPublishedIn() { 4890 return this.publishedIn != null && !this.publishedIn.isEmpty(); 4891 } 4892 4893 /** 4894 * @param value {@link #publishedIn} (The collection the cited article or artifact is published in.) 4895 */ 4896 public CitationCitedArtifactPublicationFormComponent setPublishedIn(CitationCitedArtifactPublicationFormPublishedInComponent value) { 4897 this.publishedIn = value; 4898 return this; 4899 } 4900 4901 /** 4902 * @return {@link #citedMedium} (Describes the form of the medium cited. Common codes are "Internet" or "Print".) 4903 */ 4904 public CodeableConcept getCitedMedium() { 4905 if (this.citedMedium == null) 4906 if (Configuration.errorOnAutoCreate()) 4907 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.citedMedium"); 4908 else if (Configuration.doAutoCreate()) 4909 this.citedMedium = new CodeableConcept(); // cc 4910 return this.citedMedium; 4911 } 4912 4913 public boolean hasCitedMedium() { 4914 return this.citedMedium != null && !this.citedMedium.isEmpty(); 4915 } 4916 4917 /** 4918 * @param value {@link #citedMedium} (Describes the form of the medium cited. Common codes are "Internet" or "Print".) 4919 */ 4920 public CitationCitedArtifactPublicationFormComponent setCitedMedium(CodeableConcept value) { 4921 this.citedMedium = value; 4922 return this; 4923 } 4924 4925 /** 4926 * @return {@link #volume} (Volume number of journal in which the article is published.). This is the underlying object with id, value and extensions. The accessor "getVolume" gives direct access to the value 4927 */ 4928 public StringType getVolumeElement() { 4929 if (this.volume == null) 4930 if (Configuration.errorOnAutoCreate()) 4931 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.volume"); 4932 else if (Configuration.doAutoCreate()) 4933 this.volume = new StringType(); // bb 4934 return this.volume; 4935 } 4936 4937 public boolean hasVolumeElement() { 4938 return this.volume != null && !this.volume.isEmpty(); 4939 } 4940 4941 public boolean hasVolume() { 4942 return this.volume != null && !this.volume.isEmpty(); 4943 } 4944 4945 /** 4946 * @param value {@link #volume} (Volume number of journal in which the article is published.). This is the underlying object with id, value and extensions. The accessor "getVolume" gives direct access to the value 4947 */ 4948 public CitationCitedArtifactPublicationFormComponent setVolumeElement(StringType value) { 4949 this.volume = value; 4950 return this; 4951 } 4952 4953 /** 4954 * @return Volume number of journal in which the article is published. 4955 */ 4956 public String getVolume() { 4957 return this.volume == null ? null : this.volume.getValue(); 4958 } 4959 4960 /** 4961 * @param value Volume number of journal in which the article is published. 4962 */ 4963 public CitationCitedArtifactPublicationFormComponent setVolume(String value) { 4964 if (Utilities.noString(value)) 4965 this.volume = null; 4966 else { 4967 if (this.volume == null) 4968 this.volume = new StringType(); 4969 this.volume.setValue(value); 4970 } 4971 return this; 4972 } 4973 4974 /** 4975 * @return {@link #issue} (Issue, part or supplement of journal in which the article is published.). This is the underlying object with id, value and extensions. The accessor "getIssue" gives direct access to the value 4976 */ 4977 public StringType getIssueElement() { 4978 if (this.issue == null) 4979 if (Configuration.errorOnAutoCreate()) 4980 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.issue"); 4981 else if (Configuration.doAutoCreate()) 4982 this.issue = new StringType(); // bb 4983 return this.issue; 4984 } 4985 4986 public boolean hasIssueElement() { 4987 return this.issue != null && !this.issue.isEmpty(); 4988 } 4989 4990 public boolean hasIssue() { 4991 return this.issue != null && !this.issue.isEmpty(); 4992 } 4993 4994 /** 4995 * @param value {@link #issue} (Issue, part or supplement of journal in which the article is published.). This is the underlying object with id, value and extensions. The accessor "getIssue" gives direct access to the value 4996 */ 4997 public CitationCitedArtifactPublicationFormComponent setIssueElement(StringType value) { 4998 this.issue = value; 4999 return this; 5000 } 5001 5002 /** 5003 * @return Issue, part or supplement of journal in which the article is published. 5004 */ 5005 public String getIssue() { 5006 return this.issue == null ? null : this.issue.getValue(); 5007 } 5008 5009 /** 5010 * @param value Issue, part or supplement of journal in which the article is published. 5011 */ 5012 public CitationCitedArtifactPublicationFormComponent setIssue(String value) { 5013 if (Utilities.noString(value)) 5014 this.issue = null; 5015 else { 5016 if (this.issue == null) 5017 this.issue = new StringType(); 5018 this.issue.setValue(value); 5019 } 5020 return this; 5021 } 5022 5023 /** 5024 * @return {@link #publicationDateYear} (Year on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateYear" gives direct access to the value 5025 */ 5026 public StringType getPublicationDateYearElement() { 5027 if (this.publicationDateYear == null) 5028 if (Configuration.errorOnAutoCreate()) 5029 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publicationDateYear"); 5030 else if (Configuration.doAutoCreate()) 5031 this.publicationDateYear = new StringType(); // bb 5032 return this.publicationDateYear; 5033 } 5034 5035 public boolean hasPublicationDateYearElement() { 5036 return this.publicationDateYear != null && !this.publicationDateYear.isEmpty(); 5037 } 5038 5039 public boolean hasPublicationDateYear() { 5040 return this.publicationDateYear != null && !this.publicationDateYear.isEmpty(); 5041 } 5042 5043 /** 5044 * @param value {@link #publicationDateYear} (Year on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateYear" gives direct access to the value 5045 */ 5046 public CitationCitedArtifactPublicationFormComponent setPublicationDateYearElement(StringType value) { 5047 this.publicationDateYear = value; 5048 return this; 5049 } 5050 5051 /** 5052 * @return Year on which the issue of the journal was published. 5053 */ 5054 public String getPublicationDateYear() { 5055 return this.publicationDateYear == null ? null : this.publicationDateYear.getValue(); 5056 } 5057 5058 /** 5059 * @param value Year on which the issue of the journal was published. 5060 */ 5061 public CitationCitedArtifactPublicationFormComponent setPublicationDateYear(String value) { 5062 if (Utilities.noString(value)) 5063 this.publicationDateYear = null; 5064 else { 5065 if (this.publicationDateYear == null) 5066 this.publicationDateYear = new StringType(); 5067 this.publicationDateYear.setValue(value); 5068 } 5069 return this; 5070 } 5071 5072 /** 5073 * @return {@link #publicationDateMonth} (Month on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateMonth" gives direct access to the value 5074 */ 5075 public StringType getPublicationDateMonthElement() { 5076 if (this.publicationDateMonth == null) 5077 if (Configuration.errorOnAutoCreate()) 5078 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publicationDateMonth"); 5079 else if (Configuration.doAutoCreate()) 5080 this.publicationDateMonth = new StringType(); // bb 5081 return this.publicationDateMonth; 5082 } 5083 5084 public boolean hasPublicationDateMonthElement() { 5085 return this.publicationDateMonth != null && !this.publicationDateMonth.isEmpty(); 5086 } 5087 5088 public boolean hasPublicationDateMonth() { 5089 return this.publicationDateMonth != null && !this.publicationDateMonth.isEmpty(); 5090 } 5091 5092 /** 5093 * @param value {@link #publicationDateMonth} (Month on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateMonth" gives direct access to the value 5094 */ 5095 public CitationCitedArtifactPublicationFormComponent setPublicationDateMonthElement(StringType value) { 5096 this.publicationDateMonth = value; 5097 return this; 5098 } 5099 5100 /** 5101 * @return Month on which the issue of the journal was published. 5102 */ 5103 public String getPublicationDateMonth() { 5104 return this.publicationDateMonth == null ? null : this.publicationDateMonth.getValue(); 5105 } 5106 5107 /** 5108 * @param value Month on which the issue of the journal was published. 5109 */ 5110 public CitationCitedArtifactPublicationFormComponent setPublicationDateMonth(String value) { 5111 if (Utilities.noString(value)) 5112 this.publicationDateMonth = null; 5113 else { 5114 if (this.publicationDateMonth == null) 5115 this.publicationDateMonth = new StringType(); 5116 this.publicationDateMonth.setValue(value); 5117 } 5118 return this; 5119 } 5120 5121 /** 5122 * @return {@link #publicationDateDay} (Day on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateDay" gives direct access to the value 5123 */ 5124 public StringType getPublicationDateDayElement() { 5125 if (this.publicationDateDay == null) 5126 if (Configuration.errorOnAutoCreate()) 5127 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publicationDateDay"); 5128 else if (Configuration.doAutoCreate()) 5129 this.publicationDateDay = new StringType(); // bb 5130 return this.publicationDateDay; 5131 } 5132 5133 public boolean hasPublicationDateDayElement() { 5134 return this.publicationDateDay != null && !this.publicationDateDay.isEmpty(); 5135 } 5136 5137 public boolean hasPublicationDateDay() { 5138 return this.publicationDateDay != null && !this.publicationDateDay.isEmpty(); 5139 } 5140 5141 /** 5142 * @param value {@link #publicationDateDay} (Day on which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateDay" gives direct access to the value 5143 */ 5144 public CitationCitedArtifactPublicationFormComponent setPublicationDateDayElement(StringType value) { 5145 this.publicationDateDay = value; 5146 return this; 5147 } 5148 5149 /** 5150 * @return Day on which the issue of the journal was published. 5151 */ 5152 public String getPublicationDateDay() { 5153 return this.publicationDateDay == null ? null : this.publicationDateDay.getValue(); 5154 } 5155 5156 /** 5157 * @param value Day on which the issue of the journal was published. 5158 */ 5159 public CitationCitedArtifactPublicationFormComponent setPublicationDateDay(String value) { 5160 if (Utilities.noString(value)) 5161 this.publicationDateDay = null; 5162 else { 5163 if (this.publicationDateDay == null) 5164 this.publicationDateDay = new StringType(); 5165 this.publicationDateDay.setValue(value); 5166 } 5167 return this; 5168 } 5169 5170 /** 5171 * @return {@link #publicationDateSeason} (Spring, Summer, Fall/Autumn, Winter.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateSeason" gives direct access to the value 5172 */ 5173 public StringType getPublicationDateSeasonElement() { 5174 if (this.publicationDateSeason == null) 5175 if (Configuration.errorOnAutoCreate()) 5176 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publicationDateSeason"); 5177 else if (Configuration.doAutoCreate()) 5178 this.publicationDateSeason = new StringType(); // bb 5179 return this.publicationDateSeason; 5180 } 5181 5182 public boolean hasPublicationDateSeasonElement() { 5183 return this.publicationDateSeason != null && !this.publicationDateSeason.isEmpty(); 5184 } 5185 5186 public boolean hasPublicationDateSeason() { 5187 return this.publicationDateSeason != null && !this.publicationDateSeason.isEmpty(); 5188 } 5189 5190 /** 5191 * @param value {@link #publicationDateSeason} (Spring, Summer, Fall/Autumn, Winter.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateSeason" gives direct access to the value 5192 */ 5193 public CitationCitedArtifactPublicationFormComponent setPublicationDateSeasonElement(StringType value) { 5194 this.publicationDateSeason = value; 5195 return this; 5196 } 5197 5198 /** 5199 * @return Spring, Summer, Fall/Autumn, Winter. 5200 */ 5201 public String getPublicationDateSeason() { 5202 return this.publicationDateSeason == null ? null : this.publicationDateSeason.getValue(); 5203 } 5204 5205 /** 5206 * @param value Spring, Summer, Fall/Autumn, Winter. 5207 */ 5208 public CitationCitedArtifactPublicationFormComponent setPublicationDateSeason(String value) { 5209 if (Utilities.noString(value)) 5210 this.publicationDateSeason = null; 5211 else { 5212 if (this.publicationDateSeason == null) 5213 this.publicationDateSeason = new StringType(); 5214 this.publicationDateSeason.setValue(value); 5215 } 5216 return this; 5217 } 5218 5219 /** 5220 * @return {@link #publicationDateText} (Text representation of the date of which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateText" gives direct access to the value 5221 */ 5222 public StringType getPublicationDateTextElement() { 5223 if (this.publicationDateText == null) 5224 if (Configuration.errorOnAutoCreate()) 5225 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.publicationDateText"); 5226 else if (Configuration.doAutoCreate()) 5227 this.publicationDateText = new StringType(); // bb 5228 return this.publicationDateText; 5229 } 5230 5231 public boolean hasPublicationDateTextElement() { 5232 return this.publicationDateText != null && !this.publicationDateText.isEmpty(); 5233 } 5234 5235 public boolean hasPublicationDateText() { 5236 return this.publicationDateText != null && !this.publicationDateText.isEmpty(); 5237 } 5238 5239 /** 5240 * @param value {@link #publicationDateText} (Text representation of the date of which the issue of the journal was published.). This is the underlying object with id, value and extensions. The accessor "getPublicationDateText" gives direct access to the value 5241 */ 5242 public CitationCitedArtifactPublicationFormComponent setPublicationDateTextElement(StringType value) { 5243 this.publicationDateText = value; 5244 return this; 5245 } 5246 5247 /** 5248 * @return Text representation of the date of which the issue of the journal was published. 5249 */ 5250 public String getPublicationDateText() { 5251 return this.publicationDateText == null ? null : this.publicationDateText.getValue(); 5252 } 5253 5254 /** 5255 * @param value Text representation of the date of which the issue of the journal was published. 5256 */ 5257 public CitationCitedArtifactPublicationFormComponent setPublicationDateText(String value) { 5258 if (Utilities.noString(value)) 5259 this.publicationDateText = null; 5260 else { 5261 if (this.publicationDateText == null) 5262 this.publicationDateText = new StringType(); 5263 this.publicationDateText.setValue(value); 5264 } 5265 return this; 5266 } 5267 5268 /** 5269 * @return {@link #articleDate} (The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date).). This is the underlying object with id, value and extensions. The accessor "getArticleDate" gives direct access to the value 5270 */ 5271 public DateTimeType getArticleDateElement() { 5272 if (this.articleDate == null) 5273 if (Configuration.errorOnAutoCreate()) 5274 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.articleDate"); 5275 else if (Configuration.doAutoCreate()) 5276 this.articleDate = new DateTimeType(); // bb 5277 return this.articleDate; 5278 } 5279 5280 public boolean hasArticleDateElement() { 5281 return this.articleDate != null && !this.articleDate.isEmpty(); 5282 } 5283 5284 public boolean hasArticleDate() { 5285 return this.articleDate != null && !this.articleDate.isEmpty(); 5286 } 5287 5288 /** 5289 * @param value {@link #articleDate} (The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date).). This is the underlying object with id, value and extensions. The accessor "getArticleDate" gives direct access to the value 5290 */ 5291 public CitationCitedArtifactPublicationFormComponent setArticleDateElement(DateTimeType value) { 5292 this.articleDate = value; 5293 return this; 5294 } 5295 5296 /** 5297 * @return The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date). 5298 */ 5299 public Date getArticleDate() { 5300 return this.articleDate == null ? null : this.articleDate.getValue(); 5301 } 5302 5303 /** 5304 * @param value The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date). 5305 */ 5306 public CitationCitedArtifactPublicationFormComponent setArticleDate(Date value) { 5307 if (value == null) 5308 this.articleDate = null; 5309 else { 5310 if (this.articleDate == null) 5311 this.articleDate = new DateTimeType(); 5312 this.articleDate.setValue(value); 5313 } 5314 return this; 5315 } 5316 5317 /** 5318 * @return {@link #lastRevisionDate} (The date the article was last revised or updated in the database.). This is the underlying object with id, value and extensions. The accessor "getLastRevisionDate" gives direct access to the value 5319 */ 5320 public DateTimeType getLastRevisionDateElement() { 5321 if (this.lastRevisionDate == null) 5322 if (Configuration.errorOnAutoCreate()) 5323 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.lastRevisionDate"); 5324 else if (Configuration.doAutoCreate()) 5325 this.lastRevisionDate = new DateTimeType(); // bb 5326 return this.lastRevisionDate; 5327 } 5328 5329 public boolean hasLastRevisionDateElement() { 5330 return this.lastRevisionDate != null && !this.lastRevisionDate.isEmpty(); 5331 } 5332 5333 public boolean hasLastRevisionDate() { 5334 return this.lastRevisionDate != null && !this.lastRevisionDate.isEmpty(); 5335 } 5336 5337 /** 5338 * @param value {@link #lastRevisionDate} (The date the article was last revised or updated in the database.). This is the underlying object with id, value and extensions. The accessor "getLastRevisionDate" gives direct access to the value 5339 */ 5340 public CitationCitedArtifactPublicationFormComponent setLastRevisionDateElement(DateTimeType value) { 5341 this.lastRevisionDate = value; 5342 return this; 5343 } 5344 5345 /** 5346 * @return The date the article was last revised or updated in the database. 5347 */ 5348 public Date getLastRevisionDate() { 5349 return this.lastRevisionDate == null ? null : this.lastRevisionDate.getValue(); 5350 } 5351 5352 /** 5353 * @param value The date the article was last revised or updated in the database. 5354 */ 5355 public CitationCitedArtifactPublicationFormComponent setLastRevisionDate(Date value) { 5356 if (value == null) 5357 this.lastRevisionDate = null; 5358 else { 5359 if (this.lastRevisionDate == null) 5360 this.lastRevisionDate = new DateTimeType(); 5361 this.lastRevisionDate.setValue(value); 5362 } 5363 return this; 5364 } 5365 5366 /** 5367 * @return {@link #language} (Language in which this form of the article is published.) 5368 */ 5369 public List<CodeableConcept> getLanguage() { 5370 if (this.language == null) 5371 this.language = new ArrayList<CodeableConcept>(); 5372 return this.language; 5373 } 5374 5375 /** 5376 * @return Returns a reference to <code>this</code> for easy method chaining 5377 */ 5378 public CitationCitedArtifactPublicationFormComponent setLanguage(List<CodeableConcept> theLanguage) { 5379 this.language = theLanguage; 5380 return this; 5381 } 5382 5383 public boolean hasLanguage() { 5384 if (this.language == null) 5385 return false; 5386 for (CodeableConcept item : this.language) 5387 if (!item.isEmpty()) 5388 return true; 5389 return false; 5390 } 5391 5392 public CodeableConcept addLanguage() { //3 5393 CodeableConcept t = new CodeableConcept(); 5394 if (this.language == null) 5395 this.language = new ArrayList<CodeableConcept>(); 5396 this.language.add(t); 5397 return t; 5398 } 5399 5400 public CitationCitedArtifactPublicationFormComponent addLanguage(CodeableConcept t) { //3 5401 if (t == null) 5402 return this; 5403 if (this.language == null) 5404 this.language = new ArrayList<CodeableConcept>(); 5405 this.language.add(t); 5406 return this; 5407 } 5408 5409 /** 5410 * @return The first repetition of repeating field {@link #language}, creating it if it does not already exist {3} 5411 */ 5412 public CodeableConcept getLanguageFirstRep() { 5413 if (getLanguage().isEmpty()) { 5414 addLanguage(); 5415 } 5416 return getLanguage().get(0); 5417 } 5418 5419 /** 5420 * @return {@link #accessionNumber} (Entry number or identifier for inclusion in a database.). This is the underlying object with id, value and extensions. The accessor "getAccessionNumber" gives direct access to the value 5421 */ 5422 public StringType getAccessionNumberElement() { 5423 if (this.accessionNumber == null) 5424 if (Configuration.errorOnAutoCreate()) 5425 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.accessionNumber"); 5426 else if (Configuration.doAutoCreate()) 5427 this.accessionNumber = new StringType(); // bb 5428 return this.accessionNumber; 5429 } 5430 5431 public boolean hasAccessionNumberElement() { 5432 return this.accessionNumber != null && !this.accessionNumber.isEmpty(); 5433 } 5434 5435 public boolean hasAccessionNumber() { 5436 return this.accessionNumber != null && !this.accessionNumber.isEmpty(); 5437 } 5438 5439 /** 5440 * @param value {@link #accessionNumber} (Entry number or identifier for inclusion in a database.). This is the underlying object with id, value and extensions. The accessor "getAccessionNumber" gives direct access to the value 5441 */ 5442 public CitationCitedArtifactPublicationFormComponent setAccessionNumberElement(StringType value) { 5443 this.accessionNumber = value; 5444 return this; 5445 } 5446 5447 /** 5448 * @return Entry number or identifier for inclusion in a database. 5449 */ 5450 public String getAccessionNumber() { 5451 return this.accessionNumber == null ? null : this.accessionNumber.getValue(); 5452 } 5453 5454 /** 5455 * @param value Entry number or identifier for inclusion in a database. 5456 */ 5457 public CitationCitedArtifactPublicationFormComponent setAccessionNumber(String value) { 5458 if (Utilities.noString(value)) 5459 this.accessionNumber = null; 5460 else { 5461 if (this.accessionNumber == null) 5462 this.accessionNumber = new StringType(); 5463 this.accessionNumber.setValue(value); 5464 } 5465 return this; 5466 } 5467 5468 /** 5469 * @return {@link #pageString} (Used for full display of pagination.). This is the underlying object with id, value and extensions. The accessor "getPageString" gives direct access to the value 5470 */ 5471 public StringType getPageStringElement() { 5472 if (this.pageString == null) 5473 if (Configuration.errorOnAutoCreate()) 5474 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.pageString"); 5475 else if (Configuration.doAutoCreate()) 5476 this.pageString = new StringType(); // bb 5477 return this.pageString; 5478 } 5479 5480 public boolean hasPageStringElement() { 5481 return this.pageString != null && !this.pageString.isEmpty(); 5482 } 5483 5484 public boolean hasPageString() { 5485 return this.pageString != null && !this.pageString.isEmpty(); 5486 } 5487 5488 /** 5489 * @param value {@link #pageString} (Used for full display of pagination.). This is the underlying object with id, value and extensions. The accessor "getPageString" gives direct access to the value 5490 */ 5491 public CitationCitedArtifactPublicationFormComponent setPageStringElement(StringType value) { 5492 this.pageString = value; 5493 return this; 5494 } 5495 5496 /** 5497 * @return Used for full display of pagination. 5498 */ 5499 public String getPageString() { 5500 return this.pageString == null ? null : this.pageString.getValue(); 5501 } 5502 5503 /** 5504 * @param value Used for full display of pagination. 5505 */ 5506 public CitationCitedArtifactPublicationFormComponent setPageString(String value) { 5507 if (Utilities.noString(value)) 5508 this.pageString = null; 5509 else { 5510 if (this.pageString == null) 5511 this.pageString = new StringType(); 5512 this.pageString.setValue(value); 5513 } 5514 return this; 5515 } 5516 5517 /** 5518 * @return {@link #firstPage} (Used for isolated representation of first page.). This is the underlying object with id, value and extensions. The accessor "getFirstPage" gives direct access to the value 5519 */ 5520 public StringType getFirstPageElement() { 5521 if (this.firstPage == null) 5522 if (Configuration.errorOnAutoCreate()) 5523 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.firstPage"); 5524 else if (Configuration.doAutoCreate()) 5525 this.firstPage = new StringType(); // bb 5526 return this.firstPage; 5527 } 5528 5529 public boolean hasFirstPageElement() { 5530 return this.firstPage != null && !this.firstPage.isEmpty(); 5531 } 5532 5533 public boolean hasFirstPage() { 5534 return this.firstPage != null && !this.firstPage.isEmpty(); 5535 } 5536 5537 /** 5538 * @param value {@link #firstPage} (Used for isolated representation of first page.). This is the underlying object with id, value and extensions. The accessor "getFirstPage" gives direct access to the value 5539 */ 5540 public CitationCitedArtifactPublicationFormComponent setFirstPageElement(StringType value) { 5541 this.firstPage = value; 5542 return this; 5543 } 5544 5545 /** 5546 * @return Used for isolated representation of first page. 5547 */ 5548 public String getFirstPage() { 5549 return this.firstPage == null ? null : this.firstPage.getValue(); 5550 } 5551 5552 /** 5553 * @param value Used for isolated representation of first page. 5554 */ 5555 public CitationCitedArtifactPublicationFormComponent setFirstPage(String value) { 5556 if (Utilities.noString(value)) 5557 this.firstPage = null; 5558 else { 5559 if (this.firstPage == null) 5560 this.firstPage = new StringType(); 5561 this.firstPage.setValue(value); 5562 } 5563 return this; 5564 } 5565 5566 /** 5567 * @return {@link #lastPage} (Used for isolated representation of last page.). This is the underlying object with id, value and extensions. The accessor "getLastPage" gives direct access to the value 5568 */ 5569 public StringType getLastPageElement() { 5570 if (this.lastPage == null) 5571 if (Configuration.errorOnAutoCreate()) 5572 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.lastPage"); 5573 else if (Configuration.doAutoCreate()) 5574 this.lastPage = new StringType(); // bb 5575 return this.lastPage; 5576 } 5577 5578 public boolean hasLastPageElement() { 5579 return this.lastPage != null && !this.lastPage.isEmpty(); 5580 } 5581 5582 public boolean hasLastPage() { 5583 return this.lastPage != null && !this.lastPage.isEmpty(); 5584 } 5585 5586 /** 5587 * @param value {@link #lastPage} (Used for isolated representation of last page.). This is the underlying object with id, value and extensions. The accessor "getLastPage" gives direct access to the value 5588 */ 5589 public CitationCitedArtifactPublicationFormComponent setLastPageElement(StringType value) { 5590 this.lastPage = value; 5591 return this; 5592 } 5593 5594 /** 5595 * @return Used for isolated representation of last page. 5596 */ 5597 public String getLastPage() { 5598 return this.lastPage == null ? null : this.lastPage.getValue(); 5599 } 5600 5601 /** 5602 * @param value Used for isolated representation of last page. 5603 */ 5604 public CitationCitedArtifactPublicationFormComponent setLastPage(String value) { 5605 if (Utilities.noString(value)) 5606 this.lastPage = null; 5607 else { 5608 if (this.lastPage == null) 5609 this.lastPage = new StringType(); 5610 this.lastPage.setValue(value); 5611 } 5612 return this; 5613 } 5614 5615 /** 5616 * @return {@link #pageCount} (Actual or approximate number of pages or screens.). This is the underlying object with id, value and extensions. The accessor "getPageCount" gives direct access to the value 5617 */ 5618 public StringType getPageCountElement() { 5619 if (this.pageCount == null) 5620 if (Configuration.errorOnAutoCreate()) 5621 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.pageCount"); 5622 else if (Configuration.doAutoCreate()) 5623 this.pageCount = new StringType(); // bb 5624 return this.pageCount; 5625 } 5626 5627 public boolean hasPageCountElement() { 5628 return this.pageCount != null && !this.pageCount.isEmpty(); 5629 } 5630 5631 public boolean hasPageCount() { 5632 return this.pageCount != null && !this.pageCount.isEmpty(); 5633 } 5634 5635 /** 5636 * @param value {@link #pageCount} (Actual or approximate number of pages or screens.). This is the underlying object with id, value and extensions. The accessor "getPageCount" gives direct access to the value 5637 */ 5638 public CitationCitedArtifactPublicationFormComponent setPageCountElement(StringType value) { 5639 this.pageCount = value; 5640 return this; 5641 } 5642 5643 /** 5644 * @return Actual or approximate number of pages or screens. 5645 */ 5646 public String getPageCount() { 5647 return this.pageCount == null ? null : this.pageCount.getValue(); 5648 } 5649 5650 /** 5651 * @param value Actual or approximate number of pages or screens. 5652 */ 5653 public CitationCitedArtifactPublicationFormComponent setPageCount(String value) { 5654 if (Utilities.noString(value)) 5655 this.pageCount = null; 5656 else { 5657 if (this.pageCount == null) 5658 this.pageCount = new StringType(); 5659 this.pageCount.setValue(value); 5660 } 5661 return this; 5662 } 5663 5664 /** 5665 * @return {@link #copyright} (Copyright notice for the full article or artifact.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 5666 */ 5667 public MarkdownType getCopyrightElement() { 5668 if (this.copyright == null) 5669 if (Configuration.errorOnAutoCreate()) 5670 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormComponent.copyright"); 5671 else if (Configuration.doAutoCreate()) 5672 this.copyright = new MarkdownType(); // bb 5673 return this.copyright; 5674 } 5675 5676 public boolean hasCopyrightElement() { 5677 return this.copyright != null && !this.copyright.isEmpty(); 5678 } 5679 5680 public boolean hasCopyright() { 5681 return this.copyright != null && !this.copyright.isEmpty(); 5682 } 5683 5684 /** 5685 * @param value {@link #copyright} (Copyright notice for the full article or artifact.). This is the underlying object with id, value and extensions. The accessor "getCopyright" gives direct access to the value 5686 */ 5687 public CitationCitedArtifactPublicationFormComponent setCopyrightElement(MarkdownType value) { 5688 this.copyright = value; 5689 return this; 5690 } 5691 5692 /** 5693 * @return Copyright notice for the full article or artifact. 5694 */ 5695 public String getCopyright() { 5696 return this.copyright == null ? null : this.copyright.getValue(); 5697 } 5698 5699 /** 5700 * @param value Copyright notice for the full article or artifact. 5701 */ 5702 public CitationCitedArtifactPublicationFormComponent setCopyright(String value) { 5703 if (value == null) 5704 this.copyright = null; 5705 else { 5706 if (this.copyright == null) 5707 this.copyright = new MarkdownType(); 5708 this.copyright.setValue(value); 5709 } 5710 return this; 5711 } 5712 5713 protected void listChildren(List<Property> children) { 5714 super.listChildren(children); 5715 children.add(new Property("publishedIn", "", "The collection the cited article or artifact is published in.", 0, 1, publishedIn)); 5716 children.add(new Property("citedMedium", "CodeableConcept", "Describes the form of the medium cited. Common codes are \"Internet\" or \"Print\".", 0, 1, citedMedium)); 5717 children.add(new Property("volume", "string", "Volume number of journal in which the article is published.", 0, 1, volume)); 5718 children.add(new Property("issue", "string", "Issue, part or supplement of journal in which the article is published.", 0, 1, issue)); 5719 children.add(new Property("publicationDateYear", "string", "Year on which the issue of the journal was published.", 0, 1, publicationDateYear)); 5720 children.add(new Property("publicationDateMonth", "string", "Month on which the issue of the journal was published.", 0, 1, publicationDateMonth)); 5721 children.add(new Property("publicationDateDay", "string", "Day on which the issue of the journal was published.", 0, 1, publicationDateDay)); 5722 children.add(new Property("publicationDateSeason", "string", "Spring, Summer, Fall/Autumn, Winter.", 0, 1, publicationDateSeason)); 5723 children.add(new Property("publicationDateText", "string", "Text representation of the date of which the issue of the journal was published.", 0, 1, publicationDateText)); 5724 children.add(new Property("articleDate", "dateTime", "The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date).", 0, 1, articleDate)); 5725 children.add(new Property("lastRevisionDate", "dateTime", "The date the article was last revised or updated in the database.", 0, 1, lastRevisionDate)); 5726 children.add(new Property("language", "CodeableConcept", "Language in which this form of the article is published.", 0, java.lang.Integer.MAX_VALUE, language)); 5727 children.add(new Property("accessionNumber", "string", "Entry number or identifier for inclusion in a database.", 0, 1, accessionNumber)); 5728 children.add(new Property("pageString", "string", "Used for full display of pagination.", 0, 1, pageString)); 5729 children.add(new Property("firstPage", "string", "Used for isolated representation of first page.", 0, 1, firstPage)); 5730 children.add(new Property("lastPage", "string", "Used for isolated representation of last page.", 0, 1, lastPage)); 5731 children.add(new Property("pageCount", "string", "Actual or approximate number of pages or screens.", 0, 1, pageCount)); 5732 children.add(new Property("copyright", "markdown", "Copyright notice for the full article or artifact.", 0, 1, copyright)); 5733 } 5734 5735 @Override 5736 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 5737 switch (_hash) { 5738 case -614144077: /*publishedIn*/ return new Property("publishedIn", "", "The collection the cited article or artifact is published in.", 0, 1, publishedIn); 5739 case 612116418: /*citedMedium*/ return new Property("citedMedium", "CodeableConcept", "Describes the form of the medium cited. Common codes are \"Internet\" or \"Print\".", 0, 1, citedMedium); 5740 case -810883302: /*volume*/ return new Property("volume", "string", "Volume number of journal in which the article is published.", 0, 1, volume); 5741 case 100509913: /*issue*/ return new Property("issue", "string", "Issue, part or supplement of journal in which the article is published.", 0, 1, issue); 5742 case 225738583: /*publicationDateYear*/ return new Property("publicationDateYear", "string", "Year on which the issue of the journal was published.", 0, 1, publicationDateYear); 5743 case -1602810202: /*publicationDateMonth*/ return new Property("publicationDateMonth", "string", "Month on which the issue of the journal was published.", 0, 1, publicationDateMonth); 5744 case 977092930: /*publicationDateDay*/ return new Property("publicationDateDay", "string", "Day on which the issue of the journal was published.", 0, 1, publicationDateDay); 5745 case 2014643069: /*publicationDateSeason*/ return new Property("publicationDateSeason", "string", "Spring, Summer, Fall/Autumn, Winter.", 0, 1, publicationDateSeason); 5746 case 225590343: /*publicationDateText*/ return new Property("publicationDateText", "string", "Text representation of the date of which the issue of the journal was published.", 0, 1, publicationDateText); 5747 case 817743300: /*articleDate*/ return new Property("articleDate", "dateTime", "The date the article was added to the database, or the date the article was released (which may differ from the journal issue publication date).", 0, 1, articleDate); 5748 case 2129161183: /*lastRevisionDate*/ return new Property("lastRevisionDate", "dateTime", "The date the article was last revised or updated in the database.", 0, 1, lastRevisionDate); 5749 case -1613589672: /*language*/ return new Property("language", "CodeableConcept", "Language in which this form of the article is published.", 0, java.lang.Integer.MAX_VALUE, language); 5750 case 1807963277: /*accessionNumber*/ return new Property("accessionNumber", "string", "Entry number or identifier for inclusion in a database.", 0, 1, accessionNumber); 5751 case 1287145344: /*pageString*/ return new Property("pageString", "string", "Used for full display of pagination.", 0, 1, pageString); 5752 case 132895071: /*firstPage*/ return new Property("firstPage", "string", "Used for isolated representation of first page.", 0, 1, firstPage); 5753 case -1459540411: /*lastPage*/ return new Property("lastPage", "string", "Used for isolated representation of last page.", 0, 1, lastPage); 5754 case 857882560: /*pageCount*/ return new Property("pageCount", "string", "Actual or approximate number of pages or screens.", 0, 1, pageCount); 5755 case 1522889671: /*copyright*/ return new Property("copyright", "markdown", "Copyright notice for the full article or artifact.", 0, 1, copyright); 5756 default: return super.getNamedProperty(_hash, _name, _checkValid); 5757 } 5758 5759 } 5760 5761 @Override 5762 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 5763 switch (hash) { 5764 case -614144077: /*publishedIn*/ return this.publishedIn == null ? new Base[0] : new Base[] {this.publishedIn}; // CitationCitedArtifactPublicationFormPublishedInComponent 5765 case 612116418: /*citedMedium*/ return this.citedMedium == null ? new Base[0] : new Base[] {this.citedMedium}; // CodeableConcept 5766 case -810883302: /*volume*/ return this.volume == null ? new Base[0] : new Base[] {this.volume}; // StringType 5767 case 100509913: /*issue*/ return this.issue == null ? new Base[0] : new Base[] {this.issue}; // StringType 5768 case 225738583: /*publicationDateYear*/ return this.publicationDateYear == null ? new Base[0] : new Base[] {this.publicationDateYear}; // StringType 5769 case -1602810202: /*publicationDateMonth*/ return this.publicationDateMonth == null ? new Base[0] : new Base[] {this.publicationDateMonth}; // StringType 5770 case 977092930: /*publicationDateDay*/ return this.publicationDateDay == null ? new Base[0] : new Base[] {this.publicationDateDay}; // StringType 5771 case 2014643069: /*publicationDateSeason*/ return this.publicationDateSeason == null ? new Base[0] : new Base[] {this.publicationDateSeason}; // StringType 5772 case 225590343: /*publicationDateText*/ return this.publicationDateText == null ? new Base[0] : new Base[] {this.publicationDateText}; // StringType 5773 case 817743300: /*articleDate*/ return this.articleDate == null ? new Base[0] : new Base[] {this.articleDate}; // DateTimeType 5774 case 2129161183: /*lastRevisionDate*/ return this.lastRevisionDate == null ? new Base[0] : new Base[] {this.lastRevisionDate}; // DateTimeType 5775 case -1613589672: /*language*/ return this.language == null ? new Base[0] : this.language.toArray(new Base[this.language.size()]); // CodeableConcept 5776 case 1807963277: /*accessionNumber*/ return this.accessionNumber == null ? new Base[0] : new Base[] {this.accessionNumber}; // StringType 5777 case 1287145344: /*pageString*/ return this.pageString == null ? new Base[0] : new Base[] {this.pageString}; // StringType 5778 case 132895071: /*firstPage*/ return this.firstPage == null ? new Base[0] : new Base[] {this.firstPage}; // StringType 5779 case -1459540411: /*lastPage*/ return this.lastPage == null ? new Base[0] : new Base[] {this.lastPage}; // StringType 5780 case 857882560: /*pageCount*/ return this.pageCount == null ? new Base[0] : new Base[] {this.pageCount}; // StringType 5781 case 1522889671: /*copyright*/ return this.copyright == null ? new Base[0] : new Base[] {this.copyright}; // MarkdownType 5782 default: return super.getProperty(hash, name, checkValid); 5783 } 5784 5785 } 5786 5787 @Override 5788 public Base setProperty(int hash, String name, Base value) throws FHIRException { 5789 switch (hash) { 5790 case -614144077: // publishedIn 5791 this.publishedIn = (CitationCitedArtifactPublicationFormPublishedInComponent) value; // CitationCitedArtifactPublicationFormPublishedInComponent 5792 return value; 5793 case 612116418: // citedMedium 5794 this.citedMedium = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 5795 return value; 5796 case -810883302: // volume 5797 this.volume = TypeConvertor.castToString(value); // StringType 5798 return value; 5799 case 100509913: // issue 5800 this.issue = TypeConvertor.castToString(value); // StringType 5801 return value; 5802 case 225738583: // publicationDateYear 5803 this.publicationDateYear = TypeConvertor.castToString(value); // StringType 5804 return value; 5805 case -1602810202: // publicationDateMonth 5806 this.publicationDateMonth = TypeConvertor.castToString(value); // StringType 5807 return value; 5808 case 977092930: // publicationDateDay 5809 this.publicationDateDay = TypeConvertor.castToString(value); // StringType 5810 return value; 5811 case 2014643069: // publicationDateSeason 5812 this.publicationDateSeason = TypeConvertor.castToString(value); // StringType 5813 return value; 5814 case 225590343: // publicationDateText 5815 this.publicationDateText = TypeConvertor.castToString(value); // StringType 5816 return value; 5817 case 817743300: // articleDate 5818 this.articleDate = TypeConvertor.castToDateTime(value); // DateTimeType 5819 return value; 5820 case 2129161183: // lastRevisionDate 5821 this.lastRevisionDate = TypeConvertor.castToDateTime(value); // DateTimeType 5822 return value; 5823 case -1613589672: // language 5824 this.getLanguage().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 5825 return value; 5826 case 1807963277: // accessionNumber 5827 this.accessionNumber = TypeConvertor.castToString(value); // StringType 5828 return value; 5829 case 1287145344: // pageString 5830 this.pageString = TypeConvertor.castToString(value); // StringType 5831 return value; 5832 case 132895071: // firstPage 5833 this.firstPage = TypeConvertor.castToString(value); // StringType 5834 return value; 5835 case -1459540411: // lastPage 5836 this.lastPage = TypeConvertor.castToString(value); // StringType 5837 return value; 5838 case 857882560: // pageCount 5839 this.pageCount = TypeConvertor.castToString(value); // StringType 5840 return value; 5841 case 1522889671: // copyright 5842 this.copyright = TypeConvertor.castToMarkdown(value); // MarkdownType 5843 return value; 5844 default: return super.setProperty(hash, name, value); 5845 } 5846 5847 } 5848 5849 @Override 5850 public Base setProperty(String name, Base value) throws FHIRException { 5851 if (name.equals("publishedIn")) { 5852 this.publishedIn = (CitationCitedArtifactPublicationFormPublishedInComponent) value; // CitationCitedArtifactPublicationFormPublishedInComponent 5853 } else if (name.equals("citedMedium")) { 5854 this.citedMedium = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 5855 } else if (name.equals("volume")) { 5856 this.volume = TypeConvertor.castToString(value); // StringType 5857 } else if (name.equals("issue")) { 5858 this.issue = TypeConvertor.castToString(value); // StringType 5859 } else if (name.equals("publicationDateYear")) { 5860 this.publicationDateYear = TypeConvertor.castToString(value); // StringType 5861 } else if (name.equals("publicationDateMonth")) { 5862 this.publicationDateMonth = TypeConvertor.castToString(value); // StringType 5863 } else if (name.equals("publicationDateDay")) { 5864 this.publicationDateDay = TypeConvertor.castToString(value); // StringType 5865 } else if (name.equals("publicationDateSeason")) { 5866 this.publicationDateSeason = TypeConvertor.castToString(value); // StringType 5867 } else if (name.equals("publicationDateText")) { 5868 this.publicationDateText = TypeConvertor.castToString(value); // StringType 5869 } else if (name.equals("articleDate")) { 5870 this.articleDate = TypeConvertor.castToDateTime(value); // DateTimeType 5871 } else if (name.equals("lastRevisionDate")) { 5872 this.lastRevisionDate = TypeConvertor.castToDateTime(value); // DateTimeType 5873 } else if (name.equals("language")) { 5874 this.getLanguage().add(TypeConvertor.castToCodeableConcept(value)); 5875 } else if (name.equals("accessionNumber")) { 5876 this.accessionNumber = TypeConvertor.castToString(value); // StringType 5877 } else if (name.equals("pageString")) { 5878 this.pageString = TypeConvertor.castToString(value); // StringType 5879 } else if (name.equals("firstPage")) { 5880 this.firstPage = TypeConvertor.castToString(value); // StringType 5881 } else if (name.equals("lastPage")) { 5882 this.lastPage = TypeConvertor.castToString(value); // StringType 5883 } else if (name.equals("pageCount")) { 5884 this.pageCount = TypeConvertor.castToString(value); // StringType 5885 } else if (name.equals("copyright")) { 5886 this.copyright = TypeConvertor.castToMarkdown(value); // MarkdownType 5887 } else 5888 return super.setProperty(name, value); 5889 return value; 5890 } 5891 5892 @Override 5893 public Base makeProperty(int hash, String name) throws FHIRException { 5894 switch (hash) { 5895 case -614144077: return getPublishedIn(); 5896 case 612116418: return getCitedMedium(); 5897 case -810883302: return getVolumeElement(); 5898 case 100509913: return getIssueElement(); 5899 case 225738583: return getPublicationDateYearElement(); 5900 case -1602810202: return getPublicationDateMonthElement(); 5901 case 977092930: return getPublicationDateDayElement(); 5902 case 2014643069: return getPublicationDateSeasonElement(); 5903 case 225590343: return getPublicationDateTextElement(); 5904 case 817743300: return getArticleDateElement(); 5905 case 2129161183: return getLastRevisionDateElement(); 5906 case -1613589672: return addLanguage(); 5907 case 1807963277: return getAccessionNumberElement(); 5908 case 1287145344: return getPageStringElement(); 5909 case 132895071: return getFirstPageElement(); 5910 case -1459540411: return getLastPageElement(); 5911 case 857882560: return getPageCountElement(); 5912 case 1522889671: return getCopyrightElement(); 5913 default: return super.makeProperty(hash, name); 5914 } 5915 5916 } 5917 5918 @Override 5919 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 5920 switch (hash) { 5921 case -614144077: /*publishedIn*/ return new String[] {}; 5922 case 612116418: /*citedMedium*/ return new String[] {"CodeableConcept"}; 5923 case -810883302: /*volume*/ return new String[] {"string"}; 5924 case 100509913: /*issue*/ return new String[] {"string"}; 5925 case 225738583: /*publicationDateYear*/ return new String[] {"string"}; 5926 case -1602810202: /*publicationDateMonth*/ return new String[] {"string"}; 5927 case 977092930: /*publicationDateDay*/ return new String[] {"string"}; 5928 case 2014643069: /*publicationDateSeason*/ return new String[] {"string"}; 5929 case 225590343: /*publicationDateText*/ return new String[] {"string"}; 5930 case 817743300: /*articleDate*/ return new String[] {"dateTime"}; 5931 case 2129161183: /*lastRevisionDate*/ return new String[] {"dateTime"}; 5932 case -1613589672: /*language*/ return new String[] {"CodeableConcept"}; 5933 case 1807963277: /*accessionNumber*/ return new String[] {"string"}; 5934 case 1287145344: /*pageString*/ return new String[] {"string"}; 5935 case 132895071: /*firstPage*/ return new String[] {"string"}; 5936 case -1459540411: /*lastPage*/ return new String[] {"string"}; 5937 case 857882560: /*pageCount*/ return new String[] {"string"}; 5938 case 1522889671: /*copyright*/ return new String[] {"markdown"}; 5939 default: return super.getTypesForProperty(hash, name); 5940 } 5941 5942 } 5943 5944 @Override 5945 public Base addChild(String name) throws FHIRException { 5946 if (name.equals("publishedIn")) { 5947 this.publishedIn = new CitationCitedArtifactPublicationFormPublishedInComponent(); 5948 return this.publishedIn; 5949 } 5950 else if (name.equals("citedMedium")) { 5951 this.citedMedium = new CodeableConcept(); 5952 return this.citedMedium; 5953 } 5954 else if (name.equals("volume")) { 5955 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.volume"); 5956 } 5957 else if (name.equals("issue")) { 5958 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.issue"); 5959 } 5960 else if (name.equals("publicationDateYear")) { 5961 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publicationDateYear"); 5962 } 5963 else if (name.equals("publicationDateMonth")) { 5964 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publicationDateMonth"); 5965 } 5966 else if (name.equals("publicationDateDay")) { 5967 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publicationDateDay"); 5968 } 5969 else if (name.equals("publicationDateSeason")) { 5970 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publicationDateSeason"); 5971 } 5972 else if (name.equals("publicationDateText")) { 5973 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publicationDateText"); 5974 } 5975 else if (name.equals("articleDate")) { 5976 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.articleDate"); 5977 } 5978 else if (name.equals("lastRevisionDate")) { 5979 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.lastRevisionDate"); 5980 } 5981 else if (name.equals("language")) { 5982 return addLanguage(); 5983 } 5984 else if (name.equals("accessionNumber")) { 5985 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.accessionNumber"); 5986 } 5987 else if (name.equals("pageString")) { 5988 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.pageString"); 5989 } 5990 else if (name.equals("firstPage")) { 5991 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.firstPage"); 5992 } 5993 else if (name.equals("lastPage")) { 5994 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.lastPage"); 5995 } 5996 else if (name.equals("pageCount")) { 5997 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.pageCount"); 5998 } 5999 else if (name.equals("copyright")) { 6000 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.copyright"); 6001 } 6002 else 6003 return super.addChild(name); 6004 } 6005 6006 public CitationCitedArtifactPublicationFormComponent copy() { 6007 CitationCitedArtifactPublicationFormComponent dst = new CitationCitedArtifactPublicationFormComponent(); 6008 copyValues(dst); 6009 return dst; 6010 } 6011 6012 public void copyValues(CitationCitedArtifactPublicationFormComponent dst) { 6013 super.copyValues(dst); 6014 dst.publishedIn = publishedIn == null ? null : publishedIn.copy(); 6015 dst.citedMedium = citedMedium == null ? null : citedMedium.copy(); 6016 dst.volume = volume == null ? null : volume.copy(); 6017 dst.issue = issue == null ? null : issue.copy(); 6018 dst.publicationDateYear = publicationDateYear == null ? null : publicationDateYear.copy(); 6019 dst.publicationDateMonth = publicationDateMonth == null ? null : publicationDateMonth.copy(); 6020 dst.publicationDateDay = publicationDateDay == null ? null : publicationDateDay.copy(); 6021 dst.publicationDateSeason = publicationDateSeason == null ? null : publicationDateSeason.copy(); 6022 dst.publicationDateText = publicationDateText == null ? null : publicationDateText.copy(); 6023 dst.articleDate = articleDate == null ? null : articleDate.copy(); 6024 dst.lastRevisionDate = lastRevisionDate == null ? null : lastRevisionDate.copy(); 6025 if (language != null) { 6026 dst.language = new ArrayList<CodeableConcept>(); 6027 for (CodeableConcept i : language) 6028 dst.language.add(i.copy()); 6029 }; 6030 dst.accessionNumber = accessionNumber == null ? null : accessionNumber.copy(); 6031 dst.pageString = pageString == null ? null : pageString.copy(); 6032 dst.firstPage = firstPage == null ? null : firstPage.copy(); 6033 dst.lastPage = lastPage == null ? null : lastPage.copy(); 6034 dst.pageCount = pageCount == null ? null : pageCount.copy(); 6035 dst.copyright = copyright == null ? null : copyright.copy(); 6036 } 6037 6038 @Override 6039 public boolean equalsDeep(Base other_) { 6040 if (!super.equalsDeep(other_)) 6041 return false; 6042 if (!(other_ instanceof CitationCitedArtifactPublicationFormComponent)) 6043 return false; 6044 CitationCitedArtifactPublicationFormComponent o = (CitationCitedArtifactPublicationFormComponent) other_; 6045 return compareDeep(publishedIn, o.publishedIn, true) && compareDeep(citedMedium, o.citedMedium, true) 6046 && compareDeep(volume, o.volume, true) && compareDeep(issue, o.issue, true) && compareDeep(publicationDateYear, o.publicationDateYear, true) 6047 && compareDeep(publicationDateMonth, o.publicationDateMonth, true) && compareDeep(publicationDateDay, o.publicationDateDay, true) 6048 && compareDeep(publicationDateSeason, o.publicationDateSeason, true) && compareDeep(publicationDateText, o.publicationDateText, true) 6049 && compareDeep(articleDate, o.articleDate, true) && compareDeep(lastRevisionDate, o.lastRevisionDate, true) 6050 && compareDeep(language, o.language, true) && compareDeep(accessionNumber, o.accessionNumber, true) 6051 && compareDeep(pageString, o.pageString, true) && compareDeep(firstPage, o.firstPage, true) && compareDeep(lastPage, o.lastPage, true) 6052 && compareDeep(pageCount, o.pageCount, true) && compareDeep(copyright, o.copyright, true); 6053 } 6054 6055 @Override 6056 public boolean equalsShallow(Base other_) { 6057 if (!super.equalsShallow(other_)) 6058 return false; 6059 if (!(other_ instanceof CitationCitedArtifactPublicationFormComponent)) 6060 return false; 6061 CitationCitedArtifactPublicationFormComponent o = (CitationCitedArtifactPublicationFormComponent) other_; 6062 return compareValues(volume, o.volume, true) && compareValues(issue, o.issue, true) && compareValues(publicationDateYear, o.publicationDateYear, true) 6063 && compareValues(publicationDateMonth, o.publicationDateMonth, true) && compareValues(publicationDateDay, o.publicationDateDay, true) 6064 && compareValues(publicationDateSeason, o.publicationDateSeason, true) && compareValues(publicationDateText, o.publicationDateText, true) 6065 && compareValues(articleDate, o.articleDate, true) && compareValues(lastRevisionDate, o.lastRevisionDate, true) 6066 && compareValues(accessionNumber, o.accessionNumber, true) && compareValues(pageString, o.pageString, true) 6067 && compareValues(firstPage, o.firstPage, true) && compareValues(lastPage, o.lastPage, true) && compareValues(pageCount, o.pageCount, true) 6068 && compareValues(copyright, o.copyright, true); 6069 } 6070 6071 public boolean isEmpty() { 6072 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(publishedIn, citedMedium, volume 6073 , issue, publicationDateYear, publicationDateMonth, publicationDateDay, publicationDateSeason 6074 , publicationDateText, articleDate, lastRevisionDate, language, accessionNumber, pageString 6075 , firstPage, lastPage, pageCount, copyright); 6076 } 6077 6078 public String fhirType() { 6079 return "Citation.citedArtifact.publicationForm"; 6080 6081 } 6082 6083 } 6084 6085 @Block() 6086 public static class CitationCitedArtifactPublicationFormPublishedInComponent extends BackboneElement implements IBaseBackboneElement { 6087 /** 6088 * Kind of container (e.g. Periodical, database, or book). 6089 */ 6090 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 6091 @Description(shortDefinition="Kind of container (e.g. Periodical, database, or book)", formalDefinition="Kind of container (e.g. Periodical, database, or book)." ) 6092 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/published-in-type") 6093 protected CodeableConcept type; 6094 6095 /** 6096 * Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN. 6097 */ 6098 @Child(name = "identifier", type = {Identifier.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 6099 @Description(shortDefinition="Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN", formalDefinition="Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN." ) 6100 protected List<Identifier> identifier; 6101 6102 /** 6103 * Name of the database or title of the book or journal. 6104 */ 6105 @Child(name = "title", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=false) 6106 @Description(shortDefinition="Name of the database or title of the book or journal", formalDefinition="Name of the database or title of the book or journal." ) 6107 protected StringType title; 6108 6109 /** 6110 * Name of the publisher. 6111 */ 6112 @Child(name = "publisher", type = {Organization.class}, order=4, min=0, max=1, modifier=false, summary=false) 6113 @Description(shortDefinition="Name of the publisher", formalDefinition="Name of the publisher." ) 6114 protected Reference publisher; 6115 6116 /** 6117 * Geographic location of the publisher. 6118 */ 6119 @Child(name = "publisherLocation", type = {StringType.class}, order=5, min=0, max=1, modifier=false, summary=false) 6120 @Description(shortDefinition="Geographic location of the publisher", formalDefinition="Geographic location of the publisher." ) 6121 protected StringType publisherLocation; 6122 6123 private static final long serialVersionUID = 1440066953L; 6124 6125 /** 6126 * Constructor 6127 */ 6128 public CitationCitedArtifactPublicationFormPublishedInComponent() { 6129 super(); 6130 } 6131 6132 /** 6133 * @return {@link #type} (Kind of container (e.g. Periodical, database, or book).) 6134 */ 6135 public CodeableConcept getType() { 6136 if (this.type == null) 6137 if (Configuration.errorOnAutoCreate()) 6138 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormPublishedInComponent.type"); 6139 else if (Configuration.doAutoCreate()) 6140 this.type = new CodeableConcept(); // cc 6141 return this.type; 6142 } 6143 6144 public boolean hasType() { 6145 return this.type != null && !this.type.isEmpty(); 6146 } 6147 6148 /** 6149 * @param value {@link #type} (Kind of container (e.g. Periodical, database, or book).) 6150 */ 6151 public CitationCitedArtifactPublicationFormPublishedInComponent setType(CodeableConcept value) { 6152 this.type = value; 6153 return this; 6154 } 6155 6156 /** 6157 * @return {@link #identifier} (Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN.) 6158 */ 6159 public List<Identifier> getIdentifier() { 6160 if (this.identifier == null) 6161 this.identifier = new ArrayList<Identifier>(); 6162 return this.identifier; 6163 } 6164 6165 /** 6166 * @return Returns a reference to <code>this</code> for easy method chaining 6167 */ 6168 public CitationCitedArtifactPublicationFormPublishedInComponent setIdentifier(List<Identifier> theIdentifier) { 6169 this.identifier = theIdentifier; 6170 return this; 6171 } 6172 6173 public boolean hasIdentifier() { 6174 if (this.identifier == null) 6175 return false; 6176 for (Identifier item : this.identifier) 6177 if (!item.isEmpty()) 6178 return true; 6179 return false; 6180 } 6181 6182 public Identifier addIdentifier() { //3 6183 Identifier t = new Identifier(); 6184 if (this.identifier == null) 6185 this.identifier = new ArrayList<Identifier>(); 6186 this.identifier.add(t); 6187 return t; 6188 } 6189 6190 public CitationCitedArtifactPublicationFormPublishedInComponent addIdentifier(Identifier t) { //3 6191 if (t == null) 6192 return this; 6193 if (this.identifier == null) 6194 this.identifier = new ArrayList<Identifier>(); 6195 this.identifier.add(t); 6196 return this; 6197 } 6198 6199 /** 6200 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 6201 */ 6202 public Identifier getIdentifierFirstRep() { 6203 if (getIdentifier().isEmpty()) { 6204 addIdentifier(); 6205 } 6206 return getIdentifier().get(0); 6207 } 6208 6209 /** 6210 * @return {@link #title} (Name of the database or title of the book or journal.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 6211 */ 6212 public StringType getTitleElement() { 6213 if (this.title == null) 6214 if (Configuration.errorOnAutoCreate()) 6215 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormPublishedInComponent.title"); 6216 else if (Configuration.doAutoCreate()) 6217 this.title = new StringType(); // bb 6218 return this.title; 6219 } 6220 6221 public boolean hasTitleElement() { 6222 return this.title != null && !this.title.isEmpty(); 6223 } 6224 6225 public boolean hasTitle() { 6226 return this.title != null && !this.title.isEmpty(); 6227 } 6228 6229 /** 6230 * @param value {@link #title} (Name of the database or title of the book or journal.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 6231 */ 6232 public CitationCitedArtifactPublicationFormPublishedInComponent setTitleElement(StringType value) { 6233 this.title = value; 6234 return this; 6235 } 6236 6237 /** 6238 * @return Name of the database or title of the book or journal. 6239 */ 6240 public String getTitle() { 6241 return this.title == null ? null : this.title.getValue(); 6242 } 6243 6244 /** 6245 * @param value Name of the database or title of the book or journal. 6246 */ 6247 public CitationCitedArtifactPublicationFormPublishedInComponent setTitle(String value) { 6248 if (Utilities.noString(value)) 6249 this.title = null; 6250 else { 6251 if (this.title == null) 6252 this.title = new StringType(); 6253 this.title.setValue(value); 6254 } 6255 return this; 6256 } 6257 6258 /** 6259 * @return {@link #publisher} (Name of the publisher.) 6260 */ 6261 public Reference getPublisher() { 6262 if (this.publisher == null) 6263 if (Configuration.errorOnAutoCreate()) 6264 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormPublishedInComponent.publisher"); 6265 else if (Configuration.doAutoCreate()) 6266 this.publisher = new Reference(); // cc 6267 return this.publisher; 6268 } 6269 6270 public boolean hasPublisher() { 6271 return this.publisher != null && !this.publisher.isEmpty(); 6272 } 6273 6274 /** 6275 * @param value {@link #publisher} (Name of the publisher.) 6276 */ 6277 public CitationCitedArtifactPublicationFormPublishedInComponent setPublisher(Reference value) { 6278 this.publisher = value; 6279 return this; 6280 } 6281 6282 /** 6283 * @return {@link #publisherLocation} (Geographic location of the publisher.). This is the underlying object with id, value and extensions. The accessor "getPublisherLocation" gives direct access to the value 6284 */ 6285 public StringType getPublisherLocationElement() { 6286 if (this.publisherLocation == null) 6287 if (Configuration.errorOnAutoCreate()) 6288 throw new Error("Attempt to auto-create CitationCitedArtifactPublicationFormPublishedInComponent.publisherLocation"); 6289 else if (Configuration.doAutoCreate()) 6290 this.publisherLocation = new StringType(); // bb 6291 return this.publisherLocation; 6292 } 6293 6294 public boolean hasPublisherLocationElement() { 6295 return this.publisherLocation != null && !this.publisherLocation.isEmpty(); 6296 } 6297 6298 public boolean hasPublisherLocation() { 6299 return this.publisherLocation != null && !this.publisherLocation.isEmpty(); 6300 } 6301 6302 /** 6303 * @param value {@link #publisherLocation} (Geographic location of the publisher.). This is the underlying object with id, value and extensions. The accessor "getPublisherLocation" gives direct access to the value 6304 */ 6305 public CitationCitedArtifactPublicationFormPublishedInComponent setPublisherLocationElement(StringType value) { 6306 this.publisherLocation = value; 6307 return this; 6308 } 6309 6310 /** 6311 * @return Geographic location of the publisher. 6312 */ 6313 public String getPublisherLocation() { 6314 return this.publisherLocation == null ? null : this.publisherLocation.getValue(); 6315 } 6316 6317 /** 6318 * @param value Geographic location of the publisher. 6319 */ 6320 public CitationCitedArtifactPublicationFormPublishedInComponent setPublisherLocation(String value) { 6321 if (Utilities.noString(value)) 6322 this.publisherLocation = null; 6323 else { 6324 if (this.publisherLocation == null) 6325 this.publisherLocation = new StringType(); 6326 this.publisherLocation.setValue(value); 6327 } 6328 return this; 6329 } 6330 6331 protected void listChildren(List<Property> children) { 6332 super.listChildren(children); 6333 children.add(new Property("type", "CodeableConcept", "Kind of container (e.g. Periodical, database, or book).", 0, 1, type)); 6334 children.add(new Property("identifier", "Identifier", "Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN.", 0, java.lang.Integer.MAX_VALUE, identifier)); 6335 children.add(new Property("title", "string", "Name of the database or title of the book or journal.", 0, 1, title)); 6336 children.add(new Property("publisher", "Reference(Organization)", "Name of the publisher.", 0, 1, publisher)); 6337 children.add(new Property("publisherLocation", "string", "Geographic location of the publisher.", 0, 1, publisherLocation)); 6338 } 6339 6340 @Override 6341 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 6342 switch (_hash) { 6343 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Kind of container (e.g. Periodical, database, or book).", 0, 1, type); 6344 case -1618432855: /*identifier*/ return new Property("identifier", "Identifier", "Journal identifiers include ISSN, ISO Abbreviation and NLMuniqueID; Book identifiers include ISBN.", 0, java.lang.Integer.MAX_VALUE, identifier); 6345 case 110371416: /*title*/ return new Property("title", "string", "Name of the database or title of the book or journal.", 0, 1, title); 6346 case 1447404028: /*publisher*/ return new Property("publisher", "Reference(Organization)", "Name of the publisher.", 0, 1, publisher); 6347 case -1281627695: /*publisherLocation*/ return new Property("publisherLocation", "string", "Geographic location of the publisher.", 0, 1, publisherLocation); 6348 default: return super.getNamedProperty(_hash, _name, _checkValid); 6349 } 6350 6351 } 6352 6353 @Override 6354 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 6355 switch (hash) { 6356 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 6357 case -1618432855: /*identifier*/ return this.identifier == null ? new Base[0] : this.identifier.toArray(new Base[this.identifier.size()]); // Identifier 6358 case 110371416: /*title*/ return this.title == null ? new Base[0] : new Base[] {this.title}; // StringType 6359 case 1447404028: /*publisher*/ return this.publisher == null ? new Base[0] : new Base[] {this.publisher}; // Reference 6360 case -1281627695: /*publisherLocation*/ return this.publisherLocation == null ? new Base[0] : new Base[] {this.publisherLocation}; // StringType 6361 default: return super.getProperty(hash, name, checkValid); 6362 } 6363 6364 } 6365 6366 @Override 6367 public Base setProperty(int hash, String name, Base value) throws FHIRException { 6368 switch (hash) { 6369 case 3575610: // type 6370 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 6371 return value; 6372 case -1618432855: // identifier 6373 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); // Identifier 6374 return value; 6375 case 110371416: // title 6376 this.title = TypeConvertor.castToString(value); // StringType 6377 return value; 6378 case 1447404028: // publisher 6379 this.publisher = TypeConvertor.castToReference(value); // Reference 6380 return value; 6381 case -1281627695: // publisherLocation 6382 this.publisherLocation = TypeConvertor.castToString(value); // StringType 6383 return value; 6384 default: return super.setProperty(hash, name, value); 6385 } 6386 6387 } 6388 6389 @Override 6390 public Base setProperty(String name, Base value) throws FHIRException { 6391 if (name.equals("type")) { 6392 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 6393 } else if (name.equals("identifier")) { 6394 this.getIdentifier().add(TypeConvertor.castToIdentifier(value)); 6395 } else if (name.equals("title")) { 6396 this.title = TypeConvertor.castToString(value); // StringType 6397 } else if (name.equals("publisher")) { 6398 this.publisher = TypeConvertor.castToReference(value); // Reference 6399 } else if (name.equals("publisherLocation")) { 6400 this.publisherLocation = TypeConvertor.castToString(value); // StringType 6401 } else 6402 return super.setProperty(name, value); 6403 return value; 6404 } 6405 6406 @Override 6407 public Base makeProperty(int hash, String name) throws FHIRException { 6408 switch (hash) { 6409 case 3575610: return getType(); 6410 case -1618432855: return addIdentifier(); 6411 case 110371416: return getTitleElement(); 6412 case 1447404028: return getPublisher(); 6413 case -1281627695: return getPublisherLocationElement(); 6414 default: return super.makeProperty(hash, name); 6415 } 6416 6417 } 6418 6419 @Override 6420 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 6421 switch (hash) { 6422 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 6423 case -1618432855: /*identifier*/ return new String[] {"Identifier"}; 6424 case 110371416: /*title*/ return new String[] {"string"}; 6425 case 1447404028: /*publisher*/ return new String[] {"Reference"}; 6426 case -1281627695: /*publisherLocation*/ return new String[] {"string"}; 6427 default: return super.getTypesForProperty(hash, name); 6428 } 6429 6430 } 6431 6432 @Override 6433 public Base addChild(String name) throws FHIRException { 6434 if (name.equals("type")) { 6435 this.type = new CodeableConcept(); 6436 return this.type; 6437 } 6438 else if (name.equals("identifier")) { 6439 return addIdentifier(); 6440 } 6441 else if (name.equals("title")) { 6442 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publishedIn.title"); 6443 } 6444 else if (name.equals("publisher")) { 6445 this.publisher = new Reference(); 6446 return this.publisher; 6447 } 6448 else if (name.equals("publisherLocation")) { 6449 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.publicationForm.publishedIn.publisherLocation"); 6450 } 6451 else 6452 return super.addChild(name); 6453 } 6454 6455 public CitationCitedArtifactPublicationFormPublishedInComponent copy() { 6456 CitationCitedArtifactPublicationFormPublishedInComponent dst = new CitationCitedArtifactPublicationFormPublishedInComponent(); 6457 copyValues(dst); 6458 return dst; 6459 } 6460 6461 public void copyValues(CitationCitedArtifactPublicationFormPublishedInComponent dst) { 6462 super.copyValues(dst); 6463 dst.type = type == null ? null : type.copy(); 6464 if (identifier != null) { 6465 dst.identifier = new ArrayList<Identifier>(); 6466 for (Identifier i : identifier) 6467 dst.identifier.add(i.copy()); 6468 }; 6469 dst.title = title == null ? null : title.copy(); 6470 dst.publisher = publisher == null ? null : publisher.copy(); 6471 dst.publisherLocation = publisherLocation == null ? null : publisherLocation.copy(); 6472 } 6473 6474 @Override 6475 public boolean equalsDeep(Base other_) { 6476 if (!super.equalsDeep(other_)) 6477 return false; 6478 if (!(other_ instanceof CitationCitedArtifactPublicationFormPublishedInComponent)) 6479 return false; 6480 CitationCitedArtifactPublicationFormPublishedInComponent o = (CitationCitedArtifactPublicationFormPublishedInComponent) other_; 6481 return compareDeep(type, o.type, true) && compareDeep(identifier, o.identifier, true) && compareDeep(title, o.title, true) 6482 && compareDeep(publisher, o.publisher, true) && compareDeep(publisherLocation, o.publisherLocation, true) 6483 ; 6484 } 6485 6486 @Override 6487 public boolean equalsShallow(Base other_) { 6488 if (!super.equalsShallow(other_)) 6489 return false; 6490 if (!(other_ instanceof CitationCitedArtifactPublicationFormPublishedInComponent)) 6491 return false; 6492 CitationCitedArtifactPublicationFormPublishedInComponent o = (CitationCitedArtifactPublicationFormPublishedInComponent) other_; 6493 return compareValues(title, o.title, true) && compareValues(publisherLocation, o.publisherLocation, true) 6494 ; 6495 } 6496 6497 public boolean isEmpty() { 6498 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, identifier, title 6499 , publisher, publisherLocation); 6500 } 6501 6502 public String fhirType() { 6503 return "Citation.citedArtifact.publicationForm.publishedIn"; 6504 6505 } 6506 6507 } 6508 6509 @Block() 6510 public static class CitationCitedArtifactWebLocationComponent extends BackboneElement implements IBaseBackboneElement { 6511 /** 6512 * Code the reason for different URLs, e.g. abstract and full-text. 6513 */ 6514 @Child(name = "classifier", type = {CodeableConcept.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 6515 @Description(shortDefinition="Code the reason for different URLs, e.g. abstract and full-text", formalDefinition="Code the reason for different URLs, e.g. abstract and full-text." ) 6516 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/artifact-url-classifier") 6517 protected List<CodeableConcept> classifier; 6518 6519 /** 6520 * The specific URL. 6521 */ 6522 @Child(name = "url", type = {UriType.class}, order=2, min=0, max=1, modifier=false, summary=false) 6523 @Description(shortDefinition="The specific URL", formalDefinition="The specific URL." ) 6524 protected UriType url; 6525 6526 private static final long serialVersionUID = -1300703403L; 6527 6528 /** 6529 * Constructor 6530 */ 6531 public CitationCitedArtifactWebLocationComponent() { 6532 super(); 6533 } 6534 6535 /** 6536 * @return {@link #classifier} (Code the reason for different URLs, e.g. abstract and full-text.) 6537 */ 6538 public List<CodeableConcept> getClassifier() { 6539 if (this.classifier == null) 6540 this.classifier = new ArrayList<CodeableConcept>(); 6541 return this.classifier; 6542 } 6543 6544 /** 6545 * @return Returns a reference to <code>this</code> for easy method chaining 6546 */ 6547 public CitationCitedArtifactWebLocationComponent setClassifier(List<CodeableConcept> theClassifier) { 6548 this.classifier = theClassifier; 6549 return this; 6550 } 6551 6552 public boolean hasClassifier() { 6553 if (this.classifier == null) 6554 return false; 6555 for (CodeableConcept item : this.classifier) 6556 if (!item.isEmpty()) 6557 return true; 6558 return false; 6559 } 6560 6561 public CodeableConcept addClassifier() { //3 6562 CodeableConcept t = new CodeableConcept(); 6563 if (this.classifier == null) 6564 this.classifier = new ArrayList<CodeableConcept>(); 6565 this.classifier.add(t); 6566 return t; 6567 } 6568 6569 public CitationCitedArtifactWebLocationComponent addClassifier(CodeableConcept t) { //3 6570 if (t == null) 6571 return this; 6572 if (this.classifier == null) 6573 this.classifier = new ArrayList<CodeableConcept>(); 6574 this.classifier.add(t); 6575 return this; 6576 } 6577 6578 /** 6579 * @return The first repetition of repeating field {@link #classifier}, creating it if it does not already exist {3} 6580 */ 6581 public CodeableConcept getClassifierFirstRep() { 6582 if (getClassifier().isEmpty()) { 6583 addClassifier(); 6584 } 6585 return getClassifier().get(0); 6586 } 6587 6588 /** 6589 * @return {@link #url} (The specific URL.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 6590 */ 6591 public UriType getUrlElement() { 6592 if (this.url == null) 6593 if (Configuration.errorOnAutoCreate()) 6594 throw new Error("Attempt to auto-create CitationCitedArtifactWebLocationComponent.url"); 6595 else if (Configuration.doAutoCreate()) 6596 this.url = new UriType(); // bb 6597 return this.url; 6598 } 6599 6600 public boolean hasUrlElement() { 6601 return this.url != null && !this.url.isEmpty(); 6602 } 6603 6604 public boolean hasUrl() { 6605 return this.url != null && !this.url.isEmpty(); 6606 } 6607 6608 /** 6609 * @param value {@link #url} (The specific URL.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 6610 */ 6611 public CitationCitedArtifactWebLocationComponent setUrlElement(UriType value) { 6612 this.url = value; 6613 return this; 6614 } 6615 6616 /** 6617 * @return The specific URL. 6618 */ 6619 public String getUrl() { 6620 return this.url == null ? null : this.url.getValue(); 6621 } 6622 6623 /** 6624 * @param value The specific URL. 6625 */ 6626 public CitationCitedArtifactWebLocationComponent setUrl(String value) { 6627 if (Utilities.noString(value)) 6628 this.url = null; 6629 else { 6630 if (this.url == null) 6631 this.url = new UriType(); 6632 this.url.setValue(value); 6633 } 6634 return this; 6635 } 6636 6637 protected void listChildren(List<Property> children) { 6638 super.listChildren(children); 6639 children.add(new Property("classifier", "CodeableConcept", "Code the reason for different URLs, e.g. abstract and full-text.", 0, java.lang.Integer.MAX_VALUE, classifier)); 6640 children.add(new Property("url", "uri", "The specific URL.", 0, 1, url)); 6641 } 6642 6643 @Override 6644 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 6645 switch (_hash) { 6646 case -281470431: /*classifier*/ return new Property("classifier", "CodeableConcept", "Code the reason for different URLs, e.g. abstract and full-text.", 0, java.lang.Integer.MAX_VALUE, classifier); 6647 case 116079: /*url*/ return new Property("url", "uri", "The specific URL.", 0, 1, url); 6648 default: return super.getNamedProperty(_hash, _name, _checkValid); 6649 } 6650 6651 } 6652 6653 @Override 6654 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 6655 switch (hash) { 6656 case -281470431: /*classifier*/ return this.classifier == null ? new Base[0] : this.classifier.toArray(new Base[this.classifier.size()]); // CodeableConcept 6657 case 116079: /*url*/ return this.url == null ? new Base[0] : new Base[] {this.url}; // UriType 6658 default: return super.getProperty(hash, name, checkValid); 6659 } 6660 6661 } 6662 6663 @Override 6664 public Base setProperty(int hash, String name, Base value) throws FHIRException { 6665 switch (hash) { 6666 case -281470431: // classifier 6667 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 6668 return value; 6669 case 116079: // url 6670 this.url = TypeConvertor.castToUri(value); // UriType 6671 return value; 6672 default: return super.setProperty(hash, name, value); 6673 } 6674 6675 } 6676 6677 @Override 6678 public Base setProperty(String name, Base value) throws FHIRException { 6679 if (name.equals("classifier")) { 6680 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); 6681 } else if (name.equals("url")) { 6682 this.url = TypeConvertor.castToUri(value); // UriType 6683 } else 6684 return super.setProperty(name, value); 6685 return value; 6686 } 6687 6688 @Override 6689 public Base makeProperty(int hash, String name) throws FHIRException { 6690 switch (hash) { 6691 case -281470431: return addClassifier(); 6692 case 116079: return getUrlElement(); 6693 default: return super.makeProperty(hash, name); 6694 } 6695 6696 } 6697 6698 @Override 6699 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 6700 switch (hash) { 6701 case -281470431: /*classifier*/ return new String[] {"CodeableConcept"}; 6702 case 116079: /*url*/ return new String[] {"uri"}; 6703 default: return super.getTypesForProperty(hash, name); 6704 } 6705 6706 } 6707 6708 @Override 6709 public Base addChild(String name) throws FHIRException { 6710 if (name.equals("classifier")) { 6711 return addClassifier(); 6712 } 6713 else if (name.equals("url")) { 6714 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.webLocation.url"); 6715 } 6716 else 6717 return super.addChild(name); 6718 } 6719 6720 public CitationCitedArtifactWebLocationComponent copy() { 6721 CitationCitedArtifactWebLocationComponent dst = new CitationCitedArtifactWebLocationComponent(); 6722 copyValues(dst); 6723 return dst; 6724 } 6725 6726 public void copyValues(CitationCitedArtifactWebLocationComponent dst) { 6727 super.copyValues(dst); 6728 if (classifier != null) { 6729 dst.classifier = new ArrayList<CodeableConcept>(); 6730 for (CodeableConcept i : classifier) 6731 dst.classifier.add(i.copy()); 6732 }; 6733 dst.url = url == null ? null : url.copy(); 6734 } 6735 6736 @Override 6737 public boolean equalsDeep(Base other_) { 6738 if (!super.equalsDeep(other_)) 6739 return false; 6740 if (!(other_ instanceof CitationCitedArtifactWebLocationComponent)) 6741 return false; 6742 CitationCitedArtifactWebLocationComponent o = (CitationCitedArtifactWebLocationComponent) other_; 6743 return compareDeep(classifier, o.classifier, true) && compareDeep(url, o.url, true); 6744 } 6745 6746 @Override 6747 public boolean equalsShallow(Base other_) { 6748 if (!super.equalsShallow(other_)) 6749 return false; 6750 if (!(other_ instanceof CitationCitedArtifactWebLocationComponent)) 6751 return false; 6752 CitationCitedArtifactWebLocationComponent o = (CitationCitedArtifactWebLocationComponent) other_; 6753 return compareValues(url, o.url, true); 6754 } 6755 6756 public boolean isEmpty() { 6757 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(classifier, url); 6758 } 6759 6760 public String fhirType() { 6761 return "Citation.citedArtifact.webLocation"; 6762 6763 } 6764 6765 } 6766 6767 @Block() 6768 public static class CitationCitedArtifactClassificationComponent extends BackboneElement implements IBaseBackboneElement { 6769 /** 6770 * The kind of classifier (e.g. publication type, keyword). 6771 */ 6772 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 6773 @Description(shortDefinition="The kind of classifier (e.g. publication type, keyword)", formalDefinition="The kind of classifier (e.g. publication type, keyword)." ) 6774 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/cited-artifact-classification-type") 6775 protected CodeableConcept type; 6776 6777 /** 6778 * The specific classification value. 6779 */ 6780 @Child(name = "classifier", type = {CodeableConcept.class}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 6781 @Description(shortDefinition="The specific classification value", formalDefinition="The specific classification value." ) 6782 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-artifact-classifier") 6783 protected List<CodeableConcept> classifier; 6784 6785 /** 6786 * Complex or externally created classification. 6787 */ 6788 @Child(name = "artifactAssessment", type = {ArtifactAssessment.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 6789 @Description(shortDefinition="Complex or externally created classification\n", formalDefinition="Complex or externally created classification." ) 6790 protected List<Reference> artifactAssessment; 6791 6792 private static final long serialVersionUID = 394554928L; 6793 6794 /** 6795 * Constructor 6796 */ 6797 public CitationCitedArtifactClassificationComponent() { 6798 super(); 6799 } 6800 6801 /** 6802 * @return {@link #type} (The kind of classifier (e.g. publication type, keyword).) 6803 */ 6804 public CodeableConcept getType() { 6805 if (this.type == null) 6806 if (Configuration.errorOnAutoCreate()) 6807 throw new Error("Attempt to auto-create CitationCitedArtifactClassificationComponent.type"); 6808 else if (Configuration.doAutoCreate()) 6809 this.type = new CodeableConcept(); // cc 6810 return this.type; 6811 } 6812 6813 public boolean hasType() { 6814 return this.type != null && !this.type.isEmpty(); 6815 } 6816 6817 /** 6818 * @param value {@link #type} (The kind of classifier (e.g. publication type, keyword).) 6819 */ 6820 public CitationCitedArtifactClassificationComponent setType(CodeableConcept value) { 6821 this.type = value; 6822 return this; 6823 } 6824 6825 /** 6826 * @return {@link #classifier} (The specific classification value.) 6827 */ 6828 public List<CodeableConcept> getClassifier() { 6829 if (this.classifier == null) 6830 this.classifier = new ArrayList<CodeableConcept>(); 6831 return this.classifier; 6832 } 6833 6834 /** 6835 * @return Returns a reference to <code>this</code> for easy method chaining 6836 */ 6837 public CitationCitedArtifactClassificationComponent setClassifier(List<CodeableConcept> theClassifier) { 6838 this.classifier = theClassifier; 6839 return this; 6840 } 6841 6842 public boolean hasClassifier() { 6843 if (this.classifier == null) 6844 return false; 6845 for (CodeableConcept item : this.classifier) 6846 if (!item.isEmpty()) 6847 return true; 6848 return false; 6849 } 6850 6851 public CodeableConcept addClassifier() { //3 6852 CodeableConcept t = new CodeableConcept(); 6853 if (this.classifier == null) 6854 this.classifier = new ArrayList<CodeableConcept>(); 6855 this.classifier.add(t); 6856 return t; 6857 } 6858 6859 public CitationCitedArtifactClassificationComponent addClassifier(CodeableConcept t) { //3 6860 if (t == null) 6861 return this; 6862 if (this.classifier == null) 6863 this.classifier = new ArrayList<CodeableConcept>(); 6864 this.classifier.add(t); 6865 return this; 6866 } 6867 6868 /** 6869 * @return The first repetition of repeating field {@link #classifier}, creating it if it does not already exist {3} 6870 */ 6871 public CodeableConcept getClassifierFirstRep() { 6872 if (getClassifier().isEmpty()) { 6873 addClassifier(); 6874 } 6875 return getClassifier().get(0); 6876 } 6877 6878 /** 6879 * @return {@link #artifactAssessment} (Complex or externally created classification.) 6880 */ 6881 public List<Reference> getArtifactAssessment() { 6882 if (this.artifactAssessment == null) 6883 this.artifactAssessment = new ArrayList<Reference>(); 6884 return this.artifactAssessment; 6885 } 6886 6887 /** 6888 * @return Returns a reference to <code>this</code> for easy method chaining 6889 */ 6890 public CitationCitedArtifactClassificationComponent setArtifactAssessment(List<Reference> theArtifactAssessment) { 6891 this.artifactAssessment = theArtifactAssessment; 6892 return this; 6893 } 6894 6895 public boolean hasArtifactAssessment() { 6896 if (this.artifactAssessment == null) 6897 return false; 6898 for (Reference item : this.artifactAssessment) 6899 if (!item.isEmpty()) 6900 return true; 6901 return false; 6902 } 6903 6904 public Reference addArtifactAssessment() { //3 6905 Reference t = new Reference(); 6906 if (this.artifactAssessment == null) 6907 this.artifactAssessment = new ArrayList<Reference>(); 6908 this.artifactAssessment.add(t); 6909 return t; 6910 } 6911 6912 public CitationCitedArtifactClassificationComponent addArtifactAssessment(Reference t) { //3 6913 if (t == null) 6914 return this; 6915 if (this.artifactAssessment == null) 6916 this.artifactAssessment = new ArrayList<Reference>(); 6917 this.artifactAssessment.add(t); 6918 return this; 6919 } 6920 6921 /** 6922 * @return The first repetition of repeating field {@link #artifactAssessment}, creating it if it does not already exist {3} 6923 */ 6924 public Reference getArtifactAssessmentFirstRep() { 6925 if (getArtifactAssessment().isEmpty()) { 6926 addArtifactAssessment(); 6927 } 6928 return getArtifactAssessment().get(0); 6929 } 6930 6931 protected void listChildren(List<Property> children) { 6932 super.listChildren(children); 6933 children.add(new Property("type", "CodeableConcept", "The kind of classifier (e.g. publication type, keyword).", 0, 1, type)); 6934 children.add(new Property("classifier", "CodeableConcept", "The specific classification value.", 0, java.lang.Integer.MAX_VALUE, classifier)); 6935 children.add(new Property("artifactAssessment", "Reference(ArtifactAssessment)", "Complex or externally created classification.", 0, java.lang.Integer.MAX_VALUE, artifactAssessment)); 6936 } 6937 6938 @Override 6939 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 6940 switch (_hash) { 6941 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The kind of classifier (e.g. publication type, keyword).", 0, 1, type); 6942 case -281470431: /*classifier*/ return new Property("classifier", "CodeableConcept", "The specific classification value.", 0, java.lang.Integer.MAX_VALUE, classifier); 6943 case 1014987316: /*artifactAssessment*/ return new Property("artifactAssessment", "Reference(ArtifactAssessment)", "Complex or externally created classification.", 0, java.lang.Integer.MAX_VALUE, artifactAssessment); 6944 default: return super.getNamedProperty(_hash, _name, _checkValid); 6945 } 6946 6947 } 6948 6949 @Override 6950 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 6951 switch (hash) { 6952 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 6953 case -281470431: /*classifier*/ return this.classifier == null ? new Base[0] : this.classifier.toArray(new Base[this.classifier.size()]); // CodeableConcept 6954 case 1014987316: /*artifactAssessment*/ return this.artifactAssessment == null ? new Base[0] : this.artifactAssessment.toArray(new Base[this.artifactAssessment.size()]); // Reference 6955 default: return super.getProperty(hash, name, checkValid); 6956 } 6957 6958 } 6959 6960 @Override 6961 public Base setProperty(int hash, String name, Base value) throws FHIRException { 6962 switch (hash) { 6963 case 3575610: // type 6964 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 6965 return value; 6966 case -281470431: // classifier 6967 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 6968 return value; 6969 case 1014987316: // artifactAssessment 6970 this.getArtifactAssessment().add(TypeConvertor.castToReference(value)); // Reference 6971 return value; 6972 default: return super.setProperty(hash, name, value); 6973 } 6974 6975 } 6976 6977 @Override 6978 public Base setProperty(String name, Base value) throws FHIRException { 6979 if (name.equals("type")) { 6980 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 6981 } else if (name.equals("classifier")) { 6982 this.getClassifier().add(TypeConvertor.castToCodeableConcept(value)); 6983 } else if (name.equals("artifactAssessment")) { 6984 this.getArtifactAssessment().add(TypeConvertor.castToReference(value)); 6985 } else 6986 return super.setProperty(name, value); 6987 return value; 6988 } 6989 6990 @Override 6991 public Base makeProperty(int hash, String name) throws FHIRException { 6992 switch (hash) { 6993 case 3575610: return getType(); 6994 case -281470431: return addClassifier(); 6995 case 1014987316: return addArtifactAssessment(); 6996 default: return super.makeProperty(hash, name); 6997 } 6998 6999 } 7000 7001 @Override 7002 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 7003 switch (hash) { 7004 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 7005 case -281470431: /*classifier*/ return new String[] {"CodeableConcept"}; 7006 case 1014987316: /*artifactAssessment*/ return new String[] {"Reference"}; 7007 default: return super.getTypesForProperty(hash, name); 7008 } 7009 7010 } 7011 7012 @Override 7013 public Base addChild(String name) throws FHIRException { 7014 if (name.equals("type")) { 7015 this.type = new CodeableConcept(); 7016 return this.type; 7017 } 7018 else if (name.equals("classifier")) { 7019 return addClassifier(); 7020 } 7021 else if (name.equals("artifactAssessment")) { 7022 return addArtifactAssessment(); 7023 } 7024 else 7025 return super.addChild(name); 7026 } 7027 7028 public CitationCitedArtifactClassificationComponent copy() { 7029 CitationCitedArtifactClassificationComponent dst = new CitationCitedArtifactClassificationComponent(); 7030 copyValues(dst); 7031 return dst; 7032 } 7033 7034 public void copyValues(CitationCitedArtifactClassificationComponent dst) { 7035 super.copyValues(dst); 7036 dst.type = type == null ? null : type.copy(); 7037 if (classifier != null) { 7038 dst.classifier = new ArrayList<CodeableConcept>(); 7039 for (CodeableConcept i : classifier) 7040 dst.classifier.add(i.copy()); 7041 }; 7042 if (artifactAssessment != null) { 7043 dst.artifactAssessment = new ArrayList<Reference>(); 7044 for (Reference i : artifactAssessment) 7045 dst.artifactAssessment.add(i.copy()); 7046 }; 7047 } 7048 7049 @Override 7050 public boolean equalsDeep(Base other_) { 7051 if (!super.equalsDeep(other_)) 7052 return false; 7053 if (!(other_ instanceof CitationCitedArtifactClassificationComponent)) 7054 return false; 7055 CitationCitedArtifactClassificationComponent o = (CitationCitedArtifactClassificationComponent) other_; 7056 return compareDeep(type, o.type, true) && compareDeep(classifier, o.classifier, true) && compareDeep(artifactAssessment, o.artifactAssessment, true) 7057 ; 7058 } 7059 7060 @Override 7061 public boolean equalsShallow(Base other_) { 7062 if (!super.equalsShallow(other_)) 7063 return false; 7064 if (!(other_ instanceof CitationCitedArtifactClassificationComponent)) 7065 return false; 7066 CitationCitedArtifactClassificationComponent o = (CitationCitedArtifactClassificationComponent) other_; 7067 return true; 7068 } 7069 7070 public boolean isEmpty() { 7071 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, classifier, artifactAssessment 7072 ); 7073 } 7074 7075 public String fhirType() { 7076 return "Citation.citedArtifact.classification"; 7077 7078 } 7079 7080 } 7081 7082 @Block() 7083 public static class CitationCitedArtifactContributorshipComponent extends BackboneElement implements IBaseBackboneElement { 7084 /** 7085 * Indicates if the list includes all authors and/or contributors. 7086 */ 7087 @Child(name = "complete", type = {BooleanType.class}, order=1, min=0, max=1, modifier=false, summary=false) 7088 @Description(shortDefinition="Indicates if the list includes all authors and/or contributors", formalDefinition="Indicates if the list includes all authors and/or contributors." ) 7089 protected BooleanType complete; 7090 7091 /** 7092 * An individual entity named in the author list or contributor list. 7093 */ 7094 @Child(name = "entry", type = {}, order=2, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 7095 @Description(shortDefinition="An individual entity named in the list", formalDefinition="An individual entity named in the author list or contributor list." ) 7096 protected List<CitationCitedArtifactContributorshipEntryComponent> entry; 7097 7098 /** 7099 * Used to record a display of the author/contributor list without separate coding for each list member. 7100 */ 7101 @Child(name = "summary", type = {}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 7102 @Description(shortDefinition="Used to record a display of the author/contributor list without separate coding for each list member", formalDefinition="Used to record a display of the author/contributor list without separate coding for each list member." ) 7103 protected List<ContributorshipSummaryComponent> summary; 7104 7105 private static final long serialVersionUID = 662810405L; 7106 7107 /** 7108 * Constructor 7109 */ 7110 public CitationCitedArtifactContributorshipComponent() { 7111 super(); 7112 } 7113 7114 /** 7115 * @return {@link #complete} (Indicates if the list includes all authors and/or contributors.). This is the underlying object with id, value and extensions. The accessor "getComplete" gives direct access to the value 7116 */ 7117 public BooleanType getCompleteElement() { 7118 if (this.complete == null) 7119 if (Configuration.errorOnAutoCreate()) 7120 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipComponent.complete"); 7121 else if (Configuration.doAutoCreate()) 7122 this.complete = new BooleanType(); // bb 7123 return this.complete; 7124 } 7125 7126 public boolean hasCompleteElement() { 7127 return this.complete != null && !this.complete.isEmpty(); 7128 } 7129 7130 public boolean hasComplete() { 7131 return this.complete != null && !this.complete.isEmpty(); 7132 } 7133 7134 /** 7135 * @param value {@link #complete} (Indicates if the list includes all authors and/or contributors.). This is the underlying object with id, value and extensions. The accessor "getComplete" gives direct access to the value 7136 */ 7137 public CitationCitedArtifactContributorshipComponent setCompleteElement(BooleanType value) { 7138 this.complete = value; 7139 return this; 7140 } 7141 7142 /** 7143 * @return Indicates if the list includes all authors and/or contributors. 7144 */ 7145 public boolean getComplete() { 7146 return this.complete == null || this.complete.isEmpty() ? false : this.complete.getValue(); 7147 } 7148 7149 /** 7150 * @param value Indicates if the list includes all authors and/or contributors. 7151 */ 7152 public CitationCitedArtifactContributorshipComponent setComplete(boolean value) { 7153 if (this.complete == null) 7154 this.complete = new BooleanType(); 7155 this.complete.setValue(value); 7156 return this; 7157 } 7158 7159 /** 7160 * @return {@link #entry} (An individual entity named in the author list or contributor list.) 7161 */ 7162 public List<CitationCitedArtifactContributorshipEntryComponent> getEntry() { 7163 if (this.entry == null) 7164 this.entry = new ArrayList<CitationCitedArtifactContributorshipEntryComponent>(); 7165 return this.entry; 7166 } 7167 7168 /** 7169 * @return Returns a reference to <code>this</code> for easy method chaining 7170 */ 7171 public CitationCitedArtifactContributorshipComponent setEntry(List<CitationCitedArtifactContributorshipEntryComponent> theEntry) { 7172 this.entry = theEntry; 7173 return this; 7174 } 7175 7176 public boolean hasEntry() { 7177 if (this.entry == null) 7178 return false; 7179 for (CitationCitedArtifactContributorshipEntryComponent item : this.entry) 7180 if (!item.isEmpty()) 7181 return true; 7182 return false; 7183 } 7184 7185 public CitationCitedArtifactContributorshipEntryComponent addEntry() { //3 7186 CitationCitedArtifactContributorshipEntryComponent t = new CitationCitedArtifactContributorshipEntryComponent(); 7187 if (this.entry == null) 7188 this.entry = new ArrayList<CitationCitedArtifactContributorshipEntryComponent>(); 7189 this.entry.add(t); 7190 return t; 7191 } 7192 7193 public CitationCitedArtifactContributorshipComponent addEntry(CitationCitedArtifactContributorshipEntryComponent t) { //3 7194 if (t == null) 7195 return this; 7196 if (this.entry == null) 7197 this.entry = new ArrayList<CitationCitedArtifactContributorshipEntryComponent>(); 7198 this.entry.add(t); 7199 return this; 7200 } 7201 7202 /** 7203 * @return The first repetition of repeating field {@link #entry}, creating it if it does not already exist {3} 7204 */ 7205 public CitationCitedArtifactContributorshipEntryComponent getEntryFirstRep() { 7206 if (getEntry().isEmpty()) { 7207 addEntry(); 7208 } 7209 return getEntry().get(0); 7210 } 7211 7212 /** 7213 * @return {@link #summary} (Used to record a display of the author/contributor list without separate coding for each list member.) 7214 */ 7215 public List<ContributorshipSummaryComponent> getSummary() { 7216 if (this.summary == null) 7217 this.summary = new ArrayList<ContributorshipSummaryComponent>(); 7218 return this.summary; 7219 } 7220 7221 /** 7222 * @return Returns a reference to <code>this</code> for easy method chaining 7223 */ 7224 public CitationCitedArtifactContributorshipComponent setSummary(List<ContributorshipSummaryComponent> theSummary) { 7225 this.summary = theSummary; 7226 return this; 7227 } 7228 7229 public boolean hasSummary() { 7230 if (this.summary == null) 7231 return false; 7232 for (ContributorshipSummaryComponent item : this.summary) 7233 if (!item.isEmpty()) 7234 return true; 7235 return false; 7236 } 7237 7238 public ContributorshipSummaryComponent addSummary() { //3 7239 ContributorshipSummaryComponent t = new ContributorshipSummaryComponent(); 7240 if (this.summary == null) 7241 this.summary = new ArrayList<ContributorshipSummaryComponent>(); 7242 this.summary.add(t); 7243 return t; 7244 } 7245 7246 public CitationCitedArtifactContributorshipComponent addSummary(ContributorshipSummaryComponent t) { //3 7247 if (t == null) 7248 return this; 7249 if (this.summary == null) 7250 this.summary = new ArrayList<ContributorshipSummaryComponent>(); 7251 this.summary.add(t); 7252 return this; 7253 } 7254 7255 /** 7256 * @return The first repetition of repeating field {@link #summary}, creating it if it does not already exist {3} 7257 */ 7258 public ContributorshipSummaryComponent getSummaryFirstRep() { 7259 if (getSummary().isEmpty()) { 7260 addSummary(); 7261 } 7262 return getSummary().get(0); 7263 } 7264 7265 protected void listChildren(List<Property> children) { 7266 super.listChildren(children); 7267 children.add(new Property("complete", "boolean", "Indicates if the list includes all authors and/or contributors.", 0, 1, complete)); 7268 children.add(new Property("entry", "", "An individual entity named in the author list or contributor list.", 0, java.lang.Integer.MAX_VALUE, entry)); 7269 children.add(new Property("summary", "", "Used to record a display of the author/contributor list without separate coding for each list member.", 0, java.lang.Integer.MAX_VALUE, summary)); 7270 } 7271 7272 @Override 7273 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 7274 switch (_hash) { 7275 case -599445191: /*complete*/ return new Property("complete", "boolean", "Indicates if the list includes all authors and/or contributors.", 0, 1, complete); 7276 case 96667762: /*entry*/ return new Property("entry", "", "An individual entity named in the author list or contributor list.", 0, java.lang.Integer.MAX_VALUE, entry); 7277 case -1857640538: /*summary*/ return new Property("summary", "", "Used to record a display of the author/contributor list without separate coding for each list member.", 0, java.lang.Integer.MAX_VALUE, summary); 7278 default: return super.getNamedProperty(_hash, _name, _checkValid); 7279 } 7280 7281 } 7282 7283 @Override 7284 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 7285 switch (hash) { 7286 case -599445191: /*complete*/ return this.complete == null ? new Base[0] : new Base[] {this.complete}; // BooleanType 7287 case 96667762: /*entry*/ return this.entry == null ? new Base[0] : this.entry.toArray(new Base[this.entry.size()]); // CitationCitedArtifactContributorshipEntryComponent 7288 case -1857640538: /*summary*/ return this.summary == null ? new Base[0] : this.summary.toArray(new Base[this.summary.size()]); // ContributorshipSummaryComponent 7289 default: return super.getProperty(hash, name, checkValid); 7290 } 7291 7292 } 7293 7294 @Override 7295 public Base setProperty(int hash, String name, Base value) throws FHIRException { 7296 switch (hash) { 7297 case -599445191: // complete 7298 this.complete = TypeConvertor.castToBoolean(value); // BooleanType 7299 return value; 7300 case 96667762: // entry 7301 this.getEntry().add((CitationCitedArtifactContributorshipEntryComponent) value); // CitationCitedArtifactContributorshipEntryComponent 7302 return value; 7303 case -1857640538: // summary 7304 this.getSummary().add((ContributorshipSummaryComponent) value); // ContributorshipSummaryComponent 7305 return value; 7306 default: return super.setProperty(hash, name, value); 7307 } 7308 7309 } 7310 7311 @Override 7312 public Base setProperty(String name, Base value) throws FHIRException { 7313 if (name.equals("complete")) { 7314 this.complete = TypeConvertor.castToBoolean(value); // BooleanType 7315 } else if (name.equals("entry")) { 7316 this.getEntry().add((CitationCitedArtifactContributorshipEntryComponent) value); 7317 } else if (name.equals("summary")) { 7318 this.getSummary().add((ContributorshipSummaryComponent) value); 7319 } else 7320 return super.setProperty(name, value); 7321 return value; 7322 } 7323 7324 @Override 7325 public Base makeProperty(int hash, String name) throws FHIRException { 7326 switch (hash) { 7327 case -599445191: return getCompleteElement(); 7328 case 96667762: return addEntry(); 7329 case -1857640538: return addSummary(); 7330 default: return super.makeProperty(hash, name); 7331 } 7332 7333 } 7334 7335 @Override 7336 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 7337 switch (hash) { 7338 case -599445191: /*complete*/ return new String[] {"boolean"}; 7339 case 96667762: /*entry*/ return new String[] {}; 7340 case -1857640538: /*summary*/ return new String[] {}; 7341 default: return super.getTypesForProperty(hash, name); 7342 } 7343 7344 } 7345 7346 @Override 7347 public Base addChild(String name) throws FHIRException { 7348 if (name.equals("complete")) { 7349 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.complete"); 7350 } 7351 else if (name.equals("entry")) { 7352 return addEntry(); 7353 } 7354 else if (name.equals("summary")) { 7355 return addSummary(); 7356 } 7357 else 7358 return super.addChild(name); 7359 } 7360 7361 public CitationCitedArtifactContributorshipComponent copy() { 7362 CitationCitedArtifactContributorshipComponent dst = new CitationCitedArtifactContributorshipComponent(); 7363 copyValues(dst); 7364 return dst; 7365 } 7366 7367 public void copyValues(CitationCitedArtifactContributorshipComponent dst) { 7368 super.copyValues(dst); 7369 dst.complete = complete == null ? null : complete.copy(); 7370 if (entry != null) { 7371 dst.entry = new ArrayList<CitationCitedArtifactContributorshipEntryComponent>(); 7372 for (CitationCitedArtifactContributorshipEntryComponent i : entry) 7373 dst.entry.add(i.copy()); 7374 }; 7375 if (summary != null) { 7376 dst.summary = new ArrayList<ContributorshipSummaryComponent>(); 7377 for (ContributorshipSummaryComponent i : summary) 7378 dst.summary.add(i.copy()); 7379 }; 7380 } 7381 7382 @Override 7383 public boolean equalsDeep(Base other_) { 7384 if (!super.equalsDeep(other_)) 7385 return false; 7386 if (!(other_ instanceof CitationCitedArtifactContributorshipComponent)) 7387 return false; 7388 CitationCitedArtifactContributorshipComponent o = (CitationCitedArtifactContributorshipComponent) other_; 7389 return compareDeep(complete, o.complete, true) && compareDeep(entry, o.entry, true) && compareDeep(summary, o.summary, true) 7390 ; 7391 } 7392 7393 @Override 7394 public boolean equalsShallow(Base other_) { 7395 if (!super.equalsShallow(other_)) 7396 return false; 7397 if (!(other_ instanceof CitationCitedArtifactContributorshipComponent)) 7398 return false; 7399 CitationCitedArtifactContributorshipComponent o = (CitationCitedArtifactContributorshipComponent) other_; 7400 return compareValues(complete, o.complete, true); 7401 } 7402 7403 public boolean isEmpty() { 7404 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(complete, entry, summary 7405 ); 7406 } 7407 7408 public String fhirType() { 7409 return "Citation.citedArtifact.contributorship"; 7410 7411 } 7412 7413 } 7414 7415 @Block() 7416 public static class CitationCitedArtifactContributorshipEntryComponent extends BackboneElement implements IBaseBackboneElement { 7417 /** 7418 * The identity of the individual entity. 7419 */ 7420 @Child(name = "contributor", type = {Practitioner.class, Organization.class}, order=1, min=1, max=1, modifier=false, summary=false) 7421 @Description(shortDefinition="The identity of the individual entity", formalDefinition="The identity of the individual entity." ) 7422 protected Reference contributor; 7423 7424 /** 7425 * Initials for forename. 7426 */ 7427 @Child(name = "forenameInitials", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=false) 7428 @Description(shortDefinition="Initials for forename", formalDefinition="Initials for forename." ) 7429 protected StringType forenameInitials; 7430 7431 /** 7432 * Organization affiliated with the entity. 7433 */ 7434 @Child(name = "affiliation", type = {Organization.class, PractitionerRole.class}, order=3, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 7435 @Description(shortDefinition="Organizational affiliation", formalDefinition="Organization affiliated with the entity." ) 7436 protected List<Reference> affiliation; 7437 7438 /** 7439 * This element identifies the specific nature of an individual?s contribution with respect to the cited work. 7440 */ 7441 @Child(name = "contributionType", type = {CodeableConcept.class}, order=4, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 7442 @Description(shortDefinition="The specific contribution", formalDefinition="This element identifies the specific nature of an individual?s contribution with respect to the cited work." ) 7443 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/artifact-contribution-type") 7444 protected List<CodeableConcept> contributionType; 7445 7446 /** 7447 * The role of the contributor (e.g. author, editor, reviewer). 7448 */ 7449 @Child(name = "role", type = {CodeableConcept.class}, order=5, min=0, max=1, modifier=false, summary=false) 7450 @Description(shortDefinition="The role of the contributor (e.g. author, editor, reviewer)", formalDefinition="The role of the contributor (e.g. author, editor, reviewer)." ) 7451 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/contributor-role") 7452 protected CodeableConcept role; 7453 7454 /** 7455 * Contributions with accounting for time or number. 7456 */ 7457 @Child(name = "contributionInstance", type = {}, order=6, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 7458 @Description(shortDefinition="Contributions with accounting for time or number", formalDefinition="Contributions with accounting for time or number." ) 7459 protected List<CitationCitedArtifactContributorshipEntryContributionInstanceComponent> contributionInstance; 7460 7461 /** 7462 * Indication of which contributor is the corresponding contributor for the role. 7463 */ 7464 @Child(name = "correspondingContact", type = {BooleanType.class}, order=7, min=0, max=1, modifier=false, summary=false) 7465 @Description(shortDefinition="Indication of which contributor is the corresponding contributor for the role", formalDefinition="Indication of which contributor is the corresponding contributor for the role." ) 7466 protected BooleanType correspondingContact; 7467 7468 /** 7469 * Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author. 7470 */ 7471 @Child(name = "rankingOrder", type = {PositiveIntType.class}, order=8, min=0, max=1, modifier=false, summary=false) 7472 @Description(shortDefinition="Ranked order of contribution", formalDefinition="Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author." ) 7473 protected PositiveIntType rankingOrder; 7474 7475 private static final long serialVersionUID = 1654594857L; 7476 7477 /** 7478 * Constructor 7479 */ 7480 public CitationCitedArtifactContributorshipEntryComponent() { 7481 super(); 7482 } 7483 7484 /** 7485 * Constructor 7486 */ 7487 public CitationCitedArtifactContributorshipEntryComponent(Reference contributor) { 7488 super(); 7489 this.setContributor(contributor); 7490 } 7491 7492 /** 7493 * @return {@link #contributor} (The identity of the individual entity.) 7494 */ 7495 public Reference getContributor() { 7496 if (this.contributor == null) 7497 if (Configuration.errorOnAutoCreate()) 7498 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryComponent.contributor"); 7499 else if (Configuration.doAutoCreate()) 7500 this.contributor = new Reference(); // cc 7501 return this.contributor; 7502 } 7503 7504 public boolean hasContributor() { 7505 return this.contributor != null && !this.contributor.isEmpty(); 7506 } 7507 7508 /** 7509 * @param value {@link #contributor} (The identity of the individual entity.) 7510 */ 7511 public CitationCitedArtifactContributorshipEntryComponent setContributor(Reference value) { 7512 this.contributor = value; 7513 return this; 7514 } 7515 7516 /** 7517 * @return {@link #forenameInitials} (Initials for forename.). This is the underlying object with id, value and extensions. The accessor "getForenameInitials" gives direct access to the value 7518 */ 7519 public StringType getForenameInitialsElement() { 7520 if (this.forenameInitials == null) 7521 if (Configuration.errorOnAutoCreate()) 7522 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryComponent.forenameInitials"); 7523 else if (Configuration.doAutoCreate()) 7524 this.forenameInitials = new StringType(); // bb 7525 return this.forenameInitials; 7526 } 7527 7528 public boolean hasForenameInitialsElement() { 7529 return this.forenameInitials != null && !this.forenameInitials.isEmpty(); 7530 } 7531 7532 public boolean hasForenameInitials() { 7533 return this.forenameInitials != null && !this.forenameInitials.isEmpty(); 7534 } 7535 7536 /** 7537 * @param value {@link #forenameInitials} (Initials for forename.). This is the underlying object with id, value and extensions. The accessor "getForenameInitials" gives direct access to the value 7538 */ 7539 public CitationCitedArtifactContributorshipEntryComponent setForenameInitialsElement(StringType value) { 7540 this.forenameInitials = value; 7541 return this; 7542 } 7543 7544 /** 7545 * @return Initials for forename. 7546 */ 7547 public String getForenameInitials() { 7548 return this.forenameInitials == null ? null : this.forenameInitials.getValue(); 7549 } 7550 7551 /** 7552 * @param value Initials for forename. 7553 */ 7554 public CitationCitedArtifactContributorshipEntryComponent setForenameInitials(String value) { 7555 if (Utilities.noString(value)) 7556 this.forenameInitials = null; 7557 else { 7558 if (this.forenameInitials == null) 7559 this.forenameInitials = new StringType(); 7560 this.forenameInitials.setValue(value); 7561 } 7562 return this; 7563 } 7564 7565 /** 7566 * @return {@link #affiliation} (Organization affiliated with the entity.) 7567 */ 7568 public List<Reference> getAffiliation() { 7569 if (this.affiliation == null) 7570 this.affiliation = new ArrayList<Reference>(); 7571 return this.affiliation; 7572 } 7573 7574 /** 7575 * @return Returns a reference to <code>this</code> for easy method chaining 7576 */ 7577 public CitationCitedArtifactContributorshipEntryComponent setAffiliation(List<Reference> theAffiliation) { 7578 this.affiliation = theAffiliation; 7579 return this; 7580 } 7581 7582 public boolean hasAffiliation() { 7583 if (this.affiliation == null) 7584 return false; 7585 for (Reference item : this.affiliation) 7586 if (!item.isEmpty()) 7587 return true; 7588 return false; 7589 } 7590 7591 public Reference addAffiliation() { //3 7592 Reference t = new Reference(); 7593 if (this.affiliation == null) 7594 this.affiliation = new ArrayList<Reference>(); 7595 this.affiliation.add(t); 7596 return t; 7597 } 7598 7599 public CitationCitedArtifactContributorshipEntryComponent addAffiliation(Reference t) { //3 7600 if (t == null) 7601 return this; 7602 if (this.affiliation == null) 7603 this.affiliation = new ArrayList<Reference>(); 7604 this.affiliation.add(t); 7605 return this; 7606 } 7607 7608 /** 7609 * @return The first repetition of repeating field {@link #affiliation}, creating it if it does not already exist {3} 7610 */ 7611 public Reference getAffiliationFirstRep() { 7612 if (getAffiliation().isEmpty()) { 7613 addAffiliation(); 7614 } 7615 return getAffiliation().get(0); 7616 } 7617 7618 /** 7619 * @return {@link #contributionType} (This element identifies the specific nature of an individual?s contribution with respect to the cited work.) 7620 */ 7621 public List<CodeableConcept> getContributionType() { 7622 if (this.contributionType == null) 7623 this.contributionType = new ArrayList<CodeableConcept>(); 7624 return this.contributionType; 7625 } 7626 7627 /** 7628 * @return Returns a reference to <code>this</code> for easy method chaining 7629 */ 7630 public CitationCitedArtifactContributorshipEntryComponent setContributionType(List<CodeableConcept> theContributionType) { 7631 this.contributionType = theContributionType; 7632 return this; 7633 } 7634 7635 public boolean hasContributionType() { 7636 if (this.contributionType == null) 7637 return false; 7638 for (CodeableConcept item : this.contributionType) 7639 if (!item.isEmpty()) 7640 return true; 7641 return false; 7642 } 7643 7644 public CodeableConcept addContributionType() { //3 7645 CodeableConcept t = new CodeableConcept(); 7646 if (this.contributionType == null) 7647 this.contributionType = new ArrayList<CodeableConcept>(); 7648 this.contributionType.add(t); 7649 return t; 7650 } 7651 7652 public CitationCitedArtifactContributorshipEntryComponent addContributionType(CodeableConcept t) { //3 7653 if (t == null) 7654 return this; 7655 if (this.contributionType == null) 7656 this.contributionType = new ArrayList<CodeableConcept>(); 7657 this.contributionType.add(t); 7658 return this; 7659 } 7660 7661 /** 7662 * @return The first repetition of repeating field {@link #contributionType}, creating it if it does not already exist {3} 7663 */ 7664 public CodeableConcept getContributionTypeFirstRep() { 7665 if (getContributionType().isEmpty()) { 7666 addContributionType(); 7667 } 7668 return getContributionType().get(0); 7669 } 7670 7671 /** 7672 * @return {@link #role} (The role of the contributor (e.g. author, editor, reviewer).) 7673 */ 7674 public CodeableConcept getRole() { 7675 if (this.role == null) 7676 if (Configuration.errorOnAutoCreate()) 7677 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryComponent.role"); 7678 else if (Configuration.doAutoCreate()) 7679 this.role = new CodeableConcept(); // cc 7680 return this.role; 7681 } 7682 7683 public boolean hasRole() { 7684 return this.role != null && !this.role.isEmpty(); 7685 } 7686 7687 /** 7688 * @param value {@link #role} (The role of the contributor (e.g. author, editor, reviewer).) 7689 */ 7690 public CitationCitedArtifactContributorshipEntryComponent setRole(CodeableConcept value) { 7691 this.role = value; 7692 return this; 7693 } 7694 7695 /** 7696 * @return {@link #contributionInstance} (Contributions with accounting for time or number.) 7697 */ 7698 public List<CitationCitedArtifactContributorshipEntryContributionInstanceComponent> getContributionInstance() { 7699 if (this.contributionInstance == null) 7700 this.contributionInstance = new ArrayList<CitationCitedArtifactContributorshipEntryContributionInstanceComponent>(); 7701 return this.contributionInstance; 7702 } 7703 7704 /** 7705 * @return Returns a reference to <code>this</code> for easy method chaining 7706 */ 7707 public CitationCitedArtifactContributorshipEntryComponent setContributionInstance(List<CitationCitedArtifactContributorshipEntryContributionInstanceComponent> theContributionInstance) { 7708 this.contributionInstance = theContributionInstance; 7709 return this; 7710 } 7711 7712 public boolean hasContributionInstance() { 7713 if (this.contributionInstance == null) 7714 return false; 7715 for (CitationCitedArtifactContributorshipEntryContributionInstanceComponent item : this.contributionInstance) 7716 if (!item.isEmpty()) 7717 return true; 7718 return false; 7719 } 7720 7721 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent addContributionInstance() { //3 7722 CitationCitedArtifactContributorshipEntryContributionInstanceComponent t = new CitationCitedArtifactContributorshipEntryContributionInstanceComponent(); 7723 if (this.contributionInstance == null) 7724 this.contributionInstance = new ArrayList<CitationCitedArtifactContributorshipEntryContributionInstanceComponent>(); 7725 this.contributionInstance.add(t); 7726 return t; 7727 } 7728 7729 public CitationCitedArtifactContributorshipEntryComponent addContributionInstance(CitationCitedArtifactContributorshipEntryContributionInstanceComponent t) { //3 7730 if (t == null) 7731 return this; 7732 if (this.contributionInstance == null) 7733 this.contributionInstance = new ArrayList<CitationCitedArtifactContributorshipEntryContributionInstanceComponent>(); 7734 this.contributionInstance.add(t); 7735 return this; 7736 } 7737 7738 /** 7739 * @return The first repetition of repeating field {@link #contributionInstance}, creating it if it does not already exist {3} 7740 */ 7741 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent getContributionInstanceFirstRep() { 7742 if (getContributionInstance().isEmpty()) { 7743 addContributionInstance(); 7744 } 7745 return getContributionInstance().get(0); 7746 } 7747 7748 /** 7749 * @return {@link #correspondingContact} (Indication of which contributor is the corresponding contributor for the role.). This is the underlying object with id, value and extensions. The accessor "getCorrespondingContact" gives direct access to the value 7750 */ 7751 public BooleanType getCorrespondingContactElement() { 7752 if (this.correspondingContact == null) 7753 if (Configuration.errorOnAutoCreate()) 7754 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryComponent.correspondingContact"); 7755 else if (Configuration.doAutoCreate()) 7756 this.correspondingContact = new BooleanType(); // bb 7757 return this.correspondingContact; 7758 } 7759 7760 public boolean hasCorrespondingContactElement() { 7761 return this.correspondingContact != null && !this.correspondingContact.isEmpty(); 7762 } 7763 7764 public boolean hasCorrespondingContact() { 7765 return this.correspondingContact != null && !this.correspondingContact.isEmpty(); 7766 } 7767 7768 /** 7769 * @param value {@link #correspondingContact} (Indication of which contributor is the corresponding contributor for the role.). This is the underlying object with id, value and extensions. The accessor "getCorrespondingContact" gives direct access to the value 7770 */ 7771 public CitationCitedArtifactContributorshipEntryComponent setCorrespondingContactElement(BooleanType value) { 7772 this.correspondingContact = value; 7773 return this; 7774 } 7775 7776 /** 7777 * @return Indication of which contributor is the corresponding contributor for the role. 7778 */ 7779 public boolean getCorrespondingContact() { 7780 return this.correspondingContact == null || this.correspondingContact.isEmpty() ? false : this.correspondingContact.getValue(); 7781 } 7782 7783 /** 7784 * @param value Indication of which contributor is the corresponding contributor for the role. 7785 */ 7786 public CitationCitedArtifactContributorshipEntryComponent setCorrespondingContact(boolean value) { 7787 if (this.correspondingContact == null) 7788 this.correspondingContact = new BooleanType(); 7789 this.correspondingContact.setValue(value); 7790 return this; 7791 } 7792 7793 /** 7794 * @return {@link #rankingOrder} (Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author.). This is the underlying object with id, value and extensions. The accessor "getRankingOrder" gives direct access to the value 7795 */ 7796 public PositiveIntType getRankingOrderElement() { 7797 if (this.rankingOrder == null) 7798 if (Configuration.errorOnAutoCreate()) 7799 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryComponent.rankingOrder"); 7800 else if (Configuration.doAutoCreate()) 7801 this.rankingOrder = new PositiveIntType(); // bb 7802 return this.rankingOrder; 7803 } 7804 7805 public boolean hasRankingOrderElement() { 7806 return this.rankingOrder != null && !this.rankingOrder.isEmpty(); 7807 } 7808 7809 public boolean hasRankingOrder() { 7810 return this.rankingOrder != null && !this.rankingOrder.isEmpty(); 7811 } 7812 7813 /** 7814 * @param value {@link #rankingOrder} (Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author.). This is the underlying object with id, value and extensions. The accessor "getRankingOrder" gives direct access to the value 7815 */ 7816 public CitationCitedArtifactContributorshipEntryComponent setRankingOrderElement(PositiveIntType value) { 7817 this.rankingOrder = value; 7818 return this; 7819 } 7820 7821 /** 7822 * @return Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author. 7823 */ 7824 public int getRankingOrder() { 7825 return this.rankingOrder == null || this.rankingOrder.isEmpty() ? 0 : this.rankingOrder.getValue(); 7826 } 7827 7828 /** 7829 * @param value Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author. 7830 */ 7831 public CitationCitedArtifactContributorshipEntryComponent setRankingOrder(int value) { 7832 if (this.rankingOrder == null) 7833 this.rankingOrder = new PositiveIntType(); 7834 this.rankingOrder.setValue(value); 7835 return this; 7836 } 7837 7838 protected void listChildren(List<Property> children) { 7839 super.listChildren(children); 7840 children.add(new Property("contributor", "Reference(Practitioner|Organization)", "The identity of the individual entity.", 0, 1, contributor)); 7841 children.add(new Property("forenameInitials", "string", "Initials for forename.", 0, 1, forenameInitials)); 7842 children.add(new Property("affiliation", "Reference(Organization|PractitionerRole)", "Organization affiliated with the entity.", 0, java.lang.Integer.MAX_VALUE, affiliation)); 7843 children.add(new Property("contributionType", "CodeableConcept", "This element identifies the specific nature of an individual?s contribution with respect to the cited work.", 0, java.lang.Integer.MAX_VALUE, contributionType)); 7844 children.add(new Property("role", "CodeableConcept", "The role of the contributor (e.g. author, editor, reviewer).", 0, 1, role)); 7845 children.add(new Property("contributionInstance", "", "Contributions with accounting for time or number.", 0, java.lang.Integer.MAX_VALUE, contributionInstance)); 7846 children.add(new Property("correspondingContact", "boolean", "Indication of which contributor is the corresponding contributor for the role.", 0, 1, correspondingContact)); 7847 children.add(new Property("rankingOrder", "positiveInt", "Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author.", 0, 1, rankingOrder)); 7848 } 7849 7850 @Override 7851 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 7852 switch (_hash) { 7853 case -1895276325: /*contributor*/ return new Property("contributor", "Reference(Practitioner|Organization)", "The identity of the individual entity.", 0, 1, contributor); 7854 case -740521962: /*forenameInitials*/ return new Property("forenameInitials", "string", "Initials for forename.", 0, 1, forenameInitials); 7855 case 2019918576: /*affiliation*/ return new Property("affiliation", "Reference(Organization|PractitionerRole)", "Organization affiliated with the entity.", 0, java.lang.Integer.MAX_VALUE, affiliation); 7856 case -1600446614: /*contributionType*/ return new Property("contributionType", "CodeableConcept", "This element identifies the specific nature of an individual?s contribution with respect to the cited work.", 0, java.lang.Integer.MAX_VALUE, contributionType); 7857 case 3506294: /*role*/ return new Property("role", "CodeableConcept", "The role of the contributor (e.g. author, editor, reviewer).", 0, 1, role); 7858 case -547910459: /*contributionInstance*/ return new Property("contributionInstance", "", "Contributions with accounting for time or number.", 0, java.lang.Integer.MAX_VALUE, contributionInstance); 7859 case -1816008851: /*correspondingContact*/ return new Property("correspondingContact", "boolean", "Indication of which contributor is the corresponding contributor for the role.", 0, 1, correspondingContact); 7860 case -762905416: /*rankingOrder*/ return new Property("rankingOrder", "positiveInt", "Provides a numerical ranking to represent the degree of contributorship relative to other contributors, such as 1 for first author and 2 for second author.", 0, 1, rankingOrder); 7861 default: return super.getNamedProperty(_hash, _name, _checkValid); 7862 } 7863 7864 } 7865 7866 @Override 7867 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 7868 switch (hash) { 7869 case -1895276325: /*contributor*/ return this.contributor == null ? new Base[0] : new Base[] {this.contributor}; // Reference 7870 case -740521962: /*forenameInitials*/ return this.forenameInitials == null ? new Base[0] : new Base[] {this.forenameInitials}; // StringType 7871 case 2019918576: /*affiliation*/ return this.affiliation == null ? new Base[0] : this.affiliation.toArray(new Base[this.affiliation.size()]); // Reference 7872 case -1600446614: /*contributionType*/ return this.contributionType == null ? new Base[0] : this.contributionType.toArray(new Base[this.contributionType.size()]); // CodeableConcept 7873 case 3506294: /*role*/ return this.role == null ? new Base[0] : new Base[] {this.role}; // CodeableConcept 7874 case -547910459: /*contributionInstance*/ return this.contributionInstance == null ? new Base[0] : this.contributionInstance.toArray(new Base[this.contributionInstance.size()]); // CitationCitedArtifactContributorshipEntryContributionInstanceComponent 7875 case -1816008851: /*correspondingContact*/ return this.correspondingContact == null ? new Base[0] : new Base[] {this.correspondingContact}; // BooleanType 7876 case -762905416: /*rankingOrder*/ return this.rankingOrder == null ? new Base[0] : new Base[] {this.rankingOrder}; // PositiveIntType 7877 default: return super.getProperty(hash, name, checkValid); 7878 } 7879 7880 } 7881 7882 @Override 7883 public Base setProperty(int hash, String name, Base value) throws FHIRException { 7884 switch (hash) { 7885 case -1895276325: // contributor 7886 this.contributor = TypeConvertor.castToReference(value); // Reference 7887 return value; 7888 case -740521962: // forenameInitials 7889 this.forenameInitials = TypeConvertor.castToString(value); // StringType 7890 return value; 7891 case 2019918576: // affiliation 7892 this.getAffiliation().add(TypeConvertor.castToReference(value)); // Reference 7893 return value; 7894 case -1600446614: // contributionType 7895 this.getContributionType().add(TypeConvertor.castToCodeableConcept(value)); // CodeableConcept 7896 return value; 7897 case 3506294: // role 7898 this.role = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 7899 return value; 7900 case -547910459: // contributionInstance 7901 this.getContributionInstance().add((CitationCitedArtifactContributorshipEntryContributionInstanceComponent) value); // CitationCitedArtifactContributorshipEntryContributionInstanceComponent 7902 return value; 7903 case -1816008851: // correspondingContact 7904 this.correspondingContact = TypeConvertor.castToBoolean(value); // BooleanType 7905 return value; 7906 case -762905416: // rankingOrder 7907 this.rankingOrder = TypeConvertor.castToPositiveInt(value); // PositiveIntType 7908 return value; 7909 default: return super.setProperty(hash, name, value); 7910 } 7911 7912 } 7913 7914 @Override 7915 public Base setProperty(String name, Base value) throws FHIRException { 7916 if (name.equals("contributor")) { 7917 this.contributor = TypeConvertor.castToReference(value); // Reference 7918 } else if (name.equals("forenameInitials")) { 7919 this.forenameInitials = TypeConvertor.castToString(value); // StringType 7920 } else if (name.equals("affiliation")) { 7921 this.getAffiliation().add(TypeConvertor.castToReference(value)); 7922 } else if (name.equals("contributionType")) { 7923 this.getContributionType().add(TypeConvertor.castToCodeableConcept(value)); 7924 } else if (name.equals("role")) { 7925 this.role = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 7926 } else if (name.equals("contributionInstance")) { 7927 this.getContributionInstance().add((CitationCitedArtifactContributorshipEntryContributionInstanceComponent) value); 7928 } else if (name.equals("correspondingContact")) { 7929 this.correspondingContact = TypeConvertor.castToBoolean(value); // BooleanType 7930 } else if (name.equals("rankingOrder")) { 7931 this.rankingOrder = TypeConvertor.castToPositiveInt(value); // PositiveIntType 7932 } else 7933 return super.setProperty(name, value); 7934 return value; 7935 } 7936 7937 @Override 7938 public Base makeProperty(int hash, String name) throws FHIRException { 7939 switch (hash) { 7940 case -1895276325: return getContributor(); 7941 case -740521962: return getForenameInitialsElement(); 7942 case 2019918576: return addAffiliation(); 7943 case -1600446614: return addContributionType(); 7944 case 3506294: return getRole(); 7945 case -547910459: return addContributionInstance(); 7946 case -1816008851: return getCorrespondingContactElement(); 7947 case -762905416: return getRankingOrderElement(); 7948 default: return super.makeProperty(hash, name); 7949 } 7950 7951 } 7952 7953 @Override 7954 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 7955 switch (hash) { 7956 case -1895276325: /*contributor*/ return new String[] {"Reference"}; 7957 case -740521962: /*forenameInitials*/ return new String[] {"string"}; 7958 case 2019918576: /*affiliation*/ return new String[] {"Reference"}; 7959 case -1600446614: /*contributionType*/ return new String[] {"CodeableConcept"}; 7960 case 3506294: /*role*/ return new String[] {"CodeableConcept"}; 7961 case -547910459: /*contributionInstance*/ return new String[] {}; 7962 case -1816008851: /*correspondingContact*/ return new String[] {"boolean"}; 7963 case -762905416: /*rankingOrder*/ return new String[] {"positiveInt"}; 7964 default: return super.getTypesForProperty(hash, name); 7965 } 7966 7967 } 7968 7969 @Override 7970 public Base addChild(String name) throws FHIRException { 7971 if (name.equals("contributor")) { 7972 this.contributor = new Reference(); 7973 return this.contributor; 7974 } 7975 else if (name.equals("forenameInitials")) { 7976 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.entry.forenameInitials"); 7977 } 7978 else if (name.equals("affiliation")) { 7979 return addAffiliation(); 7980 } 7981 else if (name.equals("contributionType")) { 7982 return addContributionType(); 7983 } 7984 else if (name.equals("role")) { 7985 this.role = new CodeableConcept(); 7986 return this.role; 7987 } 7988 else if (name.equals("contributionInstance")) { 7989 return addContributionInstance(); 7990 } 7991 else if (name.equals("correspondingContact")) { 7992 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.entry.correspondingContact"); 7993 } 7994 else if (name.equals("rankingOrder")) { 7995 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.entry.rankingOrder"); 7996 } 7997 else 7998 return super.addChild(name); 7999 } 8000 8001 public CitationCitedArtifactContributorshipEntryComponent copy() { 8002 CitationCitedArtifactContributorshipEntryComponent dst = new CitationCitedArtifactContributorshipEntryComponent(); 8003 copyValues(dst); 8004 return dst; 8005 } 8006 8007 public void copyValues(CitationCitedArtifactContributorshipEntryComponent dst) { 8008 super.copyValues(dst); 8009 dst.contributor = contributor == null ? null : contributor.copy(); 8010 dst.forenameInitials = forenameInitials == null ? null : forenameInitials.copy(); 8011 if (affiliation != null) { 8012 dst.affiliation = new ArrayList<Reference>(); 8013 for (Reference i : affiliation) 8014 dst.affiliation.add(i.copy()); 8015 }; 8016 if (contributionType != null) { 8017 dst.contributionType = new ArrayList<CodeableConcept>(); 8018 for (CodeableConcept i : contributionType) 8019 dst.contributionType.add(i.copy()); 8020 }; 8021 dst.role = role == null ? null : role.copy(); 8022 if (contributionInstance != null) { 8023 dst.contributionInstance = new ArrayList<CitationCitedArtifactContributorshipEntryContributionInstanceComponent>(); 8024 for (CitationCitedArtifactContributorshipEntryContributionInstanceComponent i : contributionInstance) 8025 dst.contributionInstance.add(i.copy()); 8026 }; 8027 dst.correspondingContact = correspondingContact == null ? null : correspondingContact.copy(); 8028 dst.rankingOrder = rankingOrder == null ? null : rankingOrder.copy(); 8029 } 8030 8031 @Override 8032 public boolean equalsDeep(Base other_) { 8033 if (!super.equalsDeep(other_)) 8034 return false; 8035 if (!(other_ instanceof CitationCitedArtifactContributorshipEntryComponent)) 8036 return false; 8037 CitationCitedArtifactContributorshipEntryComponent o = (CitationCitedArtifactContributorshipEntryComponent) other_; 8038 return compareDeep(contributor, o.contributor, true) && compareDeep(forenameInitials, o.forenameInitials, true) 8039 && compareDeep(affiliation, o.affiliation, true) && compareDeep(contributionType, o.contributionType, true) 8040 && compareDeep(role, o.role, true) && compareDeep(contributionInstance, o.contributionInstance, true) 8041 && compareDeep(correspondingContact, o.correspondingContact, true) && compareDeep(rankingOrder, o.rankingOrder, true) 8042 ; 8043 } 8044 8045 @Override 8046 public boolean equalsShallow(Base other_) { 8047 if (!super.equalsShallow(other_)) 8048 return false; 8049 if (!(other_ instanceof CitationCitedArtifactContributorshipEntryComponent)) 8050 return false; 8051 CitationCitedArtifactContributorshipEntryComponent o = (CitationCitedArtifactContributorshipEntryComponent) other_; 8052 return compareValues(forenameInitials, o.forenameInitials, true) && compareValues(correspondingContact, o.correspondingContact, true) 8053 && compareValues(rankingOrder, o.rankingOrder, true); 8054 } 8055 8056 public boolean isEmpty() { 8057 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(contributor, forenameInitials 8058 , affiliation, contributionType, role, contributionInstance, correspondingContact 8059 , rankingOrder); 8060 } 8061 8062 public String fhirType() { 8063 return "Citation.citedArtifact.contributorship.entry"; 8064 8065 } 8066 8067 } 8068 8069 @Block() 8070 public static class CitationCitedArtifactContributorshipEntryContributionInstanceComponent extends BackboneElement implements IBaseBackboneElement { 8071 /** 8072 * The specific contribution. 8073 */ 8074 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=1, max=1, modifier=false, summary=false) 8075 @Description(shortDefinition="The specific contribution", formalDefinition="The specific contribution." ) 8076 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/artifact-contribution-instance-type") 8077 protected CodeableConcept type; 8078 8079 /** 8080 * The time that the contribution was made. 8081 */ 8082 @Child(name = "time", type = {DateTimeType.class}, order=2, min=0, max=1, modifier=false, summary=false) 8083 @Description(shortDefinition="The time that the contribution was made", formalDefinition="The time that the contribution was made." ) 8084 protected DateTimeType time; 8085 8086 private static final long serialVersionUID = -196837729L; 8087 8088 /** 8089 * Constructor 8090 */ 8091 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent() { 8092 super(); 8093 } 8094 8095 /** 8096 * Constructor 8097 */ 8098 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent(CodeableConcept type) { 8099 super(); 8100 this.setType(type); 8101 } 8102 8103 /** 8104 * @return {@link #type} (The specific contribution.) 8105 */ 8106 public CodeableConcept getType() { 8107 if (this.type == null) 8108 if (Configuration.errorOnAutoCreate()) 8109 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryContributionInstanceComponent.type"); 8110 else if (Configuration.doAutoCreate()) 8111 this.type = new CodeableConcept(); // cc 8112 return this.type; 8113 } 8114 8115 public boolean hasType() { 8116 return this.type != null && !this.type.isEmpty(); 8117 } 8118 8119 /** 8120 * @param value {@link #type} (The specific contribution.) 8121 */ 8122 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent setType(CodeableConcept value) { 8123 this.type = value; 8124 return this; 8125 } 8126 8127 /** 8128 * @return {@link #time} (The time that the contribution was made.). This is the underlying object with id, value and extensions. The accessor "getTime" gives direct access to the value 8129 */ 8130 public DateTimeType getTimeElement() { 8131 if (this.time == null) 8132 if (Configuration.errorOnAutoCreate()) 8133 throw new Error("Attempt to auto-create CitationCitedArtifactContributorshipEntryContributionInstanceComponent.time"); 8134 else if (Configuration.doAutoCreate()) 8135 this.time = new DateTimeType(); // bb 8136 return this.time; 8137 } 8138 8139 public boolean hasTimeElement() { 8140 return this.time != null && !this.time.isEmpty(); 8141 } 8142 8143 public boolean hasTime() { 8144 return this.time != null && !this.time.isEmpty(); 8145 } 8146 8147 /** 8148 * @param value {@link #time} (The time that the contribution was made.). This is the underlying object with id, value and extensions. The accessor "getTime" gives direct access to the value 8149 */ 8150 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent setTimeElement(DateTimeType value) { 8151 this.time = value; 8152 return this; 8153 } 8154 8155 /** 8156 * @return The time that the contribution was made. 8157 */ 8158 public Date getTime() { 8159 return this.time == null ? null : this.time.getValue(); 8160 } 8161 8162 /** 8163 * @param value The time that the contribution was made. 8164 */ 8165 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent setTime(Date value) { 8166 if (value == null) 8167 this.time = null; 8168 else { 8169 if (this.time == null) 8170 this.time = new DateTimeType(); 8171 this.time.setValue(value); 8172 } 8173 return this; 8174 } 8175 8176 protected void listChildren(List<Property> children) { 8177 super.listChildren(children); 8178 children.add(new Property("type", "CodeableConcept", "The specific contribution.", 0, 1, type)); 8179 children.add(new Property("time", "dateTime", "The time that the contribution was made.", 0, 1, time)); 8180 } 8181 8182 @Override 8183 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 8184 switch (_hash) { 8185 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "The specific contribution.", 0, 1, type); 8186 case 3560141: /*time*/ return new Property("time", "dateTime", "The time that the contribution was made.", 0, 1, time); 8187 default: return super.getNamedProperty(_hash, _name, _checkValid); 8188 } 8189 8190 } 8191 8192 @Override 8193 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 8194 switch (hash) { 8195 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 8196 case 3560141: /*time*/ return this.time == null ? new Base[0] : new Base[] {this.time}; // DateTimeType 8197 default: return super.getProperty(hash, name, checkValid); 8198 } 8199 8200 } 8201 8202 @Override 8203 public Base setProperty(int hash, String name, Base value) throws FHIRException { 8204 switch (hash) { 8205 case 3575610: // type 8206 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8207 return value; 8208 case 3560141: // time 8209 this.time = TypeConvertor.castToDateTime(value); // DateTimeType 8210 return value; 8211 default: return super.setProperty(hash, name, value); 8212 } 8213 8214 } 8215 8216 @Override 8217 public Base setProperty(String name, Base value) throws FHIRException { 8218 if (name.equals("type")) { 8219 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8220 } else if (name.equals("time")) { 8221 this.time = TypeConvertor.castToDateTime(value); // DateTimeType 8222 } else 8223 return super.setProperty(name, value); 8224 return value; 8225 } 8226 8227 @Override 8228 public Base makeProperty(int hash, String name) throws FHIRException { 8229 switch (hash) { 8230 case 3575610: return getType(); 8231 case 3560141: return getTimeElement(); 8232 default: return super.makeProperty(hash, name); 8233 } 8234 8235 } 8236 8237 @Override 8238 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 8239 switch (hash) { 8240 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 8241 case 3560141: /*time*/ return new String[] {"dateTime"}; 8242 default: return super.getTypesForProperty(hash, name); 8243 } 8244 8245 } 8246 8247 @Override 8248 public Base addChild(String name) throws FHIRException { 8249 if (name.equals("type")) { 8250 this.type = new CodeableConcept(); 8251 return this.type; 8252 } 8253 else if (name.equals("time")) { 8254 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.entry.contributionInstance.time"); 8255 } 8256 else 8257 return super.addChild(name); 8258 } 8259 8260 public CitationCitedArtifactContributorshipEntryContributionInstanceComponent copy() { 8261 CitationCitedArtifactContributorshipEntryContributionInstanceComponent dst = new CitationCitedArtifactContributorshipEntryContributionInstanceComponent(); 8262 copyValues(dst); 8263 return dst; 8264 } 8265 8266 public void copyValues(CitationCitedArtifactContributorshipEntryContributionInstanceComponent dst) { 8267 super.copyValues(dst); 8268 dst.type = type == null ? null : type.copy(); 8269 dst.time = time == null ? null : time.copy(); 8270 } 8271 8272 @Override 8273 public boolean equalsDeep(Base other_) { 8274 if (!super.equalsDeep(other_)) 8275 return false; 8276 if (!(other_ instanceof CitationCitedArtifactContributorshipEntryContributionInstanceComponent)) 8277 return false; 8278 CitationCitedArtifactContributorshipEntryContributionInstanceComponent o = (CitationCitedArtifactContributorshipEntryContributionInstanceComponent) other_; 8279 return compareDeep(type, o.type, true) && compareDeep(time, o.time, true); 8280 } 8281 8282 @Override 8283 public boolean equalsShallow(Base other_) { 8284 if (!super.equalsShallow(other_)) 8285 return false; 8286 if (!(other_ instanceof CitationCitedArtifactContributorshipEntryContributionInstanceComponent)) 8287 return false; 8288 CitationCitedArtifactContributorshipEntryContributionInstanceComponent o = (CitationCitedArtifactContributorshipEntryContributionInstanceComponent) other_; 8289 return compareValues(time, o.time, true); 8290 } 8291 8292 public boolean isEmpty() { 8293 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, time); 8294 } 8295 8296 public String fhirType() { 8297 return "Citation.citedArtifact.contributorship.entry.contributionInstance"; 8298 8299 } 8300 8301 } 8302 8303 @Block() 8304 public static class ContributorshipSummaryComponent extends BackboneElement implements IBaseBackboneElement { 8305 /** 8306 * Used most commonly to express an author list or a contributorship statement. 8307 */ 8308 @Child(name = "type", type = {CodeableConcept.class}, order=1, min=0, max=1, modifier=false, summary=false) 8309 @Description(shortDefinition="Either authorList or contributorshipStatement", formalDefinition="Used most commonly to express an author list or a contributorship statement." ) 8310 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/contributor-summary-type") 8311 protected CodeableConcept type; 8312 8313 /** 8314 * The format for the display string. 8315 */ 8316 @Child(name = "style", type = {CodeableConcept.class}, order=2, min=0, max=1, modifier=false, summary=false) 8317 @Description(shortDefinition="The format for the display string", formalDefinition="The format for the display string." ) 8318 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/contributor-summary-style") 8319 protected CodeableConcept style; 8320 8321 /** 8322 * Used to code the producer or rule for creating the display string. 8323 */ 8324 @Child(name = "source", type = {CodeableConcept.class}, order=3, min=0, max=1, modifier=false, summary=false) 8325 @Description(shortDefinition="Used to code the producer or rule for creating the display string", formalDefinition="Used to code the producer or rule for creating the display string." ) 8326 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/contributor-summary-source") 8327 protected CodeableConcept source; 8328 8329 /** 8330 * The display string for the author list, contributor list, or contributorship statement. 8331 */ 8332 @Child(name = "value", type = {MarkdownType.class}, order=4, min=1, max=1, modifier=false, summary=false) 8333 @Description(shortDefinition="The display string for the author list, contributor list, or contributorship statement", formalDefinition="The display string for the author list, contributor list, or contributorship statement." ) 8334 protected MarkdownType value; 8335 8336 private static final long serialVersionUID = 1353383781L; 8337 8338 /** 8339 * Constructor 8340 */ 8341 public ContributorshipSummaryComponent() { 8342 super(); 8343 } 8344 8345 /** 8346 * Constructor 8347 */ 8348 public ContributorshipSummaryComponent(String value) { 8349 super(); 8350 this.setValue(value); 8351 } 8352 8353 /** 8354 * @return {@link #type} (Used most commonly to express an author list or a contributorship statement.) 8355 */ 8356 public CodeableConcept getType() { 8357 if (this.type == null) 8358 if (Configuration.errorOnAutoCreate()) 8359 throw new Error("Attempt to auto-create ContributorshipSummaryComponent.type"); 8360 else if (Configuration.doAutoCreate()) 8361 this.type = new CodeableConcept(); // cc 8362 return this.type; 8363 } 8364 8365 public boolean hasType() { 8366 return this.type != null && !this.type.isEmpty(); 8367 } 8368 8369 /** 8370 * @param value {@link #type} (Used most commonly to express an author list or a contributorship statement.) 8371 */ 8372 public ContributorshipSummaryComponent setType(CodeableConcept value) { 8373 this.type = value; 8374 return this; 8375 } 8376 8377 /** 8378 * @return {@link #style} (The format for the display string.) 8379 */ 8380 public CodeableConcept getStyle() { 8381 if (this.style == null) 8382 if (Configuration.errorOnAutoCreate()) 8383 throw new Error("Attempt to auto-create ContributorshipSummaryComponent.style"); 8384 else if (Configuration.doAutoCreate()) 8385 this.style = new CodeableConcept(); // cc 8386 return this.style; 8387 } 8388 8389 public boolean hasStyle() { 8390 return this.style != null && !this.style.isEmpty(); 8391 } 8392 8393 /** 8394 * @param value {@link #style} (The format for the display string.) 8395 */ 8396 public ContributorshipSummaryComponent setStyle(CodeableConcept value) { 8397 this.style = value; 8398 return this; 8399 } 8400 8401 /** 8402 * @return {@link #source} (Used to code the producer or rule for creating the display string.) 8403 */ 8404 public CodeableConcept getSource() { 8405 if (this.source == null) 8406 if (Configuration.errorOnAutoCreate()) 8407 throw new Error("Attempt to auto-create ContributorshipSummaryComponent.source"); 8408 else if (Configuration.doAutoCreate()) 8409 this.source = new CodeableConcept(); // cc 8410 return this.source; 8411 } 8412 8413 public boolean hasSource() { 8414 return this.source != null && !this.source.isEmpty(); 8415 } 8416 8417 /** 8418 * @param value {@link #source} (Used to code the producer or rule for creating the display string.) 8419 */ 8420 public ContributorshipSummaryComponent setSource(CodeableConcept value) { 8421 this.source = value; 8422 return this; 8423 } 8424 8425 /** 8426 * @return {@link #value} (The display string for the author list, contributor list, or contributorship statement.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 8427 */ 8428 public MarkdownType getValueElement() { 8429 if (this.value == null) 8430 if (Configuration.errorOnAutoCreate()) 8431 throw new Error("Attempt to auto-create ContributorshipSummaryComponent.value"); 8432 else if (Configuration.doAutoCreate()) 8433 this.value = new MarkdownType(); // bb 8434 return this.value; 8435 } 8436 8437 public boolean hasValueElement() { 8438 return this.value != null && !this.value.isEmpty(); 8439 } 8440 8441 public boolean hasValue() { 8442 return this.value != null && !this.value.isEmpty(); 8443 } 8444 8445 /** 8446 * @param value {@link #value} (The display string for the author list, contributor list, or contributorship statement.). This is the underlying object with id, value and extensions. The accessor "getValue" gives direct access to the value 8447 */ 8448 public ContributorshipSummaryComponent setValueElement(MarkdownType value) { 8449 this.value = value; 8450 return this; 8451 } 8452 8453 /** 8454 * @return The display string for the author list, contributor list, or contributorship statement. 8455 */ 8456 public String getValue() { 8457 return this.value == null ? null : this.value.getValue(); 8458 } 8459 8460 /** 8461 * @param value The display string for the author list, contributor list, or contributorship statement. 8462 */ 8463 public ContributorshipSummaryComponent setValue(String value) { 8464 if (this.value == null) 8465 this.value = new MarkdownType(); 8466 this.value.setValue(value); 8467 return this; 8468 } 8469 8470 protected void listChildren(List<Property> children) { 8471 super.listChildren(children); 8472 children.add(new Property("type", "CodeableConcept", "Used most commonly to express an author list or a contributorship statement.", 0, 1, type)); 8473 children.add(new Property("style", "CodeableConcept", "The format for the display string.", 0, 1, style)); 8474 children.add(new Property("source", "CodeableConcept", "Used to code the producer or rule for creating the display string.", 0, 1, source)); 8475 children.add(new Property("value", "markdown", "The display string for the author list, contributor list, or contributorship statement.", 0, 1, value)); 8476 } 8477 8478 @Override 8479 public Property getNamedProperty(int _hash, String _name, boolean _checkValid) throws FHIRException { 8480 switch (_hash) { 8481 case 3575610: /*type*/ return new Property("type", "CodeableConcept", "Used most commonly to express an author list or a contributorship statement.", 0, 1, type); 8482 case 109780401: /*style*/ return new Property("style", "CodeableConcept", "The format for the display string.", 0, 1, style); 8483 case -896505829: /*source*/ return new Property("source", "CodeableConcept", "Used to code the producer or rule for creating the display string.", 0, 1, source); 8484 case 111972721: /*value*/ return new Property("value", "markdown", "The display string for the author list, contributor list, or contributorship statement.", 0, 1, value); 8485 default: return super.getNamedProperty(_hash, _name, _checkValid); 8486 } 8487 8488 } 8489 8490 @Override 8491 public Base[] getProperty(int hash, String name, boolean checkValid) throws FHIRException { 8492 switch (hash) { 8493 case 3575610: /*type*/ return this.type == null ? new Base[0] : new Base[] {this.type}; // CodeableConcept 8494 case 109780401: /*style*/ return this.style == null ? new Base[0] : new Base[] {this.style}; // CodeableConcept 8495 case -896505829: /*source*/ return this.source == null ? new Base[0] : new Base[] {this.source}; // CodeableConcept 8496 case 111972721: /*value*/ return this.value == null ? new Base[0] : new Base[] {this.value}; // MarkdownType 8497 default: return super.getProperty(hash, name, checkValid); 8498 } 8499 8500 } 8501 8502 @Override 8503 public Base setProperty(int hash, String name, Base value) throws FHIRException { 8504 switch (hash) { 8505 case 3575610: // type 8506 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8507 return value; 8508 case 109780401: // style 8509 this.style = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8510 return value; 8511 case -896505829: // source 8512 this.source = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8513 return value; 8514 case 111972721: // value 8515 this.value = TypeConvertor.castToMarkdown(value); // MarkdownType 8516 return value; 8517 default: return super.setProperty(hash, name, value); 8518 } 8519 8520 } 8521 8522 @Override 8523 public Base setProperty(String name, Base value) throws FHIRException { 8524 if (name.equals("type")) { 8525 this.type = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8526 } else if (name.equals("style")) { 8527 this.style = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8528 } else if (name.equals("source")) { 8529 this.source = TypeConvertor.castToCodeableConcept(value); // CodeableConcept 8530 } else if (name.equals("value")) { 8531 this.value = TypeConvertor.castToMarkdown(value); // MarkdownType 8532 } else 8533 return super.setProperty(name, value); 8534 return value; 8535 } 8536 8537 @Override 8538 public Base makeProperty(int hash, String name) throws FHIRException { 8539 switch (hash) { 8540 case 3575610: return getType(); 8541 case 109780401: return getStyle(); 8542 case -896505829: return getSource(); 8543 case 111972721: return getValueElement(); 8544 default: return super.makeProperty(hash, name); 8545 } 8546 8547 } 8548 8549 @Override 8550 public String[] getTypesForProperty(int hash, String name) throws FHIRException { 8551 switch (hash) { 8552 case 3575610: /*type*/ return new String[] {"CodeableConcept"}; 8553 case 109780401: /*style*/ return new String[] {"CodeableConcept"}; 8554 case -896505829: /*source*/ return new String[] {"CodeableConcept"}; 8555 case 111972721: /*value*/ return new String[] {"markdown"}; 8556 default: return super.getTypesForProperty(hash, name); 8557 } 8558 8559 } 8560 8561 @Override 8562 public Base addChild(String name) throws FHIRException { 8563 if (name.equals("type")) { 8564 this.type = new CodeableConcept(); 8565 return this.type; 8566 } 8567 else if (name.equals("style")) { 8568 this.style = new CodeableConcept(); 8569 return this.style; 8570 } 8571 else if (name.equals("source")) { 8572 this.source = new CodeableConcept(); 8573 return this.source; 8574 } 8575 else if (name.equals("value")) { 8576 throw new FHIRException("Cannot call addChild on a primitive type Citation.citedArtifact.contributorship.summary.value"); 8577 } 8578 else 8579 return super.addChild(name); 8580 } 8581 8582 public ContributorshipSummaryComponent copy() { 8583 ContributorshipSummaryComponent dst = new ContributorshipSummaryComponent(); 8584 copyValues(dst); 8585 return dst; 8586 } 8587 8588 public void copyValues(ContributorshipSummaryComponent dst) { 8589 super.copyValues(dst); 8590 dst.type = type == null ? null : type.copy(); 8591 dst.style = style == null ? null : style.copy(); 8592 dst.source = source == null ? null : source.copy(); 8593 dst.value = value == null ? null : value.copy(); 8594 } 8595 8596 @Override 8597 public boolean equalsDeep(Base other_) { 8598 if (!super.equalsDeep(other_)) 8599 return false; 8600 if (!(other_ instanceof ContributorshipSummaryComponent)) 8601 return false; 8602 ContributorshipSummaryComponent o = (ContributorshipSummaryComponent) other_; 8603 return compareDeep(type, o.type, true) && compareDeep(style, o.style, true) && compareDeep(source, o.source, true) 8604 && compareDeep(value, o.value, true); 8605 } 8606 8607 @Override 8608 public boolean equalsShallow(Base other_) { 8609 if (!super.equalsShallow(other_)) 8610 return false; 8611 if (!(other_ instanceof ContributorshipSummaryComponent)) 8612 return false; 8613 ContributorshipSummaryComponent o = (ContributorshipSummaryComponent) other_; 8614 return compareValues(value, o.value, true); 8615 } 8616 8617 public boolean isEmpty() { 8618 return super.isEmpty() && ca.uhn.fhir.util.ElementUtil.isEmpty(type, style, source, value 8619 ); 8620 } 8621 8622 public String fhirType() { 8623 return "Citation.citedArtifact.contributorship.summary"; 8624 8625 } 8626 8627 } 8628 8629 /** 8630 * An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers. 8631 */ 8632 @Child(name = "url", type = {UriType.class}, order=0, min=0, max=1, modifier=false, summary=true) 8633 @Description(shortDefinition="Canonical identifier for this citation, represented as a globally unique URI", formalDefinition="An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers." ) 8634 protected UriType url; 8635 8636 /** 8637 * A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance. 8638 */ 8639 @Child(name = "identifier", type = {Identifier.class}, order=1, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 8640 @Description(shortDefinition="Identifier for the Citation resource itself", formalDefinition="A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance." ) 8641 protected List<Identifier> identifier; 8642 8643 /** 8644 * The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. 8645 */ 8646 @Child(name = "version", type = {StringType.class}, order=2, min=0, max=1, modifier=false, summary=true) 8647 @Description(shortDefinition="Business version of the citation", formalDefinition="The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence." ) 8648 protected StringType version; 8649 8650 /** 8651 * A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation. 8652 */ 8653 @Child(name = "name", type = {StringType.class}, order=3, min=0, max=1, modifier=false, summary=true) 8654 @Description(shortDefinition="Name for this citation (computer friendly)", formalDefinition="A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation." ) 8655 protected StringType name; 8656 8657 /** 8658 * A short, descriptive, user-friendly title for the citation. 8659 */ 8660 @Child(name = "title", type = {StringType.class}, order=4, min=0, max=1, modifier=false, summary=true) 8661 @Description(shortDefinition="Name for this citation (human friendly)", formalDefinition="A short, descriptive, user-friendly title for the citation." ) 8662 protected StringType title; 8663 8664 /** 8665 * The status of this summary. Enables tracking the life-cycle of the content. 8666 */ 8667 @Child(name = "status", type = {CodeType.class}, order=5, min=1, max=1, modifier=true, summary=true) 8668 @Description(shortDefinition="draft | active | retired | unknown", formalDefinition="The status of this summary. Enables tracking the life-cycle of the content." ) 8669 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/publication-status") 8670 protected Enumeration<PublicationStatus> status; 8671 8672 /** 8673 * A Boolean value to indicate that this citation is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage. 8674 */ 8675 @Child(name = "experimental", type = {BooleanType.class}, order=6, min=0, max=1, modifier=false, summary=true) 8676 @Description(shortDefinition="For testing purposes, not real usage", formalDefinition="A Boolean value to indicate that this citation is authored for testing purposes (or education/evaluation/marketing) and is not intended to be used for genuine usage." ) 8677 protected BooleanType experimental; 8678 8679 /** 8680 * The date (and optionally time) when the citation was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the citation changes. 8681 */ 8682 @Child(name = "date", type = {DateTimeType.class}, order=7, min=0, max=1, modifier=false, summary=true) 8683 @Description(shortDefinition="Date last changed", formalDefinition="The date (and optionally time) when the citation was published. The date must change when the business version changes and it must change if the status code changes. In addition, it should change when the substantive content of the citation changes." ) 8684 protected DateTimeType date; 8685 8686 /** 8687 * The name of the organization or individual that published the citation. 8688 */ 8689 @Child(name = "publisher", type = {StringType.class}, order=8, min=0, max=1, modifier=false, summary=true) 8690 @Description(shortDefinition="The publisher of the Citation, not the publisher of the article or artifact being cited", formalDefinition="The name of the organization or individual that published the citation." ) 8691 protected StringType publisher; 8692 8693 /** 8694 * Contact details to assist a user in finding and communicating with the publisher. 8695 */ 8696 @Child(name = "contact", type = {ContactDetail.class}, order=9, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 8697 @Description(shortDefinition="Contact details for the publisher of the Citation Resource", formalDefinition="Contact details to assist a user in finding and communicating with the publisher." ) 8698 protected List<ContactDetail> contact; 8699 8700 /** 8701 * A free text natural language description of the citation from a consumer's perspective. 8702 */ 8703 @Child(name = "description", type = {MarkdownType.class}, order=10, min=0, max=1, modifier=false, summary=false) 8704 @Description(shortDefinition="Natural language description of the citation", formalDefinition="A free text natural language description of the citation from a consumer's perspective." ) 8705 protected MarkdownType description; 8706 8707 /** 8708 * The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate citation instances. 8709 */ 8710 @Child(name = "useContext", type = {UsageContext.class}, order=11, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 8711 @Description(shortDefinition="The context that the Citation Resource content is intended to support", formalDefinition="The content was developed with a focus and intent of supporting the contexts that are listed. These contexts may be general categories (gender, age, ...) or may be references to specific programs (insurance plans, studies, ...) and may be used to assist with indexing and searching for appropriate citation instances." ) 8712 protected List<UsageContext> useContext; 8713 8714 /** 8715 * A legal or geographic region in which the citation is intended to be used. 8716 */ 8717 @Child(name = "jurisdiction", type = {CodeableConcept.class}, order=12, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=true) 8718 @Description(shortDefinition="Intended jurisdiction for citation (if applicable)", formalDefinition="A legal or geographic region in which the citation is intended to be used." ) 8719 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/jurisdiction") 8720 protected List<CodeableConcept> jurisdiction; 8721 8722 /** 8723 * Explanation of why this citation is needed and why it has been designed as it has. 8724 */ 8725 @Child(name = "purpose", type = {MarkdownType.class}, order=13, min=0, max=1, modifier=false, summary=false) 8726 @Description(shortDefinition="Why this citation is defined", formalDefinition="Explanation of why this citation is needed and why it has been designed as it has." ) 8727 protected MarkdownType purpose; 8728 8729 /** 8730 * Use and/or publishing restrictions for the Citation, not for the cited artifact. 8731 */ 8732 @Child(name = "copyright", type = {MarkdownType.class}, order=14, min=0, max=1, modifier=false, summary=false) 8733 @Description(shortDefinition="Use and/or publishing restrictions for the Citation, not for the cited artifact", formalDefinition="Use and/or publishing restrictions for the Citation, not for the cited artifact." ) 8734 protected MarkdownType copyright; 8735 8736 /** 8737 * The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage. 8738 */ 8739 @Child(name = "approvalDate", type = {DateType.class}, order=15, min=0, max=1, modifier=false, summary=false) 8740 @Description(shortDefinition="When the citation was approved by publisher", formalDefinition="The date on which the resource content was approved by the publisher. Approval happens once when the content is officially approved for usage." ) 8741 protected DateType approvalDate; 8742 8743 /** 8744 * The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date. 8745 */ 8746 @Child(name = "lastReviewDate", type = {DateType.class}, order=16, min=0, max=1, modifier=false, summary=false) 8747 @Description(shortDefinition="When the citation was last reviewed", formalDefinition="The date on which the resource content was last reviewed. Review happens periodically after approval but does not change the original approval date." ) 8748 protected DateType lastReviewDate; 8749 8750 /** 8751 * The period during which the citation content was or is planned to be in active use. 8752 */ 8753 @Child(name = "effectivePeriod", type = {Period.class}, order=17, min=0, max=1, modifier=false, summary=true) 8754 @Description(shortDefinition="When the citation is expected to be used", formalDefinition="The period during which the citation content was or is planned to be in active use." ) 8755 protected Period effectivePeriod; 8756 8757 /** 8758 * Who authored the Citation. 8759 */ 8760 @Child(name = "author", type = {ContactDetail.class}, order=18, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8761 @Description(shortDefinition="Who authored the Citation", formalDefinition="Who authored the Citation." ) 8762 protected List<ContactDetail> author; 8763 8764 /** 8765 * Who edited the Citation. 8766 */ 8767 @Child(name = "editor", type = {ContactDetail.class}, order=19, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8768 @Description(shortDefinition="Who edited the Citation", formalDefinition="Who edited the Citation." ) 8769 protected List<ContactDetail> editor; 8770 8771 /** 8772 * Who reviewed the Citation. 8773 */ 8774 @Child(name = "reviewer", type = {ContactDetail.class}, order=20, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8775 @Description(shortDefinition="Who reviewed the Citation", formalDefinition="Who reviewed the Citation." ) 8776 protected List<ContactDetail> reviewer; 8777 8778 /** 8779 * Who endorsed the Citation. 8780 */ 8781 @Child(name = "endorser", type = {ContactDetail.class}, order=21, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8782 @Description(shortDefinition="Who endorsed the Citation", formalDefinition="Who endorsed the Citation." ) 8783 protected List<ContactDetail> endorser; 8784 8785 /** 8786 * A human-readable display of the citation. 8787 */ 8788 @Child(name = "summary", type = {}, order=22, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8789 @Description(shortDefinition="A human-readable display of the citation", formalDefinition="A human-readable display of the citation." ) 8790 protected List<CitationSummaryComponent> summary; 8791 8792 /** 8793 * The assignment to an organizing scheme. 8794 */ 8795 @Child(name = "classification", type = {}, order=23, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8796 @Description(shortDefinition="The assignment to an organizing scheme", formalDefinition="The assignment to an organizing scheme." ) 8797 protected List<CitationClassificationComponent> classification; 8798 8799 /** 8800 * Used for general notes and annotations not coded elsewhere. 8801 */ 8802 @Child(name = "note", type = {Annotation.class}, order=24, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8803 @Description(shortDefinition="Used for general notes and annotations not coded elsewhere", formalDefinition="Used for general notes and annotations not coded elsewhere." ) 8804 protected List<Annotation> note; 8805 8806 /** 8807 * The status of the citation. 8808 */ 8809 @Child(name = "currentState", type = {CodeableConcept.class}, order=25, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8810 @Description(shortDefinition="The status of the citation", formalDefinition="The status of the citation." ) 8811 @ca.uhn.fhir.model.api.annotation.Binding(valueSet="http://hl7.org/fhir/ValueSet/citation-status-type") 8812 protected List<CodeableConcept> currentState; 8813 8814 /** 8815 * An effective date or period for a status of the citation. 8816 */ 8817 @Child(name = "statusDate", type = {}, order=26, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8818 @Description(shortDefinition="An effective date or period for a status of the citation", formalDefinition="An effective date or period for a status of the citation." ) 8819 protected List<CitationStatusDateComponent> statusDate; 8820 8821 /** 8822 * Artifact related to the Citation Resource. 8823 */ 8824 @Child(name = "relatedArtifact", type = {RelatedArtifact.class}, order=27, min=0, max=Child.MAX_UNLIMITED, modifier=false, summary=false) 8825 @Description(shortDefinition="Artifact related to the Citation Resource", formalDefinition="Artifact related to the Citation Resource." ) 8826 protected List<RelatedArtifact> relatedArtifact; 8827 8828 /** 8829 * The article or artifact being described. 8830 */ 8831 @Child(name = "citedArtifact", type = {}, order=28, min=0, max=1, modifier=false, summary=false) 8832 @Description(shortDefinition="The article or artifact being described", formalDefinition="The article or artifact being described." ) 8833 protected CitationCitedArtifactComponent citedArtifact; 8834 8835 private static final long serialVersionUID = 3140818L; 8836 8837 /** 8838 * Constructor 8839 */ 8840 public Citation() { 8841 super(); 8842 } 8843 8844 /** 8845 * Constructor 8846 */ 8847 public Citation(PublicationStatus status) { 8848 super(); 8849 this.setStatus(status); 8850 } 8851 8852 /** 8853 * @return {@link #url} (An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 8854 */ 8855 public UriType getUrlElement() { 8856 if (this.url == null) 8857 if (Configuration.errorOnAutoCreate()) 8858 throw new Error("Attempt to auto-create Citation.url"); 8859 else if (Configuration.doAutoCreate()) 8860 this.url = new UriType(); // bb 8861 return this.url; 8862 } 8863 8864 public boolean hasUrlElement() { 8865 return this.url != null && !this.url.isEmpty(); 8866 } 8867 8868 public boolean hasUrl() { 8869 return this.url != null && !this.url.isEmpty(); 8870 } 8871 8872 /** 8873 * @param value {@link #url} (An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers.). This is the underlying object with id, value and extensions. The accessor "getUrl" gives direct access to the value 8874 */ 8875 public Citation setUrlElement(UriType value) { 8876 this.url = value; 8877 return this; 8878 } 8879 8880 /** 8881 * @return An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers. 8882 */ 8883 public String getUrl() { 8884 return this.url == null ? null : this.url.getValue(); 8885 } 8886 8887 /** 8888 * @param value An absolute URI that is used to identify this citation when it is referenced in a specification, model, design or an instance; also called its canonical identifier. This SHOULD be globally unique and SHOULD be a literal address at which an authoritative instance of this summary is (or will be) published. This URL can be the target of a canonical reference. It SHALL remain the same when the summary is stored on different servers. 8889 */ 8890 public Citation setUrl(String value) { 8891 if (Utilities.noString(value)) 8892 this.url = null; 8893 else { 8894 if (this.url == null) 8895 this.url = new UriType(); 8896 this.url.setValue(value); 8897 } 8898 return this; 8899 } 8900 8901 /** 8902 * @return {@link #identifier} (A formal identifier that is used to identify this citation when it is represented in other formats, or referenced in a specification, model, design or an instance.) 8903 */ 8904 public List<Identifier> getIdentifier() { 8905 if (this.identifier == null) 8906 this.identifier = new ArrayList<Identifier>(); 8907 return this.identifier; 8908 } 8909 8910 /** 8911 * @return Returns a reference to <code>this</code> for easy method chaining 8912 */ 8913 public Citation setIdentifier(List<Identifier> theIdentifier) { 8914 this.identifier = theIdentifier; 8915 return this; 8916 } 8917 8918 public boolean hasIdentifier() { 8919 if (this.identifier == null) 8920 return false; 8921 for (Identifier item : this.identifier) 8922 if (!item.isEmpty()) 8923 return true; 8924 return false; 8925 } 8926 8927 public Identifier addIdentifier() { //3 8928 Identifier t = new Identifier(); 8929 if (this.identifier == null) 8930 this.identifier = new ArrayList<Identifier>(); 8931 this.identifier.add(t); 8932 return t; 8933 } 8934 8935 public Citation addIdentifier(Identifier t) { //3 8936 if (t == null) 8937 return this; 8938 if (this.identifier == null) 8939 this.identifier = new ArrayList<Identifier>(); 8940 this.identifier.add(t); 8941 return this; 8942 } 8943 8944 /** 8945 * @return The first repetition of repeating field {@link #identifier}, creating it if it does not already exist {3} 8946 */ 8947 public Identifier getIdentifierFirstRep() { 8948 if (getIdentifier().isEmpty()) { 8949 addIdentifier(); 8950 } 8951 return getIdentifier().get(0); 8952 } 8953 8954 /** 8955 * @return {@link #version} (The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 8956 */ 8957 public StringType getVersionElement() { 8958 if (this.version == null) 8959 if (Configuration.errorOnAutoCreate()) 8960 throw new Error("Attempt to auto-create Citation.version"); 8961 else if (Configuration.doAutoCreate()) 8962 this.version = new StringType(); // bb 8963 return this.version; 8964 } 8965 8966 public boolean hasVersionElement() { 8967 return this.version != null && !this.version.isEmpty(); 8968 } 8969 8970 public boolean hasVersion() { 8971 return this.version != null && !this.version.isEmpty(); 8972 } 8973 8974 /** 8975 * @param value {@link #version} (The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence.). This is the underlying object with id, value and extensions. The accessor "getVersion" gives direct access to the value 8976 */ 8977 public Citation setVersionElement(StringType value) { 8978 this.version = value; 8979 return this; 8980 } 8981 8982 /** 8983 * @return The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. 8984 */ 8985 public String getVersion() { 8986 return this.version == null ? null : this.version.getValue(); 8987 } 8988 8989 /** 8990 * @param value The identifier that is used to identify this version of the citation when it is referenced in a specification, model, design or instance. This is an arbitrary value managed by the citation author and is not expected to be globally unique. For example, it might be a timestamp (e.g. yyyymmdd) if a managed version is not available. There is also no expectation that versions can be placed in a lexicographical sequence. 8991 */ 8992 public Citation setVersion(String value) { 8993 if (Utilities.noString(value)) 8994 this.version = null; 8995 else { 8996 if (this.version == null) 8997 this.version = new StringType(); 8998 this.version.setValue(value); 8999 } 9000 return this; 9001 } 9002 9003 /** 9004 * @return {@link #name} (A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 9005 */ 9006 public StringType getNameElement() { 9007 if (this.name == null) 9008 if (Configuration.errorOnAutoCreate()) 9009 throw new Error("Attempt to auto-create Citation.name"); 9010 else if (Configuration.doAutoCreate()) 9011 this.name = new StringType(); // bb 9012 return this.name; 9013 } 9014 9015 public boolean hasNameElement() { 9016 return this.name != null && !this.name.isEmpty(); 9017 } 9018 9019 public boolean hasName() { 9020 return this.name != null && !this.name.isEmpty(); 9021 } 9022 9023 /** 9024 * @param value {@link #name} (A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation.). This is the underlying object with id, value and extensions. The accessor "getName" gives direct access to the value 9025 */ 9026 public Citation setNameElement(StringType value) { 9027 this.name = value; 9028 return this; 9029 } 9030 9031 /** 9032 * @return A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation. 9033 */ 9034 public String getName() { 9035 return this.name == null ? null : this.name.getValue(); 9036 } 9037 9038 /** 9039 * @param value A natural language name identifying the citation. This name should be usable as an identifier for the module by machine processing applications such as code generation. 9040 */ 9041 public Citation setName(String value) { 9042 if (Utilities.noString(value)) 9043 this.name = null; 9044 else { 9045 if (this.name == null) 9046 this.name = new StringType(); 9047 this.name.setValue(value); 9048 } 9049 return this; 9050 } 9051 9052 /** 9053 * @return {@link #title} (A short, descriptive, user-friendly title for the citation.). This is the underlying object with id, value and extensions. The accessor "getTitle" gives direct access to the value 9054 */ 9055 public StringType getTitleElement() { 9056 if (this.title == null) 9057 if (Configuration.errorOnAutoCreate()) 9058 throw new Error("Attempt to auto-create Citation.title"); 9059 else if (Configuration.doAutoCreate()) 9060 this.title = new StringType(); // bb 9061 return this.title; 9062 } 9063 9064 public boolean hasTitleElement() { 9065 return this.title != null && !this.title.isEmpty(); 9066 } 9067 9068 public boolean hasTitle() { 9069 return this.title != null && !this.title.isEmpty(); 9070 } 9071 9072 /** 9073 * @param value {@link #title} (A short, descriptive, user-friendly title for the citation.). This is the underlying object with id, value and extensions. The accessor "