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,12 +520,14 @@ public class IgLoader implements IValidationEngineLoader {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (loadInContext) {
|
if (!pi.isCoreExamples()) {
|
||||||
// getContext().getLoadedPackages().add(pi.name() + "#" + pi.version());
|
if (loadInContext) {
|
||||||
getContext().loadFromPackage(pi, ValidatorUtils.loaderForVersion(pi.fhirVersion()));
|
// getContext().getLoadedPackages().add(pi.name() + "#" + pi.version());
|
||||||
}
|
getContext().loadFromPackage(pi, ValidatorUtils.loaderForVersion(pi.fhirVersion()));
|
||||||
for (String s : pi.listResources("CodeSystem", "ConceptMap", "ImplementationGuide", "CapabilityStatement", "SearchParameter", "Conformance", "StructureMap", "ValueSet", "StructureDefinition")) {
|
}
|
||||||
res.put(s, TextFile.streamToBytes(pi.load("package", s)));
|
for (String s : pi.listResources("CodeSystem", "ConceptMap", "ImplementationGuide", "CapabilityStatement", "SearchParameter", "Conformance", "StructureMap", "ValueSet", "StructureDefinition")) {
|
||||||
|
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());
|
||||||
|
|
Loading…
Reference in New Issue