001package org.hl7.fhir.dstu2016may.model.codesystems; 002 003 004 005 006/* 007 Copyright (c) 2011+, HL7, Inc. 008 All rights reserved. 009 010 Redistribution and use in source and binary forms, with or without modification, 011 are permitted provided that the following conditions are met: 012 013 * Redistributions of source code must retain the above copyright notice, this 014 list of conditions and the following disclaimer. 015 * Redistributions in binary form must reproduce the above copyright notice, 016 this list of conditions and the following disclaimer in the documentation 017 and/or other materials provided with the distribution. 018 * Neither the name of HL7 nor the names of its contributors may be used to 019 endorse or promote products derived from this software without specific 020 prior written permission. 021 022 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND 023 ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 024 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. 025 IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, 026 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT 027 NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR 028 PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, 029 WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 030 ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 031 POSSIBILITY OF SUCH DAMAGE. 032 033*/ 034 035// Generated on Sun, May 8, 2016 03:05+1000 for FHIR v1.4.0 036 037 038import org.hl7.fhir.exceptions.FHIRException; 039 040public enum TestscriptOperationCodes { 041 042 /** 043 * Read the current state of the resource. 044 */ 045 READ, 046 /** 047 * Read the state of a specific version of the resource. 048 */ 049 VREAD, 050 /** 051 * Update an existing resource by its id (or create it if it is new). 052 */ 053 UPDATE, 054 /** 055 * Delete a resource. 056 */ 057 DELETE, 058 /** 059 * Retrieve the change history for a particular resource or resource type. 060 */ 061 HISTORY, 062 /** 063 * Create a new resource with a server assigned id. 064 */ 065 CREATE, 066 /** 067 * Search based on some filter criteria. 068 */ 069 SEARCH, 070 /** 071 * Update, create or delete a set of resources as independent actions. 072 */ 073 BATCH, 074 /** 075 * Update, create or delete a set of resources as a single transaction. 076 */ 077 TRANSACTION, 078 /** 079 * Get a conformance statement for the system. 080 */ 081 CONFORMANCE, 082 /** 083 * Cancel Task 084 */ 085 CANCEL, 086 /** 087 * The CDS Hook operation is the core API request for CDS Hooks 088 */ 089 CDSHOOK, 090 /** 091 * Closure Table Maintenance 092 */ 093 CLOSURE, 094 /** 095 * Generate a Document 096 */ 097 DOCUMENT, 098 /** 099 * Evaluate DecisionSupportRule / DecisionSupportServiceModule 100 */ 101 EVALUATE, 102 /** 103 * Evaluate Measure 104 */ 105 EVALUATEMEASURE, 106 /** 107 * Fetch Encounter/Patient Record 108 */ 109 EVERYTHING, 110 /** 111 * Value Set Expansion 112 */ 113 EXPAND, 114 /** 115 * Fail Task 116 */ 117 FAIL, 118 /** 119 * Find a functional list 120 */ 121 FIND, 122 /** 123 * Finish Task 124 */ 125 FINISH, 126 /** 127 * Concept Look Up 128 */ 129 LOOKUP, 130 /** 131 * Find patient matches using MPI based logic 132 */ 133 MATCH, 134 /** 135 * Access a list of profiles, tags, and security labels 136 */ 137 META, 138 /** 139 * Add profiles, tags, and security labels to a resource 140 */ 141 METAADD, 142 /** 143 * Delete profiles, tags, and security labels for a resource 144 */ 145 METADELETE, 146 /** 147 * Place OrderSet 148 */ 149 PLACE, 150 /** 151 * Populate Questionnaire 152 */ 153 POPULATE, 154 /** 155 * Process Message 156 */ 157 PROCESSMESSAGE, 158 /** 159 * Build Questionnaire 160 */ 161 QUESTIONNAIRE, 162 /** 163 * Release Task 164 */ 165 RELEASE, 166 /** 167 * Reserve Task 168 */ 169 RESERVE, 170 /** 171 * Resume Task 172 */ 173 RESUME, 174 /** 175 * Set Task Input 176 */ 177 SETINPUT, 178 /** 179 * Set Task Output 180 */ 181 SETOUTPUT, 182 /** 183 * Start Task 184 */ 185 START, 186 /** 187 * Stop Task 188 */ 189 STOP, 190 /** 191 * Suspend Task 192 */ 193 SUSPEND, 194 /** 195 * Concept Translation 196 */ 197 TRANSLATE, 198 /** 199 * Validate a resource 200 */ 201 VALIDATE, 202 /** 203 * Value Set based Validation 204 */ 205 VALIDATECODE, 206 /** 207 * added to help the parsers 208 */ 209 NULL; 210 public static TestscriptOperationCodes fromCode(String codeString) throws FHIRException { 211 if (codeString == null || "".equals(codeString)) 212 return null; 213 if ("read".equals(codeString)) 214 return READ; 215 if ("vread".equals(codeString)) 216 return VREAD; 217 if ("update".equals(codeString)) 218 return UPDATE; 219 if ("delete".equals(codeString)) 220 return DELETE; 221 if ("history".equals(codeString)) 222 return HISTORY; 223 if ("create".equals(codeString)) 224 return CREATE; 225 if ("search".equals(codeString)) 226 return SEARCH; 227 if ("batch".equals(codeString)) 228 return BATCH; 229 if ("transaction".equals(codeString)) 230 return TRANSACTION; 231 if ("conformance".equals(codeString)) 232 return CONFORMANCE; 233 if ("cancel".equals(codeString)) 234 return CANCEL; 235 if ("cds-hook".equals(codeString)) 236 return CDSHOOK; 237 if ("closure".equals(codeString)) 238 return CLOSURE; 239 if ("document".equals(codeString)) 240 return DOCUMENT; 241 if ("evaluate".equals(codeString)) 242 return EVALUATE; 243 if ("evaluate-measure".equals(codeString)) 244 return EVALUATEMEASURE; 245 if ("everything".equals(codeString)) 246 return EVERYTHING; 247 if ("expand".equals(codeString)) 248 return EXPAND; 249 if ("fail".equals(codeString)) 250 return FAIL; 251 if ("find".equals(codeString)) 252 return FIND; 253 if ("finish".equals(codeString)) 254 return FINISH; 255 if ("lookup".equals(codeString)) 256 return LOOKUP; 257 if ("match".equals(codeString)) 258 return MATCH; 259 if ("meta".equals(codeString)) 260 return META; 261 if ("meta-add".equals(codeString)) 262 return METAADD; 263 if ("meta-delete".equals(codeString)) 264 return METADELETE; 265 if ("place".equals(codeString)) 266 return PLACE; 267 if ("populate".equals(codeString)) 268 return POPULATE; 269 if ("process-message".equals(codeString)) 270 return PROCESSMESSAGE; 271 if ("questionnaire".equals(codeString)) 272 return QUESTIONNAIRE; 273 if ("release".equals(codeString)) 274 return RELEASE; 275 if ("reserve".equals(codeString)) 276 return RESERVE; 277 if ("resume".equals(codeString)) 278 return RESUME; 279 if ("set-input".equals(codeString)) 280 return SETINPUT; 281 if ("set-output".equals(codeString)) 282 return SETOUTPUT; 283 if ("start".equals(codeString)) 284 return START; 285 if ("stop".equals(codeString)) 286 return STOP; 287 if ("suspend".equals(codeString)) 288 return SUSPEND; 289 if ("translate".equals(codeString)) 290 return TRANSLATE; 291 if ("validate".equals(codeString)) 292 return VALIDATE; 293 if ("validate-code".equals(codeString)) 294 return VALIDATECODE; 295 throw new FHIRException("Unknown TestscriptOperationCodes code '"+codeString+"'"); 296 } 297 public String toCode() { 298 switch (this) { 299 case READ: return "read"; 300 case VREAD: return "vread"; 301 case UPDATE: return "update"; 302 case DELETE: return "delete"; 303 case HISTORY: return "history"; 304 case CREATE: return "create"; 305 case SEARCH: return "search"; 306 case BATCH: return "batch"; 307 case TRANSACTION: return "transaction"; 308 case CONFORMANCE: return "conformance"; 309 case CANCEL: return "cancel"; 310 case CDSHOOK: return "cds-hook"; 311 case CLOSURE: return "closure"; 312 case DOCUMENT: return "document"; 313 case EVALUATE: return "evaluate"; 314 case EVALUATEMEASURE: return "evaluate-measure"; 315 case EVERYTHING: return "everything"; 316 case EXPAND: return "expand"; 317 case FAIL: return "fail"; 318 case FIND: return "find"; 319 case FINISH: return "finish"; 320 case LOOKUP: return "lookup"; 321 case MATCH: return "match"; 322 case META: return "meta"; 323 case METAADD: return "meta-add"; 324 case METADELETE: return "meta-delete"; 325 case PLACE: return "place"; 326 case POPULATE: return "populate"; 327 case PROCESSMESSAGE: return "process-message"; 328 case QUESTIONNAIRE: return "questionnaire"; 329 case RELEASE: return "release"; 330 case RESERVE: return "reserve"; 331 case RESUME: return "resume"; 332 case SETINPUT: return "set-input"; 333 case SETOUTPUT: return "set-output"; 334 case START: return "start"; 335 case STOP: return "stop"; 336 case SUSPEND: return "suspend"; 337 case TRANSLATE: return "translate"; 338 case VALIDATE: return "validate"; 339 case VALIDATECODE: return "validate-code"; 340 case NULL: return null; 341 default: return "?"; 342 } 343 } 344 public String getSystem() { 345 return "http://hl7.org/fhir/testscript-operation-codes"; 346 } 347 public String getDefinition() { 348 switch (this) { 349 case READ: return "Read the current state of the resource."; 350 case VREAD: return "Read the state of a specific version of the resource."; 351 case UPDATE: return "Update an existing resource by its id (or create it if it is new)."; 352 case DELETE: return "Delete a resource."; 353 case HISTORY: return "Retrieve the change history for a particular resource or resource type."; 354 case CREATE: return "Create a new resource with a server assigned id."; 355 case SEARCH: return "Search based on some filter criteria."; 356 case BATCH: return "Update, create or delete a set of resources as independent actions."; 357 case TRANSACTION: return "Update, create or delete a set of resources as a single transaction."; 358 case CONFORMANCE: return "Get a conformance statement for the system."; 359 case CANCEL: return "Cancel Task"; 360 case CDSHOOK: return "The CDS Hook operation is the core API request for CDS Hooks"; 361 case CLOSURE: return "Closure Table Maintenance"; 362 case DOCUMENT: return "Generate a Document"; 363 case EVALUATE: return "Evaluate DecisionSupportRule / DecisionSupportServiceModule"; 364 case EVALUATEMEASURE: return "Evaluate Measure"; 365 case EVERYTHING: return "Fetch Encounter/Patient Record"; 366 case EXPAND: return "Value Set Expansion"; 367 case FAIL: return "Fail Task"; 368 case FIND: return "Find a functional list"; 369 case FINISH: return "Finish Task"; 370 case LOOKUP: return "Concept Look Up"; 371 case MATCH: return "Find patient matches using MPI based logic"; 372 case META: return "Access a list of profiles, tags, and security labels"; 373 case METAADD: return "Add profiles, tags, and security labels to a resource"; 374 case METADELETE: return "Delete profiles, tags, and security labels for a resource"; 375 case PLACE: return "Place OrderSet"; 376 case POPULATE: return "Populate Questionnaire"; 377 case PROCESSMESSAGE: return "Process Message"; 378 case QUESTIONNAIRE: return "Build Questionnaire"; 379 case RELEASE: return "Release Task"; 380 case RESERVE: return "Reserve Task"; 381 case RESUME: return "Resume Task"; 382 case SETINPUT: return "Set Task Input"; 383 case SETOUTPUT: return "Set Task Output"; 384 case START: return "Start Task"; 385 case STOP: return "Stop Task"; 386 case SUSPEND: return "Suspend Task"; 387 case TRANSLATE: return "Concept Translation"; 388 case VALIDATE: return "Validate a resource"; 389 case VALIDATECODE: return "Value Set based Validation"; 390 case NULL: return null; 391 default: return "?"; 392 } 393 } 394 public String getDisplay() { 395 switch (this) { 396 case READ: return "Read"; 397 case VREAD: return "Version Read"; 398 case UPDATE: return "Update"; 399 case DELETE: return "Delete"; 400 case HISTORY: return "History"; 401 case CREATE: return "Create"; 402 case SEARCH: return "Search"; 403 case BATCH: return "Batch"; 404 case TRANSACTION: return "Transaction"; 405 case CONFORMANCE: return "Conformance"; 406 case CANCEL: return "$cancel"; 407 case CDSHOOK: return "$cds-hook"; 408 case CLOSURE: return "$closure"; 409 case DOCUMENT: return "$document"; 410 case EVALUATE: return "$evaluate"; 411 case EVALUATEMEASURE: return "$evaluate-measure"; 412 case EVERYTHING: return "$everything"; 413 case EXPAND: return "$expand"; 414 case FAIL: return "$fail"; 415 case FIND: return "$find"; 416 case FINISH: return "$finish"; 417 case LOOKUP: return "$lookup"; 418 case MATCH: return "$match"; 419 case META: return "$meta"; 420 case METAADD: return "$meta-add"; 421 case METADELETE: return "$meta-delete"; 422 case PLACE: return "$place"; 423 case POPULATE: return "$populate"; 424 case PROCESSMESSAGE: return "$process-message"; 425 case QUESTIONNAIRE: return "$questionnaire"; 426 case RELEASE: return "$release"; 427 case RESERVE: return "$reserve"; 428 case RESUME: return "$resume"; 429 case SETINPUT: return "$set-input"; 430 case SETOUTPUT: return "$set-output"; 431 case START: return "$start"; 432 case STOP: return "$stop"; 433 case SUSPEND: return "$suspend"; 434 case TRANSLATE: return "$translate"; 435 case VALIDATE: return "$validate"; 436 case VALIDATECODE: return "$validate-code"; 437 case NULL: return null; 438 default: return "?"; 439 } 440 } 441 442 443}