<commit_before>//
//  Extensions.swift
//  Sourcery
//
//  Created by <NAME> on 27/04/16.
//  Copyright © 2016 Nodes ApS. All rights reserved.
//

import UIKit

// MARK: - UITableView -

public extension UITableView {

    // MARK: Register

    public func registerCellType(cellType: TableViewPresentable.Type) {
        self.registerNib(cellType.nib, forCellReuseIdentifier: cellType.reuseIdentifier)
    }

    public func registerCellType<T where T: TableViewPresentable>(cellType: T.Type) {
        self.registerNib(cellType.nib, forCellReuseIdentifier: cellType.reuseIdentifier)
    }

    public func registerCellTypes(cellTypes: [TableViewPresentable.Type]) {
        for cell in cellTypes {<commit_msg>Support for cell types without nib<commit_after>//
//  Extensions.swift
//  Sourcery
//
//  Created by <NAME> on 27/04/16.
//  Copyright © 2016 Nodes ApS. All rights reserved.
//

import UIKit

// MARK: - UITableView -

public extension UITableView {

    // MARK: Register

    public func registerCellType(cellType: TableViewPresentable.Type) {
        if cellType.loadsFromNib {
            self.registerNib(cellType.nib, forCellReuseIdentifier: cellType.reuseIdentifier)
        } else {
            self.registerClass(cellType, forCellReuseIdentifier: cellType.reuseIdentifier)
        }
    }

    public func registerCellType<T where T: TableViewPresentable>(cellType: T.Type) {
        if cellType.loadsFromNib {
            self.registerNib(cellType.nib, forCellReuseIdentifier: cellType.reuseIdentifier)
        } else {
            self.registerClass(cellType, forCellReuseIdentifier: cellType.reuseIdentifier)
        }
    }

    public func registerCellTypes(cellTypes: [TableViewPresentable.Type]) {
        for cell in cellTypes {
{'fraction_non_alphanumeric': 0.09447922595332954, 'fraction_numerical': 0.011383039271485486, 'mean_word_length': 3.0694444444444446, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, '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': '4038706', 'n_tokens_mistral': 559, 'n_tokens_neox': 519, 'n_words': 117}