EhrPatient

public struct EhrPatient : Codable, Equatable

The base structure for an EHR Patient

  • First name of patient (often called Given Name)

    Declaration

    Swift

    public var firstName: String
  • Last name of patient (often call surname or family name)

    Declaration

    Swift

    public var lastName: String
  • male, female, other

    Declaration

    Swift

    public var gender: Gender
  • The patient’s date of birth

    Important

    dateOfBirth will be converted to a string with GMT:0 when pushed to the server Therefore it’s important that any Date object that gets set here, must be set with a timezone of GMT:0 .

    Declaration

    Swift

    public var dateOfBirth: Date
  • A phone number which the patient can be contact with

    Declaration

    Swift

    public var phone: String
  • The patients email address

    Declaration

    Swift

    public var email: String
  • Address of the patient

    Declaration

    Swift

    public var address: Address
  • An identifier of the patient record in Epic.

    Declaration

    Swift

    public var ehrIdentifier: String?
  • The type of identifier being sent in [ehrIdentifier], e.g. “MRN” or “EPI”.

    Declaration

    Swift

    public var ehrIdentifierType: String?
  • Home EHR code

    Declaration

    Swift

    public var homeEhr: String?
  • Undocumented

    Declaration

    Swift

    public init(
        firstName: String,
        lastName: String,
        gender: Gender,
        dateOfBirth: Date,
        phone: String,
        email: String,
        address: Address,
        ehrIdentifier: String?,
        ehrIdentifierType: String?,
        homeEhr: String?,
        homeMarket: String?
    )
  • a custom encoder used internally by DexcareSDK

    Declaration

    Swift

    public func encode(to encoder: Encoder) throws