} else if (o instanceof ElementDefinitionConstraintComponent) { ElementDefinitionConstraintComponent c = (ElementDefinitionConstraintComponent)o; val = c.getKey() + ":" + c.getHuman() + " {" + c.getExpression() + "}"; } else if (o instanceof ElementDefinitionSlicingDiscriminatorComponent) { ElementDefinitionSlicingDiscriminatorComponent c = (ElementDefinitionSlicingDiscriminatorComponent)o;
if (!c.getPieces().isEmpty()) c.addPiece(gen.new Piece("br")); c.getPieces().add(checkForNoChange(inv, gen.new Piece(null, inv.getKey()+": ", null).addStyle("font-weight:bold"))); c.getPieces().add(checkForNoChange(inv, gen.new Piece(null, inv.getHuman(), null)));
Section s = sch.section(ed.getPath()); Rule r = s.rule(xpath); r.assrt(inv.getXpath(), (inv.hasId() ? inv.getId()+": " : "")+inv.getHuman()+(inv.hasUserData(IS_DERIVED) ? " (inherited)" : ""));
if (!c.getPieces().isEmpty()) c.addPiece(gen.new Piece("br")); c.getPieces().add(checkForNoChange(inv, gen.new Piece(null, inv.getKey()+": ", null).addStyle("font-weight:bold"))); c.getPieces().add(checkForNoChange(inv, gen.new Piece(null, inv.getHuman(), null)));
ToolingExtensions.readBooleanExtension(inv, "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice")) { if (bpWarnings == BestPracticeWarningLevel.Hint) hint(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (bpWarnings == BestPracticeWarningLevel.Warning) warning(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (bpWarnings == BestPracticeWarningLevel.Error) rule(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); rule(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (inv.getSeverity() == ConstraintSeverity.WARNING) warning(errors, IssueType.INVARIANT, element.line(), element.line(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]");
} else if (o instanceof ElementDefinitionConstraintComponent) { ElementDefinitionConstraintComponent c = (ElementDefinitionConstraintComponent)o; val = c.getKey() + ":" + c.getHuman() + " {" + c.getExpression() + "}"; } else if (o instanceof ElementDefinitionSlicingDiscriminatorComponent) { ElementDefinitionSlicingDiscriminatorComponent c = (ElementDefinitionSlicingDiscriminatorComponent)o;
Section s = sch.section(ed.getPath()); Rule r = s.rule(xpath); r.assrt(inv.getXpath(), (inv.hasId() ? inv.getId()+": " : "")+inv.getHuman()+(inv.hasUserData(IS_DERIVED) ? " (inherited)" : ""));
public static org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent convertElementDefinitionConstraintComponent(org.hl7.fhir.r4.model.ElementDefinition.ElementDefinitionConstraintComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent tgt = new org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent(); copyElement(src, tgt); tgt.setKey(src.getKey()); if (src.hasRequirements()) tgt.setRequirements(src.getRequirements()); tgt.setSeverity(convertConstraintSeverity(src.getSeverity())); tgt.setHuman(src.getHuman()); if (src.hasExpression()) tgt.setExpression(convertTo2016MayExpression(src.getExpression())); tgt.setXpath(src.getXpath()); return tgt; }
public org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent convertElementDefinitionConstraintComponent(org.hl7.fhir.r4.model.ElementDefinition.ElementDefinitionConstraintComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent tgt = new org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent(); copyElement(src, tgt); tgt.setKey(src.getKey()); tgt.setRequirements(src.getRequirements()); tgt.setSeverity(convertConstraintSeverity(src.getSeverity())); tgt.setHuman(src.getHuman()); if (src.hasExpression()) ToolingExtensions.addStringExtension(tgt, ToolingExtensions.EXT_EXPRESSION, src.getExpression()); tgt.setXpath(src.getXpath()); return tgt; }
ToolingExtensions.readBooleanExtension(inv, "http://hl7.org/fhir/StructureDefinition/elementdefinition-bestpractice")) { if (bpWarnings == BestPracticeWarningLevel.Hint) hint(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (bpWarnings == BestPracticeWarningLevel.Warning) warning(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (bpWarnings == BestPracticeWarningLevel.Error) rule(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); rule(errors, IssueType.INVARIANT, element.line(), element.col(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]"); else if (inv.getSeverity() == ConstraintSeverity.WARNING) warning(errors, IssueType.INVARIANT, element.line(), element.line(), path, ok, inv.getHuman()+msg+" ["+inv.getExpression()+"]");
public static org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent convertElementDefinitionConstraintComponent(org.hl7.fhir.r4.model.ElementDefinition.ElementDefinitionConstraintComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent tgt = new org.hl7.fhir.dstu2016may.model.ElementDefinition.ElementDefinitionConstraintComponent(); copyElement(src, tgt); tgt.setKey(src.getKey()); if (src.hasRequirements()) tgt.setRequirements(src.getRequirements()); tgt.setSeverity(convertConstraintSeverity(src.getSeverity())); tgt.setHuman(src.getHuman()); if (src.hasExpression()) tgt.setExpression(convertTo2016MayExpression(src.getExpression())); tgt.setXpath(src.getXpath()); return tgt; }
public org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent convertElementDefinitionConstraintComponent(org.hl7.fhir.r4.model.ElementDefinition.ElementDefinitionConstraintComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent tgt = new org.hl7.fhir.instance.model.ElementDefinition.ElementDefinitionConstraintComponent(); copyElement(src, tgt); tgt.setKey(src.getKey()); tgt.setRequirements(src.getRequirements()); tgt.setSeverity(convertConstraintSeverity(src.getSeverity())); tgt.setHuman(src.getHuman()); if (src.hasExpression()) ToolingExtensions.addStringExtension(tgt, ToolingExtensions.EXT_EXPRESSION, src.getExpression()); tgt.setXpath(src.getXpath()); return tgt; }