Class PixV3Query

All Implemented Interfaces:
org.apache.camel.CamelContextAware

@Component public class PixV3Query extends PixPdqV3QueryBase
PixV3Query

PixV3Query implements the Actor Patient Identity Source from ITI-44 Patient Identity Feed HL7 V3 and the Actor Patient Identifier Cross-reference Consumer from ITI-45 PIXV3 Query

  • Constructor Details

    • PixV3Query

      public PixV3Query()
    • PixV3Query

      public PixV3Query(AffinityDomain affinityDomain, String homeCommunityOid, org.apache.camel.CamelContext context, org.openehealth.ipf.commons.audit.AuditContext auditContext)
    • PixV3Query

      public PixV3Query(AffinityDomain affinityDomain, String homeCommunityOid, String homeCommunityNamespace, String domainToReturnOid, String domainToReturnNamespace, org.apache.camel.CamelContext context, org.openehealth.ipf.commons.audit.AuditContext auditContext)
  • Method Details

    • queryPatientId

      public List<String> queryPatientId(FhirPatient patient, List<String> queryDomainOids, List<String> queryDomainNamespaces, SecurityHeaderElement assertion, String messageId)
      query the mpi with patient id and return the ids in the queried domains from the mpi.

      Implements ITI-45 Patient Identifier Cross-reference Consumer Queries the Patient Identifier Cross-reference Manager for a list of corresponding patientidentifiers, if any

      Parameters:
      patient - the patient
      queryDomainOids - the query domain oids
      queryDomainNamespaces - the query domain namespaces
      assertion - a security header element for example an assertion
      messageId - a id preset or null, if the id shall be generated
      Returns:
      the list of string
    • addPatient

      public boolean addPatient(FhirPatient patient, SecurityHeaderElement assertion, String messageId)
      adds a patient to the mpi. implements ITI-44 Patient Identity Source – Add Patient Record
      Parameters:
      patient - the patient
      assertion - a security header element for example an assertion
      Returns:
      true, if successful
    • mergePatient

      public boolean mergePatient(FhirPatient patient, String obsoleteId, SecurityHeaderElement assertion, String messageId)
      Merge patient. implements ITI-44 Patient Identity Source – Patient Identity Merge

      Patient Registry Duplicates Resolved message indicates that the Patient Identity Source has done a merge within a specific Patient Identification Domain. That is, the surviving identifier (patient ID) has subsumed a duplicate patient identifier.

      Parameters:
      patient - the patient (with the surviving identifier)
      obsoleteId - the obsolete id (duplicate patient identifier)
      assertion - a security header element for example an assertion
      Returns:
      true, if successful
    • updatePatient

      public boolean updatePatient(FhirPatient patient, SecurityHeaderElement assertion, String messageId)
      updates the demographic information of the patient in the mpi.

      implements ITI-44 Patient Identity Source – Revise Patient Record updates the demographic information of the patient in the mpi.

      Parameters:
      patient - the patient
      assertion - a security header element for example an assertion
      Returns:
      true, if successful
    • checkResponse

      protected boolean checkResponse(V3Acknowledgement response)
      Checks the response, error are logged.
      Parameters:
      response - the response
      Returns:
      true, if response has no error, false if there are errors
    • queryPatientId

      public String queryPatientId(FhirPatient patient, SecurityHeaderElement assertion, String messageId)
      Query patient id.
      Parameters:
      patient - the patient
      assertion - a security header element for example an assertion
      Returns:
      the string
    • getHomeCommunityPatientId

      protected String getHomeCommunityPatientId(FhirPatient patient)
      Gets the home community patient id.
      Parameters:
      patient - the patient
      Returns:
      the home community patient id
    • getPatientDomainId

      public String getPatientDomainId(org.openehealth.ipf.commons.ihe.hl7v3.core.responses.PixV3QueryResponse v3PixConsumerResponse, String rootOid)
      Gets the patient domain id.
      Parameters:
      v3PixConsumerResponse - the v3 pix consumer response
      rootOid - the root oid
      Returns:
      the patient domain id