clean up handling of xml_name

This commit is contained in:
Grahame Grieve 2023-12-15 02:44:07 -05:00
parent ca694588b6
commit bb020dd739
2 changed files with 3 additions and 3 deletions

View File

@ -72,9 +72,9 @@ public class Property {
}
public String getXmlName() {
if (definition.hasExtension("http://hl7.org/fhir/StructureDefinition/elementdefinition-xml-name")) {
if (definition.hasExtension(ToolingExtensions.EXT_XML_NAME)) {
return ToolingExtensions.readStringExtension(definition,
"http://hl7.org/fhir/StructureDefinition/elementdefinition-xml-name");
ToolingExtensions.EXT_XML_NAME);
} else {
return getName();
}

View File

@ -145,7 +145,7 @@ public abstract class ParserBase {
protected StructureDefinition getDefinition(List<ValidationMessage> errors, int line, int col, String ns, String name) throws FHIRFormatError {
if (logical != null) {
String expectedName = ToolingExtensions.readStringExtension(logical, "http://hl7.org/fhir/StructureDefinition/elementdefinition-xml-name");
String expectedName = ToolingExtensions.readStringExtension(logical, ToolingExtensions.EXT_XML_NAME);
if (expectedName == null) {
expectedName = logical.getType();
if (Utilities.isAbsoluteUrl(expectedName)) {