public org.hl7.fhir.instance.model.Identifier convertIdentifier(org.hl7.fhir.dstu3.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 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; }
/** * Handles the PIXm Retrieve. Note that this is not part of the specification, but a useful variant that allows to use resource IDs * in requests such as .../Patient/4711/$ihe-pix would be equivalent with .../Patient/$ihe-pix?sourceIdentifier=URI|4711 where URI * identifies the NamingSystem used for resource IDs * * @param resourceId resource ID * @param targetSystemParam target system URI * @param httpServletRequest servlet request * @param httpServletResponse servlet response * @return {@link Parameters} containing found identifiers */ @Operation(name = Iti83Constants.PIXM_OPERATION_NAME, type = Patient.class, idempotent = true, returnParameters = {@OperationParam(name = "return", type = Identifier.class, max = 100)}) public Parameters pixmRetrieve( @IdParam IdType resourceId, @OperationParam(name = TARGET_SYSTEM_NAME) UriParam targetSystemParam, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { UriType targetUri = targetSystemParam == null ? null : new UriType(targetSystemParam.getValue()); Parameters inParams = new Parameters(); inParams.addParameter().setName(SOURCE_IDENTIFIER_NAME).setValue(new Identifier().setValue(resourceId.getIdPart())); inParams.addParameter().setName(TARGET_SYSTEM_NAME).setValue(targetUri); // Run down the route return requestResource(inParams, Parameters.class, httpServletRequest, httpServletResponse); } }
/** * Handles the PIXm Query * * @param sourceIdentifierParam Identifier to search for. Should be an {@link Identifier}, but obviously * non-primitive types are forbidden in GET operations * @param targetSystemParam target system URI * @return {@link Parameters} containing found identifiers */ @SuppressWarnings("unused") @Operation(name = Iti83Constants.PIXM_OPERATION_NAME, type = Patient.class, idempotent = true, returnParameters = {@OperationParam(name = "return", type = Identifier.class, max = 100)}) public Parameters pixmQuery( @OperationParam(name = SOURCE_IDENTIFIER_NAME) TokenParam sourceIdentifierParam, @OperationParam(name = TARGET_SYSTEM_NAME) UriParam targetSystemParam, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { Identifier sourceIdentifier = new Identifier() .setSystem(sourceIdentifierParam.getSystem()) .setValue(sourceIdentifierParam.getValue()); UriType targetUri = targetSystemParam == null ? null : new UriType(targetSystemParam.getValue()); Parameters inParams = new Parameters(); inParams.addParameter().setName(SOURCE_IDENTIFIER_NAME).setValue(sourceIdentifier); inParams.addParameter().setName(TARGET_SYSTEM_NAME).setValue(targetUri); // Run down the route return requestResource(inParams, Parameters.class, httpServletRequest, httpServletResponse); }
public org.hl7.fhir.instance.model.Identifier convertIdentifier(org.hl7.fhir.dstu3.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 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; }
new Identifier() .setSystem("urn:ietf:rfc:3986") .setValue("urn:oid:129.6.58.92.88336")) .setCreated(timestamp)