question: private static BinlogEventV4 formDWDataEvent ( long tableId , int eventType , List < MySqlValue > valueList ) { BinlogEventV4HeaderImpl eventV4Header = new BinlogEventV4HeaderImpl ( ) ; eventV4Header . setTimestamp ( System . currentTimeMillis ( ) ) ; eventV4Header . setEventType ( eventType ) ; eventV4Header . setServerId ( 1 ) ; if ( eventType == MySQLConstants . WRITE_ROWS_EVENT_V2 ) { WriteRowsEventV2 writeRowsEventV2 = new WriteRowsEventV2 ( eventV4Header ) ; writeRowsEventV2 . setTableId ( tableId ) ; writeRowsEventV2 . setRows ( getRows ( valueList ) ) ; return writeRowsEventV2 ; } else if ( eventType == MySQLConstants . WRITE_ROWS_EVENT ) { WriteRowsEvent writeRowsEvent = new WriteRowsEvent ( eventV4Header ) ; writeRowsEvent . setTableId ( tableId ) ; writeRowsEvent . setRows ( getRows ( valueList ) ) ; return writeRowsEvent ; } else if ( eventType == MySQLConstants . DELETE_ROWS_EVENT_V2 ) { DeleteRowsEventV2 deleteRowsEventV2 = new DeleteRowsEventV2 ( eventV4Header ) ; deleteRowsEventV2 . setTableId ( tableId ) ; deleteRowsEventV2 . setRows ( getRows ( valueList ) ) ; return deleteRowsEventV2 ; } else if ( eventType == MySQLConstants . DELETE_ROWS_EVENT ) { DeleteRowsEvent deleteRowsEvent = new DeleteRowsEvent ( eventV4Header ) ; deleteRowsEvent . setTableId ( tableId ) ; deleteRowsEvent . setRows ( getRows ( valueList ) ) ; return deleteRowsEvent ; } return null ; }
target:  This creates the Data Event based on the parameters passed. Delete/Write Only.