Package be.ehealth.businessconnector.therlink.builders.impl

# Class CommonObjectBuilderImpl

java.lang.Object
be.ehealth.businessconnector.therlink.builders.impl.CommonObjectBuilderImpl

All Implemented Interfaces:
  `CommonObjectBuilder`

public final class CommonObjectBuilderImpl extends Object implements CommonObjectBuilder
Implementation for `CommonObjectBuilder` requires following config property : kmehr.therlink.identifier.id.idhcparty ( or kmehr.default.identifier.id.idhcparty if default properties for kmehr are used )

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `CommonObjectBuilderImpl()`

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Author`
  `createAuthor(List<HcParty> list)`
  Creates the author part of the message
  `String`
  `createKmehrID()`
  Creates the id of the kmehr message
  `TherapeuticLink`
  `createTherapeuticLink(Patient patient, String hcpType, String therLinkType, Instant startDate, Instant endDate, String comment, HcParty hcp)`
  Deprecated.
  `TherapeuticLink`
  `createTherapeuticLink(Instant startDate, Instant endDate, Patient patient, String hcpType, String therLinkType, String comment, HcParty concernedHcp)`
  Creates a therapeutic link

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

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

- ## Constructor Details

  - ### CommonObjectBuilderImpl

    public CommonObjectBuilderImpl()

- ## Method Details

  - ### createTherapeuticLink

    @Deprecated public TherapeuticLink createTherapeuticLink(Patient patient, String hcpType, String therLinkType, Instant startDate, Instant endDate, String comment, HcParty hcp) throws TechnicalConnectorException
    Deprecated.
    Description copied from interface: `CommonObjectBuilder`
    Creates a therapeutic link
    Specified by:
      `createTherapeuticLink` in interface `CommonObjectBuilder`
    Parameters:
      `patient` - the concerned patient
      `hcpType` - the type of the professional concerned by the therapeutic link
      `therLinkType` - the type of the therapeutic link
      `startDate` - the start date
      `endDate` - (optional) the end date
      `comment` - (optional) a comment about the therapeutic link
      `hcp` - The HCP concerned by the link. If it's null, then we will use session info by default
    Returns:
    Throws:
      `TechnicalConnectorException` - Deprecated : replaced by the other function

  - ### createAuthor

    public Author createAuthor(List<HcParty> list) throws TechnicalConnectorException
    Description copied from interface: `CommonObjectBuilder`
    Creates the author part of the message
    Specified by:
      `createAuthor` in interface `CommonObjectBuilder`
    Parameters:
      `list` - list of professionals to add in the author part
    Returns:
    Throws:
      `TechnicalConnectorException`

  - ### createKmehrID

    public String createKmehrID() throws TechnicalConnectorException
    Description copied from interface: `CommonObjectBuilder`
    Creates the id of the kmehr message
    Specified by:
      `createKmehrID` in interface `CommonObjectBuilder`
    Returns:
    Throws:
      `TechnicalConnectorException`

  - ### createTherapeuticLink

    public TherapeuticLink createTherapeuticLink(Instant startDate, Instant endDate, Patient patient, String hcpType, String therLinkType, String comment, HcParty concernedHcp) throws TechnicalConnectorException
    Description copied from interface: `CommonObjectBuilder`
    Creates a therapeutic link
    Specified by:
      `createTherapeuticLink` in interface `CommonObjectBuilder`
    Parameters:
      `startDate` - the start date
      `endDate` - (optional) the end date
      `patient` - the concerned patient
      `hcpType` - the type of the professional concerned by the therapeutic link
      `therLinkType` - the type of the therapeutic link
      `comment` - (optional) a comment about the therapeutic link
      `concernedHcp` - The HCP concerned by the link. If it's null, then we will use session info by default
    Returns:
    Throws:
      `TechnicalConnectorException`
    See Also:
      - `CommonObjectBuilder.createTherapeuticLink(be.ehealth.business.common.domain.Patient, java.lang.String, java.lang.String, java.time.Instant, java.time.Instant, java.lang.String, be.ehealth.businessconnector.therlink.domain.HcParty)`