//
// FaqSectionModelFaqs.swift
//
// Generated by openapi-generator
// https://openapi-generator.tech
//

import Foundation
#if canImport(AnyCodable)
import AnyCodable
#endif
import Vapor

public struct FaqSectionModelFaqs: Content, Hashable {

    public enum Status: String, Content, Hashable, CaseIterable {
        case _public = "public"
    }
    public var createdAt: Date
    public var updatedAt: Date
    public var id: String
    public var question: String
    /** This field may contain HTML that should be rendered. */
    public var answer: String
    public var status: Status
    public var link: String
    public var order: Double
    public var faqSection: String

    public init(createdAt: Date, updatedAt: Date, id: String, question: String, answer: String, status: Status, link: String, order: Double, faqSection: String) {
        self.createdAt = createdAt
        self.updatedAt = updatedAt
        self.id = id
        self.question = question
        self.answer = answer
        self.status = status
        self.link = link
        self.order = order
        self.faqSection = faqSection
    }

    public enum CodingKeys: String, CodingKey, CaseIterable {
        case createdAt
        case updatedAt
        case id
        case question
        case answer
        case status
        case link
        case order
        case faqSection
    }

    // Encodable protocol methods

    public func encode(to encoder: Encoder) throws {
        var container = encoder.container(keyedBy: CodingKeys.self)
        try container.encode(createdAt, forKey: .createdAt)
        try container.encode(updatedAt, forKey: .updatedAt)
        try container.encode(id, forKey: .id)
        try container.encode(question, forKey: .question)
        try container.encode(answer, forKey: .answer)
        try container.encode(status, forKey: .status)
        try container.encode(link, forKey: .link)
        try container.encode(order, forKey: .order)
        try container.encode(faqSection, forKey: .faqSection)
    }
}

