<commit_before>//
//  Entity.swift
//  Haneke
//
//  Created by <NAME> on 9/9/14.
//  Copyright (c) 2014 Haneke. All rights reserved.
//

import UIKit

public protocol Entity {

    var key : String { get }
    
    func fetchImageWithSuccess(success doSuccess : (UIImage) -> (), failure doFailure : ((NSError?) -> ()))
    
    func cancelFetch()
}

class SimpleEntity : Entity {
    
    let key : String<commit_msg>Make Entity a @objc class protocol<commit_after>//
//  Entity.swift
//  Haneke
//
//  Created by <NAME> on 9/9/14.
//  Copyright (c) 2014 Haneke. All rights reserved.
//

import UIKit

@objc
// Entity must be class and @objc to be associated with UIImageView. When Swift supports stored properties we might be able to change it.
public protocol Entity : class {

    var key : String { get }
    
    func fetchImageWithSuccess(success doSuccess : (UIImage) -> (), failure doFailure : ((NSError?) -> ()))
    
    func cancelFetch()
}

class SimpleEntity : Entity {
    
    let key : String
{'fraction_non_alphanumeric': 0.12091179385530228, 'fraction_numerical': 0.015857284440039643, 'mean_word_length': 2.672727272727273, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4510122', 'n_tokens_mistral': 334, 'n_tokens_neox': 312, 'n_words': 107}