Don't load resources from core examples package
This commit is contained in:
parent
42aef4ad40
commit
db0413c735
|
@ -2,8 +2,11 @@
|
||||||
|
|
||||||
* Fix invalid integer detection
|
* Fix invalid integer detection
|
||||||
* Improved invariant checking
|
* Improved invariant checking
|
||||||
|
* Create warnings for status on terminology resources
|
||||||
|
|
||||||
## Other code changes
|
## Other code changes
|
||||||
|
|
||||||
* Update obligation handling code for split definitions
|
* Update obligation handling code for split definitions
|
||||||
* Update ICF importer to handle grouping levels
|
* Update ICF importer to handle grouping levels
|
||||||
|
* fix up copy directory for case differences
|
||||||
|
|
||||||
|
|
|
@ -1266,6 +1266,11 @@ public class NpmPackage {
|
||||||
return Utilities.existsInList(npm.asString("type"), "fhir.core", "Core");
|
return Utilities.existsInList(npm.asString("type"), "fhir.core", "Core");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public boolean isCoreExamples() {
|
||||||
|
return name().startsWith("hl7.fhir.r") && name().endsWith(".examples");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
public boolean isTx() {
|
public boolean isTx() {
|
||||||
return npm.asString("name").startsWith("hl7.terminology");
|
return npm.asString("name").startsWith("hl7.terminology");
|
||||||
}
|
}
|
||||||
|
|
|
@ -520,6 +520,7 @@ public class IgLoader implements IValidationEngineLoader {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!pi.isCoreExamples()) {
|
||||||
if (loadInContext) {
|
if (loadInContext) {
|
||||||
// getContext().getLoadedPackages().add(pi.name() + "#" + pi.version());
|
// getContext().getLoadedPackages().add(pi.name() + "#" + pi.version());
|
||||||
getContext().loadFromPackage(pi, ValidatorUtils.loaderForVersion(pi.fhirVersion()));
|
getContext().loadFromPackage(pi, ValidatorUtils.loaderForVersion(pi.fhirVersion()));
|
||||||
|
@ -527,6 +528,7 @@ public class IgLoader implements IValidationEngineLoader {
|
||||||
for (String s : pi.listResources("CodeSystem", "ConceptMap", "ImplementationGuide", "CapabilityStatement", "SearchParameter", "Conformance", "StructureMap", "ValueSet", "StructureDefinition")) {
|
for (String s : pi.listResources("CodeSystem", "ConceptMap", "ImplementationGuide", "CapabilityStatement", "SearchParameter", "Conformance", "StructureMap", "ValueSet", "StructureDefinition")) {
|
||||||
res.put(s, TextFile.streamToBytes(pi.load("package", s)));
|
res.put(s, TextFile.streamToBytes(pi.load("package", s)));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
String ini = "[FHIR]\r\nversion=" + pi.fhirVersion() + "\r\n";
|
String ini = "[FHIR]\r\nversion=" + pi.fhirVersion() + "\r\n";
|
||||||
res.put("version.info", ini.getBytes());
|
res.put("version.info", ini.getBytes());
|
||||||
return res;
|
return res;
|
||||||
|
|
Loading…
Reference in New Issue