Package be.ehealth.businessconnector.dmg.builders.impl

# Class RequestObjectBuilderImpl

java.lang.Object
be.ehealth.businessconnector.dmg.builders.impl.RequestObjectBuilderImpl

All Implemented Interfaces:
  `RequestObjectBuilder`, `ConfigurationModuleBootstrap.ModuleBootstrapHook`

public class RequestObjectBuilderImpl extends Object implements RequestObjectBuilder, ConfigurationModuleBootstrap.ModuleBootstrapHook
Implementation for the `RequestObjectBuilder` interface. Implements : `RequestObjectBuilder`

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `RequestObjectBuilderImpl()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `void`
  `bootstrap()`
  `ConsultGlobalMedicalFileRequest`
  `buildSendConsultRequest(boolean isTest, DMGReferences references, Patient patientInfo, Instant referenceDate, be.fgov.ehealth.messageservices.core.v1.SelectRetrieveTransaction request)`
  * Creates the ConsultGlobalMedicalFileRequest that will be sent to the EHealth Web service and checks validity against the corresponding XSD
  `final ConsultGlobalMedicalFileRequest`
  `buildSendConsultRequest(boolean isTest, String referenceId, Patient patientInfo, Instant referenceDate, Blob blob, byte[] xades)`
  Creates the ConsultGlobalMedicalFileRequest that will be sent to the EHealth Web service and checks validity against the corresponding XSD
  `NotifyGlobalMedicalFileRequest`
  `buildSendNotifyRequest(boolean isTest, DMGReferences references, Patient patientInfo, Instant referenceDate, Kmehrmessage msg)`
  Creates the NotifyGlobalMedicalFileRequest that will be sent to the EHealth web service and checks validity against the corresponding XSD.
  `final NotifyGlobalMedicalFileRequest`
  `buildSendNotifyRequest(boolean isTest, String referenceId, Patient patientInfo, Instant referenceDate, Blob blob, byte[] xades)`
  Creates the NotifyGlobalMedicalFileRequest that will be sent to the EHealth web service and checks validity against the corresponding XSD.

  ### Methods inherited from class java.lang.Object

  `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### RequestObjectBuilderImpl

    public RequestObjectBuilderImpl()

- ## Method Details

  - ### buildSendConsultRequest

    public final ConsultGlobalMedicalFileRequest buildSendConsultRequest(boolean isTest, String referenceId, Patient patientInfo, Instant referenceDate, Blob blob, byte[] xades) throws TechnicalConnectorException, DmgBusinessConnectorException, InstantiationException
    Description copied from interface: `RequestObjectBuilder`
    Creates the ConsultGlobalMedicalFileRequest that will be sent to the EHealth Web service and checks validity against the corresponding XSD
    Specified by:
      `buildSendConsultRequest` in interface `RequestObjectBuilder`
    Parameters:
      `isTest` - indicates if this is a test or not
      `referenceId` - String containing referenceId
      `patientInfo` - contains the information about the patient
      `referenceDate` - the reference date
      `blob` - Base64 encoded detail of the request
      `xades` - byteArray containing the Xades signature (nullable)
    Returns:
      the valid request that will be sent to the WS
    Throws:
      `TechnicalConnectorException`
      `DmgBusinessConnectorException`
      `InstantiationException`
    See Also:
      - `RequestObjectBuilder.buildSendConsultRequest(boolean, be.ehealth.businessconnector.dmg.domain.DmgReferences, be.ehealth.businessconnector.dmg.domain.PatientInfo, java.time.Instant, Blob, byte[])`

  - ### buildSendConsultRequest

    public ConsultGlobalMedicalFileRequest buildSendConsultRequest(boolean isTest, DMGReferences references, Patient patientInfo, Instant referenceDate, be.fgov.ehealth.messageservices.core.v1.SelectRetrieveTransaction request) throws TechnicalConnectorException, DmgBusinessConnectorException, InstantiationException
    Description copied from interface: `RequestObjectBuilder`
    * Creates the ConsultGlobalMedicalFileRequest that will be sent to the EHealth Web service and checks validity against the corresponding XSD
    Specified by:
      `buildSendConsultRequest` in interface `RequestObjectBuilder`
    Parameters:
      `isTest` - indicates if this is a test or not
      `references` -
      invalid reference

          DmgReferences

      contains the reference ids
      `patientInfo` - contains the information about the patient
      `referenceDate` - the reference date
    Returns:
    Throws:
      `TechnicalConnectorException`
      `DmgBusinessConnectorException`
      `InstantiationException`
    See Also:
      - invalid reference

            be.ehealth.businessconnector.dmg.builders.RequestObjectBuilder#buildSendConsultRequest(boolean, be.ehealth.businessconnector.dmg.domain.DMGReferences, be.ehealth.business.common.domain.Patient, java.time.Instant, be.fgov.ehealth.messageservices.core.v1.RetrieveTransactionRequest)

  - ### buildSendNotifyRequest

    public final NotifyGlobalMedicalFileRequest buildSendNotifyRequest(boolean isTest, String referenceId, Patient patientInfo, Instant referenceDate, Blob blob, byte[] xades) throws TechnicalConnectorException, DmgBusinessConnectorException, InstantiationException
    Description copied from interface: `RequestObjectBuilder`
    Creates the NotifyGlobalMedicalFileRequest that will be sent to the EHealth web service and checks validity against the corresponding XSD.
    Specified by:
      `buildSendNotifyRequest` in interface `RequestObjectBuilder`
    Parameters:
      `isTest` - indicates if this is a test or not
      `referenceId` - String containing the reference id.
      `patientInfo` - contains the information about the patient
      `referenceDate` - the reference date
      `blob` - Base64 encoded detail of the request
      `xades` - byteArray containing the Xades signature (nullable)
    Returns:
      the valid request that will be sent to the WS
    Throws:
      `TechnicalConnectorException`
      `DmgBusinessConnectorException`
      `InstantiationException`
    See Also:
      - `RequestObjectBuilder.buildSendNotifyRequest(boolean, be.ehealth.businessconnector.dmg.domain.DmgReferences, be.ehealth.businessconnector.dmg.domain.PatientInfo, java.time.Instant, Blob, byte[])`

  - ### buildSendNotifyRequest

    public NotifyGlobalMedicalFileRequest buildSendNotifyRequest(boolean isTest, DMGReferences references, Patient patientInfo, Instant referenceDate, Kmehrmessage msg) throws TechnicalConnectorException, DmgBusinessConnectorException, InstantiationException
    Description copied from interface: `RequestObjectBuilder`
    Creates the NotifyGlobalMedicalFileRequest that will be sent to the EHealth web service and checks validity against the corresponding XSD.
    Specified by:
      `buildSendNotifyRequest` in interface `RequestObjectBuilder`
    Parameters:
      `isTest` - indicates if this is a test or not
      `references` -
      invalid reference

          DmgReferences

      contains the reference ids
      `patientInfo` - contains the information about the patient
      `referenceDate` - the reference date
      `msg` - `Kmehrmessage` contains the business KmehrMessage
    Returns:
      the valid request that will be sent to the WS
    Throws:
      `TechnicalConnectorException`
      `DmgBusinessConnectorException`
      `InstantiationException`

  - ### bootstrap

    public void bootstrap()
    Specified by:
      `bootstrap` in interface `ConfigurationModuleBootstrap.ModuleBootstrapHook`