//
//  InterstitialAdModel.swift
//  sdk-demo-ios
//
//  Created by Smaato Inc on 22.02.19.
//  Copyright © 2019 Smaato Inc. All rights reserved.
//

import Foundation

struct InterstitialAdModel: AdModel {
    var adSpaceId: String
    var name: String

    init(adSpaceId: String, name: String) {
        self.adSpaceId = adSpaceId
        self.name = name
    }

    init?(dictionary: [String: Any]) {
        guard let adSpaceId = dictionary["adSpaceId"] as? String,
              let name = dictionary["name"] as? String else {
            return nil
        }
        self.init(adSpaceId: adSpaceId, name: name)
    }
}
