
import com.jfinal.kit.PropKit;
import com.jfinal.plugin.activerecord.ActiveRecordPlugin;
import com.jfinal.plugin.activerecord.Db;
import com.jfinal.plugin.activerecord.Record;
import com.jfinal.plugin.c3p0.C3p0Plugin;
import com.jfinal.plugin.druid.DruidPlugin;
import com.model.Jieyue;
import com.model._MappingKit;
import com.utils.PicUtils;
import org.apache.commons.io.FileUtils;

import java.io.File;
import java.util.ArrayList;
import java.util.List;


public class HkcTest {

    public static void suoxiaoPic(File file, double num) throws Exception{

        i++;
        if(file.length()>81920){
            double tempnum  = num*0.9;
            String targetFilePath = "/Users/tianlumei/Desktop/"+i+".jpg";
            File targetFile = new File(targetFilePath);
            if(targetFile.exists()){
                targetFile.delete();
            }
            PicUtils pu = new PicUtils(file.getPath(), targetFilePath);
            pu.zoomByScale(tempnum);
            if(targetFile.length()>81920){
                suoxiaoPic(file, tempnum);
            }

        }
    }
    static int i = 0;
    public static void main(String args[]){
        //70:DE:BB:76:50:01:04:E0
        /*String str = "70:DE:BB:76:50:01:04:E0"; //E004015076BBDE70
        String result = changeUid(str);
        System.out.println(result);*/

    }








}
