Files
ContainerController/ContainerControllerSwift/ContainerCollection/CollectionAdapterItem.swift
T
2020-06-09 23:01:58 +03:00

30 lines
681 B
Swift
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
//
// ColletionAdapterItem.swift
// PatternsSwift
//
// Created by Рустам Мотыгуллин on 01/05/2020.
// Copyright © 2020 mrusta. All rights reserved.
//
import UIKit
open class CollectionAdapterItem: NSObject {
public let cellClass: AnyClass
public let cellData: CollectionAdapterCellData?
public var cellReuseIdentifier: String {
return String(describing: cellClass)
}
init(cellClass: AnyClass, cellData: CollectionAdapterCellData? = nil) {
self.cellClass = cellClass
self.cellData = cellData
}
public func size() -> CGSize {
return cellData?.size() ?? CGSize.zero
}
}