
001package org.hl7.fhir.r5.terminologies.utilities; 002 003import org.hl7.fhir.r5.model.Coding; 004import org.hl7.fhir.r5.model.ValueSet; 005import org.hl7.fhir.r5.terminologies.utilities.TerminologyCache.CacheToken; 006import org.hl7.fhir.utilities.MarkedToMoveToAdjunctPackage; 007 008@MarkedToMoveToAdjunctPackage 009public class CodingValidationRequest { 010 private Coding coding; 011 private ValidationResult result; 012 private CacheToken cacheToken; 013 private String vs; 014 private ValueSet vsObj; 015 016 public CodingValidationRequest(Coding coding) { 017 super(); 018 this.coding = coding; 019 } 020 021 public CodingValidationRequest(Coding coding, String vs) { 022 super(); 023 this.coding = coding; 024 this.vs = vs; 025 } 026 027 public CodingValidationRequest(Coding coding, ValueSet vsObj) { 028 super(); 029 this.coding = coding; 030 this.vsObj = vsObj; 031 } 032 033 public String getVs() { 034 return vs; 035 } 036 037 public ValueSet getVsObj() { 038 return vsObj; 039 } 040 041 public ValidationResult getResult() { 042 return result; 043 } 044 045 public void setResult(ValidationResult result) { 046 this.result = result; 047 } 048 049 public Coding getCoding() { 050 return coding; 051 } 052 053 public boolean hasResult() { 054 return result != null; 055 } 056 057 /** 058 * internal logic; external users of batch validation should ignore this property 059 * 060 * @return 061 */ 062 public CacheToken getCacheToken() { 063 return cacheToken; 064 } 065 066 /** 067 * internal logic; external users of batch validation should ignore this property 068 * 069 * @param cacheToken 070 */ 071 public void setCacheToken(CacheToken cacheToken) { 072 this.cacheToken = cacheToken; 073 } 074 075 076}