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

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

public struct CdnDeliveryV2ResponseResourceData: Content, Hashable {

    public var qualityLevels: [CdnDeliveryV2ResponseResourceDataQualityLevels]?
    public var qualityLevelParams: [String: CdnDeliveryV2ResponseResourceDataQualityLevelParams]?
    public var token: String?

    public init(qualityLevels: [CdnDeliveryV2ResponseResourceDataQualityLevels]? = nil, qualityLevelParams: [String: CdnDeliveryV2ResponseResourceDataQualityLevelParams]? = nil, token: String? = nil) {
        self.qualityLevels = qualityLevels
        self.qualityLevelParams = qualityLevelParams
        self.token = token
    }

    public enum CodingKeys: String, CodingKey, CaseIterable {
        case qualityLevels
        case qualityLevelParams
        case token
    }

    // Encodable protocol methods

    public func encode(to encoder: Encoder) throws {
        var container = encoder.container(keyedBy: CodingKeys.self)
        try container.encodeIfPresent(qualityLevels, forKey: .qualityLevels)
        try container.encodeIfPresent(qualityLevelParams, forKey: .qualityLevelParams)
        try container.encodeIfPresent(token, forKey: .token)
    }
}

