<commit_before>package com.jayrave.falkon.engine

data class DbEvent private constructor(val type: Type, val tableNames: Iterable<String>) {

    enum class Type {
        INSERT,
        UPDATE,
        DELETE
    }


    companion object {
        fun forInsert(tableName: String) = DbEvent(Type.INSERT, listOf(tableName))
        fun forUpdate(tableName: String) = DbEvent(Type.UPDATE, listOf(tableName))
        fun forDelete(tableName: String) = DbEvent(Type.DELETE, listOf(tableName))
    }
}


interface DbEventListener {
    fun onEvent(dbEvent: DbEvent)<commit_msg>DbEvent takes in just one table name instead of a collection of them<commit_after>package com.jayrave.falkon.engine

data class DbEvent private constructor(val type: Type, val tableName: String) {

    enum class Type {
        INSERT,
        UPDATE,
        DELETE
    }


    companion object {
        fun forInsert(tableName: String) = DbEvent(Type.INSERT, tableName)
        fun forUpdate(tableName: String) = DbEvent(Type.UPDATE, tableName)
        fun forDelete(tableName: String) = DbEvent(Type.DELETE, tableName)
    }
}


interface DbEventListener {
    fun onEvent(dbEvent: DbEvent)
{'fraction_non_alphanumeric': 0.08732876712328767, 'fraction_numerical': 0.0, 'mean_word_length': 3.3136531365313653, 'pattern_counts': {'":': 0, '<': 4, '<?xml version=': 0, '>': 4, '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': '1218695', 'n_tokens_mistral': 368, 'n_tokens_neox': 336, 'n_words': 91}