properly handle...

This commit is contained in:
Grahame Grieve 2023-05-29 01:13:45 +03:00
parent cba782fcb3
commit fe474b1ad2
2 changed files with 17 additions and 0 deletions

View File

@ -385,5 +385,21 @@ public class ValueSetUtilities {
return code;
}
public static int countExpansion(ValueSet valueset) {
int i = valueset.getExpansion().getContains().size();
for (ValueSetExpansionContainsComponent t : valueset.getExpansion().getContains()) {
i = i + countExpansion(t);
}
return i;
}
private static int countExpansion(ValueSetExpansionContainsComponent c) {
int i = c.getContains().size();
for (ValueSetExpansionContainsComponent t : c.getContains()) {
i = i + countExpansion(t);
}
return i;
}
}

View File

@ -493,6 +493,7 @@ public class ValueSetValidator {
res.getIssues().addAll(makeIssue(IssueSeverity.WARNING, IssueType.NOTFOUND, path, m));
res.setUnknownSystems(unknownSystems);
res.setSeverity(IssueSeverity.ERROR); // back patching for display logic issue
res.setErrorClass(TerminologyServiceErrorClass.CODESYSTEM_UNSUPPORTED);
} else if (!inExpansion && !inInclude) {
// if (!info.getIssues().isEmpty()) {
// res.setMessage("Not in value set "+valueset.getUrl()+": "+info.summary()).setSeverity(IssueSeverity.ERROR);