use of org.hl7.fhir.dstu3.model.Enumerations.SearchParamTypeEnumFactory in project org.hl7.fhir.core by hapifhir.
the class SearchParameter method setProperty.
@Override
public Base setProperty(String name, Base value) throws FHIRException {
if (name.equals("url")) {
// UriType
this.url = castToUri(value);
} else if (name.equals("version")) {
// StringType
this.version = castToString(value);
} else if (name.equals("name")) {
// StringType
this.name = castToString(value);
} else if (name.equals("status")) {
value = new PublicationStatusEnumFactory().fromType(castToCode(value));
// Enumeration<PublicationStatus>
this.status = (Enumeration) value;
} else if (name.equals("experimental")) {
// BooleanType
this.experimental = castToBoolean(value);
} else if (name.equals("date")) {
// DateTimeType
this.date = castToDateTime(value);
} else if (name.equals("publisher")) {
// StringType
this.publisher = castToString(value);
} else if (name.equals("contact")) {
this.getContact().add(castToContactDetail(value));
} else if (name.equals("useContext")) {
this.getUseContext().add(castToUsageContext(value));
} else if (name.equals("jurisdiction")) {
this.getJurisdiction().add(castToCodeableConcept(value));
} else if (name.equals("purpose")) {
// MarkdownType
this.purpose = castToMarkdown(value);
} else if (name.equals("code")) {
// CodeType
this.code = castToCode(value);
} else if (name.equals("base")) {
this.getBase().add(castToCode(value));
} else if (name.equals("type")) {
value = new SearchParamTypeEnumFactory().fromType(castToCode(value));
// Enumeration<SearchParamType>
this.type = (Enumeration) value;
} else if (name.equals("derivedFrom")) {
// UriType
this.derivedFrom = castToUri(value);
} else if (name.equals("description")) {
// MarkdownType
this.description = castToMarkdown(value);
} else if (name.equals("expression")) {
// StringType
this.expression = castToString(value);
} else if (name.equals("xpath")) {
// StringType
this.xpath = castToString(value);
} else if (name.equals("xpathUsage")) {
value = new XPathUsageTypeEnumFactory().fromType(castToCode(value));
// Enumeration<XPathUsageType>
this.xpathUsage = (Enumeration) value;
} else if (name.equals("target")) {
this.getTarget().add(castToCode(value));
} else if (name.equals("comparator")) {
value = new SearchComparatorEnumFactory().fromType(castToCode(value));
this.getComparator().add((Enumeration) value);
} else if (name.equals("modifier")) {
value = new SearchModifierCodeEnumFactory().fromType(castToCode(value));
this.getModifier().add((Enumeration) value);
} else if (name.equals("chain")) {
this.getChain().add(castToString(value));
} else if (name.equals("component")) {
this.getComponent().add((SearchParameterComponentComponent) value);
} else
return super.setProperty(name, value);
return value;
}
Aggregations