加入收藏 | 设为首页 | 会员中心 | 我要投稿 李大同 (https://www.lidatong.com.cn/)- 科技、建站、经验、云计算、5G、大数据,站长网!
当前位置: 首页 > 百科 > 正文

swift – 不是BOMStorage文件

发布时间:2020-12-14 02:23:50 所属栏目:百科 来源:网络整理
导读:当使用带有大量包含图像的单元格的UICollectionView时,只要屏幕上的单元格滚动到屏幕上,我就会在日志中收到奇怪的警告: 2015-11-06 15:50:20.777 MyApp[49415:13109991] [/BuildRoot/Library/Caches/com.apple.xbs/Sources/CoreUI_Sim/CoreUI-370.8/Bom/Sto
当使用带有大量包含图像的单元格的UICollectionView时,只要屏幕上的单元格滚动到屏幕上,我就会在日志中收到奇怪的警告:
2015-11-06 15:50:20.777 MyApp[49415:13109991] [/BuildRoot/Library/Caches/com.apple.xbs/Sources/CoreUI_Sim/CoreUI-370.8/Bom/Storage/BOMStorage.c:517] <memory> is not a BOMStorage file

这是单元设置:

import UIKit

class FeaturedCell: UICollectionViewCell {

    @IBOutlet weak var imageView: UIImageView!
    @IBOutlet weak var activityIndicator: UIActivityIndicatorView!

    private var xml: XMLIndexer? = nil

    override func awakeFromNib() {
        super.awakeFromNib()

        // this enables the parallax type look
        self.imageView.adjustsImageWhenAncestorFocused = true
        self.imageView.clipsToBounds = false
    }

    func loadImageFromUrlString(str: String) {
        if let url = NSURL(string: str) {
            if let data = NSData(contentsOfURL: url){
                let image = UIImage(data: data)
                self.imageView.image = image

                self.activityIndicator.stopAnimating();
            }
        }
    }

    func setXml(xml: XMLIndexer) {
        self.xml = xml;

        if let imageUrl: String = (xml["FullAd"].element?.text)! {
            self.loadImageFromUrlString(imageUrl)
        }
    }

}
根据 this thread,这个消息是无害的.

(编辑:李大同)

【声明】本站内容均来自网络,其相关言论仅代表作者个人观点,不代表本站立场。若无意侵犯到您的权利,请及时与联系站长删除相关内容!

    推荐文章
      热点阅读