package com.eversec.dbq.stattask;

import com.eversec.dbq.E;

import java.util.List;

public class StatTaskToMySql extends StatTaskAbs implements StatTask{

    public StatTaskToMySql(E e) {
        super(e);
    }

    @Override
    public void dataToDb() {
        Object query = query();

        String tableName = getE().tableName;
        //data insert mysql db;  如：insert into
        if ("list".equalsIgnoreCase(getE().restType)){
            ((List) query).forEach(x->{
                // todo:  same as map
            });
        }else if ("map".equalsIgnoreCase(getE().restType)){
            // todo:
        }
    }
}
