/** * @return The first repetition of repeating field {@link #parameter}, creating it if it does not already exist */ public StructureMapGroupRuleTargetParameterComponent getParameterFirstRep() { if (getParameter().isEmpty()) { addParameter(); } return getParameter().get(0); }
@Override public Base addChild(String name) throws FHIRException { if (name.equals("context")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.context"); } else if (name.equals("contextType")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.contextType"); } else if (name.equals("element")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.element"); } else if (name.equals("variable")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.variable"); } else if (name.equals("listMode")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.listMode"); } else if (name.equals("listRuleId")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.listRuleId"); } else if (name.equals("transform")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.transform"); } else if (name.equals("parameter")) { return addParameter(); } else return super.addChild(name); }
/** * @return The first repetition of repeating field {@link #parameter}, creating it if it does not already exist */ public StructureMapGroupRuleTargetParameterComponent getParameterFirstRep() { if (getParameter().isEmpty()) { addParameter(); } return getParameter().get(0); }
ExpressionNode node = fpe.parse(lexer); target.setUserData(MAP_EXPRESSION, node); target.addParameter().setValue(new StringType(node.toString())); lexer.token(")"); } else if (lexer.hasToken("(")) { ExpressionNode node = fpe.parse(lexer); target.setUserData(MAP_EXPRESSION, node); target.addParameter().setValue(new StringType(node.toString())); } else { while (!lexer.hasToken(")")) { id = id + lexer.take() + lexer.take(); target.addParameter().setValue(new IdType(id)); target.addParameter().setValue(readConstant(name, lexer));
@Override public Base addChild(String name) throws FHIRException { if (name.equals("context")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.context"); } else if (name.equals("contextType")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.contextType"); } else if (name.equals("element")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.element"); } else if (name.equals("variable")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.variable"); } else if (name.equals("listMode")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.listMode"); } else if (name.equals("listRuleId")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.listRuleId"); } else if (name.equals("transform")) { throw new FHIRException("Cannot call addChild on a primitive type StructureMap.transform"); } else if (name.equals("parameter")) { return addParameter(); } else return super.addChild(name); }
public static org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent convertStructureMapGroupRuleTargetComponent(org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapGroupRuleTargetComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent tgt = new org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent(); copyElement(src, tgt); if (src.hasContext()) tgt.setContext(src.getContext()); if (src.hasContextType()) tgt.setContextType(convertStructureMapContextType(src.getContextType())); if (src.hasElement()) tgt.setElement(src.getElement()); if (src.hasVariable()) tgt.setVariable(src.getVariable()); for (org.hl7.fhir.dstu2016may.model.Enumeration<org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapListMode> t : src.getListMode()) tgt.addListMode(convertStructureMapTargetListMode(t.getValue())); if (src.hasListRuleId()) tgt.setListRuleId(src.getListRuleId()); if (src.hasTransform()) tgt.setTransform(convertStructureMapTransform(src.getTransform())); for (org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapGroupRuleTargetParameterComponent t : src.getParameter()) tgt.addParameter(convertStructureMapGroupRuleTargetParameterComponent(t)); return tgt; }
@Override public Base makeProperty(int hash, String name) throws FHIRException { switch (hash) { case 951530927: return getContextElement(); case -102839927: return getContextTypeElement(); case -1662836996: return getElementElement(); case -1249586564: return getVariableElement(); case 1345445729: return addListModeElement(); case 337117045: return getListRuleIdElement(); case 1052666732: return getTransformElement(); case 1954460585: return addParameter(); default: return super.makeProperty(hash, name); } }
private void parseParameter(StructureMapGroupRuleTargetComponent target, FHIRLexer lexer) throws FHIRLexerException, FHIRFormatError { if (!lexer.isConstant(true)) { target.addParameter().setValue(new IdType(lexer.take())); } else if (lexer.isStringConstant()) target.addParameter().setValue(new StringType(lexer.readConstant("??"))); else { target.addParameter().setValue(readConstant(lexer.take(), lexer)); } }
ExpressionNode node = fpe.parse(lexer); target.setUserData(MAP_EXPRESSION, node); target.addParameter().setValue(new StringType(node.toString())); lexer.token(")"); } else if (lexer.hasToken("(")) { ExpressionNode node = fpe.parse(lexer); target.setUserData(MAP_EXPRESSION, node); target.addParameter().setValue(new StringType(node.toString())); } else { while (!lexer.hasToken(")")) { id = id + lexer.take() + lexer.take(); target.addParameter().setValue(new IdType(id)); target.addParameter().setValue(readConstant(name, lexer));
public static org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent convertStructureMapGroupRuleTargetComponent(org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapGroupRuleTargetComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent tgt = new org.hl7.fhir.r4.model.StructureMap.StructureMapGroupRuleTargetComponent(); copyElement(src, tgt); if (src.hasContext()) tgt.setContext(src.getContext()); if (src.hasContextType()) tgt.setContextType(convertStructureMapContextType(src.getContextType())); if (src.hasElement()) tgt.setElement(src.getElement()); if (src.hasVariable()) tgt.setVariable(src.getVariable()); for (org.hl7.fhir.dstu2016may.model.Enumeration<org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapListMode> t : src.getListMode()) tgt.addListMode(convertStructureMapTargetListMode(t.getValue())); if (src.hasListRuleId()) tgt.setListRuleId(src.getListRuleId()); if (src.hasTransform()) tgt.setTransform(convertStructureMapTransform(src.getTransform())); for (org.hl7.fhir.dstu2016may.model.StructureMap.StructureMapGroupRuleTargetParameterComponent t : src.getParameter()) tgt.addParameter(convertStructureMapGroupRuleTargetParameterComponent(t)); return tgt; }
@Override public Base makeProperty(int hash, String name) throws FHIRException { switch (hash) { case 951530927: return getContextElement(); case -102839927: return getContextTypeElement(); case -1662836996: return getElementElement(); case -1249586564: return getVariableElement(); case 1345445729: return addListModeElement(); case 337117045: return getListRuleIdElement(); case 1052666732: return getTransformElement(); case 1954460585: return addParameter(); default: return super.makeProperty(hash, name); } }
private void parseParameter(StructureMapGroupRuleTargetComponent target, FHIRLexer lexer) throws FHIRLexerException, FHIRFormatError { if (!lexer.isConstant(true)) { target.addParameter().setValue(new IdType(lexer.take())); } else if (lexer.isStringConstant()) target.addParameter().setValue(new StringType(lexer.readConstant("??"))); else { target.addParameter().setValue(readConstant(lexer.take(), lexer)); } }