public org.hl7.fhir.r4.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.instance.model.OperationDefinition src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.r4.model.OperationDefinition tgt = new org.hl7.fhir.r4.model.OperationDefinition(); copyDomainResource(src, tgt); tgt.setUrl(src.getUrl()); tgt.setVersion(src.getVersion()); tgt.setName(src.getName()); tgt.setStatus(convertConformanceResourceStatus(src.getStatus())); tgt.setKind(convertOperationKind(src.getKind())); if (src.hasExperimental()) tgt.setExperimental(src.getExperimental()); if (src.hasDate()) tgt.setDate(src.getDate()); tgt.setPublisher(src.getPublisher()); for (org.hl7.fhir.instance.model.OperationDefinition.OperationDefinitionContactComponent t : src.getContact()) tgt.addContact(convertOperationDefinitionContactComponent(t)); tgt.setDescription(src.getDescription()); tgt.setPurpose(src.getRequirements()); if (src.hasIdempotent()) tgt.setAffectsState(!src.getIdempotent()); tgt.setCode(src.getCode()); tgt.setComment(src.getNotes()); tgt.setBaseElement(convertReferenceToCanonical(src.getBase())); tgt.setSystem(src.getSystem()); for (org.hl7.fhir.instance.model.CodeType t : src.getType()) tgt.addResource(t.getValue()); tgt.setType(tgt.hasResource()); tgt.setInstance(src.getInstance()); for (org.hl7.fhir.instance.model.OperationDefinition.OperationDefinitionParameterComponent t : src.getParameter())
@Override public Base makeProperty(int hash, String name) throws FHIRException { switch (hash) { case 116079: return getUrlElement(); case 351608024: return getVersionElement(); case 3373707: return getNameElement(); case 110371416: return getTitleElement(); case -892481550: return getStatusElement(); case 3292052: return getKindElement(); case -404562712: return getExperimentalElement(); case 3076014: return getDateElement(); case 1447404028: return getPublisherElement(); case 951526432: return addContact(); case -1724546052: return getDescriptionElement(); case -669707736: return addUseContext(); case -507075711: return addJurisdiction(); case -220463842: return getPurposeElement(); case -14805197: return getAffectsStateElement(); case 3059181: return getCodeElement(); case 950398559: return getCommentElement(); case 3016401: return getBaseElement(); case -341064690: return addResourceElement(); case -887328209: return getSystemElement(); case 3575610: return getTypeElement(); case 555127957: return getInstanceElement(); case 676942463: return getInputProfileElement(); case 1826166120: return getOutputProfileElement(); case 1954460585: return addParameter(); case 529823674: return addOverload(); default: return super.makeProperty(hash, name);
private OperationDefinition readOperationDefinitionForNamedSearch(List<SearchMethodBinding> bindings) { OperationDefinition op = new OperationDefinition(); op.setStatus(PublicationStatus.ACTIVE); op.setKind(OperationKind.QUERY); op.setAffectsState(false); op.setSystem(false); op.setType(false); op.setInstance(false); op.setDescription(binding.getDescription()); op.setSystem(true); } else { op.setType(true); op.addResourceElement().setValue(binding.getResourceProviderResourceName()); op.setCode(binding.getQueryName()); for (IParameter nextParamUntyped : binding.getParameters()) { if (nextParamUntyped instanceof SearchParameter) { OperationDefinitionParameterComponent param = op.addParameter(); param.setUse(OperationParameterUse.IN); param.setType("string"); if (isBlank(op.getName())) { if (isNotBlank(op.getDescription())) { op.setName(op.getDescription()); } else { op.setName(op.getCode());
/** * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist */ public ContactDetail getContactFirstRep() { if (getContact().isEmpty()) { addContact(); } return getContact().get(0); }
/** * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist */ public CodeableConcept getJurisdictionFirstRep() { if (getJurisdiction().isEmpty()) { addJurisdiction(); } return getJurisdiction().get(0); }
/** * @return The first repetition of repeating field {@link #parameter}, creating it if it does not already exist */ public OperationDefinitionParameterComponent getParameterFirstRep() { if (getParameter().isEmpty()) { addParameter(); } return getParameter().get(0); }
public static org.hl7.fhir.dstu2016may.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.r4.model.OperationDefinition src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.OperationDefinition tgt = new org.hl7.fhir.dstu2016may.model.OperationDefinition(); copyDomainResource(src, tgt); if (src.hasUrl()) tgt.setUrl(src.getUrl()); if (src.hasVersion()) tgt.setVersion(src.getVersion()); tgt.setName(src.getName()); tgt.setStatus(convertConformanceResourceStatus(src.getStatus())); tgt.setKind(convertOperationKind(src.getKind())); if (src.hasExperimental()) tgt.setExperimental(src.getExperimental()); if (src.hasDate()) tgt.setDate(src.getDate()); if (src.hasPublisher()) tgt.setPublisher(src.getPublisher()); for (org.hl7.fhir.r4.model.ContactDetail t : src.getContact()) tgt.addContact(convertOperationDefinitionContactComponent(t)); if (src.hasDescription()) tgt.setDescription(src.getDescription()); for (org.hl7.fhir.r4.model.UsageContext t : src.getUseContext()) if (t.hasValueCodeableConcept()) tgt.addUseContext(convertCodeableConcept(t.getValueCodeableConcept())); for (org.hl7.fhir.r4.model.CodeableConcept t : src.getJurisdiction()) tgt.addUseContext(convertCodeableConcept(t)); if (src.hasPurpose()) tgt.setRequirements(src.getPurpose()); if (src.hasAffectsState())
public org.hl7.fhir.instance.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.r4.model.OperationDefinition src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.OperationDefinition tgt = new org.hl7.fhir.instance.model.OperationDefinition(); copyDomainResource(src, tgt); tgt.setUrl(src.getUrl()); tgt.setVersion(src.getVersion()); tgt.setName(src.getName()); tgt.setStatus(convertConformanceResourceStatus(src.getStatus())); tgt.setKind(convertOperationKind(src.getKind())); if (src.hasExperimental()) tgt.setExperimental(src.getExperimental()); if (src.hasDate()) tgt.setDate(src.getDate()); tgt.setPublisher(src.getPublisher()); for (org.hl7.fhir.r4.model.ContactDetail t : src.getContact()) tgt.addContact(convertOperationDefinitionContactComponent(t)); tgt.setDescription(src.getDescription()); tgt.setRequirements(src.getPurpose()); tgt.setIdempotent(!src.getAffectsState()); tgt.setCode(src.getCode()); tgt.setNotes(src.getComment()); if (src.hasBase()) tgt.setBase(convertCanonicalToReference(src.getBaseElement())); tgt.setSystem(src.getSystem()); if (src.getType()) for (org.hl7.fhir.r4.model.CodeType t : src.getResource()) tgt.addType(t.getValue()); tgt.setInstance(src.getInstance()); for (org.hl7.fhir.r4.model.OperationDefinition.OperationDefinitionParameterComponent t : src.getParameter())
switch (hash) { case 116079: // url this.url = castToUri(value); // UriType return value; case 351608024: // version this.version = castToString(value); // StringType return value; case 3373707: // name this.name = castToString(value); // StringType return value; case 110371416: // title this.title = castToString(value); // StringType return value; case -892481550: // status value = new PublicationStatusEnumFactory().fromType(castToCode(value)); this.status = (Enumeration) value; // Enumeration<PublicationStatus> return value; case 3292052: // kind value = new OperationKindEnumFactory().fromType(castToCode(value)); this.kind = (Enumeration) value; // Enumeration<OperationKind> return value; case -404562712: // experimental this.experimental = castToBoolean(value); // BooleanType return value; case 3076014: // date this.date = castToDateTime(value); // DateTimeType return value; case 1447404028: // publisher this.publisher = castToString(value); // StringType
return addContact(); return addUseContext(); return addJurisdiction(); return addParameter(); return addOverload();
/** * @return The first repetition of repeating field {@link #useContext}, creating it if it does not already exist */ public UsageContext getUseContextFirstRep() { if (getUseContext().isEmpty()) { addUseContext(); } return getUseContext().get(0); }
public OperationDefinition copy() { OperationDefinition dst = new OperationDefinition(); copyValues(dst); dst.url = url == null ? null : url.copy(); dst.version = version == null ? null : version.copy();
return new ValueSet(); if ("OperationDefinition".equals(name)) return new OperationDefinition(); if ("Immunization".equals(name)) return new Immunization();
public static org.hl7.fhir.dstu2016may.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.r4.model.OperationDefinition src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.OperationDefinition tgt = new org.hl7.fhir.dstu2016may.model.OperationDefinition(); copyDomainResource(src, tgt); if (src.hasUrl()) tgt.setUrl(src.getUrl()); if (src.hasVersion()) tgt.setVersion(src.getVersion()); tgt.setName(src.getName()); tgt.setStatus(convertConformanceResourceStatus(src.getStatus())); tgt.setKind(convertOperationKind(src.getKind())); if (src.hasExperimental()) tgt.setExperimental(src.getExperimental()); if (src.hasDate()) tgt.setDate(src.getDate()); if (src.hasPublisher()) tgt.setPublisher(src.getPublisher()); for (org.hl7.fhir.r4.model.ContactDetail t : src.getContact()) tgt.addContact(convertOperationDefinitionContactComponent(t)); if (src.hasDescription()) tgt.setDescription(src.getDescription()); for (org.hl7.fhir.r4.model.UsageContext t : src.getUseContext()) if (t.hasValueCodeableConcept()) tgt.addUseContext(convertCodeableConcept(t.getValueCodeableConcept())); for (org.hl7.fhir.r4.model.CodeableConcept t : src.getJurisdiction()) tgt.addUseContext(convertCodeableConcept(t)); if (src.hasPurpose()) tgt.setRequirements(src.getPurpose()); if (src.hasAffectsState())
public org.hl7.fhir.instance.model.OperationDefinition convertOperationDefinition(org.hl7.fhir.r4.model.OperationDefinition src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.OperationDefinition tgt = new org.hl7.fhir.instance.model.OperationDefinition(); copyDomainResource(src, tgt); tgt.setUrl(src.getUrl()); tgt.setVersion(src.getVersion()); tgt.setName(src.getName()); tgt.setStatus(convertConformanceResourceStatus(src.getStatus())); tgt.setKind(convertOperationKind(src.getKind())); if (src.hasExperimental()) tgt.setExperimental(src.getExperimental()); if (src.hasDate()) tgt.setDate(src.getDate()); tgt.setPublisher(src.getPublisher()); for (org.hl7.fhir.r4.model.ContactDetail t : src.getContact()) tgt.addContact(convertOperationDefinitionContactComponent(t)); tgt.setDescription(src.getDescription()); tgt.setRequirements(src.getPurpose()); tgt.setIdempotent(!src.getAffectsState()); tgt.setCode(src.getCode()); tgt.setNotes(src.getComment()); if (src.hasBase()) tgt.setBase(convertCanonicalToReference(src.getBaseElement())); tgt.setSystem(src.getSystem()); if (src.getType()) for (org.hl7.fhir.r4.model.CodeType t : src.getResource()) tgt.addType(t.getValue()); tgt.setInstance(src.getInstance()); for (org.hl7.fhir.r4.model.OperationDefinition.OperationDefinitionParameterComponent t : src.getParameter())
@Override public Base setProperty(String name, Base value) throws FHIRException { if (name.equals("url")) { this.url = castToUri(value); // UriType } else if (name.equals("version")) { this.version = castToString(value); // StringType } else if (name.equals("name")) { this.name = castToString(value); // StringType } else if (name.equals("title")) { this.title = castToString(value); // StringType } else if (name.equals("status")) { value = new PublicationStatusEnumFactory().fromType(castToCode(value)); this.status = (Enumeration) value; // Enumeration<PublicationStatus> } else if (name.equals("kind")) { value = new OperationKindEnumFactory().fromType(castToCode(value)); this.kind = (Enumeration) value; // Enumeration<OperationKind> } else if (name.equals("experimental")) { this.experimental = castToBoolean(value); // BooleanType } else if (name.equals("date")) { this.date = castToDateTime(value); // DateTimeType } else if (name.equals("publisher")) { this.publisher = castToString(value); // StringType } else if (name.equals("contact")) { this.getContact().add(castToContactDetail(value)); } else if (name.equals("description")) { this.description = castToMarkdown(value); // MarkdownType } else if (name.equals("useContext")) { this.getUseContext().add(castToUsageContext(value)); } else if (name.equals("jurisdiction")) { this.getJurisdiction().add(castToCodeableConcept(value));
return addContact(); return addUseContext(); return addJurisdiction(); return addParameter(); return addOverload();
/** * @return The first repetition of repeating field {@link #contact}, creating it if it does not already exist */ public ContactDetail getContactFirstRep() { if (getContact().isEmpty()) { addContact(); } return getContact().get(0); }
/** * @return The first repetition of repeating field {@link #jurisdiction}, creating it if it does not already exist */ public CodeableConcept getJurisdictionFirstRep() { if (getJurisdiction().isEmpty()) { addJurisdiction(); } return getJurisdiction().get(0); }
/** * @return The first repetition of repeating field {@link #parameter}, creating it if it does not already exist */ public OperationDefinitionParameterComponent getParameterFirstRep() { if (getParameter().isEmpty()) { addParameter(); } return getParameter().get(0); }