this.source = new MessageSourceComponent(); return this.source;
@Override public Base setProperty(String name, Base value) throws FHIRException { if (name.equals("name")) { this.name = castToString(value); // StringType } else if (name.equals("software")) { this.software = castToString(value); // StringType } else if (name.equals("version")) { this.version = castToString(value); // StringType } else if (name.equals("contact")) { this.contact = castToContactPoint(value); // ContactPoint } else if (name.equals("endpoint")) { this.endpoint = castToUri(value); // UriType } else return super.setProperty(name, value); return value; }
public MessageHeader copy() { MessageHeader dst = new MessageHeader(); copyValues(dst); dst.event = event == null ? null : event.copy(); if (destination != null) { dst.destination = new ArrayList<MessageDestinationComponent>(); for (MessageDestinationComponent i : destination) dst.destination.add(i.copy()); }; dst.receiver = receiver == null ? null : receiver.copy(); dst.sender = sender == null ? null : sender.copy(); dst.timestamp = timestamp == null ? null : timestamp.copy(); dst.enterer = enterer == null ? null : enterer.copy(); dst.author = author == null ? null : author.copy(); dst.source = source == null ? null : source.copy(); dst.responsible = responsible == null ? null : responsible.copy(); dst.reason = reason == null ? null : reason.copy(); dst.response = response == null ? null : response.copy(); if (focus != null) { dst.focus = new ArrayList<Reference>(); for (Reference i : focus) dst.focus.add(i.copy()); }; return dst; }
@Override public Base setProperty(int hash, String name, Base value) throws FHIRException { switch (hash) { case 3373707: // name this.name = castToString(value); // StringType return value; case 1319330215: // software this.software = castToString(value); // StringType return value; case 351608024: // version this.version = castToString(value); // StringType return value; case 951526432: // contact this.contact = castToContactPoint(value); // ContactPoint return value; case 1741102485: // endpoint this.endpoint = castToUri(value); // UriType return value; default: return super.setProperty(hash, name, value); } }
public boolean hasSource() { return this.source != null && !this.source.isEmpty(); }
/** * @return {@link #source} (The source application from which this message originated.) */ public MessageSourceComponent getSource() { if (this.source == null) if (Configuration.errorOnAutoCreate()) throw new Error("Attempt to auto-create MessageHeader.source"); else if (Configuration.doAutoCreate()) this.source = new MessageSourceComponent(); // cc return this.source; }
public MessageSourceComponent copy() { MessageSourceComponent dst = new MessageSourceComponent(); copyValues(dst); dst.name = name == null ? null : name.copy(); dst.software = software == null ? null : software.copy(); dst.version = version == null ? null : version.copy(); dst.contact = contact == null ? null : contact.copy(); dst.endpoint = endpoint == null ? null : endpoint.copy(); return dst; }
@Override public boolean equalsShallow(Base other_) { if (!super.equalsShallow(other_)) return false; if (!(other_ instanceof MessageSourceComponent)) return false; MessageSourceComponent o = (MessageSourceComponent) other_; return compareValues(name, o.name, true) && compareValues(software, o.software, true) && compareValues(version, o.version, true) && compareValues(endpoint, o.endpoint, true); }
@Override public boolean equalsDeep(Base other_) { if (!super.equalsDeep(other_)) return false; if (!(other_ instanceof MessageSourceComponent)) return false; MessageSourceComponent o = (MessageSourceComponent) other_; return compareDeep(name, o.name, true) && compareDeep(software, o.software, true) && compareDeep(version, o.version, true) && compareDeep(contact, o.contact, true) && compareDeep(endpoint, o.endpoint, true); }
public org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent convertMessageSourceComponent(org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent tgt = new org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent(); copyElement(src, tgt); tgt.setName(src.getName()); tgt.setSoftware(src.getSoftware()); tgt.setVersion(src.getVersion()); tgt.setContact(convertContactPoint(src.getContact())); tgt.setEndpoint(src.getEndpoint()); return tgt; }
@Override public Base makeProperty(int hash, String name) throws FHIRException { switch (hash) { case 3373707: return getNameElement(); case 1319330215: return getSoftwareElement(); case 351608024: return getVersionElement(); case 951526432: return getContact(); case 1741102485: return getEndpointElement(); default: return super.makeProperty(hash, name); } }
public org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent convertMessageSourceComponent(org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent tgt = new org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent(); copyElement(src, tgt); tgt.setName(src.getName()); tgt.setSoftware(src.getSoftware()); tgt.setVersion(src.getVersion()); tgt.setContact(convertContactPoint(src.getContact())); tgt.setEndpoint(src.getEndpoint()); return tgt; }
public org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent convertMessageSourceComponent(org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent tgt = new org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent(); copyElement(src, tgt); tgt.setName(src.getName()); tgt.setSoftware(src.getSoftware()); tgt.setVersion(src.getVersion()); tgt.setContact(convertContactPoint(src.getContact())); tgt.setEndpoint(src.getEndpoint()); return tgt; }
public org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent convertMessageSourceComponent(org.hl7.fhir.dstu3.model.MessageHeader.MessageSourceComponent src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent tgt = new org.hl7.fhir.instance.model.MessageHeader.MessageSourceComponent(); copyElement(src, tgt); tgt.setName(src.getName()); tgt.setSoftware(src.getSoftware()); tgt.setVersion(src.getVersion()); tgt.setContact(convertContactPoint(src.getContact())); tgt.setEndpoint(src.getEndpoint()); return tgt; }