Fix issue where .resolve() in FHIRPath didn't work with URL values (and fix typo in i18n system)
This commit is contained in:
parent
be9f5e0d36
commit
103984c10e
|
@ -3632,7 +3632,7 @@ public class FHIRPathEngine {
|
|||
}
|
||||
|
||||
private void checkContextReference(TypeDetails focus, String name, ExpressionNode expr) throws PathEngineException {
|
||||
if (!focus.hasType(worker, "string") && !focus.hasType(worker, "uri") && !focus.hasType(worker, "Reference") && !focus.hasType(worker, "canonical")) {
|
||||
if (!focus.hasType(worker, "string") && !focus.hasType(worker, "uri") && !focus.hasType(worker, "url") && !focus.hasType(worker, "Reference") && !focus.hasType(worker, "canonical")) {
|
||||
throw makeException(expr, I18nConstants.FHIRPATH_REFERENCE_ONLY, name, focus.describe());
|
||||
}
|
||||
}
|
||||
|
|
|
@ -10,7 +10,13 @@ public class ResourceSorters {
|
|||
|
||||
@Override
|
||||
public int compare(CanonicalResource arg0, CanonicalResource arg1) {
|
||||
return arg0.getUrl().compareTo(arg1.getUrl());
|
||||
if (arg0.getUrl() != null) {
|
||||
return arg0.getUrl().compareTo(arg1.getUrl());
|
||||
} else if (arg1.getUrl() != null) {
|
||||
return -arg1.getUrl().compareTo(arg0.getUrl());
|
||||
} else {
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -177,7 +177,7 @@ public class I18nConstants {
|
|||
public static final String FHIRPATH_ORDERED_ONLY = "FHIRPATH_ORDERED_ONLY";
|
||||
public static final String FHIRPATH_PARAM_WRONG = "FHIRPATH_PARAM_WRONG";
|
||||
public static final String FHIRPATH_PRIMITIVE_ONLY = "FHIRPATH_PRIMITIVE_ONLY";
|
||||
public static final String FHIRPATH_REFERENCE_ONLY = "FHIRPATH_ORDERED_ONLY";
|
||||
public static final String FHIRPATH_REFERENCE_ONLY = "FHIRPATH_REFERENCE_ONLY";
|
||||
public static final String FHIRPATH_RESOLVE_DISCRIMINATOR_CANT_FIND = "FHIRPATH_RESOLVE_DISCRIMINATOR_CANT_FIND";
|
||||
public static final String FHIRPATH_RESOLVE_DISCRIMINATOR_NO_TARGET = "FHIRPATH_RESOLVE_DISCRIMINATOR_NO_TARGET";
|
||||
public static final String FHIRPATH_RIGHT_VALUE = "FHIRPATH_RIGHT_VALUE";
|
||||
|
|
Loading…
Reference in New Issue