<commit_before>package main.design.pattern.null_object;

/**
 * Title : main.design.pattern.null_object
 * Company : 北京华宇元典信息服务有限公司
 * Description :
 *  - 工厂类
 *  - 根据id, 返回book对象
 *
 * @author chile
 * @version 1.0
 * @date 2017/8/10 11:17
 */

public class BookFactory {

    public static Book getBook(String id) {
        Book book;
        switch (id) {
            case "1" :
                book = new ConcreteBook("1", "11111111");
                break;
            case "2" :
                book = new ConcreteBook("2", "22222222");
                break;
            default :
                book = new NullBook();
                break;
        }
        return book;
    }

}
<commit_msg>info : change access level of class `BookFactory` committer : chile<commit_after>package main.design.pattern.null_object;

/**
 * Title : main.design.pattern.null_object
 * Company : 北京华宇元典信息服务有限公司
 * Description :
 *  - 工厂类
 *  - 根据id, 返回book对象
 *
 * @author chile
 * @version 1.0
 * @date 2017/8/10 11:17
 */

class BookFactory {

    static Book getBook(String id) {
        Book book;
        switch (id) {
            case "1" :
                book = new ConcreteBook("1", "11111111");
                break;
            case "2" :
                book = new ConcreteBook("2", "22222222");
                break;
            default :
                book = new NullBook();
                break;
        }
        return book;
    }

}

{'fraction_non_alphanumeric': 0.11479944674965421, 'fraction_numerical': 0.04564315352697095, 'mean_word_length': 1.5520282186948853, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 4, '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': '6266742', 'n_tokens_mistral': 518, 'n_tokens_neox': 475, 'n_words': 106}