// // HealthInsuranceSectionAllOf.swift // // Generated by openapi-generator // https://openapi-generator.tech // import Foundation #if canImport(AnyCodable) import AnyCodable #endif public struct HealthInsuranceSectionAllOf: Codable, Hashable { public enum InsuranceGroup: String, Codable, CaseIterable { case _1 = "1" case _2 = "2" } public var insuranceGroup: InsuranceGroup public var generalPractitioner: Person? public var generalPractitionerAddress: Address? public var generalPractitionerTelephoneNumber: String? public init(insuranceGroup: InsuranceGroup, generalPractitioner: Person? = nil, generalPractitionerAddress: Address? = nil, generalPractitionerTelephoneNumber: String? = nil) { self.insuranceGroup = insuranceGroup self.generalPractitioner = generalPractitioner self.generalPractitionerAddress = generalPractitionerAddress self.generalPractitionerTelephoneNumber = generalPractitionerTelephoneNumber } public enum CodingKeys: String, CodingKey, CaseIterable { case insuranceGroup case generalPractitioner case generalPractitionerAddress case generalPractitionerTelephoneNumber } // Encodable protocol methods public func encode(to encoder: Encoder) throws { var container = encoder.container(keyedBy: CodingKeys.self) try container.encode(insuranceGroup, forKey: .insuranceGroup) try container.encodeIfPresent(generalPractitioner, forKey: .generalPractitioner) try container.encodeIfPresent(generalPractitionerAddress, forKey: .generalPractitionerAddress) try container.encodeIfPresent(generalPractitionerTelephoneNumber, forKey: .generalPractitionerTelephoneNumber) } }