package com.file.util;
import java.io.File;
import java.util.ArrayList;
import java.util.List;
import com.video.videoPath.VideopathDAO;
public class FileUtil {
/*
* 判断目录是否为空 true 表示存在 path传入要判断的文件目录
*/
public boolean dirisemp(String path) {
boolean isnotemp = false;
File file = new File(path);
if (file.exists()) {
isnotemp = true;
}
return isnotemp;
}
/*
* 创建目录 true表示创建成功 path传入要创建的文件目录
*/
public boolean creatdir(String path) {
File creatdir = new File(path);
boolean creatok = false;
if (creatdir.mkdir()) {
creatok = true;
}
return creatok;
}
/*
* 判断是否有重名文件 path要比较的文件目录 upfile要比较的文件名
*/
public boolean Juna_file(String path, String upfile) {
boolean ejuna_file = false;
File juna_file