extracted: bpCheck|warningOrError|suppressedwarning|*Exception|Error

This commit is contained in:
patrick-werner 2020-03-01 20:28:53 +01:00
parent 3291aaf03a
commit ef65d09497
4 changed files with 171 additions and 48 deletions

View File

@ -197,17 +197,17 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
@Override @Override
public FunctionDetails resolveFunction(String functionName) { public FunctionDetails resolveFunction(String functionName) {
throw new Error("Not done yet (ValidatorHostServices.resolveFunction): " + functionName); throw new Error( I18nConstants.NOT_DONE_YET_VALIDATORHOSTSERVICESRESOLVEFUNCTION_, functionName);
} }
@Override @Override
public TypeDetails checkFunction(Object appContext, String functionName, List<TypeDetails> parameters) throws PathEngineException { public TypeDetails checkFunction(Object appContext, String functionName, List<TypeDetails> parameters) throws PathEngineException {
throw new Error("Not done yet (ValidatorHostServices.checkFunction)"); throw new Error( I18nConstants.NOT_DONE_YET_VALIDATORHOSTSERVICESCHECKFUNCTION);
} }
@Override @Override
public List<Base> executeFunction(Object appContext, String functionName, List<List<Base>> parameters) { public List<Base> executeFunction(Object appContext, String functionName, List<List<Base>> parameters) {
throw new Error("Not done yet (ValidatorHostServices.executeFunction)"); throw new Error( I18nConstants.NOT_DONE_YET_VALIDATORHOSTSERVICESEXECUTEFUNCTION);
} }
@Override @Override
@ -240,7 +240,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
throw new FHIRException(e); throw new FHIRException(e);
} }
else else
throw new Error("Not done yet - resolve " + url + " locally (2)"); throw new Error( I18nConstants.NOT_DONE_YET__RESOLVE__LOCALLY_2, url);
} }
@ -269,7 +269,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
ValidatorHostContext ctxt = (ValidatorHostContext) appContext; ValidatorHostContext ctxt = (ValidatorHostContext) appContext;
StructureDefinition sd = context.fetchResource(StructureDefinition.class, url); StructureDefinition sd = context.fetchResource(StructureDefinition.class, url);
if (sd == null) { if (sd == null) {
throw new FHIRException("Unable to resolve " + url); throw new FHIRException( I18nConstants.UNABLE_TO_RESOLVE_, url);
} }
InstanceValidator self = InstanceValidator.this; InstanceValidator self = InstanceValidator.this;
List<ValidationMessage> valerrors = new ArrayList<ValidationMessage>(); List<ValidationMessage> valerrors = new ArrayList<ValidationMessage>();
@ -285,10 +285,10 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
if (e.isResource()) { if (e.isResource()) {
self.validateResource(new ValidatorHostContext(ctxt.getAppContext(), e), valerrors, e, e, sd, IdStatus.OPTIONAL, new NodeStack(e)); self.validateResource(new ValidatorHostContext(ctxt.getAppContext(), e), valerrors, e, e, sd, IdStatus.OPTIONAL, new NodeStack(e));
} else { } else {
throw new FHIRException("Not supported yet"); throw new FHIRException( I18nConstants.NOT_SUPPORTED_YET);
} }
} else } else
throw new NotImplementedException("Not done yet (ValidatorHostServices.conformsToProfile), when item is not an element"); throw new NotImplementedException( I18nConstants.NOT_DONE_YET_VALIDATORHOSTSERVICESCONFORMSTOPROFILE_WHEN_ITEM_IS_NOT_AN_ELEMENT);
boolean ok = true; boolean ok = true;
List<ValidationMessage> record = new ArrayList<>(); List<ValidationMessage> record = new ArrayList<>();
for (ValidationMessage v : valerrors) { for (ValidationMessage v : valerrors) {
@ -312,7 +312,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
if (r instanceof ValueSet) if (r instanceof ValueSet)
return (ValueSet) r; return (ValueSet) r;
else else
throw new FHIRException("Reference " + url + " refers to a " + r.fhirType() + " not a ValueSet"); throw new FHIRException( I18nConstants.REFERENCE__REFERS_TO_A__NOT_A_VALUESET, url, r.fhirType());
} }
} }
return null; return null;
@ -513,7 +513,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
private StructureDefinition getSpecifiedProfile(String profile) { private StructureDefinition getSpecifiedProfile(String profile) {
StructureDefinition sd = context.fetchResource(StructureDefinition.class, profile); StructureDefinition sd = context.fetchResource(StructureDefinition.class, profile);
if (sd == null) { if (sd == null) {
throw new FHIRException("Unable to locate the profile '" + profile + "' in order to validate against it"); throw new FHIRException( I18nConstants.UNABLE_TO_LOCATE_THE_PROFILE__IN_ORDER_TO_VALIDATE_AGAINST_IT, profile);
} }
return sd; return sd;
} }
@ -1566,7 +1566,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
ok = true; ok = true;
} }
} else { } else {
throw new Error("Unrecognised extension context " + ctxt.getTypeElement().asStringValue()); throw new Error( I18nConstants.UNRECOGNISED_EXTENSION_CONTEXT_, ctxt.getTypeElement().asStringValue());
} }
} }
if (!ok) { if (!ok) {
@ -2092,7 +2092,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
if (we == null) { if (we == null) {
if (fetcher == null) { if (fetcher == null) {
if (!refType.equals("contained")) if (!refType.equals("contained"))
throw new FHIRException("Resource resolution services not provided"); throw new FHIRException( I18nConstants.RESOURCE_RESOLUTION_SERVICES_NOT_PROVIDED);
} else { } else {
Element ext = null; Element ext = null;
if (fetchCache.containsKey(ref)) { if (fetchCache.containsKey(ref)) {
@ -2477,7 +2477,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
String id = p.hasExtension(ToolingExtensions.EXT_PROFILE_ELEMENT) ? p.getExtensionString(ToolingExtensions.EXT_PROFILE_ELEMENT) : null; String id = p.hasExtension(ToolingExtensions.EXT_PROFILE_ELEMENT) ? p.getExtensionString(ToolingExtensions.EXT_PROFILE_ELEMENT) : null;
StructureDefinition sd = context.fetchResource(StructureDefinition.class, p.getValue()); StructureDefinition sd = context.fetchResource(StructureDefinition.class, p.getValue());
if (sd == null) if (sd == null)
throw new DefinitionException("Unable to resolve profile " + p); throw new DefinitionException( I18nConstants.UNABLE_TO_RESOLVE_PROFILE_, p);
profile = sd; profile = sd;
if (id == null) if (id == null)
element = sd.getSnapshot().getElementFirstRep(); element = sd.getSnapshot().getElementFirstRep();
@ -2488,7 +2488,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
element = t; element = t;
} }
if (element == null) if (element == null)
throw new DefinitionException("Unable to resolve element " + id + " in profile " + p); throw new DefinitionException( I18nConstants.UNABLE_TO_RESOLVE_ELEMENT__IN_PROFILE_, id, p);
} }
expr = fpe.parse(fixExpr(discriminator)); expr = fpe.parse(fixExpr(discriminator));
t2 = System.nanoTime(); t2 = System.nanoTime();
@ -2639,20 +2639,20 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
if (focus.fhirType().equals("Reference") && d.equals("reference")) { if (focus.fhirType().equals("Reference") && d.equals("reference")) {
String url = focus.getChildValue("reference"); String url = focus.getChildValue("reference");
if (Utilities.noString(url)) if (Utilities.noString(url))
throw new FHIRException("No reference resolving discriminator " + discriminator + " from " + element.getProperty().getName()); throw new FHIRException( I18nConstants.NO_REFERENCE_RESOLVING_DISCRIMINATOR__FROM_, discriminator, element.getProperty().getName());
// Note that we use the passed in stack here. This might be a problem if the discriminator is deep enough? // Note that we use the passed in stack here. This might be a problem if the discriminator is deep enough?
Element target = resolve(appContext, url, stack, errors, p); Element target = resolve(appContext, url, stack, errors, p);
if (target == null) if (target == null)
throw new FHIRException("Unable to find resource " + url + " at " + d + " resolving discriminator " + discriminator + " from " + element.getProperty().getName()); throw new FHIRException( I18nConstants.UNABLE_TO_FIND_RESOURCE__AT__RESOLVING_DISCRIMINATOR__FROM_, url, d, discriminator, element.getProperty().getName());
focus = target; focus = target;
} else if (d.equals("value") && focus.isPrimitive()) { } else if (d.equals("value") && focus.isPrimitive()) {
return focus; return focus;
} else { } else {
List<Element> children = focus.getChildren(d); List<Element> children = focus.getChildren(d);
if (children.isEmpty()) if (children.isEmpty())
throw new FHIRException("Unable to find " + d + " resolving discriminator " + discriminator + " from " + element.getProperty().getName()); throw new FHIRException( I18nConstants.UNABLE_TO_FIND__RESOLVING_DISCRIMINATOR__FROM_, d, discriminator, element.getProperty().getName());
if (children.size() > 1) if (children.size() > 1)
throw new FHIRException("Found " + Integer.toString(children.size()) + " items for " + d + " resolving discriminator " + discriminator + " from " + element.getProperty().getName()); throw new FHIRException( I18nConstants.FOUND__ITEMS_FOR__RESOLVING_DISCRIMINATOR__FROM_, Integer.toString(children.size()), d, discriminator, element.getProperty().getName());
focus = children.get(0); focus = children.get(0);
p = p + "." + d; p = p + "." + d;
} }
@ -3077,23 +3077,23 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
discriminator = discriminator.substring(0, discriminator.indexOf('[')); discriminator = discriminator.substring(0, discriminator.indexOf('['));
type = criteriaElement.getType().get(0).getWorkingCode(); type = criteriaElement.getType().get(0).getWorkingCode();
} else if (criteriaElement.getType().size() > 1) { } else if (criteriaElement.getType().size() > 1) {
throw new DefinitionException("Discriminator (" + discriminator + ") is based on type, but slice " + ed.getId() + " in " + profile.getUrl() + " has multiple types: " + criteriaElement.typeSummary()); throw new DefinitionException( I18nConstants.DISCRIMINATOR__IS_BASED_ON_TYPE_BUT_SLICE__IN__HAS_MULTIPLE_TYPES_, discriminator, ed.getId(), profile.getUrl(), criteriaElement.typeSummary());
} else } else
throw new DefinitionException("Discriminator (" + discriminator + ") is based on type, but slice " + ed.getId() + " in " + profile.getUrl() + " has no types"); throw new DefinitionException( I18nConstants.DISCRIMINATOR__IS_BASED_ON_TYPE_BUT_SLICE__IN__HAS_NO_TYPES, discriminator, ed.getId(), profile.getUrl());
if (discriminator.isEmpty()) if (discriminator.isEmpty())
expression.append(" and $this is " + type); expression.append(" and $this is " + type);
else else
expression.append(" and " + discriminator + " is " + type); expression.append(" and " + discriminator + " is " + type);
} else if (s.getType() == DiscriminatorType.PROFILE) { } else if (s.getType() == DiscriminatorType.PROFILE) {
if (criteriaElement.getType().size() == 0) { if (criteriaElement.getType().size() == 0) {
throw new DefinitionException("Profile based discriminators must have a type (" + criteriaElement.getId() + " in profile " + profile.getUrl() + ")"); throw new DefinitionException( I18nConstants.PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_A_TYPE__IN_PROFILE_, criteriaElement.getId(), profile.getUrl());
} }
if (criteriaElement.getType().size() != 1) { if (criteriaElement.getType().size() != 1) {
throw new DefinitionException("Profile based discriminators must have only one type (" + criteriaElement.getId() + " in profile " + profile.getUrl() + ")"); throw new DefinitionException( I18nConstants.PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_ONLY_ONE_TYPE__IN_PROFILE_, criteriaElement.getId(), profile.getUrl());
} }
List<CanonicalType> list = discriminator.endsWith(".resolve()") || discriminator.equals("resolve()") ? criteriaElement.getType().get(0).getTargetProfile() : criteriaElement.getType().get(0).getProfile(); List<CanonicalType> list = discriminator.endsWith(".resolve()") || discriminator.equals("resolve()") ? criteriaElement.getType().get(0).getTargetProfile() : criteriaElement.getType().get(0).getProfile();
if (list.size() == 0) { if (list.size() == 0) {
throw new DefinitionException("Profile based discriminators must have a type with a profile (" + criteriaElement.getId() + " in profile " + profile.getUrl() + ")"); throw new DefinitionException( I18nConstants.PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_A_TYPE_WITH_A_PROFILE__IN_PROFILE_, criteriaElement.getId(), profile.getUrl());
} else if (list.size() > 1) { } else if (list.size() > 1) {
CommaSeparatedStringBuilder b = new CommaSeparatedStringBuilder(" or "); CommaSeparatedStringBuilder b = new CommaSeparatedStringBuilder(" or ");
for (CanonicalType c : list) { for (CanonicalType c : list) {
@ -3109,7 +3109,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
else if (criteriaElement.hasMax() && criteriaElement.getMax().equals("0")) else if (criteriaElement.hasMax() && criteriaElement.getMax().equals("0"))
expression.append(" and (" + discriminator + ".exists().not())"); expression.append(" and (" + discriminator + ".exists().not())");
else else
throw new FHIRException("Discriminator (" + discriminator + ") is based on element existence, but slice " + ed.getId() + " neither sets min>=1 or max=0"); throw new FHIRException( I18nConstants.DISCRIMINATOR__IS_BASED_ON_ELEMENT_EXISTENCE_BUT_SLICE__NEITHER_SETS_MIN1_OR_MAX0, discriminator, ed.getId());
} else if (criteriaElement.hasFixed()) { } else if (criteriaElement.hasFixed()) {
buildFixedExpression(ed, expression, discriminator, criteriaElement); buildFixedExpression(ed, expression, discriminator, criteriaElement);
} else if (criteriaElement.hasPattern()) { } else if (criteriaElement.hasPattern()) {
@ -3127,15 +3127,15 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
} }
if (!anyFound) { if (!anyFound) {
if (slicer.getSlicing().getDiscriminator().size() > 1) if (slicer.getSlicing().getDiscriminator().size() > 1)
throw new DefinitionException("Could not match any discriminators (" + discriminators + ") for slice " + ed.getId() + " in profile " + profile.getUrl() + " - None of the discriminator " + discriminators + " have fixed value, binding or existence assertions"); throw new DefinitionException( I18nConstants.COULD_NOT_MATCH_ANY_DISCRIMINATORS__FOR_SLICE__IN_PROFILE___NONE_OF_THE_DISCRIMINATOR__HAVE_FIXED_VALUE_BINDING_OR_EXISTENCE_ASSERTIONS, discriminators, ed.getId(), profile.getUrl(), discriminators);
else else
throw new DefinitionException("Could not match discriminator (" + discriminators + ") for slice " + ed.getId() + " in profile " + profile.getUrl() + " - the discriminator " + discriminators + " does not have fixed value, binding or existence assertions"); throw new DefinitionException( I18nConstants.COULD_NOT_MATCH_DISCRIMINATOR__FOR_SLICE__IN_PROFILE___THE_DISCRIMINATOR__DOES_NOT_HAVE_FIXED_VALUE_BINDING_OR_EXISTENCE_ASSERTIONS, discriminators, ed.getId(), profile.getUrl(), discriminators);
} }
try { try {
n = fpe.parse(fixExpr(expression.toString())); n = fpe.parse(fixExpr(expression.toString()));
} catch (FHIRLexerException e) { } catch (FHIRLexerException e) {
throw new FHIRException("Problem processing expression " + expression + " in profile " + profile.getUrl() + " path " + path + ": " + e.getMessage()); throw new FHIRException( I18nConstants.PROBLEM_PROCESSING_EXPRESSION__IN_PROFILE__PATH__, expression, profile.getUrl(), path, e.getMessage());
} }
fpeTime = fpeTime + (System.nanoTime() - t); fpeTime = fpeTime + (System.nanoTime() - t);
ed.setUserData("slice.expression.cache", n); ed.setUserData("slice.expression.cache", n);
@ -3163,7 +3163,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
msg = fpe.forLog(); msg = fpe.forLog();
} catch (Exception ex) { } catch (Exception ex) {
ex.printStackTrace(); ex.printStackTrace();
throw new FHIRException("Problem evaluating slicing expression for element in profile " + profile.getUrl() + " path " + path + " (fhirPath = " + n + "): " + ex.getMessage()); throw new FHIRException( I18nConstants.PROBLEM_EVALUATING_SLICING_EXPRESSION_FOR_ELEMENT_IN_PROFILE__PATH__FHIRPATH___, profile.getUrl(), path, n, ex.getMessage());
} }
return ok; return ok;
} }
@ -3183,13 +3183,13 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
expression.append(" and "); expression.append(" and ");
buildIdentifierExpression(ed, expression, discriminator, ii); buildIdentifierExpression(ed, expression, discriminator, ii);
} else } else
throw new DefinitionException("Unsupported fixed pattern type for discriminator(" + discriminator + ") for slice " + ed.getId() + ": " + pattern.getClass().getName()); throw new DefinitionException( I18nConstants.UNSUPPORTED_FIXED_PATTERN_TYPE_FOR_DISCRIMINATOR_FOR_SLICE__, discriminator, ed.getId(), pattern.getClass().getName());
} }
private void buildIdentifierExpression(ElementDefinition ed, StringBuilder expression, String discriminator, Identifier ii) private void buildIdentifierExpression(ElementDefinition ed, StringBuilder expression, String discriminator, Identifier ii)
throws DefinitionException { throws DefinitionException {
if (ii.hasExtension()) if (ii.hasExtension())
throw new DefinitionException("Unsupported Identifier pattern - extensions are not allowed - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_IDENTIFIER_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
boolean first = true; boolean first = true;
expression.append(discriminator + ".where("); expression.append(discriminator + ".where(");
if (ii.hasSystem()) { if (ii.hasSystem()) {
@ -3223,15 +3223,15 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
private void buildCodeableConceptExpression(ElementDefinition ed, StringBuilder expression, String discriminator, CodeableConcept cc) private void buildCodeableConceptExpression(ElementDefinition ed, StringBuilder expression, String discriminator, CodeableConcept cc)
throws DefinitionException { throws DefinitionException {
if (cc.hasText()) if (cc.hasText())
throw new DefinitionException("Unsupported CodeableConcept pattern - using text - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_CODEABLECONCEPT_PATTERN__USING_TEXT__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
if (!cc.hasCoding()) if (!cc.hasCoding())
throw new DefinitionException("Unsupported CodeableConcept pattern - must have at least one coding - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_CODEABLECONCEPT_PATTERN__MUST_HAVE_AT_LEAST_ONE_CODING__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
if (cc.hasExtension()) if (cc.hasExtension())
throw new DefinitionException("Unsupported CodeableConcept pattern - extensions are not allowed - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_CODEABLECONCEPT_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
boolean firstCoding = true; boolean firstCoding = true;
for (Coding c : cc.getCoding()) { for (Coding c : cc.getCoding()) {
if (c.hasExtension()) if (c.hasExtension())
throw new DefinitionException("Unsupported CodeableConcept pattern - extensions are not allowed - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_CODEABLECONCEPT_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
if (firstCoding) firstCoding = false; if (firstCoding) firstCoding = false;
else expression.append(" and "); else expression.append(" and ");
expression.append(discriminator + ".coding.where("); expression.append(discriminator + ".coding.where(");
@ -3262,7 +3262,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
private void buildCodingExpression(ElementDefinition ed, StringBuilder expression, String discriminator, Coding c) private void buildCodingExpression(ElementDefinition ed, StringBuilder expression, String discriminator, Coding c)
throws DefinitionException { throws DefinitionException {
if (c.hasExtension()) if (c.hasExtension())
throw new DefinitionException("Unsupported CodeableConcept pattern - extensions are not allowed - for discriminator(" + discriminator + ") for slice " + ed.getId()); throw new DefinitionException( I18nConstants.UNSUPPORTED_CODEABLECONCEPT_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_, discriminator, ed.getId());
expression.append(discriminator + ".where("); expression.append(discriminator + ".where(");
boolean first = true; boolean first = true;
if (c.hasSystem()) { if (c.hasSystem()) {
@ -3318,7 +3318,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
} else if (fixed instanceof BooleanType) { } else if (fixed instanceof BooleanType) {
expression.append(((BooleanType) fixed).asStringValue()); expression.append(((BooleanType) fixed).asStringValue());
} else } else
throw new DefinitionException("Unsupported fixed value type for discriminator(" + discriminator + ") for slice " + ed.getId() + ": " + fixed.getClass().getName()); throw new DefinitionException( I18nConstants.UNSUPPORTED_FIXED_VALUE_TYPE_FOR_DISCRIMINATOR_FOR_SLICE__, discriminator, ed.getId(), fixed.getClass().getName());
expression.append(" in " + discriminator + ")"); expression.append(" in " + discriminator + ")");
} }
} }
@ -3680,7 +3680,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
byte[] json = bs.toByteArray(); byte[] json = bs.toByteArray();
switch (v) { switch (v) {
case DSTU1: case DSTU1:
throw new FHIRException("Unsupported version R1"); throw new FHIRException( I18nConstants.UNSUPPORTED_VERSION_R1);
case DSTU2: case DSTU2:
org.hl7.fhir.dstu2.model.Resource r2 = new org.hl7.fhir.dstu2.formats.JsonParser().parse(json); org.hl7.fhir.dstu2.model.Resource r2 = new org.hl7.fhir.dstu2.formats.JsonParser().parse(json);
Resource r5 = VersionConvertor_10_50.convertResource(r2); Resource r5 = VersionConvertor_10_50.convertResource(r2);
@ -4622,7 +4622,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
else else
dt = this.context.fetchResource(StructureDefinition.class, "http://hl7.org/fhir/StructureDefinition/" + actualType); dt = this.context.fetchResource(StructureDefinition.class, "http://hl7.org/fhir/StructureDefinition/" + actualType);
if (dt == null) if (dt == null)
throw new DefinitionException("Unable to resolve actual type " + actualType); throw new DefinitionException( I18nConstants.UNABLE_TO_RESOLVE_ACTUAL_TYPE_, actualType);
trackUsage(dt, hostContext, element); trackUsage(dt, hostContext, element);
childDefinitions = ProfileUtilities.getChildMap(dt, dt.getSnapshot().getElement().get(0)); childDefinitions = ProfileUtilities.getChildMap(dt, dt.getSnapshot().getElement().get(0));
@ -4980,7 +4980,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
String errorContext = "profile " + profile.getUrl(); String errorContext = "profile " + profile.getUrl();
if (!resource.getChildValue("id").isEmpty()) if (!resource.getChildValue("id").isEmpty())
errorContext += "; instance " + resource.getChildValue("id"); errorContext += "; instance " + resource.getChildValue("id");
throw new DefinitionException("Slice encountered midway through set (path = " + slicer.getPath() + ", id = " + slicer.getId() + "); " + errorContext); throw new DefinitionException( I18nConstants.SLICE_ENCOUNTERED_MIDWAY_THROUGH_SET_PATH___ID___, slicer.getPath(), slicer.getId(), errorContext);
} }
slicer = ed; slicer = ed;
process = false; process = false;
@ -5104,7 +5104,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
if (tail.equals(t.getId())) if (tail.equals(t.getId()))
return t; return t;
} }
throw new DefinitionException("Unable to find element with id '" + tail + "'"); throw new DefinitionException( I18nConstants.UNABLE_TO_FIND_ELEMENT_WITH_ID_, tail);
} }
private IdStatus idStatusForEntry(Element ep, ElementInfo ei) { private IdStatus idStatusForEntry(Element ep, ElementInfo ei) {
@ -5176,7 +5176,7 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
try { try {
n = fpe.parse(fixExpr(inv.getExpression())); n = fpe.parse(fixExpr(inv.getExpression()));
} catch (FHIRLexerException e) { } catch (FHIRLexerException e) {
throw new FHIRException("Problem processing expression " + inv.getExpression() + " in profile " + profile.getUrl() + " path " + path + ": " + e.getMessage()); throw new FHIRException( I18nConstants.PROBLEM_PROCESSING_EXPRESSION__IN_PROFILE__PATH__, inv.getExpression(), profile.getUrl(), path, e.getMessage());
} }
fpeTime = fpeTime + (System.nanoTime() - t); fpeTime = fpeTime + (System.nanoTime() - t);
inv.setUserData("validator.expression.cache", n); inv.setUserData("validator.expression.cache", n);
@ -5224,12 +5224,11 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
private void validateObservation(List<ValidationMessage> errors, Element element, NodeStack stack) { private void validateObservation(List<ValidationMessage> errors, Element element, NodeStack stack) {
// all observations should have a subject, a performer, and a time // all observations should have a subject, a performer, and a time
bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), element.getNamedChild("subject") != null, "All observations should have a subject"); bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), element.getNamedChild("subject") != null, I18nConstants.ALL_OBSERVATIONS_SHOULD_HAVE_A_SUBJECT);
List<Element> performers = new ArrayList<>(); List<Element> performers = new ArrayList<>();
element.getNamedChildren("performer", performers); element.getNamedChildren("performer", performers);
bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), performers.size() > 0, "All observations should have a performer"); bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), performers.size() > 0, I18nConstants.ALL_OBSERVATIONS_SHOULD_HAVE_A_PERFORMER);
bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), element.getNamedChild("effectiveDateTime") != null || element.getNamedChild("effectivePeriod") != null, bpCheck(errors, IssueType.INVALID, element.line(), element.col(), stack.getLiteralPath(), element.getNamedChild("effectiveDateTime") != null || element.getNamedChild("effectivePeriod") != null, I18nConstants.ALL_OBSERVATIONS_SHOULD_HAVE_AN_EFFECTIVEDATETIME_OR_AN_EFFECTIVEPERIOD);
"All observations should have an effectiveDateTime or an effectivePeriod");
} }
/* /*
@ -5316,9 +5315,9 @@ public class InstanceValidator extends BaseValidator implements IResourceValidat
checkFixedValue(msgs, "{virtual}", value, criteria.getFixed(), profile.getUrl(), "value", null); checkFixedValue(msgs, "{virtual}", value, criteria.getFixed(), profile.getUrl(), "value", null);
return msgs.size() == 0; return msgs.size() == 0;
} else if (criteria.hasBinding() && criteria.getBinding().getStrength() == BindingStrength.REQUIRED && criteria.getBinding().hasValueSet()) { } else if (criteria.hasBinding() && criteria.getBinding().getStrength() == BindingStrength.REQUIRED && criteria.getBinding().hasValueSet()) {
throw new FHIRException("Unable to resolve slice matching - slice matching by value set not done"); throw new FHIRException( I18nConstants.UNABLE_TO_RESOLVE_SLICE_MATCHING__SLICE_MATCHING_BY_VALUE_SET_NOT_DONE);
} else { } else {
throw new FHIRException("Unable to resolve slice matching - no fixed value or required value set"); throw new FHIRException( I18nConstants.UNABLE_TO_RESOLVE_SLICE_MATCHING__NO_FIXED_VALUE_OR_REQUIRED_VALUE_SET);
} }
} }

View File

@ -226,4 +226,46 @@ public class I18nConstants {
public final static String TERMINOLOGY_PASSTHROUGH_TX_MESSAGE = "Terminology_PassThrough_TX_Message"; public final static String TERMINOLOGY_PASSTHROUGH_TX_MESSAGE = "Terminology_PassThrough_TX_Message";
public final static String FIXED_TYPE_CHECKS_DT_ADDRESS_LINE = "Fixed_Type_Checks_DT_Address_Line"; public final static String FIXED_TYPE_CHECKS_DT_ADDRESS_LINE = "Fixed_Type_Checks_DT_Address_Line";
public final static String MUSTSUPPORT_VAL_MUSTSUPPORT = "MustSupport_VAL_MustSupport"; public final static String MUSTSUPPORT_VAL_MUSTSUPPORT = "MustSupport_VAL_MustSupport";
public final static String UNABLE_TO_RESOLVE_SLICE_MATCHING__NO_FIXED_VALUE_OR_REQUIRED_VALUE_SET = "Unable_to_resolve_slice_matching__no_fixed_value_or_required_value_set";
public final static String UNABLE_TO_RESOLVE_SLICE_MATCHING__SLICE_MATCHING_BY_VALUE_SET_NOT_DONE = "Unable_to_resolve_slice_matching__slice_matching_by_value_set_not_done";
public final static String ALL_OBSERVATIONS_SHOULD_HAVE_AN_EFFECTIVEDATETIME_OR_AN_EFFECTIVEPERIOD = "All_observations_should_have_an_effectiveDateTime_or_an_effectivePeriod";
public final static String ALL_OBSERVATIONS_SHOULD_HAVE_A_PERFORMER = "All_observations_should_have_a_performer";
public final static String ALL_OBSERVATIONS_SHOULD_HAVE_A_SUBJECT = "All_observations_should_have_a_subject";
public final static String PROBLEM_PROCESSING_EXPRESSION__IN_PROFILE__PATH__ = "Problem_processing_expression__in_profile__path__";
public final static String UNABLE_TO_FIND_ELEMENT_WITH_ID_ = "Unable_to_find_element_with_id_";
public final static String SLICE_ENCOUNTERED_MIDWAY_THROUGH_SET_PATH___ID___ = "Slice_encountered_midway_through_set_path___id___";
public final static String UNABLE_TO_RESOLVE_ACTUAL_TYPE_ = "Unable_to_resolve_actual_type_";
public final static String UNSUPPORTED_VERSION_R1 = "Unsupported_version_R1";
public final static String UNSUPPORTED_FIXED_VALUE_TYPE_FOR_DISCRIMINATOR_FOR_SLICE__ = "Unsupported_fixed_value_type_for_discriminator_for_slice__";
public final static String UNSUPPORTED_CODEABLECONCEPT_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_ = "Unsupported_CodeableConcept_pattern__extensions_are_not_allowed__for_discriminator_for_slice_";
public final static String UNSUPPORTED_CODEABLECONCEPT_PATTERN__MUST_HAVE_AT_LEAST_ONE_CODING__FOR_DISCRIMINATOR_FOR_SLICE_ = "Unsupported_CodeableConcept_pattern__must_have_at_least_one_coding__for_discriminator_for_slice_";
public final static String UNSUPPORTED_CODEABLECONCEPT_PATTERN__USING_TEXT__FOR_DISCRIMINATOR_FOR_SLICE_ = "Unsupported_CodeableConcept_pattern__using_text__for_discriminator_for_slice_";
public final static String UNSUPPORTED_IDENTIFIER_PATTERN__EXTENSIONS_ARE_NOT_ALLOWED__FOR_DISCRIMINATOR_FOR_SLICE_ = "Unsupported_Identifier_pattern__extensions_are_not_allowed__for_discriminator_for_slice_";
public final static String UNSUPPORTED_FIXED_PATTERN_TYPE_FOR_DISCRIMINATOR_FOR_SLICE__ = "Unsupported_fixed_pattern_type_for_discriminator_for_slice__";
public final static String PROBLEM_EVALUATING_SLICING_EXPRESSION_FOR_ELEMENT_IN_PROFILE__PATH__FHIRPATH___ = "Problem_evaluating_slicing_expression_for_element_in_profile__path__fhirPath___";
public final static String COULD_NOT_MATCH_DISCRIMINATOR__FOR_SLICE__IN_PROFILE___THE_DISCRIMINATOR__DOES_NOT_HAVE_FIXED_VALUE_BINDING_OR_EXISTENCE_ASSERTIONS = "Could_not_match_discriminator__for_slice__in_profile___the_discriminator__does_not_have_fixed_value_binding_or_existence_assertions";
public final static String COULD_NOT_MATCH_ANY_DISCRIMINATORS__FOR_SLICE__IN_PROFILE___NONE_OF_THE_DISCRIMINATOR__HAVE_FIXED_VALUE_BINDING_OR_EXISTENCE_ASSERTIONS = "Could_not_match_any_discriminators__for_slice__in_profile___None_of_the_discriminator__have_fixed_value_binding_or_existence_assertions";
public final static String DISCRIMINATOR__IS_BASED_ON_ELEMENT_EXISTENCE_BUT_SLICE__NEITHER_SETS_MIN1_OR_MAX0 = "Discriminator__is_based_on_element_existence_but_slice__neither_sets_min1_or_max0";
public final static String PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_A_TYPE_WITH_A_PROFILE__IN_PROFILE_ = "Profile_based_discriminators_must_have_a_type_with_a_profile__in_profile_";
public final static String PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_ONLY_ONE_TYPE__IN_PROFILE_ = "Profile_based_discriminators_must_have_only_one_type__in_profile_";
public final static String PROFILE_BASED_DISCRIMINATORS_MUST_HAVE_A_TYPE__IN_PROFILE_ = "Profile_based_discriminators_must_have_a_type__in_profile_";
public final static String DISCRIMINATOR__IS_BASED_ON_TYPE_BUT_SLICE__IN__HAS_NO_TYPES = "Discriminator__is_based_on_type_but_slice__in__has_no_types";
public final static String DISCRIMINATOR__IS_BASED_ON_TYPE_BUT_SLICE__IN__HAS_MULTIPLE_TYPES_ = "Discriminator__is_based_on_type_but_slice__in__has_multiple_types_";
public final static String FOUND__ITEMS_FOR__RESOLVING_DISCRIMINATOR__FROM_ = "Found__items_for__resolving_discriminator__from_";
public final static String UNABLE_TO_FIND__RESOLVING_DISCRIMINATOR__FROM_ = "Unable_to_find__resolving_discriminator__from_";
public final static String UNABLE_TO_FIND_RESOURCE__AT__RESOLVING_DISCRIMINATOR__FROM_ = "Unable_to_find_resource__at__resolving_discriminator__from_";
public final static String NO_REFERENCE_RESOLVING_DISCRIMINATOR__FROM_ = "No_reference_resolving_discriminator__from_";
public final static String UNABLE_TO_RESOLVE_ELEMENT__IN_PROFILE_ = "Unable_to_resolve_element__in_profile_";
public final static String UNABLE_TO_RESOLVE_PROFILE_ = "Unable_to_resolve_profile_";
public final static String RESOURCE_RESOLUTION_SERVICES_NOT_PROVIDED = "Resource_resolution_services_not_provided";
public final static String UNRECOGNISED_EXTENSION_CONTEXT_ = "Unrecognised_extension_context_";
public final static String UNABLE_TO_LOCATE_THE_PROFILE__IN_ORDER_TO_VALIDATE_AGAINST_IT = "Unable_to_locate_the_profile__in_order_to_validate_against_it";
public final static String REFERENCE__REFERS_TO_A__NOT_A_VALUESET = "Reference__refers_to_a__not_a_ValueSet";
public final static String NOT_DONE_YET_VALIDATORHOSTSERVICESCONFORMSTOPROFILE_WHEN_ITEM_IS_NOT_AN_ELEMENT = "Not_done_yet_ValidatorHostServicesconformsToProfile_when_item_is_not_an_element";
public final static String NOT_SUPPORTED_YET = "Not_supported_yet";
public final static String UNABLE_TO_RESOLVE_ = "Unable_to_resolve_";
public final static String NOT_DONE_YET__RESOLVE__LOCALLY_2 = "Not_done_yet__resolve__locally_2";
public final static String NOT_DONE_YET_VALIDATORHOSTSERVICESEXECUTEFUNCTION = "Not_done_yet_ValidatorHostServicesexecuteFunction";
public final static String NOT_DONE_YET_VALIDATORHOSTSERVICESCHECKFUNCTION = "Not_done_yet_ValidatorHostServicescheckFunction";
public final static String NOT_DONE_YET_VALIDATORHOSTSERVICESRESOLVEFUNCTION_ = "Not_done_yet_ValidatorHostServicesresolveFunction_";
} }

View File

@ -135,7 +135,6 @@ Type_Specific_Checks_DT_Date_Valid = Not a valid date ({0})
Type_Specific_Checks_DT_Time_Valid = Not a valid time ({0}) Type_Specific_Checks_DT_Time_Valid = Not a valid time ({0})
Type_Specific_Checks_DT_DateTime_Valid = Not a valid date/time ({0}) Type_Specific_Checks_DT_DateTime_Valid = Not a valid date/time ({0})
Type_Specific_Checks_DT_DateTime_TZ = if a date has a time, it must have a timezone Type_Specific_Checks_DT_DateTime_TZ = if a date has a time, it must have a timezone
Type_Specific_Checks_DT_DateTIme_Valid = Not a valid date time
Type_Specific_Checks_DT_String_Length = value is longer than permitted maximum length of 1 MB (1048576 bytes) Type_Specific_Checks_DT_String_Length = value is longer than permitted maximum length of 1 MB (1048576 bytes)
Type_Specific_Checks_DT_String_WS = value should not start or finish with whitespace Type_Specific_Checks_DT_String_WS = value should not start or finish with whitespace
Type_Specific_Checks_DT_Primitive_NotEmpty = @value cannot be empty Type_Specific_Checks_DT_Primitive_NotEmpty = @value cannot be empty
@ -224,3 +223,45 @@ Terminology_TX_System_Unknown = Unknown Code System '{0}'
Terminology_PassThrough_TX_Message = {0} for '{1}#{2}' Terminology_PassThrough_TX_Message = {0} for '{1}#{2}'
Fixed_Type_Checks_DT_Address_Line = Expected {0} but found {1} line elements Fixed_Type_Checks_DT_Address_Line = Expected {0} but found {1} line elements
MustSupport_VAL_MustSupport = The element {0} is not marked as 'mustSupport' in the profile {1}. Consider not using the element, or marking the element as must-Support in the profile MustSupport_VAL_MustSupport = The element {0} is not marked as 'mustSupport' in the profile {1}. Consider not using the element, or marking the element as must-Support in the profile
Unable_to_resolve_slice_matching__no_fixed_value_or_required_value_set = Unable to resolve slice matching - no fixed value or required value set
Unable_to_resolve_slice_matching__slice_matching_by_value_set_not_done = Unable to resolve slice matching - slice matching by value set not done
All_observations_should_have_an_effectiveDateTime_or_an_effectivePeriod = All observations should have an effectiveDateTime or an effectivePeriod
All_observations_should_have_a_performer = All observations should have a performer
All_observations_should_have_a_subject = All observations should have a subject
Problem_processing_expression__in_profile__path__ = Problem processing expression {0} in profile {1} path {2}: {3}
Unable_to_find_element_with_id_ = Unable to find element with id '{0}'
Slice_encountered_midway_through_set_path___id___ = Slice encountered midway through set (path = {0}, id = {1}); {2}
Unable_to_resolve_actual_type_ = Unable to resolve actual type {0}
Unsupported_version_R1 = Unsupported version R1
Unsupported_fixed_value_type_for_discriminator_for_slice__ = Unsupported fixed value type for discriminator({0}) for slice {1}: {2}
Unsupported_CodeableConcept_pattern__extensions_are_not_allowed__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - extensions are not allowed - for discriminator({0}) for slice {1}
Unsupported_CodeableConcept_pattern__must_have_at_least_one_coding__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - must have at least one coding - for discriminator({0}) for slice {1}
Unsupported_CodeableConcept_pattern__using_text__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - using text - for discriminator({0}) for slice {1}
Unsupported_Identifier_pattern__extensions_are_not_allowed__for_discriminator_for_slice_ = Unsupported Identifier pattern - extensions are not allowed - for discriminator({0}) for slice {1}
Unsupported_fixed_pattern_type_for_discriminator_for_slice__ = Unsupported fixed pattern type for discriminator({0}) for slice {1}: {2}
Problem_evaluating_slicing_expression_for_element_in_profile__path__fhirPath___ = Problem evaluating slicing expression for element in profile {0} path {1} (fhirPath = {2}): {3}
Could_not_match_discriminator__for_slice__in_profile___the_discriminator__does_not_have_fixed_value_binding_or_existence_assertions = Could not match discriminator ({0}) for slice {1} in profile {2} - the discriminator {3} does not have fixed value, binding or existence assertions
Could_not_match_any_discriminators__for_slice__in_profile___None_of_the_discriminator__have_fixed_value_binding_or_existence_assertions = Could not match any discriminators ({0}) for slice {1} in profile {2} - None of the discriminator {3} have fixed value, binding or existence assertions
Discriminator__is_based_on_element_existence_but_slice__neither_sets_min1_or_max0 = Discriminator ({0}) is based on element existence, but slice {1} neither sets min>=1 or max=0
Profile_based_discriminators_must_have_a_type_with_a_profile__in_profile_ = Profile based discriminators must have a type with a profile ({0} in profile {1})
Profile_based_discriminators_must_have_only_one_type__in_profile_ = Profile based discriminators must have only one type ({0} in profile {1})
Profile_based_discriminators_must_have_a_type__in_profile_ = Profile based discriminators must have a type ({0} in profile {1})
Discriminator__is_based_on_type_but_slice__in__has_no_types = Discriminator ({0}) is based on type, but slice {1} in {2} has no types
Discriminator__is_based_on_type_but_slice__in__has_multiple_types_ = Discriminator ({0}) is based on type, but slice {1} in {2} has multiple types: {3}
Found__items_for__resolving_discriminator__from_ = Found {0} items for {1} resolving discriminator {2} from {3}
Unable_to_find__resolving_discriminator__from_ = Unable to find {0} resolving discriminator {1} from {2}
Unable_to_find_resource__at__resolving_discriminator__from_ = Unable to find resource {0} at {1} resolving discriminator {2} from {3}
No_reference_resolving_discriminator__from_ = No reference resolving discriminator {0} from {1}
Unable_to_resolve_element__in_profile_ = Unable to resolve element {0} in profile {1}
Unable_to_resolve_profile_ = Unable to resolve profile {0}
Resource_resolution_services_not_provided = Resource resolution services not provided
Unrecognised_extension_context_ = Unrecognised extension context {0}
Unable_to_locate_the_profile__in_order_to_validate_against_it = Unable to locate the profile '{0}' in order to validate against it
Reference__refers_to_a__not_a_ValueSet = Reference {0} refers to a {1} not a ValueSet
Not_done_yet_ValidatorHostServicesconformsToProfile_when_item_is_not_an_element = Not done yet (ValidatorHostServices.conformsToProfile), when item is not an element
Not_supported_yet = Not supported yet
Unable_to_resolve_ = Unable to resolve {0}
Not_done_yet__resolve__locally_2 = Not done yet - resolve {0} locally (2)
Not_done_yet_ValidatorHostServicesexecuteFunction = Not done yet (ValidatorHostServices.executeFunction)
Not_done_yet_ValidatorHostServicescheckFunction = Not done yet (ValidatorHostServices.checkFunction)
Not_done_yet_ValidatorHostServicesresolveFunction_ = Not done yet (ValidatorHostServices.resolveFunction): {0}

View File

@ -135,7 +135,6 @@ Type_Specific_Checks_DT_Date_Valid = Not a valid date ({0})
Type_Specific_Checks_DT_Time_Valid = Not a valid time ({0}) Type_Specific_Checks_DT_Time_Valid = Not a valid time ({0})
Type_Specific_Checks_DT_DateTime_Valid = Not a valid date/time ({0}) Type_Specific_Checks_DT_DateTime_Valid = Not a valid date/time ({0})
Type_Specific_Checks_DT_DateTime_TZ = if a date has a time, it must have a timezone Type_Specific_Checks_DT_DateTime_TZ = if a date has a time, it must have a timezone
Type_Specific_Checks_DT_DateTIme_Valid = Not a valid date time
Type_Specific_Checks_DT_String_Length = value is longer than permitted maximum length of 1 MB (1048576 bytes) Type_Specific_Checks_DT_String_Length = value is longer than permitted maximum length of 1 MB (1048576 bytes)
Type_Specific_Checks_DT_String_WS = value should not start or finish with whitespace Type_Specific_Checks_DT_String_WS = value should not start or finish with whitespace
Type_Specific_Checks_DT_Primitive_NotEmpty = @value cannot be empty Type_Specific_Checks_DT_Primitive_NotEmpty = @value cannot be empty
@ -224,3 +223,45 @@ Terminology_TX_System_Unknown = Unknown Code System '{0}'
Terminology_PassThrough_TX_Message = {0} for '{1}#{2}' Terminology_PassThrough_TX_Message = {0} for '{1}#{2}'
Fixed_Type_Checks_DT_Address_Line = Expected {0} but found {1} line elements Fixed_Type_Checks_DT_Address_Line = Expected {0} but found {1} line elements
MustSupport_VAL_MustSupport = The element {0} is not marked as 'mustSupport' in the profile {1}. Consider not using the element, or marking the element as must-Support in the profile MustSupport_VAL_MustSupport = The element {0} is not marked as 'mustSupport' in the profile {1}. Consider not using the element, or marking the element as must-Support in the profile
Unable_to_resolve_slice_matching__no_fixed_value_or_required_value_set = Unable to resolve slice matching - no fixed value or required value set
Unable_to_resolve_slice_matching__slice_matching_by_value_set_not_done = Unable to resolve slice matching - slice matching by value set not done
All_observations_should_have_an_effectiveDateTime_or_an_effectivePeriod = All observations should have an effectiveDateTime or an effectivePeriod
All_observations_should_have_a_performer = All observations should have a performer
All_observations_should_have_a_subject = All observations should have a subject
Problem_processing_expression__in_profile__path__ = Problem processing expression {0} in profile {1} path {2}: {3}
Unable_to_find_element_with_id_ = Unable to find element with id '{0}'
Slice_encountered_midway_through_set_path___id___ = Slice encountered midway through set (path = {0}, id = {1}); {2}
Unable_to_resolve_actual_type_ = Unable to resolve actual type {0}
Unsupported_version_R1 = Unsupported version R1
Unsupported_fixed_value_type_for_discriminator_for_slice__ = Unsupported fixed value type for discriminator({0}) for slice {1}: {2}
Unsupported_CodeableConcept_pattern__extensions_are_not_allowed__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - extensions are not allowed - for discriminator({0}) for slice {1}
Unsupported_CodeableConcept_pattern__must_have_at_least_one_coding__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - must have at least one coding - for discriminator({0}) for slice {1}
Unsupported_CodeableConcept_pattern__using_text__for_discriminator_for_slice_ = Unsupported CodeableConcept pattern - using text - for discriminator({0}) for slice {1}
Unsupported_Identifier_pattern__extensions_are_not_allowed__for_discriminator_for_slice_ = Unsupported Identifier pattern - extensions are not allowed - for discriminator({0}) for slice {1}
Unsupported_fixed_pattern_type_for_discriminator_for_slice__ = Unsupported fixed pattern type for discriminator({0}) for slice {1}: {2}
Problem_evaluating_slicing_expression_for_element_in_profile__path__fhirPath___ = Problem evaluating slicing expression for element in profile {0} path {1} (fhirPath = {2}): {3}
Could_not_match_discriminator__for_slice__in_profile___the_discriminator__does_not_have_fixed_value_binding_or_existence_assertions = Could not match discriminator ({0}) for slice {1} in profile {2} - the discriminator {3} does not have fixed value, binding or existence assertions
Could_not_match_any_discriminators__for_slice__in_profile___None_of_the_discriminator__have_fixed_value_binding_or_existence_assertions = Could not match any discriminators ({0}) for slice {1} in profile {2} - None of the discriminator {3} have fixed value, binding or existence assertions
Discriminator__is_based_on_element_existence_but_slice__neither_sets_min1_or_max0 = Discriminator ({0}) is based on element existence, but slice {1} neither sets min>=1 or max=0
Profile_based_discriminators_must_have_a_type_with_a_profile__in_profile_ = Profile based discriminators must have a type with a profile ({0} in profile {1})
Profile_based_discriminators_must_have_only_one_type__in_profile_ = Profile based discriminators must have only one type ({0} in profile {1})
Profile_based_discriminators_must_have_a_type__in_profile_ = Profile based discriminators must have a type ({0} in profile {1})
Discriminator__is_based_on_type_but_slice__in__has_no_types = Discriminator ({0}) is based on type, but slice {1} in {2} has no types
Discriminator__is_based_on_type_but_slice__in__has_multiple_types_ = Discriminator ({0}) is based on type, but slice {1} in {2} has multiple types: {3}
Found__items_for__resolving_discriminator__from_ = Found {0} items for {1} resolving discriminator {2} from {3}
Unable_to_find__resolving_discriminator__from_ = Unable to find {0} resolving discriminator {1} from {2}
Unable_to_find_resource__at__resolving_discriminator__from_ = Unable to find resource {0} at {1} resolving discriminator {2} from {3}
No_reference_resolving_discriminator__from_ = No reference resolving discriminator {0} from {1}
Unable_to_resolve_element__in_profile_ = Unable to resolve element {0} in profile {1}
Unable_to_resolve_profile_ = Unable to resolve profile {0}
Resource_resolution_services_not_provided = Resource resolution services not provided
Unrecognised_extension_context_ = Unrecognised extension context {0}
Unable_to_locate_the_profile__in_order_to_validate_against_it = Unable to locate the profile '{0}' in order to validate against it
Reference__refers_to_a__not_a_ValueSet = Reference {0} refers to a {1} not a ValueSet
Not_done_yet_ValidatorHostServicesconformsToProfile_when_item_is_not_an_element = Not done yet (ValidatorHostServices.conformsToProfile), when item is not an element
Not_supported_yet = Not supported yet
Unable_to_resolve_ = Unable to resolve {0}
Not_done_yet__resolve__locally_2 = Not done yet - resolve {0} locally (2)
Not_done_yet_ValidatorHostServicesexecuteFunction = Not done yet (ValidatorHostServices.executeFunction)
Not_done_yet_ValidatorHostServicescheckFunction = Not done yet (ValidatorHostServices.checkFunction)
Not_done_yet_ValidatorHostServicesresolveFunction_ = Not done yet (ValidatorHostServices.resolveFunction): {0}