This commit is contained in:
Grahame Grieve 2023-10-12 20:15:31 +11:00
parent 84e3bec25f
commit 2f304a6576
3 changed files with 12 additions and 1 deletions

View File

@ -609,5 +609,15 @@ public class Property {
return ok;
}
public String getXmlTypeName() {
TypeRefComponent tr = type;
if (tr == null) {
tr = definition.getTypeFirstRep();
}
StructureDefinition sd = context.fetchTypeDefinition(tr.getWorkingCode());
return sd.getSnapshot().getElementFirstRep().getPath();
}
}

View File

@ -256,6 +256,7 @@ public class ToolingExtensions {
public static final String EXT_OBLIGATION_CORE = "http://hl7.org/fhir/StructureDefinition/obligation";
public static final String EXT_NO_BINDING = "http://hl7.org/fhir/tools/StructureDefinition/no-binding";
public static final String EXT_ID_CHOICE_GROUP = "http://hl7.org/fhir/tools/StructureDefinition/xml-choice-group";
public static final String EXT_DATE_RULES = "http://hl7.org/fhir/tools/StructureDefinition/elementdefinition-date-rules";
// specific extension helpers

View File

@ -62,7 +62,7 @@ public class NpmPackageTests {
private void checkNpm(NpmPackage npm) throws IOException {
Assertions.assertEquals(1, npm.list("other").size());
Assertions.assertEquals(2, npm.list("other").size());
Assertions.assertEquals("help.png", npm.list("other").get(0));
Assertions.assertEquals(1, npm.list("package").size());
Assertions.assertEquals("StructureDefinition-Definition.json", npm.list("package").get(0));