public static void setOID(ValueSet vs, String oid) { if (!oid.startsWith("urn:oid:")) oid = "urn:oid:" + oid; for (Identifier id : vs.getIdentifier()) { if ("urn:ietf:rfc:3986".equals(id.getSystem()) && id.hasValue() && id.getValue().startsWith("urn:oid:")) { id.setValue(oid); return; } } vs.addIdentifier().setSystem("urn:ietf:rfc:3986").setValue(oid); }
public Identifier addIdentifier() { //3 Identifier t = new Identifier(); if (this.identifier == null) this.identifier = new ArrayList<Identifier>(); this.identifier.add(t); return t; }
@Override public Base makeProperty(int hash, String name) throws FHIRException { switch (hash) { case 116103: return getUseElement(); case 3575610: return getType(); case -887328209: return getSystemElement(); case 111972721: return getValueElement(); case -991726143: return getPeriod(); case -369881636: return getAssigner(); default: return super.makeProperty(hash, name); } }
public static void merge(Identifier dst, Identifier src) { if (dst.getUseElement() == null && src.getUseElement() != null) dst.setUseElement(src.getUseElement()); if (dst.getType() == null && src.getType() != null) dst.setType(src.getType()); if (dst.getPeriod() == null && src.getPeriod() != null) dst.setPeriod(src.getPeriod()); if (dst.getAssigner() == null && src.getAssigner() != null) dst.setAssigner(src.getAssigner()); }
public org.hl7.fhir.instance.model.Identifier convertIdentifier(org.hl7.fhir.r4.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.Identifier tgt = new org.hl7.fhir.instance.model.Identifier(); copyElement(src, tgt); if (src.hasUse()) tgt.setUse(convertIdentifierUse(src.getUse())); if (src.hasType()) tgt.setType(convertCodeableConcept(src.getType())); if (src.hasSystem()) tgt.setSystem(src.getSystem()); if (src.hasValue()) tgt.setValue(src.getValue()); if (src.hasPeriod()) tgt.setPeriod(convertPeriod(src.getPeriod())); if (src.hasAssigner()) tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public static org.hl7.fhir.dstu2016may.model.Identifier convertIdentifier(org.hl7.fhir.r4.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.Identifier tgt = new org.hl7.fhir.dstu2016may.model.Identifier(); copyElement(src, tgt); tgt.setUse(convertIdentifierUse(src.getUse())); tgt.setType(convertCodeableConcept(src.getType())); if (src.hasSystem()) tgt.setSystem(src.getSystem()); if (src.hasValue()) tgt.setValue(src.getValue()); tgt.setPeriod(convertPeriod(src.getPeriod())); tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public org.hl7.fhir.r4.model.Identifier convertIdentifier(org.hl7.fhir.instance.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.r4.model.Identifier tgt = new org.hl7.fhir.r4.model.Identifier(); copyElement(src, tgt); tgt.setUse(convertIdentifierUse(src.getUse())); tgt.setType(convertCodeableConcept(src.getType())); tgt.setSystem(src.getSystem()); tgt.setValue(src.getValue()); tgt.setPeriod(convertPeriod(src.getPeriod())); tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public static Identifier readAsIdentifier(Element item) { Identifier r = new Identifier(); r.setSystem(item.getNamedChildValue("system")); r.setValue(item.getNamedChildValue("value")); return r; }
if (nextValue.isEmpty()) { continue; String system = StringUtils.defaultIfBlank(nextValue.getSystemElement().getValueAsString(), null); String value = nextValue.getValueElement().getValue(); if (isNotBlank(value)) { systems.add(system); if (isNotBlank(nextValue.getType().getText())) { addStringParam(theEntity, retVal, nextSpDef, nextValue.getType().getText());
public static boolean matches(Identifier i1, Identifier i2, MatchProfile profile) { if (profile != null) throw new NotImplementedException("Not Implemented Yet"); // in the absence of a profile, we ignore version return matches(i1.getSystem(), i2.getSystem(), null) && matches(i1.getValue(), i2.getValue(), null); }
protected AuditEvent.AuditEventSourceComponent auditSourceIdentificationToEventSource(AuditSourceIdentificationType asit) { AuditEvent.AuditEventSourceComponent source = new AuditEvent.AuditEventSourceComponent() .setSite(asit.getAuditEnterpriseSiteID()) .setObserver(new Reference().setIdentifier(new Identifier().setValue(asit.getAuditSourceID()))); asit.getAuditSourceType().forEach(ast -> source.addType(codedValueTypeToCoding(ast))); return source; }
public Identifier copy() { Identifier dst = new Identifier(); copyValues(dst); dst.use = use == null ? null : use.copy(); dst.type = type == null ? null : type.copy(); dst.system = system == null ? null : system.copy(); dst.value = value == null ? null : value.copy(); dst.period = period == null ? null : period.copy(); dst.assigner = assigner == null ? null : assigner.copy(); return dst; }
public void enrichDatasetFromDocumentManifest(DocumentManifest documentManifest) { Reference reference = documentManifest.getSubject(); getPatientIds().add(reference.getResource() != null ? reference.getResource().getIdElement().getValue() : reference.getReference()); // If available, use the documentManifest identifier as documentManifestUuid if (!documentManifest.getIdentifier().isEmpty()) { this.documentManifestUuid = documentManifest.getIdentifier().get(0).getValue(); } } }
public org.hl7.fhir.instance.model.Identifier convertIdentifier(org.hl7.fhir.r4.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.instance.model.Identifier tgt = new org.hl7.fhir.instance.model.Identifier(); copyElement(src, tgt); if (src.hasUse()) tgt.setUse(convertIdentifierUse(src.getUse())); if (src.hasType()) tgt.setType(convertCodeableConcept(src.getType())); if (src.hasSystem()) tgt.setSystem(src.getSystem()); if (src.hasValue()) tgt.setValue(src.getValue()); if (src.hasPeriod()) tgt.setPeriod(convertPeriod(src.getPeriod())); if (src.hasAssigner()) tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public static org.hl7.fhir.dstu2016may.model.Identifier convertIdentifier(org.hl7.fhir.r4.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.dstu2016may.model.Identifier tgt = new org.hl7.fhir.dstu2016may.model.Identifier(); copyElement(src, tgt); tgt.setUse(convertIdentifierUse(src.getUse())); tgt.setType(convertCodeableConcept(src.getType())); if (src.hasSystem()) tgt.setSystem(src.getSystem()); if (src.hasValue()) tgt.setValue(src.getValue()); tgt.setPeriod(convertPeriod(src.getPeriod())); tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public static org.hl7.fhir.r4.model.Identifier convertIdentifier(org.hl7.fhir.dstu2016may.model.Identifier src) throws FHIRException { if (src == null || src.isEmpty()) return null; org.hl7.fhir.r4.model.Identifier tgt = new org.hl7.fhir.r4.model.Identifier(); copyElement(src, tgt); tgt.setUse(convertIdentifierUse(src.getUse())); tgt.setType(convertCodeableConcept(src.getType())); if (src.hasSystem()) tgt.setSystem(src.getSystem()); if (src.hasValue()) tgt.setValue(src.getValue()); tgt.setPeriod(convertPeriod(src.getPeriod())); tgt.setAssigner(convertReference(src.getAssigner())); return tgt; }
public static void merge(Identifier dst, Identifier src) { if (dst.getUseElement() == null && src.getUseElement() != null) dst.setUseElement(src.getUseElement()); if (dst.getType() == null && src.getType() != null) dst.setType(src.getType()); if (dst.getPeriod() == null && src.getPeriod() != null) dst.setPeriod(src.getPeriod()); if (dst.getAssigner() == null && src.getAssigner() != null) dst.setAssigner(src.getAssigner()); }
public static String getOID(CodeSystem cs) { if (cs.hasIdentifier() && "urn:ietf:rfc:3986".equals(cs.getIdentifierFirstRep().getSystem()) && cs.getIdentifierFirstRep().hasValue() && cs.getIdentifierFirstRep().getValue().startsWith("urn:oid:")) return cs.getIdentifierFirstRep().getValue().substring(8); return null; }